public GameViewInfo GetPlayerView(int playerId, ClientCode clientCode) { GameModel game = accessLiveGame(playerId, clientCode); return(game.GetGameView(playerId)); }
public void PerformMove(int playerId, Point[] positions, ClientCode clientCode) { GameModel game = accessLiveGame(playerId, clientCode); game.PerformMove(playerId, positions); }
private void accessObservedGame(int observerId, int gameId, ClientCode clientCode, Team team, out Observer observer, out GameModel game) { lock (_gameLock) { observer = getObserver(observerId, clientCode); game = getGame(gameId); checkGameAccess(game, team); game.CheckRunState(); } }