/// <summary> /// Reset Grapher. /// </summary> void Reset() { try { channels.Clear(); replayControl = ReplayControls.Stop; replaySampleQueues.Clear(); replayFiles.Clear(); TimeKeeper.Reset(); } catch { } }
void UpdateReplay() { if (prevControl == ReplayControls.Stop && replayControl != ReplayControls.Stop) { TimeKeeper.Reset(); foreach (Channel ch in channels) { ch.firstVisiblePointIndex = 0; ch.lastVisiblePointIndex = 0; } } prevControl = replayControl; }
private void RPC_AddEvent(string data, PhotonMessageInfo info) { string[] eventData = data.Split(','); GameEvent eventToPerform = new GameEvent(this); switch (eventData[1]) { case "fallDown": eventToPerform = new FallDownEvent(this); break; } eventToPerform.Deserialize(eventData); gameEvents.Add(int.Parse(eventData[0]), eventToPerform); if (eventToPerform.players.Contains(ActorID)) { notifier.DisplayEvent(); eventDisplayer.Display(eventToPerform); timeKeeper.Reset("event", 10f); ship.gameObject.SetActive(false); } }