1 package com.codingame.game;
3 import com.codingame.gameengine.core.MultiplayerGameManager;
4 import com.codingame.gameengine.core.AbstractMultiplayerPlayer;
5 import com.google.inject.Inject;
6 import com.google.inject.Singleton;
15 CheatLevel cheatLevel;
25 LeagueManager(MultiplayerGameManager<AbstractMultiplayerPlayer> gameManager)
27 int level = gameManager.getLeagueLevel();
28 if (level < 1 || level > 3) {
29 throw new InternalError("This game does not implement level " + level);
32 cheatLevel = level <= 1 ? CheatLevel.ALLOWED
33 : level <= 2 ? CheatLevel.TOLERATED
34 : CheatLevel.FORBIDDEN;
36 mapLevel = level <= 1 ? MapLevel.SINGLE
37 : level <= 2 ? MapLevel.DISCRETE
38 : MapLevel.CONTINUOUS;