From faabca552fa6fe5a0952395fd08cbdf3740caaa4 Mon Sep 17 00:00:00 2001 From: toasterbabe Date: Sun, 4 Jun 2017 00:48:32 +0100 Subject: [PATCH] Okay, I guess this DID need to be done. (Something from the old nights fixes branch which I didn't port over initially.) --- src/p_user.c | 1 - src/r_things.c | 5 +++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/p_user.c b/src/p_user.c index 8868a558b..7ea6c9269 100644 --- a/src/p_user.c +++ b/src/p_user.c @@ -667,7 +667,6 @@ void P_NightserizePlayer(player_t *player, INT32 nighttime) { player->mo->skin = &skins[DEFAULTNIGHTSSKIN]; player->mo->color = skins[DEFAULTNIGHTSSKIN].prefcolor; - player->mo->radius = FixedMul(skins[DEFAULTNIGHTSSKIN].radius, player->mo->scale); } player->nightstime = player->startedtime = nighttime*TICRATE; diff --git a/src/r_things.c b/src/r_things.c index d71a7e7a1..3b50eb106 100644 --- a/src/r_things.c +++ b/src/r_things.c @@ -2669,16 +2669,17 @@ void SetPlayerSkinByNum(INT32 playernum, INT32 skinnum) if (player->mo) { + fixed_t radius = FixedMul(skin->radius, player->mo->scale); if ((player->powers[pw_carry] == CR_NIGHTSMODE) && (skin->sprites[SPR2_NGT0].numframes == 0)) // If you don't have a sprite for flying horizontally, use the default NiGHTS skin. { skin = &skins[DEFAULTNIGHTSSKIN]; - newcolor = ((skin->flags & SF_SUPER) ? skin->supercolor : skin->prefcolor); + newcolor = skin->prefcolor; // will be updated in thinker to flashing } player->mo->skin = skin; if (newcolor) player->mo->color = newcolor; P_SetScale(player->mo, player->mo->scale); - player->mo->radius = FixedMul(skin->radius, player->mo->scale); + player->mo->radius = radius; P_SetPlayerMobjState(player->mo, player->mo->state-states); // Prevent visual errors when switching between skins with differing number of frames }