new entry[...]
#1

Hey there!

I`m going crazy with this thing. I found property system i edited it for my needs and stuff I created like billion house pickups [ok ok ~360] and when i run server it says "~360" loaded. Everything works fine. Then i turn off server wait a few secs and turn it back on and properties are ~70 all time the same. then i found this entry stuff.
pawn Код:
new entry[256];
I Changed it to
pawn Код:
new entry[8256];
And properties dont disappear and stuff. But Compiler says this:

pawn Код:
Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase

Header size:           3980 bytes
Code size:           165696 bytes
Data size:          4386820 bytes
Stack/heap size:      16384 bytes; estimated max. usage=8283 cells (33132 bytes)
Total requirements: 4572880 bytes
Anyone can explain me what it is? and that entry what i changed?
EDIT: I probably should say that for file writing it uses Dini.
Thanks!
Reply
#2

Try lowering the dimensions to 512.
Reply
#3

This "warning" appears if the compiler detects a collision of stack and heap
They share the same memory block by default 16 kB (4096 cells)
If they collide, data from the other section will be overwritten

Solutions
1. Rewrite the code because there is in 90% cases a better solution than a huge array
2. If the array is 100% neccessary make it global or static (these gets saved in the amx file)
3. Change the size of the memory block (not recommended)

Also use a up to date file system (y_ini as example), not dini
Reply
#4

Quote:
Originally Posted by Nero_3D
Посмотреть сообщение
This "warning" appears if the compiler detects a collision of stack and heap
They share the same memory block by default 16 kB (4096 cells)
If they collide, data from the other section will be overwritten
Actually, I'm pretty sure that warning is because of too much memory assigned to the stack/heap.
Reply
#5

Thank you! Then i will start to remake it.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)