03.06.2011, 23:19
Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) { if(dialogid == DIALOG_MUDAR_FACCAO) { if(response) { if(listitem) { SetPlayerTeam(playerid, cv); OnPlayerSpawn(playerid); SetPlayerSkin(playerid, 47); } else if(listitem == 1) { SetPlayerTeam(playerid, tcc); OnPlayerSpawn(playerid); SetPlayerSkin(playerid, 105); } else if(listitem == 2) { SetPlayerTeam(playerid, tcp); OnPlayerSpawn(playerid); SetPlayerSkin(playerid, 107); } else if(listitem == 3) { SetPlayerTeam(playerid, ada); OnPlayerSpawn(playerid); SetPlayerSkin(playerid, 102); } else if(listitem == 4) { SetPlayerTeam(playerid, pcc); OnPlayerSpawn(playerid); SetPlayerSkin(playerid, 109); } else if(listitem == 5) { SetPlayerTeam(playerid, pcp); OnPlayerSpawn(playerid); SetPlayerSkin(playerid, 109); } SetPlayerHealth(playerid, 0); } } else if(dialogid == DIALOG_ESCOLHE_FACCAO) { if(response) { if(listitem) { SetPlayerTeam(playerid, cv); OnPlayerSpawn(playerid); SetPlayerSkin(playerid, 47); } else if(listitem == 1) { SetPlayerTeam(playerid, tcc); OnPlayerSpawn(playerid); SetPlayerSkin(playerid, 105); } else if(listitem == 2) { SetPlayerTeam(playerid, tcp); OnPlayerSpawn(playerid); SetPlayerSkin(playerid, 107); } else if(listitem == 3) { SetPlayerTeam(playerid, ada); OnPlayerSpawn(playerid); SetPlayerSkin(playerid, 102); } else if(listitem == 4) { SetPlayerTeam(playerid, pcc); OnPlayerSpawn(playerid); SetPlayerSkin(playerid, 109); } else if(listitem == 5) { SetPlayerTeam(playerid, pcp); OnPlayerSpawn(playerid); SetPlayerSkin(playerid, 109); } } } return 1; }