19.02.2011, 07:33
Try this.
Assuming that PlayerTeam[playerid]; is the teamId and also ID 0 is when he is in no team yet, and teams start from 1 onwards.
I guess this should work, thou its untested.
Assuming that PlayerTeam[playerid]; is the teamId and also ID 0 is when he is in no team yet, and teams start from 1 onwards.
Код:
public OnPlayerRequestSpawn(playerid) { if(PlayerTeam[playerid] == 0) { ShowPlayerDialog(......); return 0; } } public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) { if(dialogid == /*Dialog ID that you put in ShowPlayerDialog*/) { if(response == 0) // If a Player Choose first Button { } if(response == 1) // If a Player Choose second Button ( Correctly ) { SpawnPlayer(playerid); SetPlayerSpawn(playerid, /* Cordinates where you want him to spawn */); } } return 1; }