public void RemoveGameForPlayer(NetworkIdentity playerIdentitiy) { DeviceView associatedView = GetDeviceForPlayer(playerIdentitiy); if (associatedView != null) { associatedView.SetCurrentGame(null); } }
public void SetCurrentGame(Player player, GameData gameData) { DeviceView currentDevice = GetDeviceForPlayer(player); if (currentDevice != null) { currentDevice.SetCurrentGame(gameData); gameData.OnPlayerExitsGame += PlayerExitsGame; } }