Help With SetVehicleNumberPlate - 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 With SetVehicleNumberPlate (
/showthread.php?tid=195212)
Help With SetVehicleNumberPlate -
[ExT]Montana - 01.12.2010
Hi, i see the return of SetVehicleNumberPlate in the 0.3c RC, and i put a command with him, i already downloaded the new server version of 0.3c but look what it happens:
Код:
if(strcmp(cmd, "/plate", true) == 0)
{
if (PlayerInfo[playerid][pAdmin] >= 2)
{
new length = strlen(cmdtext);
while ((idx < length) && (cmdtext[idx] <= ' '))
{
idx++;
}
new offset = idx;
new result[128];
while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
{
result[idx - offset] = cmdtext[idx];
idx++;
}
result[idx - offset] = EOS;
idx++;
if(!strlen(result)) return SendClientMessage(playerid, COLOR_GREY, "USE: {AA3333}/plate{AFAFAF} [plate number]");
SetVehicleNumberplate(GetPlayerVehicleID(playerid), result)
}
return 1;
}
And Return this error:
Код:
error 017: undefined symbol "SetVehicleNumberplate"
I tried to put the native in the gamemode, and warned: symbol already defined.
Please someone help
Sry for bad english :/
Re: Help With SetVehicleNumberPlate -
Fj0rtizFredde - 01.12.2010
I think it should be a big P in "plate" SetVehicleNumberPlate
Re: Help With SetVehicleNumberPlate -
6d - 01.12.2010
I agree with you, Programming is case sensitive.
let's see a example,
if you put this:
pawn Код:
#include <a_samp>
#define MessageOfTheDay "Welcome to SA:MP Forums!"
main()
{
printf("Message of the Day: %s", MessageOfTheDay);
}
it should run perfectly, notice that letters M-O-T-D are capitalized in the word MessageOfTheDay.
Now if you put this:
pawn Код:
#include <a_samp>
#define MessageOfTheDay "Welcome to SA:MP Forums!"
main()
{
printf("Message of the Day: %s", messageoftheday);
}
it will give the following errors:
Код:
error 017: undefined symbol "messageoftheday"
which simply means, that the system will not recognize it as a declared variable.
but well, hope this explains why it was a error.
it's SetVehiclePlateNumber
Re: Help With SetVehicleNumberPlate -
[ExT]Montana - 01.12.2010
hrr it's works now, sry for this and thanks guys =)
Re: Help With SetVehicleNumberPlate -
6d - 01.12.2010
No sorries, we are here to help.
Glad we helped.