Code: Select all
virtual void CheckWeaponChange ()
{
let player = self.player;
if ((player.WeaponState & WF_DISABLESWITCH) || // <----------------------------------------------------------------Aborts here
player.morphTics != 0) // Morphed classes cannot change weapons.
{ // ...so throw away any pending weapon requests.
player.PendingWeapon = WP_NOCHANGE;
}
// Put the weapon away if the player has a pending weapon or has died, and
// we're at a place in the state sequence where dropping the weapon is okay.
if ((player.PendingWeapon != WP_NOCHANGE || player.health <= 0) &&
player.WeaponState & WF_WEAPONSWITCHOK)
{
player.DropWeapon();
}
}
Code: Select all
if ((player.WeaponState & WF_DISABLESWITCH) ||