示例#1
0
 public GameModeBridge()
 {
     // This class is just a stub so that Distance's CarStateTransceiver has a valid bridge to isGo_
     // isGo_ needs to be true for Distance's CarStateTransceiver to do its work.
     // make isGo_ true:
     isStarted_ = true;
     PrivateUtilities.setPrivateProperty(typeof(Distance::Timex), null, "PhysicsFrameCount_", 0);
     StartPhysFrame_ = -1;
 }
示例#2
0
 public void Update()
 {
     ModeTime = Network.time + ModeTimeOffset;
     PrivateUtilities.setPrivateProperty(typeof(Distance::Timex), null, "ModeTime_", ModeTime);
     OnUpdateEvent.Fire();
     if (StartingLevel)
     {
         AttemptToStartLevel();
     }
     else if (StartingMode && StartingModeTime != -1.0 && Network.time - StartingModeTime >= StartingModeTimeout && !StartingModeDelay)
     {
         AttemptToStartMode();
     }
 }