Make long motion events standalone to avoid transition overflow.

This commit is contained in:
2023-05-25 14:59:02 +08:00
parent 17042b6664
commit 5b510fa5da
2 changed files with 14 additions and 5 deletions

View File

@@ -48,10 +48,9 @@ namespace Cryville.Crtr.Event {
}
foreach (var ev in c.Events) {
if (ev.time == null) {
if (!ev.Standalone) coevents.Add(ev);
ev.time = c.time;
if (ev is EventContainer)
ev.endtime = c.endtime;
if (ev is EventContainer) ev.endtime = c.endtime;
if ((ev.CoeventMode & CoeventMode.Coevent) != 0) coevents.Add(ev);
}
if (ev.IsLong) {
Events.Add(ev.ReleaseEvent);
@@ -119,6 +118,9 @@ namespace Cryville.Crtr.Event {
coeventMap.Add(con, cevs = new List<StampedEvent>());
}
cevs.Add(sev);
if ((ev.CoeventMode & CoeventMode.Standalone) != 0) {
stampedEvents.Add(sev);
}
}
else stampedEvents.Add(sev);
map.Add(ev, sev);