Accept a ConstPtr in getSound

openmw-38
scrawl 9 years ago
parent d77f785cbc
commit d120f76031

@ -250,7 +250,7 @@ namespace MWClass
return std::make_pair(1,"");
}
std::string Light::getSound(const MWWorld::Ptr& ptr) const
std::string Light::getSound(const MWWorld::ConstPtr& ptr) const
{
return ptr.get<ESM::Light>()->mBase->mSound;
}

@ -73,7 +73,7 @@ namespace MWClass
std::pair<int, std::string> canBeEquipped(const MWWorld::ConstPtr &ptr, const MWWorld::Ptr &npc) const;
virtual std::string getSound(const MWWorld::Ptr& ptr) const;
virtual std::string getSound(const MWWorld::ConstPtr& ptr) const;
};
}

@ -428,7 +428,7 @@ namespace MWWorld
return getEncumbrance(ptr) / capacity;
}
std::string Class::getSound(const MWWorld::Ptr&) const
std::string Class::getSound(const MWWorld::ConstPtr&) const
{
return std::string();
}

@ -336,7 +336,7 @@ namespace MWWorld
virtual void restock (const MWWorld::Ptr& ptr) const {}
/// Returns sound id
virtual std::string getSound(const MWWorld::Ptr& ptr) const;
virtual std::string getSound(const MWWorld::ConstPtr& ptr) const;
virtual int getBaseFightRating (const MWWorld::Ptr& ptr) const;

Loading…
Cancel
Save