• Advertisement
Sign in to follow this  

Memory management of game objects

This topic is 3703 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi all, So I got a list of game-objects, when my memory threshhold exceeds a certain amount, I need to remove some of them based on mem size, distance, and some other parameters. If I can't find a valid one in a search, I'll need to loosen the restrictions and search again. Can someone give me the name of some algorithms that deal with this? It seems like it'd be similar to the way online games are found for the user based on connection speed, experience, game-type, etc. My first thought is to organize the objects into different lists based on size, and when needed, look through the biggest lists firsts with using params as weights, and eliminate some # of objects that scored above x. I'll stop after some number of objects have been freed. If not enough were given, go back through the lists and lower the threshold. This may have to be spread out over some number of frames as there could be 100s-1000s of these objects.

Share this post


Link to post
Share on other sites
Advertisement
Sort the objects (or store sorted) by the full set of parameters then just drop the largest N?

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement