forked from teamnwah/openmw-tes3coop
Thrown weapons, arrows and bolts shouldn't have item health
This commit is contained in:
parent
20774f8f81
commit
78f3f19f62
1 changed files with 4 additions and 1 deletions
|
@ -75,7 +75,10 @@ namespace MWClass
|
|||
|
||||
bool Weapon::hasItemHealth (const MWWorld::Ptr& ptr) const
|
||||
{
|
||||
return true;
|
||||
MWWorld::LiveCellRef<ESM::Weapon> *ref =
|
||||
ptr.get<ESM::Weapon>();
|
||||
|
||||
return (ref->mBase->mData.mType < 11); // thrown weapons and arrows/bolts don't have health, only quantity
|
||||
}
|
||||
|
||||
int Weapon::getItemMaxHealth (const MWWorld::Ptr& ptr) const
|
||||
|
|
Loading…
Reference in a new issue