Help me with this error -
B3x7K - 05.09.2017
i dont know what can i do for now, but can you please help me for this problem
This is my script:
And when i compile it, i got this thing:
If you know what is that problem, please reply with ur answer, thanks
* sorry my bad english, cuz i need to learn some grammar thing *
Re: Help me with this error -
Arbico - 05.09.2017
Bro, So many errors, I fixed it for you, Rep+ me please
Main thing, Is you leaving space between if and the (
Remove it, I did it in this code
+ Who even still uses OnPlayerCommandText, Use ZCMD next time bro, Jeez!
Anyways there is the code
PHP код:
else if(!strcmp(type, "maxhealth", true)) {
new typeint;
if(sscanf(string, "i", typeint)) return SendSyntaxMessage(playerid, "/editcar [id] [maxhealth] [number]");
if(typeint < 0) return SendErrorMessage(playerid, "the specific type can't be below 0");
SetVehicleHealth(vehicleid, typeint);
return 1;
}
Al through, i did my best to fix, This might come to an error due to the fact if you want no errors, you will have to edit a lot, and i mean "alot" of codes to make it work properly, Just try this
Re: Help me with this error -
Storm94 - 05.09.2017
This doesn't need to be rewritten... it will work how it is. Main issue is the lack of an opening brace on the
statement. Additionally, the sscanf statement is asking for 3 parameters, but only extracting one.
Re: Help me with this error -
B3x7K - 06.09.2017
Hoooh, ok i'll try this soon as possible. Btw thx dude for helping me in this problem.
And yes i will rep+ to you
Re: Help me with this error -
B3x7K - 06.09.2017
Ok, that errors has been fixed for now, but that gimme another error. This is what i got:
PHP код:
F:\iRPv0.01BETA\ipo4.pwn(48288) : error 017: undefined symbol "vehicleid"
Re: Help me with this error -
crukk11 - 06.09.2017
define the code.
Re: Help me with this error -
B3x7K - 06.09.2017
Quote:
Originally Posted by crukk11
define the code.
|
Can u gimme some example plz ?
Re: Help me with this error -
JasonRiggs - 06.09.2017
Yes, In the first part of your code ever which is the first part of the cmd "editvehicle" the params of the sscanf are d which you should define as vehicleid, I mean that in the first line in this cmd make new vehicleid; and set the sscanf params of the cmd (main cmd) be "d" and define it as "vehicleid" understand?
Re: Help me with this error -
B3x7K - 06.09.2017
Quote:
Originally Posted by JasonRiggs
Yes, In the first part of your code ever which is the first part of the cmd "editvehicle" the params of the sscanf are d which you should define as vehicleid, I mean that in the first line in this cmd make new vehicleid; and set the sscanf params of the cmd (main cmd) be "d" and define it as "vehicleid" understand?
|
Like this ?
Re: Help me with this error -
JasonRiggs - 06.09.2017
Hell no, Just send me your command here, let me check if you are doing something wrong..