mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-03-17 19:20:49 +00:00
Merge branch 'we-are-anonymous-we-are-quivers-apparently' into 'master'
Don't return a random anonymous node from getArrowBone when the current weapon doesn't fire arrows. Closes #6718 See merge request OpenMW/openmw!1822
This commit is contained in:
commit
bbec296891
@ -116,6 +116,7 @@
|
||||
Bug #6697: Shaders vertex lighting incorrectly clamped
|
||||
Bug #6711: Log time differs from real time
|
||||
Bug #6717: Broken script causes interpreter stack corruption
|
||||
Bug #6718: Throwable weapons cause arrow enchantment effect to be applied to the whole body
|
||||
Feature #890: OpenMW-CS: Column filtering
|
||||
Feature #1465: "Reset" argument for AI functions
|
||||
Feature #2491: Ability to make OpenMW "portable"
|
||||
|
@ -232,6 +232,8 @@ osg::Group *CreatureWeaponAnimation::getArrowBone()
|
||||
|
||||
int type = weapon->get<ESM::Weapon>()->mBase->mData.mType;
|
||||
int ammoType = MWMechanics::getWeaponType(type)->mAmmoType;
|
||||
if (ammoType == ESM::Weapon::None)
|
||||
return nullptr;
|
||||
|
||||
// Try to find and attachment bone in actor's skeleton, otherwise fall back to the ArrowBone in weapon's mesh
|
||||
osg::Group* bone = getBoneByName(MWMechanics::getWeaponType(ammoType)->mAttachBone);
|
||||
|
@ -1034,6 +1034,8 @@ osg::Group* NpcAnimation::getArrowBone()
|
||||
|
||||
int type = weapon->get<ESM::Weapon>()->mBase->mData.mType;
|
||||
int ammoType = MWMechanics::getWeaponType(type)->mAmmoType;
|
||||
if (ammoType == ESM::Weapon::None)
|
||||
return nullptr;
|
||||
|
||||
// Try to find and attachment bone in actor's skeleton, otherwise fall back to the ArrowBone in weapon's mesh
|
||||
osg::Group* bone = getBoneByName(MWMechanics::getWeaponType(ammoType)->mAttachBone);
|
||||
|
Loading…
x
Reference in New Issue
Block a user