Some errors while compiling - 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: Some errors while compiling (
/showthread.php?tid=609169)
Some errors while compiling -
houssam501 - 09.06.2016
PHP код:
C:\Users\endlesscrap\Desktop\STG\gamemodes\dmrace.pwn(937) : error 017: undefined symbol "MAX_STRING"
C:\Users\endlesscrap\Desktop\STG\gamemodes\dmrace.pwn(937) : error 009: invalid array size (negative, zero or out of bounds)
C:\Users\endlesscrap\Desktop\STG\gamemodes\dmrace.pwn(937) : error 036: empty statement
C:\Users\endlesscrap\Desktop\STG\gamemodes\dmrace.pwn(937) : fatal error 107: too many error messages on one line
line and stuff
PHP код:
stock trcar(car[]) {
new tmp[MAX_STRING];
set(tmp,car);
tmp=strreplace("[","(",tmp);
tmp=strreplace("]",")",tmp);
return tmp;
}
can anyone help me please ?
Re: Some errors while compiling -
SyS - 09.06.2016
@ top of ur script
PHP код:
#define MAX_STRING any_numerical_value_here
Re: Some errors while compiling -
houssam501 - 09.06.2016
got this then
Код:
C:\Users\endlesscrap\Desktop\STG\gamemodes\dmrace.pwn(941) : error 017: undefined symbol "set"
C:\Users\endlesscrap\Desktop\STG\gamemodes\dmrace.pwn(942) : error 017: undefined symbol "strreplace"
C:\Users\endlesscrap\Desktop\STG\gamemodes\dmrace.pwn(942) : error 033: array must be indexed (variable "tmp")
C:\Users\endlesscrap\Desktop\STG\gamemodes\dmrace.pwn(943) : error 017: undefined symbol "strreplace"
C:\Users\endlesscrap\Desktop\STG\gamemodes\dmrace.pwn(943) : error 033: array must be indexed (variable "tmp")
Код:
stock trcar(car[]) {
new tmp[MAX_STRING];
set(tmp,car);
tmp=strreplace("[","(",tmp);
tmp=strreplace("]",")",tmp);
return tmp;
}
Re: Some errors while compiling -
Stinged - 09.06.2016
Did you define it as
any_numerical_value_here or did you actually enter a number?
Re: Some errors while compiling -
houssam501 - 09.06.2016
i entered a number
Re: Some errors while compiling -
houssam501 - 09.06.2016
Код:
stock trcar(car[]) {
new tmp[MAX_STRING];
set(tmp,car);
tmp=strreplace("[","(",tmp);
tmp=strreplace("]",")",tmp);
return tmp;
}
all the errors are in here
Re: Some errors while compiling -
Sjn - 09.06.2016
It looks like you don't have dutils.inc included as this include contains these functions.