From 50e4a65f99f8ae57dcb453f791ec1c3352eafce0 Mon Sep 17 00:00:00 2001 From: toaster Date: Fri, 21 Jun 2019 12:51:55 +0100 Subject: [PATCH] Correct some more oversights of switching to revitem for CA2_MELEE's particles. --- src/p_enemy.c | 3 +++ src/p_inter.c | 8 ++++---- src/r_things.c | 2 +- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/src/p_enemy.c b/src/p_enemy.c index 995635b3f..07d1b9746 100644 --- a/src/p_enemy.c +++ b/src/p_enemy.c @@ -6329,6 +6329,9 @@ void A_RecyclePowers(mobj_t *actor) players[recv_pl].ringweapons = weapons[send_pl]; players[recv_pl].currentweapon = weaponheld[send_pl]; + if (((players[recv_pl].powers[pw_shield] & SH_NOSTACK) == SH_PINK) && (players[recv_pl].revitem == MT_LHRT)) // Healers can't keep their buff. + players[recv_pl].powers[pw_shield] &= SH_STACK; + P_SpawnShieldOrb(&players[recv_pl]); if (P_IsLocalPlayer(&players[recv_pl])) P_RestoreMusic(&players[recv_pl]); diff --git a/src/p_inter.c b/src/p_inter.c index 49916c858..81f046e2e 100644 --- a/src/p_inter.c +++ b/src/p_inter.c @@ -2824,7 +2824,7 @@ static inline boolean P_TagDamage(mobj_t *target, mobj_t *inflictor, mobj_t *sou { if (inflictor->type == MT_LHRT && !(player->powers[pw_shield] & SH_NOSTACK)) { - if (player->spinitem != MT_LHRT && player->revitem != MT_LHRT && player->thokitem != MT_LHRT) // Healers do not get to heal other healers. + if (player->revitem != MT_LHRT) // Healers do not get to heal other healers. { P_SwitchShield(player, SH_PINK); S_StartSound(target, mobjinfo[MT_PITY_ICON].seesound); @@ -2839,7 +2839,7 @@ static inline boolean P_TagDamage(mobj_t *target, mobj_t *inflictor, mobj_t *sou { if (inflictor->type == MT_LHRT && !(player->powers[pw_shield] & SH_NOSTACK)) { - if (player->spinitem != MT_LHRT && player->revitem != MT_LHRT && player->thokitem != MT_LHRT) // Healers do not get to heal other healers. + if (player->revitem != MT_LHRT) // Healers do not get to heal other healers. { P_SwitchShield(player, SH_PINK); S_StartSound(target, mobjinfo[MT_PITY_ICON].seesound); @@ -2924,7 +2924,7 @@ static inline boolean P_PlayerHitsPlayer(mobj_t *target, mobj_t *inflictor, mobj { if (gametype == GT_COOP && inflictor->type == MT_LHRT && !(player->powers[pw_shield] & SH_NOSTACK)) // co-op only { - if (player->spinitem != MT_LHRT && player->revitem != MT_LHRT && player->thokitem != MT_LHRT) // Healers do not get to heal other healers. + if (player->revitem != MT_LHRT) // Healers do not get to heal other healers. { P_SwitchShield(player, SH_PINK); S_StartSound(target, mobjinfo[MT_PITY_ICON].seesound); @@ -2947,7 +2947,7 @@ static inline boolean P_PlayerHitsPlayer(mobj_t *target, mobj_t *inflictor, mobj { if (inflictor->type == MT_LHRT && !(player->powers[pw_shield] & SH_NOSTACK)) { - if (player->spinitem != MT_LHRT && player->revitem != MT_LHRT && player->thokitem != MT_LHRT) // Healers do not get to heal other healers. + if (player->revitem != MT_LHRT) // Healers do not get to heal other healers. { P_SwitchShield(player, SH_PINK); S_StartSound(target, mobjinfo[MT_PITY_ICON].seesound); diff --git a/src/r_things.c b/src/r_things.c index 9b5cbc09a..22c3d96c9 100644 --- a/src/r_things.c +++ b/src/r_things.c @@ -2704,7 +2704,7 @@ void SetPlayerSkinByNum(INT32 playernum, INT32 skinnum) player->revitem = skin->revitem < 0 ? (mobjtype_t)mobjinfo[MT_PLAYER].raisestate : (UINT32)skin->revitem; player->followitem = skin->followitem; - if (((player->powers[pw_shield] & SH_NOSTACK) == SH_PINK) && (player->spinitem == MT_LHRT)) // Healers can't keep their buff. + if (((player->powers[pw_shield] & SH_NOSTACK) == SH_PINK) && (player->revitem == MT_LHRT)) // Healers can't keep their buff. player->powers[pw_shield] &= SH_STACK; player->actionspd = skin->actionspd;