public void registerPlayerColor(int index, PLAYER_COLORS playerColor) { // playerStruct.index = (short)index; if (!gameInfoManager.ColorIsAlreadyChosen(playerColor)) { if (currenColor != PLAYER_COLORS.NONE) { gameInfoManager.removeColor(currenColor, (short)playerIndex); } gameInfoManager.selectColor(playerColor, (short)playerIndex); setTexture(playerColorsImages[playerColor]); currenColor = playerColor; } else if (playerColor == currenColor) { gameInfoManager.removeColor(currenColor, (short)playerIndex); currenColor = PLAYER_COLORS.NONE; removeAlltextures(); } }