public void End(BaseRound newRound = null) { EndTime = 0f; OnEnd(); if (Host.IsClient && EndMessage.Length > 0) { ChatBox.AddInformation(EndMessage); } (Game.Current as Game).SetRound(newRound ?? GetNextRound()); }
public virtual void SetRound(BaseRound newRound = null) { // Prioritize the round specified by the OLD round. var roundToUse = newRound; if (roundToUse == null) { return; } // Assign new one and start it. Round = newRound; Round.Begin(); }
private void OnTick() { Round?.Tick(); if (IsClient) { // This is a hack for networking. I hate it. I hate it. We must fix this in the future. if (_lastRound != Round) { _lastRound?.End(); _lastRound = Round; } } }