Memory Leaks Fixed, More Nora Writing, and a Mod Shoutout! (Patreon)
Content
A few days ago I mentioned I was going to track down the memory leak that was plaguing the late game of LR2. I spent some time looking around and found a couple of possible culprits (primarily Ren'py's rollback, which was saving an unreasonable number of steps back), but the main answer ended up being provided by some amazing LR2 mod developers!
So for those curious, here's what the cause was: In a previous update I had modified the girl creation code to add a home for them when they were created, so they could properly go home before and after work, invite you home, etc. A side effect of this was that when you went to hire someone and a batch of applicants was generated each of them was given a home location. Previously the extra applicants would have no references remaining once you had picked the person to hire so the garbage collection would sweep them up. The home location meant that they needed to be kept track of. Each time you generated a new list of applicants every single one would be added to the game permanently. To fix this, new employees no longer have home locations created until they are actually hired.
I have to give thanks to the awesome mod developers who spotted and fixed this bug before I did. You can check out their mod here. It makes me incredibly happy to know that there is a community of people out there modding LR2 and doing cool things with it! This seems like a good time to mention that Lab Rats (1 and 2) are both released unencrypted and that mods and additions are absolutely welcome! The only limitations are that mods must be provided for free and that credit/a link to this patreon page must be provided. If there are other mod groups out there feel free to leave a comment about them!
Besides that optimization hunt I have been working more on Nora's new storyline events. (Minor spoilers ahead) After some revision her new content has ended up being focused on unlocking new super serum traits. By bringing her field reports about interesting characters she can develop these serum traits for you. The "interesting characters" end up being people with extreme (high or low) sluttiness, obedience, love and/or happiness. People with unique relationships with you (your mother, sister, alexia, etc.) can also unlock special traits unique to them, if they have been corrupted in the correct (ie. most thematic) way. Your mother, for example, when brought in with very high love and sluttiness lets Nora develop a super love trait.
I have some more coding to do to get the last of the serum traits working, but everything is going well so far! Less than a week to go until the release of v0.20!