Hi and thank you for find it ... I knew it for a long time... and I was lazy to change the code, because it's ...everywhere.
I was thinking to track not the month (which loops from 1 to 30) but the CurrentDay (constantly increments)... and I got again lazy and... you got the picture.
For sure one day I will fix it... one day... uhhh.... promise.
You know, I, too, believe that you don't have to deal with correcting this inaccuracy right now. I am in the process of optimizing your code. I am in no way going to appropriate the results of your work or criticize them. And I am not going to publish my development anywhere. On the contrary, you may use my development. And in general, I respect your way of writing: neatness and consistency in declaring variables - it reminds me of the old school of formal programming languages.
What is the essence of my optimization? Transfer the recurring game variables of different girls into objects - instances of the "Person" class. In this case, when the need arises, it will not be necessary to add a new variable for each girl or create a package of variables for a new girl. And I replace many repetitive calculations with functions. For example, to determine Anna's ovulation state, the code " if anna.ovulates: " And nothing more. Or in the dialog you can immediately write anna "I'm ovulated [anna.ovul_nd].". And the game will display "I am ovulated today.", "I am ovulated ysterday.", "I am ovulated 3 days ago." depending on the day of ovulation and day of the month. Of course, to separate character and Person objects, I have placed character objects in a special built-in renpy store module "character". I'm constantly testing changes and use the renpy after_load label so that old saves can be used.
By the way, the problem of girls having more children has found a rather interesting solution. I created a class "Baby" and its instances will be stored in a separate list. This also allowed to "create" children of random gender with random (but not repetitive) name (in total in the library - more than 1000 names of girls and boys respectively). There is also a switch in the game that determines the use of predetermined and random children, as well as the ability to change the ratio of boys to girls. The girl's stats screen displays a list of her children's names with gender and age. And there is also an option to change their names in the hospital for money. Accordingly, dialogs in the hospital and anywhere else take into account the gender of the random child. Here is a sample code:
...
$ baby = alina.gives_birth()
...
unkn "Congratulations! You have a baby [baby.is_a]." # boy, girl
...
alina "Okay [mcname]. If you like [baby.name], [baby.who] will be [baby.name]." # he, she
That and much more.
I will send you my development as soon as I finish the fixes. Or when you ask me to. Or in general, I can post it on
You must be registered to see the links
for you to collaborate on.