SA-MP Forums Archive
Syntax - 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: Syntax (/showthread.php?tid=480042)



Syntax - TonyNames - 08.12.2013

Can anyone help me with this error

Code:
C:\Users\JakkenKoppen\Desktop\NEW Bone County Script\gamemodes\UGRP.pwn(90957) : error 017: undefined symbol "Syntax"
Line:

Code:
		else return Syntax(playerid, "aflip", "[vehicleid] OR /aflip in a car.");



Re: Syntax - SKAzini - 08.12.2013

You have not defined Syntax.

Did you take that from another script?


Re: Syntax - TonyNames - 08.12.2013

I know i dont have the Syntax defined, and kinda. My friend got that command and i asked him that i could get it with the define he couldn't find the define but he gave me the command. I need the define. Could you create one for me?


Re: Syntax - Tagathron - 08.12.2013

Syntax(arguments) is an function.It looks like it sends an message to the player so you can use default SendClientMessage(playerid, COLOR, MSG);


Re: Syntax - SilentSoul - 08.12.2013

Use sscanf instead of Syntax,
pawn Code:
new vehicleid;
if(sscanf(params, "d", vehicleid)) return SendClientMessage(playerid, 0xFF0000FF, "Syntax: /aflip [vehicleid] OR /aflip in a car.");



Re: Syntax - TonyNames - 08.12.2013

Can someone give me a define of this:

Code:
C:\Users\JakkenKoppen\Desktop\NEW Bone County Script\gamemodes\UGRP.pwn(90978) : error 017: undefined symbol "get3g"
Line:
Code:
			format(szSpeed, sizeof(szSpeed),"~n~~n~~n~~n~~n~~n~~n~~n~~n~~w~%.0f MPH", GetPlayerSpeed(playerid, get3d));
And yes i also asked him for this


Re: Syntax - SilentSoul - 08.12.2013

Try this !
pawn Code:
format(szSpeed, sizeof(szSpeed),"~n~~n~~n~~n~~n~~n~~n~~n~~n~~w~%.0f MPH", GetPlayerSpeed(playerid));
You only used to check for the speed only and it defined with GetPlayerSpeed , i think get3d is useless or you didn't give us the correct information about that , this will work and won't give you any errors but i am not sure if it will stop using another function of the textdraw!


Re: Syntax - TonyNames - 08.12.2013

but when i removing it i get this warning

Code:
C:\Users\JakkenKoppen\Desktop\NEW Bone County Script\gamemodes\UGRP.pwn(90978) : warning 202: number of arguments does not match definition
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Warning.
Line:
Code:
			format(szSpeed, sizeof(szSpeed),"~n~~n~~n~~n~~n~~n~~n~~n~~n~~w~%.0f MPH", GetPlayerSpeed(playerid));
i need to have the script clean i mean without errors and warnings before i can run it on my host.


Re: Syntax - TonyNames - 08.12.2013

When i inputting the g3d the warning getting destroyed and then i just have to define it


Re: Syntax - erminpr0 - 08.12.2013

Try this:

pawn Code:
new Float:get3d;
GetPlayerSpeed(playerid, get3d);
format(szSpeed, sizeof(szSpeed),"~n~~n~~n~~n~~n~~n~~n~~n~~n~~w~%.0f MPH", get3d);