Pull down chart field from StateBase.
This commit is contained in:
@@ -9,7 +9,7 @@ namespace Cryville.Crtr.Event {
|
|||||||
get;
|
get;
|
||||||
private set;
|
private set;
|
||||||
}
|
}
|
||||||
ContainerState RootState;
|
readonly Chart chart;
|
||||||
readonly Dictionary<ChartEvent, ContainerState> containerMap
|
readonly Dictionary<ChartEvent, ContainerState> containerMap
|
||||||
= new Dictionary<ChartEvent, ContainerState>();
|
= new Dictionary<ChartEvent, ContainerState>();
|
||||||
readonly Dictionary<EventContainer, ContainerState> stateMap
|
readonly Dictionary<EventContainer, ContainerState> stateMap
|
||||||
@@ -25,7 +25,8 @@ namespace Cryville.Crtr.Event {
|
|||||||
double beat;
|
double beat;
|
||||||
float tempo;
|
float tempo;
|
||||||
|
|
||||||
public EventBatcher(Chart c) : base(c, new List<ChartEvent>()) {
|
public EventBatcher(Chart c) : base(new List<ChartEvent>()) {
|
||||||
|
chart = c;
|
||||||
beat = chart.BeatPosition;
|
beat = chart.BeatPosition;
|
||||||
tempo = (float)c.sigs[0].tempo;
|
tempo = (float)c.sigs[0].tempo;
|
||||||
events.Add(c);
|
events.Add(c);
|
||||||
|
@@ -18,8 +18,7 @@ namespace Cryville.Crtr.Event {
|
|||||||
HashSet<ContainerState> invalidatedStates
|
HashSet<ContainerState> invalidatedStates
|
||||||
= new HashSet<ContainerState>();
|
= new HashSet<ContainerState>();
|
||||||
|
|
||||||
public EventBus(Chart c, ContainerState root, List<EventBatch> b)
|
public EventBus(ContainerState root, List<EventBatch> b) : base(b) {
|
||||||
: base(c, b) {
|
|
||||||
RootState = root;
|
RootState = root;
|
||||||
Expand();
|
Expand();
|
||||||
AttachBus();
|
AttachBus();
|
||||||
|
@@ -5,13 +5,11 @@ namespace Cryville.Crtr {
|
|||||||
public abstract class StateBase<T> {
|
public abstract class StateBase<T> {
|
||||||
public int EventId;
|
public int EventId;
|
||||||
public double Time;
|
public double Time;
|
||||||
public Chart chart;
|
|
||||||
public List<T> events;
|
public List<T> events;
|
||||||
|
|
||||||
bool breakflag = false;
|
bool breakflag = false;
|
||||||
|
|
||||||
public StateBase(Chart c, List<T> evs) {
|
public StateBase(List<T> evs) {
|
||||||
chart = c;
|
|
||||||
events = evs;
|
events = evs;
|
||||||
EventId = 0;
|
EventId = 0;
|
||||||
Time = 0;
|
Time = 0;
|
||||||
|
Reference in New Issue
Block a user