1. I had to extract scripts.rpa file to get access to the .rpyc scripts within
2. Then, I'd used unrpyc to quickly convert all of them into human readable .rpy un-compiled format (I think .rpyc might have been able to read directly from .rpa without having to extract
3. From the traceback crash log, I know which script exactly and which line of it was causing the crash.
4. Looking at the exact problematic line, I could see the way the ep5_end_vars variable was being set was causing issues.
5. Using Visual Studio Code editor, I'd opened the whole game folder so I could do a mass file search for the text "ep5_end_vars" so I could investigate what this variable was actually intended to be used.
6. From there, I figured it was supposed to be an array of 7 booleans starting as [0,0,0,0,0,0], but the script erroneously sets it as an int value (ep5_end_vars = 1) at three different points of the script (the 3 scenes), hence the int-type related exception.
7. There are other instances of script where they "correctly" work with ep5_end_vars as an array (e.g. ep5_end_vars[5] = 1). Basically, after any of the problem scenes, the variable had turned into an int and will crash the next instance it's used like an array (which looks to include anytime you end a day at night too).
8. I'd simply just modified the int-style instances to work with an array so you ultimately can get a complete [1,1,1,1,1,1] which the game's script references to determine if you've seen everything on Episode 5 so it can trigger the next episode beginning.