SA-MP Forums Archive
Need help - 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)
+--- Thread: Need help (/showthread.php?tid=338824)



Need help - Derek_Westbrook - 01.05.2012

Need help here friends I got this error

Код:
C:\Documents and Settings\allenloza\My Documents\Downloads\Compressed\samp03dsvr_R2_win32 \gamemodes\Gangwar.pwn(402) : error 017: undefined symbol "X"
C:\Documents and Settings\allenloza\My Documents\Downloads\Compressed\samp03dsvr_R2_win32 \gamemodes\Gangwar.pwn(403) : error 021: symbol already defined: "SendClientMessageToAll"
C:\Documents and Settings\allenloza\My Documents\Downloads\Compressed\samp03dsvr_R2_win32 \gamemodes\Gangwar.pwn(404) : error 010: invalid function or declaration
Here's the line
Код:
CMD:nuke(playerid,params[])
CreateExplosion(Float:X,Float:Y,Float:Z,Float:Radius);
SendClientMessageToAll(0x58AB54FF, "%s has used a command /nuke and killed him/herself!");
return 1;
I'm creating a simple nuke system in my script on its next version...


Re: Need help - zSuYaNw - 01.05.2012

pawn Код:
CMD:nuke(playerid,params[])
{
    new
        Float:X,
        Float:Y,
        Float:Z
    ;
    GetPlayerPos(playerid, X,Y,Z);
    CreateExplosion(Float:X,Float:Y,Float:Z,Float:Radius);
   
    new str[100], n[24]; GetPlayerName(playerid, n, 24);
    format(str, sizeof(str), "%s has used a command /nuke and killed him/herself!", n);
    SendClientMessageToAll(0x58AB54FF, str);
    return 1;
}



Re: Need help - iggy1 - 01.05.2012

Quote:
Originally Posted by [Full]Garfield[XDB]
Посмотреть сообщение
pawn Код:
CreateExplosion(Float:X,Float:Y,Float:Z,Float:Radius);
Should be:

pawn Код:
CreateExplosion(X, Y, Z, 10.0);//change 10.0 to your desired blast radius



Re: Need help - zSuYaNw - 01.05.2012

Quote:
Originally Posted by iggy1
Посмотреть сообщение
Should be:

pawn Код:
CreateExplosion(X, Y, Z, 10.0);//change 10.0 to your desired blast radius
Yeah!
I forgot this..


Re: Need help - Derek_Westbrook - 01.05.2012

Hmm when I type /nuke no explosion and my testers didn't died..


Re: Need help - iggy1 - 01.05.2012

My bad there is one more param to create explosion the "type".

pawn Код:
CreateExplosion(X, Y, Z, 7, 10.0);
https://sampwiki.blast.hk/wiki/CreateExplosion
https://sampwiki.blast.hk/wiki/Explosion_List