Skip to content

Commit 9e95cb2

Browse files
committed
Fix #95: make sure animators re-activate when changing state (fixes props staying blank after recovering from power outage)
1 parent ae6b6e3 commit 9e95cb2

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

RasterPropMonitor/Auxiliary modules/JSICallbackAnimator.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -560,6 +560,7 @@ private void TurnOn()
560560
break;
561561
case Mode.Animation:
562562
onAnim[animationName].normalizedTime = reverse ? 0f : 1f;
563+
onAnim.Play();
563564
break;
564565
case Mode.LoopingAnimation:
565566
onAnim[animationName].speed = animationSpeed;
@@ -604,6 +605,7 @@ private void TurnOff()
604605
break;
605606
case Mode.Animation:
606607
onAnim[animationName].normalizedTime = reverse ? 1f : 0f;
608+
onAnim.Play();
607609
break;
608610
case Mode.LoopingAnimation:
609611
if (offAnim != null)

0 commit comments

Comments
 (0)