crispy-doom icon indicating copy to clipboard operation
crispy-doom copied to clipboard

Vertical Aiming - Direct causes lots of bugs at Doom 2 MAP30 Icon of Sin

Open SoDOOManiac opened this issue 1 year ago • 12 comments

Background

Version of Crispy Doom: daily build December 4, 2022, also 5.11.1 and 5.9.2

Operating System and version: Win 7, Win 10

Game: v1.666 Doom 2: Hell on Earth

Any loaded WADs and mods (please include full command line): crispy-doom -iwad doom2v16.wad

Bug description

Observed behavior: with Vertical Aiming: Direct the following bugs can happen in the Icon of Sin MAP30 level -

  1. Ghost monster (baron of hell in the video, all projectiles and hitscan shots go through him doing no harm with no collision) https://www.youtube.com/watch?v=7--wg1zjwXc

  2. Monster telefrag by the following Icon of Sin-launched monsters (not sure if it's a bug actually) https://www.youtube.com/watch?v=RvHD02aRVcA Icon_of_Sin_telefrag

Savegame IoS+Direct_Aiming_ghost_monster_and_telefrags.zip

Expected behavior: These bugs shouldn't happen with any vertical aiming setting.

SoDOOManiac avatar Dec 04 '22 06:12 SoDOOManiac

Why are you so convinced that these correlate with direct vertical aiming?

fabiangreffrath avatar Dec 05 '22 10:12 fabiangreffrath

  1. Monster telefrag by the following Icon of Sin-launched monsters (not sure if it's a bug actually)

Seems like monsters can do telefrags specifically on MAP30: https://github.com/fabiangreffrath/crispy-doom/blob/6a6d6c88086a03d71527707fcdfd447a008d297b/src/doom/p_map.c#L118-L120

fabiangreffrath avatar Dec 05 '22 10:12 fabiangreffrath

  1. Ghost monster (baron of hell in the video, all projectiles and hitscan shots go through him doing no harm with no collision)

Could just as well be the all-ghosts bug triggerred by an intercepts overflow.

Savegame [IoS+Direct_Aiming_ghost_monster_and_telefrags.zip]

DO you have the demo file for the videos?

fabiangreffrath avatar Dec 05 '22 10:12 fabiangreffrath

DO you have the demo file for the videos?

I probably forgot there won't be a valid demo recording with direct vertical aiming. 😆

fabiangreffrath avatar Dec 05 '22 12:12 fabiangreffrath

Why are you so convinced that these correlate with direct vertical aiming?

Because with the value Autoaim or Both (where autoaim is used in case of horizontal alignment with the enemy) this behavior doesn't occur, the shots hit this Baron properly.

SoDOOManiac avatar Dec 06 '22 15:12 SoDOOManiac

Could just as well be the all-ghosts bug triggerred by an intercepts overflow.

Intercepts overflow in a vanilla level?

SoDOOManiac avatar Dec 27 '22 06:12 SoDOOManiac

Could just as well be the all-ghosts bug triggerred by an intercepts overflow.

Intercepts overflow in a vanilla level?

The intercepts overflow is possible on any level at all, and IoS is an unusually likely candidate due to the infinitely spawning monsters. It can happen on any level in Nightmare quite easily, or even outside of Nightmare if you are extraordinarily unlucky with fixed point rounding.

Phytolizer avatar Jan 19 '23 19:01 Phytolizer

The intercepts overflow is possible on any level at all, and IoS is an unusually likely candidate due to the infinitely spawning monsters. It can happen on any level in Nightmare quite easily, or even outside of Nightmare if you are extraordinarily unlucky with fixed point rounding.

While everything you say is right, what does "fixed point rounding" have to do with intercepts overflow?

fabiangreffrath avatar Jan 20 '23 07:01 fabiangreffrath

When traversing to find intercepts, the step size can be rounded incorrectly in one or both directions, and fail to reach the next blockmap square in one step. If there are intercepts in the affected block, they will be added repeatedly for a while (not forever, there is a hardcoded limit).

Phytolizer avatar Jan 20 '23 08:01 Phytolizer

I believe there is a good video reference about this case made by decino: https://www.youtube.com/watch?v=-IYfwCWZeD0 (starts in 6:50). And looks likes, this is how Zero Master achieved same bug at E1M8: https://www.youtube.com/watch?v=5vtijM0xZMc (starts in 5:00).

JNechaevsky avatar Jan 20 '23 08:01 JNechaevsky

Ah, right, there was this issue. I remember this being the culprit for lines sometimes getting skipped for interception checks, which in turn is the cause for the mancubus fireballs flying through the pillars in MAP07, right?

fabiangreffrath avatar Jan 20 '23 09:01 fabiangreffrath

No-no, this is slightly different thing. Again, nice video by decino: https://www.youtube.com/watch?v=kRC7hGDrNsM

In practice, it was partially fixed by Lee Killough: https://github.com/doomtech/winmbf/blob/trunk/Source/p_mobj.c#L174 Exactlly "partially", since this fix is working in ~95% of collisions, while there is still a small chance of clipping though the wall. Such clipping can be easily noticed on nuts.wad with fast monsters.

JNechaevsky avatar Jan 20 '23 09:01 JNechaevsky