23.05.2009, 10:26
My code:
Porb?!:
Well, when I click the request option in the menu every player in the game get's the message "You are now LVPD, Welcome!" and everybody becomes LVPD as well !?
Something 2 do with those playerid's again but can I fix it with ease?
Greetzz Rizzy
Код:
public OnPlayerSelectedMenuRow(playerid, row) { new Menu:CurrentMenu = GetPlayerMenu(playerid); if(CurrentMenu == lvpdmenu) { switch(row) { case 0: //request { for(new i; i < MAX_PLAYERS; i++) { gTeam[i] = TEAM_LVPD; SendClientMessage(i, 0x00FF00FF, "You are now LVPD, Welcome!"); SetPlayerTeam(i, TEAM_LVPD); } } case 1: //resign { for(new i; i < MAX_PLAYERS; i++) { gTeam[i] = TEAM_CIVIL; SendClientMessage(i, 0x00FF00FF, "You are no longer LVPD"); SetPlayerTeam(i, TEAM_CIVIL); } } } } return 1; }
Well, when I click the request option in the menu every player in the game get's the message "You are now LVPD, Welcome!" and everybody becomes LVPD as well !?
Something 2 do with those playerid's again but can I fix it with ease?
Greetzz Rizzy