I couldn't find the level up routine/method/function again but I'll look into it.
The girls get quite a lot actually.
Level up is a dialogue option, not a function. It's in girlinteractions.rpy.
Level up does 5 things: set character exp to the start of next level, character level increases by 1, character max hp increases by 2 or 2 + (constitution - 10)/3 and cast to integer, character spell points increases by intelligence/10 and cast to integer, and character affection increases by 5.
Also renpy loads all rpy scripts under its directories at unicode order (probably special characters first, then numerical numbers, then alphabetical characters). Newer functions of the same name get redefined to the lastest version. See
You must be registered to see the links
.
Anyways just look at the zzAmora.rpy and zzHelp.rpy under /game, they are loaded last and contains
scripts labels for the character story updates and help menu stuffs.
Just remember if your rpy files is one that contains python scripts instead of labels, it must start with a "python:" statement, and all subsequent codes must be indented accordingly (with spaces, not tabs!). Not sure about non-script files but for the files that must be run at the start they all contains a "init" call. You can check the rpy files starting with 0- under /game to find out more.
Also the "init" call can be given specific orders. I've seen it in some patches for other renpy games by calling "init -2 python:", "init 999 python" where the numerical values are priority numbers. Default is 0. Renpy runs init statements from the lowest to highest priority (see
You must be registered to see the links
).
When I tried it earlier (again, never worked with Renpy before), I needed to add "init python:" before the function I want overwritten. That's probably because the previous script with a init statement (02screens) does not contain a python block. Using just "python:" doesn't work, although the game compiles and runs anyway, which I think is due to the fact that the function it's overwriting is a part of an "init python" statement, therefore cannot be changed afterwards unless it's reinitialized. Anways just my two cents.