Buff Spikes

Both Vertical and Wallspikes size and increase, vertical spikes tumble, speed is now TICRATE instead of 2*TICRATE
This commit is contained in:
VelocitOni 2023-03-08 22:02:24 -05:00
parent 86990d47d2
commit 23b04832ad
2 changed files with 6 additions and 6 deletions

View file

@ -8880,8 +8880,8 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
S_SPIKED2, // xdeathstate
sfx_mspogo, // deathsound
2*TICRATE, // speed
8*FRACUNIT, // radius
32*FRACUNIT, // height
14*FRACUNIT, // radius
64*FRACUNIT, // height
0, // display offset
4, // mass
0, // damage

View file

@ -1257,11 +1257,11 @@ static BlockItReturn_t PIT_CheckThing(mobj_t *thing)
{
if (thing->z + thing->height <= tm.thing->z + FixedMul(FRACUNIT, tm.thing->scale)
&& thing->z + thing->height + thing->momz >= tm.thing->z + FixedMul(FRACUNIT, tm.thing->scale) + tm.thing->momz)
P_DamageMobj(thing, tm.thing, tm.thing, 1, DMG_NORMAL);
P_DamageMobj(thing, tm.thing, tm.thing, 1, DMG_TUMBLE);
}
else if (thing->z >= tm.thing->z + tm.thing->height - FixedMul(FRACUNIT, tm.thing->scale)
&& thing->z + thing->momz <= tm.thing->z + tm.thing->height - FixedMul(FRACUNIT, tm.thing->scale) + tm.thing->momz)
P_DamageMobj(thing, tm.thing, tm.thing, 1, DMG_NORMAL);
P_DamageMobj(thing, tm.thing, tm.thing, 1, DMG_TUMBLE);
}
else if (thing->type == MT_SPIKE && thing->flags & MF_SOLID && tm.thing->player) // unfortunate player falls into spike?!
{
@ -1269,11 +1269,11 @@ static BlockItReturn_t PIT_CheckThing(mobj_t *thing)
{
if (tm.thing->z + tm.thing->height <= thing->z - FixedMul(FRACUNIT, thing->scale)
&& tm.thing->z + tm.thing->height + tm.thing->momz >= thing->z - FixedMul(FRACUNIT, thing->scale))
P_DamageMobj(tm.thing, thing, thing, 1, DMG_NORMAL);
P_DamageMobj(tm.thing, thing, thing, 1, DMG_TUMBLE);
}
else if (tm.thing->z >= thing->z + thing->height + FixedMul(FRACUNIT, thing->scale)
&& tm.thing->z + tm.thing->momz <= thing->z + thing->height + FixedMul(FRACUNIT, thing->scale))
P_DamageMobj(tm.thing, thing, thing, 1, DMG_NORMAL);
P_DamageMobj(tm.thing, thing, thing, 1, DMG_TUMBLE);
}
if (tm.thing->type == MT_WALLSPIKE && tm.thing->flags & MF_SOLID && thing->player) // wall spike impales player