04.01.2018, 06:32
Idk when I pressed ANY OF THEM I'll still in 1place!~
Код:
ShowPlayerDialog(playerid, 70, DIALOG_STYLE_LIST, "Choose an Arena", "1- Deagle Only\n2-Sawn-off + Deagle\n3-Freeroam Arena\n4-Minigun","OK", "");
PHP код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
switch(dialogid == 70)
{
case 5: // Dialog ID 70
{
if(response)
{
switch(listitem)
{
case 1:
{
SendClientMessage(playerid, Grey, "You are now In Deagle Arena!");
SendClientMessage(playerid, Yellow, "You can change your arena Type: /switcha or (/switcharena)!");
GivePlayerWeapon(playerid, 24, 10000);
SetPlayerHealth(playerid, 100);
SetPlayerPos(playerid, 288.745971,169.350997,1007.171875);
SetPlayerInterior(playerid, 3);
}
case 2:
{
SendClientMessage(playerid, Grey, "You are now in Sawnoff + Deagle Arena!");
SendClientMessage(playerid, Yellow, "You can change your arena Type: /switcha or (/switcharena)!");
GivePlayerWeapon(playerid, 24, 10000);
GivePlayerWeapon(playerid, 26, 10000);
SetPlayerHealth(playerid, 100);
SetPlayerPos(playerid,1710.433715,-1669.379272,20.225049);
SetPlayerInterior(playerid, 18);
}
case 3:
{
SendClientMessage(playerid, Grey, "You are now in Freeroam arena!");
SendClientMessage(playerid, Yellow, "You can change your arena Type: /switcha or (/switcharena)!");
ResetPlayerWeapons(playerid);
SetPlayerHealth(playerid, 99999999);
SetPlayerPos(playerid, -1465.268676,1557.868286,1052.531250);
SetPlayerInterior(playerid, 14);
}
case 4:
{
SendClientMessage(playerid, Grey, "You are now in Minigun Arena! Your health is now 250%.");
SendClientMessage(playerid, Yellow, "You can change your arena Type: /switcha or (/switcharena)!");
GivePlayerWeapon(playerid, 38, 100000);
SetPlayerHealth(playerid, 250);
SetPlayerPos(playerid, -975.975708,1060.983032,1345.671875);
SetPlayerInterior(playerid, 10);
}
}
}
}
}
return 1;
}