04.07.2014, 11:39
Make A Variable For God Command, Like This In the Top of the script:
Then, in the god command, do this:
that will make the player's value to 1 it is used if enabling the god mode, while disabling it use:
, and it will set it to the value 0 (default).
and in the command wshop do this:
That will check if the player's godmode value is to 1,if it is to 1,then it will send the message,if its not,then its working.
pawn Код:
new godmode[MAX_PLAYERS];
pawn Код:
godmode[playerid] = 1;
pawn Код:
godmode[playerid] = 0;
and in the command wshop do this:
pawn Код:
CMD:wshop(playerid, params[]){
ShowPlayerDialog(playerid, 4, DIALOG_STYLE_LIST, "Weapon Shop", "Colt 45 ($75,000)\nDesert Eagle ($90,000)\nShotgun ($20,000)\nSawnoff Shotgun ($40,500)\nCombat Shotgun ($80,000)\nMicro SMG ($80,000)\nTec9 ($100,800)\nMP5 ($100,000)\nAK-47 ($300,000)\nM4 ($190,500)\nCountry Rifle ($150,000)\nSniper Rifle ($200,500)\nHeat-Seaking Rocket ($650,000)\nFlamethrower ($500,000)\nMinigun ($600,500)\nRPG ($700,000)\nParachute ($1.000)\n", "Buy!", "Cancel");
if(godmode[playerid] == 1) return SendClientMessage(playerid,COLOR_RED,"You cant use /god and /wshop together.Turn off your gode mode and then buy weapons");
return 1;}

