SA-MP Forums Archive
5 Errors and 3 Warnings - 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: 5 Errors and 3 Warnings (/showthread.php?tid=171849)



5 Errors and 3 Warnings - nuriel8833 - 28.08.2010

I tried to improve Sandra's property system and I have a few errors:

PHP код:
C:\Documents and Settings\Liat.LIAT-5FBA01523F\Desktop\pawno\XXX\PropertySystem\filterscripts\Properties.pwn(100) : error 032: array index out of bounds (variable "PropText")
C:\Documents and Settings\Liat.LIAT-5FBA01523F\Desktop\pawno\XXX\PropertySystem\filterscripts\Properties.pwn(101) : error 032: array index out of bounds (variable "PropText")
C:\Documents and Settings\Liat.LIAT-5FBA01523F\Desktop\pawno\XXX\PropertySystem\filterscripts\Properties.pwn(101) : warning 213tag mismatch
C
:\Documents and Settings\Liat.LIAT-5FBA01523F\Desktop\pawno\XXX\PropertySystem\filterscripts\Properties.pwn(120) : warning 204symbol is assigned a value that is never used"str"
C:\Documents and Settings\Liat.LIAT-5FBA01523F\Desktop\pawno\XXX\PropertySystem\filterscripts\Properties.pwn(112) : warning 204symbol is assigned a value that is never used"tmp"
C:\Documents and Settings\Liat.LIAT-5FBA01523F\Desktop\pawno\XXX\PropertySystem\filterscripts\Properties.pwn(338) : error 035argument type mismatch (argument 1)
C:\Documents and Settings\Liat.LIAT-5FBA01523F\Desktop\pawno\XXX\PropertySystem\filterscripts\Properties.pwn(340) : error 032: array index out of bounds (variable "PropText")
C:\Documents and Settings\Liat.LIAT-5FBA01523F\Desktop\pawno\XXX\PropertySystem\filterscripts\Properties.pwn(341) : error 032: array index out of bounds (variable "PropText")
Pawn compiler 3.2.3664              Copyright (c1997-2006ITB CompuPhase
5 Errors

100-101
PHP код:
    Delete3DTextLabel(PropText[MAX_PROPERTIES]);
    
PropText[MAX_PROPERTIES] = 0
338-341
PHP код:
                fclose("PropertySystem/PropertyInfo.txt");
                
format(textsizeof(text), "%s"PropInfo[id][PropName]);
                
PropText[MAX_PROPERTIES] = Create3DTextLabel(text0xF2FF41FF0003000);
                
Attach3DTextLabelToVehicle(PropText[MAX_PROPERTIES],id001); 
Help!


Re: 5 Errors and 3 Warnings - IceTea15 - 28.08.2010

your string is small new string[32]; write bigger new string[64]; etc..
Warning:You don't use "str" and "tmp" so you have to delete it if you don't want warning
And in the 101 you didn't write it based on the defined


Re: 5 Errors and 3 Warnings - nuriel8833 - 28.08.2010

Quote:
Originally Posted by IceTea15
Посмотреть сообщение
your string is small new string[32]; write bigger new string[64]; etc..
Warning:You don't use "str" and "tmp" so you have to delete it if you don't want warning
And in the 101 you didn't write it based on the defined
My string is 128 O.o