mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-04-10 06:44:29 +00:00
Accept a ConstPtr in getBloodTexture
This commit is contained in:
parent
2bd8d60e9f
commit
4a47fc32fa
@ -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;
|
int flags = ptr.get<ESM::Creature>()->mBase->mFlags;
|
||||||
|
|
||||||
|
@ -114,7 +114,7 @@ namespace MWClass
|
|||||||
virtual int getSkill(const MWWorld::Ptr &ptr, int skill) const;
|
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)
|
/// 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;
|
virtual void readAdditionalState (const MWWorld::Ptr& ptr, const ESM::ObjectState& state) const;
|
||||||
///< Read additional state from \a state into \a ptr.
|
///< Read additional state from \a state into \a ptr.
|
||||||
|
@ -1136,9 +1136,9 @@ namespace MWClass
|
|||||||
return ptr.getClass().getNpcStats(ptr).getSkill(skill).getModified();
|
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)
|
if (ref->mBase->mFlags & ESM::NPC::Skeleton)
|
||||||
return 1;
|
return 1;
|
||||||
|
@ -130,7 +130,7 @@ namespace MWClass
|
|||||||
virtual int getSkill(const MWWorld::Ptr& ptr, int skill) const;
|
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)
|
/// 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 {
|
virtual bool isActor() const {
|
||||||
return true;
|
return true;
|
||||||
|
@ -390,7 +390,7 @@ namespace MWWorld
|
|||||||
throw std::runtime_error("class does not support skills");
|
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");
|
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; };
|
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)
|
/// 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;
|
virtual Ptr copyToCell(const ConstPtr &ptr, CellStore &cell) const;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user