Code cleanup.

This commit is contained in:
2023-01-15 11:54:11 +08:00
parent 898fb7d557
commit 609bb317d0
5 changed files with 91 additions and 31 deletions

View File

@@ -125,7 +125,7 @@ namespace Cryville.Crtr.Event {
}
public override void ForwardOnceToTime(double toTime) {
double time1 = EventId < events.Count ? events[EventId].Time : double.PositiveInfinity;
double time1 = EventId < Events.Count ? Events[EventId].Time : double.PositiveInfinity;
double time2 = tempEvents.Count > 0 ? tempEvents[0].Time : double.PositiveInfinity;
double time0 = Math.Min(time1, time2);
if (time0 <= toTime && time0 != double.PositiveInfinity) {
@@ -133,7 +133,7 @@ namespace Cryville.Crtr.Event {
foreach (var s in workingStates) s.Handle(null);
ValidateStates();
if (time1 == time0) {
var batch = events[EventId];
var batch = Events[EventId];
for (var i = 0; i < batch.Count; i++) {
var ev = batch[i];
if (ev.Container != null) {