So, I was playing with temporal token on trapdoor at room edges today, and I noticed several
edge casesthings worths fixing (ordered roughly by their complexity):
1. For some reason, pit, water and shallow water cannot be placed on a temporal token, but temporal token can be placed on them.
2. When a time clone points his sword at room edge and performs a move, the movement preview animation of him draws properly under the UI when he's rotating and when he's moving along the room edge, but not when he's moving
away from room edge. This results in weapon being drawn over the UI.
3. If the player's sword is pointing outside the room while the temporal token drops the trapdoor and kills the player, the game beeps and drod.err outputs stuff.
What is outputted depends on the sword's position when this is performed:
Let's call the following two message errors A and B respectively:
A:
Assertion error in line 47 of .\TrapdoorFallEffect.cpp: "this->pRoom->IsValidColRow(this->wCol, this->wRow)"
B:
Assertion error in line 6377 of .\DbRooms.cpp: "wX < this->wRoomCols"
Every time at least output an instance of A. However, the number of instance of B outputted after A depends on the sword's position: it can be 0, 1, some arbitrary number or every frame in the death animation.
It happens every frame if the sword's hypothetical coordinate warps back to a tile in the room that is a pit, platform on pit or trapdoor on pit: for example, if the player is at (37,15) and sword pointing SE, then the sword's hypothetical coordinate is (38,16), which translates to (0,17), and if this tile is either of the abovementioned tile, the game will output B for every frame in the death animation. This suggests that the bug probably has to do with array indexing.
If it warps back to such a tile, but the tile is along the bottom few rows, B will then output for a specific number of times during death animation. I suspect it has to do with the trapdoor animation falling beyond the bottom room edge, and hence isn't drawn anymore.
If it warps back to a tile in the room, but said tile is not one the abovementioned tiles, then B will only be outputted once.
If it doesn't warp back to a tile in the room, no B will be outputted.
This doesn't happen if the temporal clone is dropped instead, and happens with every kind of weapon (except daggers of course, since they don't drop trapdoors).
There is a demo hold attached that you can play with these bugs.
[Last edited by uncopy2002 at 11-30-2016 04:31 PM]