public GameObject RemoveMarble() { if (currentMarble == null) { return(null); } var temp = currentMarble; currentMarble = null; state = SPACE_STATE.UNOCCUPIED; return(temp); }
public void AddMarble(PLAYER player, GameObject marble) { currentMarble = marble; currentMarble.transform.SetParent(transform); state = player == PLAYER.PLAYER1 ? SPACE_STATE.OCCUPIED_PLAYER1 : SPACE_STATE.OCCUPIED_PLAYER2; }
private WIN_STATE GetWinState(SPACE_STATE spaceState) { return(spaceState == SPACE_STATE.OCCUPIED_PLAYER1 ? WIN_STATE.PLAYER1_WON : WIN_STATE.PLAYER2_WON); }