Skip to content

Commit

Permalink
Fixed|Hexen: Disable all weapon switching when morphed
Browse files Browse the repository at this point in the history
IssueID #2044
  • Loading branch information
skyjake committed Nov 24, 2018
1 parent 01a277a commit 196e80e
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions doomsday/apps/plugins/common/src/p_user.c
Expand Up @@ -1226,10 +1226,10 @@ void P_PlayerThinkWeapons(player_t *player)
}
else
// Check for weapon change.
#if __JHERETIC__ || __JHEXEN__
if(brain->changeWeapon != WT_NOCHANGE && !player->morphTics)
#if defined(__JHERETIC__) || defined(__JHEXEN__)
if (brain->changeWeapon != WT_NOCHANGE && !player->morphTics)
#else
if(brain->changeWeapon != WT_NOCHANGE)
if (brain->changeWeapon != WT_NOCHANGE)
#endif
{
// Direct slot selection.
Expand All @@ -1256,7 +1256,11 @@ void P_PlayerThinkWeapons(player_t *player)
(cand = P_WeaponSlotCycle(cand, brain->cycleWeapon < 0)) !=
first);
}
else if(brain->cycleWeapon)
#if defined(__JHERETIC__) || defined(__JHEXEN__)
if (brain->cycleWeapon && player->morphTics == 0)
#else
if (brain->cycleWeapon)
#endif
{
// Linear cycle.
newweapon = P_PlayerFindWeapon(player, brain->cycleWeapon < 0);
Expand Down

0 comments on commit 196e80e

Please sign in to comment.