SA-MP Forums Archive
[Help] War System - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: [Help] War System (/showthread.php?tid=80249)



[Help] War System - _System_ - 03.06.2009

Hey,

i built a war system , and i want to do ( /StartWar [WeaponId] ) that when they spawned to the war they get the weapon id.

how to it ?

Код:
if(!strcmp(cmd, "/StartWar", true)) {
tmp = strtok(cmdtext, idx);
if(!strlen(tmp)) return SendClientMessage(playerid, COLOR_LIGHTGREEN, "/WarStart [WeaponId] :щйоещ");
if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, COLOR_RED, "аъд ма агойп.");
if(ChainSawOn == 1) return SendClientMessage(playerid, COLOR_RED, ".йщ лбш омзод фтймд");
format(ChainSawknob, sizeof(ChainSawknob), "~R~~H~ /JoinWar", playername);
GameTextForAll(ChainSawknob,3000,4);
for(new i = 0; i < MAX_PLAYERS; i++) {
PlayerPlaySound(i,1058, 0.0, 0.0, 0.0); }
ChainSawReward = strval(tmp);
SetTimer("CsStart",3000,0);
return 1; }
and how to do that if [Weaponid] > 0 || < 46 return a message