ZTex

Engaged Member
Apr 3, 2019
2,896
4,182
Surely it can't be just me, but this game is a RAM eater! I have 16GB of RAM and this game is using 8GB minimum and constantly freezing lol. Me thinks me needs a new pc.
You're not and you don't.
The game needs a real optimization pass. It's trying to do way to much at the same time leading to memory out of bound errors and leaks. There's also a real problem with save files becoming to big to actually load due to recursive data storage.
 

mrkhing

Khing Orchestra
Game Developer
Feb 20, 2018
123
956
For those that are having issues with game freezing and consuming more than 1gb of RAM, what are some values in your save files that seem to be getting out of hand? I will add a cap to the amount of money in the wallet since that seems to be the main suspect. You can try it out with this small patch I attached that only adds the money cap.
 

ZTex

Engaged Member
Apr 3, 2019
2,896
4,182
For those that are having issues with game freezing and consuming more than 1gb of RAM, what are some values in your save files that seem to be getting out of hand?
Let me just do a thing real quick here.
I haven't tried the patch but here's a side by side of the size of a save file from your game vs another equally as large game. (Yours is at the top). Nearly 8x the file size.
BMC file size.png

COBD save size.png
 
  • Like
Reactions: MC Johnsson

mrkhing

Khing Orchestra
Game Developer
Feb 20, 2018
123
956
Let me just do a thing real quick here.
I haven't tried the patch but here's a side by side of the size of a save file from your game vs another equally as large game. (Yours is at the top). Nearly 8x the file size.
View attachment 2570739

View attachment 2570741
Well, this tends to happen because of very large numbers somewhere in your save. Having trillions of MCT is just an example. The same might apply if you have thousands of heirs or even corrupted values with a lot of decimals. My biggest late game save files are sitting around at 7 mb. Unless I can narrow down which variables are causing bloating in these specific save file there is nothing I can do in terms of optimization.
 

Pr0GamerJohnny

Forum Fanatic
Sep 7, 2022
5,250
7,500
My mind is blown at how large those saves are, what exactly is going on here?

Clearly there's something outside just "large wallet sizes", since even quadrillion bucks (10^15) is well within the 10^38 limit for a single float. I mean these are just trival number calculations....nothing should be slowing down a modern computer here.

Like ZTex suggested prior - I'm guessing there's some kind of repeating or recursive calculation running far too often, some "non-expected behavior", because none of this is normal for what's basically a glorified calculator. I'll redownload when I get some time this week and poke around these saves because I'm curious, or I might add renpy log notifications to the major calculation labels and see what's slowing it down.

(Don't get me wrong to the dev; that's not to disparage your game as a mere calculator; obviously there's a lot more here as a game, I'm referring to under the hood at it's core it's basically a big calculator-most of the game focuses on money and its generation and spending in different forms)

-edit: I know nothing about python, was always raised in c, but I can't help wonder if dynamic variable type casting plays a role given that values OFTEN hop back and forth around the int limit of 2,147,483,647 in this game; the low trillions to high billions is commonly seen.
 

ZTex

Engaged Member
Apr 3, 2019
2,896
4,182
Well, this tends to happen because of very large numbers somewhere in your save. Having trillions of MCT is just an example. The same might apply if you have thousands of heirs or even corrupted values with a lot of decimals. My biggest late game save files are sitting around at 7 mb. Unless I can narrow down which variables are causing bloating in these specific save file there is nothing I can do in terms of optimization.
Well here you go. I've attached a save and persistent post patch.
Hopefully that helps you narrow things down.
 

mrkhing

Khing Orchestra
Game Developer
Feb 20, 2018
123
956
Well here you go. I've attached a save and persistent post patch.
Hopefully that helps you narrow things down.
Not 100% sure what it is but I suspect you went a bit too crazy with the shares in the portfolio (tens of thousands of some of the most expansive shares in the game). Perhaps I need to tune down the amount of money people get from the money cheat to prevent this sort of thing from happening.
 
  • Thinking Face
Reactions: PapaPhat

JimMorrison19

Active Member
Dec 14, 2017
723
671
Not 100% sure what it is but I suspect you went a bit too crazy with the shares in the portfolio (tens of thousands of some of the most expansive shares in the game). Perhaps I need to tune down the amount of money people get from the money cheat to prevent this sort of thing from happening.
I have not installed your fix, but I am not having the issues with my save sizes or my ram usage.
 

mrkhing

Khing Orchestra
Game Developer
Feb 20, 2018
123
956
I have not installed your fix, but I am not having the issues with my save sizes or my ram usage.
Indeed, this problem only seems to affect some players that did specific things (usually involving the money cheat). But it's hard to tell what these things are in each situation and or if it can be done organically without using cheats and exploits.
 
3.40 star(s) 36 Votes