Posted: 20th Mar 2004 16:36
A possible way to avoid having to remember object numbers and the like. The functions could be altered to work for images, sprites, or whatever you need. (See attached source code).
Posted: 21st Mar 2004 4:04
I manage all media with a typed array
eg:

Monster(1).Hitpoints

IT still uses a numbered sequence but dang its sweet to manage.
Posted: 21st Mar 2004 13:39
Replace the for-next with while-endwhile because you waste a lot of cpu time going through the entire 65535 numbers, when the free space was object number 1 after all. Hehe, didn't I post something like this here before?
Posted: 21st Mar 2004 21:35
Replace the for-next with while-endwhile because you waste a lot of cpu time going through the entire 65535 numbers, when the free space was object number 1 after all. Hehe, didn't I post something like this here before?


Whoops! Sorry, this line:

if object exist(i)=0 then free=i

should be:

if object exist(i)=0 then free=i: exit

Then it will stop when it finds it.