Gamestudio Links
Zorro Links
Newest Posts
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (AndrewAMD, Nymphodora), 1,466 guests, and 4 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Memory problems / Optimizing for better performanc #130869
05/21/07 02:15
05/21/07 02:15
Joined: May 2007
Posts: 16
At the Gates of Midian
Illegitima Offline OP
Newbie
Illegitima  Offline OP
Newbie

Joined: May 2007
Posts: 16
At the Gates of Midian
Hello,
I have mainly some general questions about how to optimize a game for better performance.
My current problem is that our game takes around three times more memory than all the game files (if not more), and continues increasing the memory and cpu usage.
So can you tell me what might be the problem.
First there are three of animated panels (animated sequences in Targa format) and 3 static panels, 3 avatars (humanoids, each MDL file with all animations and included texture is around 15mb - is that ok?), and some really low quality textures for the flat walls. There are not more than 30mb sound files. And all this takes more than 700mb RAM! :/
Do you think the problem is in the script, or the big models, or textures? I have no idea. We succeeded to lower the RAM usage by loosing some textures, but the that's not the way...
What is the main cause of the big memory usage and can you tell me ways to optimize a game?
Sorry for the swarm of questions. I would really appreciate your replies, so thanks in advance!
Regards,
Nikolay

Re: Memory problems / Optimizing for better performanc [Re: Illegitima] #130870
05/21/07 03:43
05/21/07 03:43
Joined: Mar 2003
Posts: 4,264
Wellington
Nems Offline

.
Nems  Offline

.

Joined: Mar 2003
Posts: 4,264
Wellington
Sounds like a coding issue to me, probably 'while' loops with 'if' statements incrementing on each cycle.

Find and fix them before anything else.

Re: Memory problems / Optimizing for better perfor [Re: Nems] #130871
05/21/07 10:59
05/21/07 10:59
Joined: Mar 2007
Posts: 776
Poor village - Poland ;)
tompo Offline
User
tompo  Offline
User

Joined: Mar 2007
Posts: 776
Poor village - Poland ;)
Check num_actions by pressing F11 or add this function to your panel and You'll see number of running actions in one time.


Never say never.
Re: Memory problems / Optimizing for better perfor [Re: tompo] #130872
05/23/07 22:32
05/23/07 22:32
Joined: May 2007
Posts: 16
At the Gates of Midian
Illegitima Offline OP
Newbie
Illegitima  Offline OP
Newbie

Joined: May 2007
Posts: 16
At the Gates of Midian
Thanks for the replies. We couldn't find errors in the code, but we do found that the Targa image files and sequences take huge amount of memory. We were using animated menu-s, and all the frames were different pictures (32bit with alpha channel), and these turned to be memory eating components. I guess we need to find another way of animating our menus.

Which leads to another question: Our game has and will have many graphic files (UI with all panels, textures and other small graphics.) Are they supposed to me in the memory all the time from the start of the game? Is There a way to load them only if they are needed and not at the beginning (for example the panels or the optional graphics that appear only if something is done), and to remove them from memory after we use them. We tried the "purge" function, but it doesn't seem to be changing the situation...

Re: Memory problems / Optimizing for better perfor [Re: Illegitima] #130873
05/23/07 22:36
05/23/07 22:36
Joined: Mar 2007
Posts: 776
Poor village - Poland ;)
tompo Offline
User
tompo  Offline
User

Joined: Mar 2007
Posts: 776
Poor village - Poland ;)
maybe use one bmap with frames? like explosion bmap with frames
name_of_bmap+10.jpg and then call which frame should be visible?
or use .dds format
just suggestion

Last edited by tompo; 05/23/07 22:37.

Never say never.

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1