public OpeningState(bool isLocal) { this.isLocal = isLocal; this.game = LinesGame.instance; this.animationTime = 0; this.game.InitFields(); }
public ClosingState(int turn) { this.turn = turn; this.game = LinesGame.instance; this.animationTime = 0; this.game.FirstPlayerField.ResetAnimation(); this.game.SecondPlayerField.ResetAnimation(); }
public PreSelectState(Color color, Texture2D title, Texture2D first, Texture2D second, OnSelectHandler onFirst, OnSelectHandler onSecond, bool isOpening) { this.color = color; this.title = title; this.first = first; this.second = second; this.onFirst = onFirst; this.onSecond = onSecond; this.isOpening = isOpening; this.game = LinesGame.instance; }
public GameState() { GameState.instance = this; CurrentTurn = Constants.FIRST_PLAYER; this.game = LinesGame.instance; this.InputManager = new InputManager(); this.InputManager.OnMouseDown += OnMouseDown; this.InputManager.OnClick += OnMouseUp; this.OldLines = new List<Line>(); }
public SelectState(Color color, Texture2D title, Texture2D first, Texture2D second, PreSelectState.OnSelectHandler onFirst, PreSelectState.OnSelectHandler onSecond) { this.color = color; this.title = title; this.first = first; this.second = second; this.onFirst = onFirst; this.onSecond = onSecond; this.game = LinesGame.instance; this.lineWidth = 0.5f; this.inputManager = new InputManager(); this.inputManager.OnClick += OnDown; }