Hopefully fix ghosts without fucking my next branch

This commit is contained in:
Radicalicious 2021-06-18 01:08:41 -04:00
parent 87bcdb8643
commit 1160b97a41

View file

@ -784,6 +784,19 @@ void G_GhostTicker(void)
mobj = P_SpawnGhostMobj(g->mo); // does a large portion of the work for us mobj = P_SpawnGhostMobj(g->mo); // does a large portion of the work for us
mobj->frame = (mobj->frame & ~FF_FRAMEMASK)|tr_trans60<<FF_TRANSSHIFT; // P_SpawnGhostMobj sets trans50, we want trans60 mobj->frame = (mobj->frame & ~FF_FRAMEMASK)|tr_trans60<<FF_TRANSSHIFT; // P_SpawnGhostMobj sets trans50, we want trans60
} }
else if (type == MT_THOKEFFECT)
{
mobj = P_SpawnMobjFromMobj(g->mo, 0, 0, g->mo->scale * 24, type);
mobj->angle = g->mo->angle + ANGLE_90;
mobj->fuse = 7;
mobj->scale = FRACUNIT / 3;
mobj->destscale = 10*FRACUNIT;
mobj->colorized = true;
mobj->color = g->mo->color;
mobj->momx = -g->mo->momx / 2;
mobj->momy = -g->mo->momy / 2;
}
else else
{ {
mobj = P_SpawnMobjFromMobj(g->mo, 0, 0, -FixedDiv(FixedMul(g->mo->info->height, g->mo->scale) - g->mo->height,3*FRACUNIT), MT_THOK); mobj = P_SpawnMobjFromMobj(g->mo, 0, 0, -FixedDiv(FixedMul(g->mo->info->height, g->mo->scale) - g->mo->height,3*FRACUNIT), MT_THOK);
@ -1074,6 +1087,18 @@ void G_ReadMetalTic(mobj_t *metal)
{ {
mobj = P_SpawnGhostMobj(metal); // does a large portion of the work for us mobj = P_SpawnGhostMobj(metal); // does a large portion of the work for us
} }
else if (type == MT_THOKEFFECT)
{
mobj = P_SpawnMobjFromMobj(metal, 0, 0, metal->scale * 24, type);
mobj->angle = metal->angle + ANGLE_90;
mobj->fuse = 7;
mobj->scale = FRACUNIT / 3;
mobj->destscale = 10*FRACUNIT;
mobj->colorized = true;
mobj->color = metal->color;
mobj->momx = -metal->momx / 2;
mobj->momy = -metal->momy / 2;
}
else else
{ {
mobj = P_SpawnMobjFromMobj(metal, 0, 0, -FixedDiv(FixedMul(metal->info->height, metal->scale) - metal->height,3*FRACUNIT), MT_THOK); mobj = P_SpawnMobjFromMobj(metal, 0, 0, -FixedDiv(FixedMul(metal->info->height, metal->scale) - metal->height,3*FRACUNIT), MT_THOK);