mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-03-12 13:13:27 +00:00
Fixes a regression with bound weapons equipping (bug #4050)
This commit is contained in:
parent
91dcd5bc6e
commit
0d7279ea2a
@ -374,7 +374,9 @@ namespace MWClass
|
||||
if (hasItemHealth(ptr) && ptr.getCellRef().getCharge() == 0)
|
||||
return std::make_pair(0, "#{sInventoryMessage1}");
|
||||
|
||||
if (MWBase::Environment::get().getMechanicsManager()->isAttackingOrSpell(npc))
|
||||
// Do not allow equip weapons from inventory during attack
|
||||
if (MWBase::Environment::get().getMechanicsManager()->isAttackingOrSpell(npc)
|
||||
&& MWBase::Environment::get().getWindowManager()->isGuiMode())
|
||||
return std::make_pair(0, "#{sCantEquipWeapWarning}");
|
||||
|
||||
std::pair<std::vector<int>, bool> slots_ = ptr.getClass().getEquipmentSlots(ptr);
|
||||
|
Loading…
x
Reference in New Issue
Block a user