- 7
- Posts
- 2
- Years
- Age 35
- he/him
- OR, USA
- Seen Jan 5, 2023
As you may have already sussed, I'm working with a fork of pokecrystal, and I'm getting a softlock upon whiting out (i.e., having all my Pokemon faint). The music keeps playing, so it's not a crash; I'm pretty sure the game's stuck in a loop trying to decide where to send me. You should normally be sent to the last Pokemon Center you visited, and I haven't changed that. The only thing I've done that's vaguely related is add some new possible spawn points, but it softlocks regardless of whether your last Pokemon Center was at one of these new spawn points or one of the original ones.
The code for whiting out seems to be in engine/events/whiteout.asm. You can see from the commit history that I haven't done anything to this file since I first created my fork.
At the bottom, there's "GetWhiteoutSpawn", which farcalls "IsSpawnPoint". I tracked that down to engine/overworld/spawn_points.asm, another file that I've never modified. It does contain a loop, but I don't understand assembly well enough to tell you much more than that.
As for adding the new spawn points, I followed the tutorial. It's really as simple as adding new entries to a few tables; you just want to make sure they're all in sync. The new spawn points work for other purposes such as Fly, so I don't know why they would cause a softlock.
If it's not the spawn points that's causing the softlock... then I have no idea what it is. I've certainly made lots of other changes, but I don't know what would've affected whiting out.
The code for whiting out seems to be in engine/events/whiteout.asm. You can see from the commit history that I haven't done anything to this file since I first created my fork.
At the bottom, there's "GetWhiteoutSpawn", which farcalls "IsSpawnPoint". I tracked that down to engine/overworld/spawn_points.asm, another file that I've never modified. It does contain a loop, but I don't understand assembly well enough to tell you much more than that.
As for adding the new spawn points, I followed the tutorial. It's really as simple as adding new entries to a few tables; you just want to make sure they're all in sync. The new spawn points work for other purposes such as Fly, so I don't know why they would cause a softlock.
If it's not the spawn points that's causing the softlock... then I have no idea what it is. I've certainly made lots of other changes, but I don't know what would've affected whiting out.