Search in sources :

Example 1 with GameClientMessage

use of mage.view.GameClientMessage in project mage by magefree.

the class GameSessionWatcher method gameOver.

public void gameOver(final String message) {
    if (!killed) {
        userManager.getUser(userId).ifPresent(user -> {
            user.removeGameWatchInfo(game.getId());
            user.fireCallback(new ClientCallback(ClientCallbackMethod.GAME_OVER, game.getId(), new GameClientMessage(getGameView(), null, message)));
        });
    }
}
Also used : ClientCallback(mage.interfaces.callback.ClientCallback) GameClientMessage(mage.view.GameClientMessage)

Aggregations

ClientCallback (mage.interfaces.callback.ClientCallback)1 GameClientMessage (mage.view.GameClientMessage)1