private void UpdateGamePhase(GamePhases.GameplayPhase newGamePhase) { if (newGamePhase == GamePhases.GameplayPhase.Evacuation || newGamePhase == GamePhases.GameplayPhase.DeEvacuation) { gamePhase = newGamePhase; } }
public void CallEvent(GamePhases.GameplayPhase gamePhase, object param) { if (eventDict.ContainsKey(gamePhase)) { eventDict[gamePhase]?.Invoke(param); GameplayPhaseChanged?.Invoke(gamePhase); } }
public bool DetachFromEvent(GamePhases.GameplayPhase gamePhase, Action <object> action) { if (eventDict.ContainsKey(gamePhase)) { eventDict[gamePhase] -= action; return(true); } return(false); }