Merge branch 'jartha/toxomister-balance' into 'master'

Toxomister Balance Tweaks

See merge request kart-krew-dev/ring-racers-internal!2700
This commit is contained in:
Oni VelocitOni 2025-07-23 22:46:54 +00:00
commit 7af083e557
2 changed files with 21 additions and 6 deletions

View file

@ -22826,13 +22826,13 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
S_NULL, // xdeathstate
sfx_None, // deathsound
0, // speed
70*FRACUNIT, // radius
35*FRACUNIT, // radius
70*FRACUNIT, // height
0, // display offset
0, // mass
0, // damage
sfx_None, // activesound
MF_SPECIAL|MF_NOGRAVITY|MF_DONTENCOREMAP, // flags
MF_SPECIAL|MF_NOGRAVITY|MF_DONTENCOREMAP|MF_ELEMENTAL, // flags
S_NULL // raisestate
},
};

View file

@ -18,6 +18,7 @@
#include "../doomdef.h"
#include "../doomtype.h"
#include "../g_game.h"
#include "../k_collide.h"
#include "../k_hud.h" // transflag
#include "../m_easing.h"
#include "../m_fixed.h"
@ -287,6 +288,12 @@ struct Cloud : Mobj
return false;
}
if (K_PuntCollide(this, follow()))
{
remove();
return false;
}
move_origin(follow()->pos());
momx = 0;
momy = 0;
@ -324,18 +331,22 @@ struct Cloud : Mobj
}
else
{
if (!fuse)
if (FixedHypot(momx, momy) > 2 * mapobjectscale)
{
fuse = 3*TICRATE;
instathrust(angle, 2 * mapobjectscale);
}
if (leveltime & 1)
if (fuse > 3*TICRATE)
{
renderflags ^= RF_DONTDRAW;
fuse = 3*TICRATE;
}
}
if (fuse <= 3*TICRATE && (leveltime & 1))
{
renderflags ^= RF_DONTDRAW;
}
return true;
}
@ -344,6 +355,9 @@ struct Cloud : Mobj
if (toucher == target())
return false;
if (K_PuntCollide(this, toucher))
return true;
if (toucher->player)
{
if (this == toucher->player->toxomisterCloud) // already attached
@ -396,6 +410,7 @@ void Pole::spawn_clouds_in_orbit()
cloud->spriteyoffset(24*FRACUNIT);
cloud->hitlag(2 + i * 4);
cloud->scale_between(1, cloud->scale(), cloud->scale() / 5);
cloud->fuse = 15*TICRATE;
a += a_incr;
}