Broly: scale hitbox

This commit is contained in:
James R 2023-12-07 15:42:58 -08:00
parent c5f421831f
commit a96a64dff6
2 changed files with 5 additions and 3 deletions

View file

@ -30674,8 +30674,8 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
S_NULL, // xdeathstate
sfx_None, // deathsound
0, // speed
0, // radius
0, // height
40*FRACUNIT, // radius
80*FRACUNIT, // height
0, // display offset
100, // mass
1, // damage

View file

@ -64,7 +64,7 @@ struct Broly : Mobj
x->target(source);
// Shrink into center of source object.
x->z = (source->z + source->height / 2);
x->z = source->center().z - (x->height / 2);
x->colorized = true;
x->color = source->color;
@ -90,9 +90,11 @@ struct Broly : Mobj
return false;
}
const Fixed center = z + (height / 2);
const Vec2<Fixed> v = size();
scale(Easing_OutSine(linear(), v.y, v.x));
z = center - (height / 2);
return true;
}