Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Memory full when loading multiple images
#1
Question 
Hi to all !!!

I will try to explain myself with my limited english ?

I am making a space shooting/strategy game that loads multiple images. I have a main image (ship) and when it is attacked I load two different images in other two layers (shields impact, damages made to the ship). Last thing I do is _PUTIMAGE of these three layers. During the game I use _LOADIMAGE to change the images of these layers, and there are several ships in the game with the same three layers.

I noticed that when I start my game, the Windows task manager shows some RAM used, and as I am playing it this RAM is increasing.

I know the _FREEIMAGE command, but my code is very large and I find very difficult to check when to use it...

Also I noticed that when I execute a _LOADIMAGE command, and some time later I execute this command over the same variable the memory is still increasing. I thought that when using the same variable the RAM occupied was the same... obviously I was wrong Sad

Is there any way to re-use some LONG variable to load several images without having to _FREEIMAGE between every load? I thought to make a SUB that makes a _FREEIMAGE in the variable just before load an image, but it goes wrong a lot of times Sad

Anybody can help me? Thank you !!! Smile
10 PRINT "Hola! Smile"
20 GOTO 10
Reply


Messages In This Thread
Memory full when loading multiple images - by Ikerkaz - 11-02-2024, 10:52 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  about Hardware Images and _DisplayOrder,Help! qbfans 11 546 02-11-2026, 07:10 AM
Last Post: SMcNeill
  Nth problem with hardware images Ikerkaz 9 481 01-23-2026, 02:58 PM
Last Post: bplus
  Hardware images questions Dav 5 462 12-04-2025, 04:18 PM
Last Post: Pete
  Hardware images...Talk to me! Unseen Machine 5 725 09-22-2025, 11:12 PM
Last Post: TempodiBasic
  Loading from file into _MEM? and LEN a TYPE... Unseen Machine 9 958 08-03-2025, 02:55 AM
Last Post: SMcNeill

Forum Jump:


Users browsing this thread: 1 Guest(s)