mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-03-03 15:49:40 +00:00
Accept a ConstPtr in getBloodTexture
This commit is contained in:
parent
2bd8d60e9f
commit
4a47fc32fa
6 changed files with 7 additions and 7 deletions
|
@ -675,7 +675,7 @@ namespace MWClass
|
|||
}
|
||||
}
|
||||
|
||||
int Creature::getBloodTexture(const MWWorld::Ptr &ptr) const
|
||||
int Creature::getBloodTexture(const MWWorld::ConstPtr &ptr) const
|
||||
{
|
||||
int flags = ptr.get<ESM::Creature>()->mBase->mFlags;
|
||||
|
||||
|
|
|
@ -114,7 +114,7 @@ namespace MWClass
|
|||
virtual int getSkill(const MWWorld::Ptr &ptr, int skill) const;
|
||||
|
||||
/// Get a blood texture suitable for \a ptr (see Blood Texture 0-2 in Morrowind.ini)
|
||||
virtual int getBloodTexture (const MWWorld::Ptr& ptr) const;
|
||||
virtual int getBloodTexture (const MWWorld::ConstPtr& ptr) const;
|
||||
|
||||
virtual void readAdditionalState (const MWWorld::Ptr& ptr, const ESM::ObjectState& state) const;
|
||||
///< Read additional state from \a state into \a ptr.
|
||||
|
|
|
@ -1136,9 +1136,9 @@ namespace MWClass
|
|||
return ptr.getClass().getNpcStats(ptr).getSkill(skill).getModified();
|
||||
}
|
||||
|
||||
int Npc::getBloodTexture(const MWWorld::Ptr &ptr) const
|
||||
int Npc::getBloodTexture(const MWWorld::ConstPtr &ptr) const
|
||||
{
|
||||
MWWorld::LiveCellRef<ESM::NPC> *ref = ptr.get<ESM::NPC>();
|
||||
const MWWorld::LiveCellRef<ESM::NPC> *ref = ptr.get<ESM::NPC>();
|
||||
|
||||
if (ref->mBase->mFlags & ESM::NPC::Skeleton)
|
||||
return 1;
|
||||
|
|
|
@ -130,7 +130,7 @@ namespace MWClass
|
|||
virtual int getSkill(const MWWorld::Ptr& ptr, int skill) const;
|
||||
|
||||
/// Get a blood texture suitable for \a ptr (see Blood Texture 0-2 in Morrowind.ini)
|
||||
virtual int getBloodTexture (const MWWorld::Ptr& ptr) const;
|
||||
virtual int getBloodTexture (const MWWorld::ConstPtr& ptr) const;
|
||||
|
||||
virtual bool isActor() const {
|
||||
return true;
|
||||
|
|
|
@ -390,7 +390,7 @@ namespace MWWorld
|
|||
throw std::runtime_error("class does not support skills");
|
||||
}
|
||||
|
||||
int Class::getBloodTexture (const MWWorld::Ptr& ptr) const
|
||||
int Class::getBloodTexture (const MWWorld::ConstPtr& ptr) const
|
||||
{
|
||||
throw std::runtime_error("class does not support gore");
|
||||
}
|
||||
|
|
|
@ -284,7 +284,7 @@ namespace MWWorld
|
|||
virtual bool isGold(const MWWorld::ConstPtr& ptr) const { return false; };
|
||||
|
||||
/// Get a blood texture suitable for \a ptr (see Blood Texture 0-2 in Morrowind.ini)
|
||||
virtual int getBloodTexture (const MWWorld::Ptr& ptr) const;
|
||||
virtual int getBloodTexture (const MWWorld::ConstPtr& ptr) const;
|
||||
|
||||
virtual Ptr copyToCell(const ConstPtr &ptr, CellStore &cell) const;
|
||||
|
||||
|
|
Loading…
Reference in a new issue