error on compile -
icko202 - 09.02.2013
The error is:
C:\Users\DELL\Desktop\Experienced Workers 1.1\gamemodes\Exworkers.pwn(10

: error 029: invalid expression, assumed zero
This is the script:
if(!strcmp(cmdtext, "/jointrucker"))
{
IsPlayerInRangeOfPoint(playerid, 1.0, 2440.4272460938, -2116, 13.546875);
{
new Text3D:label = Create3DTextLabel("Trucker", 0x10F441AA, 30.0, 40.0, 50.0, 40.0, 0);
Attach3DTextLabelToPlayer(label, playerid, 0.0, 0.0, -0.5);
SendClientMessage(playerid, COLOR_RED, "You have joined the truckers!");
}
else ----------------- HERE IS THE ERROR
{
SendClientMessage(playerid, 0x10F441AA, "You are not in range of the pickup");
}
return 1;
}
Re: error on compile -
bensmart469 - 09.02.2013
PHP код:
if(!strcmp(cmdtext, "/jointrucker"))
{
if(IsPlayerInRangeOfPoint(playerid, 1.0, 2440.4272460938, -2116, 13.546875))
{
new Text3D:label = Create3DTextLabel("Trucker", 0x10F441AA, 30.0, 40.0, 50.0, 40.0, 0);
Attach3DTextLabelToPlayer(label, playerid, 0.0, 0.0, -0.5);
SendClientMessage(playerid, COLOR_RED, "You have joined the truckers!");
}
else
{
SendClientMessage(playerid, 0x10F441AA, "You are not in range of the pickup");
}
return 1;
}
You forgot to do this:
if(IsPlayerInRangeOfPoint(playerid, 1.0, 2440.4272460938, -2116, 13.546875))
Re: error on compile -
icko202 - 09.02.2013
now all my commands ingame wont work only FS commands
Re: error on compile -
park4bmx - 09.02.2013
Because your "returning" a value before the GM cmds get checked through, which means it will stop checking for the cmds once the FS calls the return
Re: error on compile -
icko202 - 09.02.2013
how to fix it?
Re: error on compile -
mastermax7777 - 09.02.2013
remove return 1?
Re: error on compile -
icko202 - 09.02.2013
i removed this command but cant see other commands too, the other command /loadtruck have return 1; and return 0;