ough. returning to code we wrote months and months ago like. wow, ok, how does this work again?? what is it doing??
ok. ok, nice. why did we write it like that, though?
soo we’ve ended up refactoring a lot! mainly because there was a bug we needed to fix! and I was struggling to read the script I needed to alter. it was… a bit of a mess? like, we had this one function trying to handle every possible time we’d need to change from one map to another.
but actually, “going through a door”, “loading a save”, “respawning the player”, and “starting a new game” all want slightly different things to happen?? so I broke everything down into smaller functions. it’s a little more repetitive, but also a little easier to navigate. I’m sure future me will go “wtf” and rearrange everything again but hey. it works well enough for now.
anyway! today I’m revisiting the turn-based battle script!
this one is less horrible to read, but also. um, we came up with an actual battle system design doc, and now I need to change the way the code is structured as a result! gah!
… ok, ok, I guess I can’t really complain. it feels nice to be making progress on nightmare_complex again :')