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



Deleted - LustcheR - 20.02.2014

Deleted


Re: Error - LocMax - 21.02.2014

Код:
DOF2_SetInt(PFile(DOF2_GetInt(VFile(vehicleid), "CarOwned")), "MoneyBank"), DOF2_GetInt(DOF2_GetInt(VFile(vehicleid), "CarOwned"), "MoneyBank") + DOF2_GetInt(VFile(vehicleid),"CarPrice"));
Try this


Re: Error - Aerotactics - 21.02.2014

Quote:

DOF2_SetInt(PFile(DOF2_GetInt(VFile(vehicleid), "CarOwned")), "MoneyBank", DOF2_GetInt(DOF2_GetInt(VFile(vehicleid), "CarOwned"), "MoneyBank") + DOF2_GetInt(VFile(vehicleid),"CarPrice"));
Quote:

DOF2_SetInt(PFile(DOF2_GetInt(VFile(vehicleid), "CarOwned")), "MoneyBank"), DOF2_GetInt(DOF2_GetInt(VFile(vehicleid), "CarOwned"), "MoneyBank") + DOF2_GetInt(VFile(vehicleid),"CarPrice");
He added a parentheses, just to clarify. (underlined)

Also, it appeared you had an extra parentheses so I removed it. (bold)


Re: Error - LustcheR - 22.02.2014

Quote:
Originally Posted by LocMax
Посмотреть сообщение
Код:
DOF2_SetInt(PFile(DOF2_GetInt(VFile(vehicleid), "CarOwned")), "MoneyBank"), DOF2_GetInt(DOF2_GetInt(VFile(vehicleid), "CarOwned"), "MoneyBank") + DOF2_GetInt(VFile(vehicleid),"CarPrice"));
Try this
your errors:
PHP код:
warning 202number of arguments does not match definition
error 035
argument type mismatch (argument 1)
error 029invalid expressionassumed zero
warning 215
expression has no effect 
Quote:
Originally Posted by Aerotactics
Посмотреть сообщение
He added a parentheses, just to clarify. (underlined)
Also, it appeared you had an extra parentheses so I removed it. (bold)
your errors:
PHP код:
warning 202number of arguments does not match definition
error 035
argument type mismatch (argument 1)
warning 215expression has no effect 



Re: Error - Konstantinos - 22.02.2014

http://forum.sa-mp.com/showpost.php?...33&postcount=5


Re: Error - LustcheR - 22.02.2014

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
but CarOwner is a playername(string)
i change and this have me this warning:
error 035: argument type mismatch (argument 1)


Re: Error - Konstantinos - 22.02.2014

In your first post, you say "CarOwned" and now "CarOwner". For the "CarOwner" which is string, use DOF2_GetString.


Re: Error - LustcheR - 22.02.2014

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
In your first post, you say "CarOwned" and now "CarOwner". For the "CarOwner" which is string, use DOF2_GetString.
Error:
PHP код:
error 035argument type mismatch (argument 1
The line:
PHP код:
DOF2_SetInt(PFile(DOF2_GetString(VFile(vehicleid), "CarOwner")), "MoneyBank"DOF2_GetInt(xPFile(DOF2_GetString(VFile(vehicleid), "CarOwner")), "MoneyBank") + DOF2_GetInt(VFile(vehicleid),"CarPrice"));