Fix -Winconsistent-missing-override warnings

This commit is contained in:
Desour 2023-08-29 14:34:13 +02:00 committed by Gregor Parzefall
parent 2ad4c9e0ce
commit 7897450b27
2 changed files with 26 additions and 26 deletions

View File

@ -144,7 +144,7 @@ public:
return new GenericCAO(client, env); return new GenericCAO(client, env);
} }
inline ActiveObjectType getType() const inline ActiveObjectType getType() const override
{ {
return ACTIVEOBJECT_TYPE_GENERIC; return ACTIVEOBJECT_TYPE_GENERIC;
} }
@ -152,15 +152,15 @@ public:
{ {
return m_armor_groups; return m_armor_groups;
} }
void initialize(const std::string &data); void initialize(const std::string &data) override;
void processInitData(const std::string &data); void processInitData(const std::string &data);
bool getCollisionBox(aabb3f *toset) const; bool getCollisionBox(aabb3f *toset) const override;
bool collideWithObjects() const; bool collideWithObjects() const override;
virtual bool getSelectionBox(aabb3f *toset) const; virtual bool getSelectionBox(aabb3f *toset) const override;
const v3f getPosition() const override final; const v3f getPosition() const override final;
@ -172,9 +172,9 @@ public:
inline const ObjectProperties &getProperties() const { return m_prop; } inline const ObjectProperties &getProperties() const { return m_prop; }
scene::ISceneNode *getSceneNode() const; scene::ISceneNode *getSceneNode() const override;
scene::IAnimatedMeshSceneNode *getAnimatedMeshSceneNode() const; scene::IAnimatedMeshSceneNode *getAnimatedMeshSceneNode() const override;
// m_matrixnode controls the position and rotation of the child node // m_matrixnode controls the position and rotation of the child node
// for all scene nodes, as a workaround for an Irrlicht problem with // for all scene nodes, as a workaround for an Irrlicht problem with
@ -201,7 +201,7 @@ public:
return m_prop.stepheight; return m_prop.stepheight;
} }
inline bool isLocalPlayer() const inline bool isLocalPlayer() const override
{ {
return m_is_local_player; return m_is_local_player;
} }
@ -218,28 +218,28 @@ public:
void setChildrenVisible(bool toset); void setChildrenVisible(bool toset);
void setAttachment(int parent_id, const std::string &bone, v3f position, void setAttachment(int parent_id, const std::string &bone, v3f position,
v3f rotation, bool force_visible); v3f rotation, bool force_visible) override;
void getAttachment(int *parent_id, std::string *bone, v3f *position, void getAttachment(int *parent_id, std::string *bone, v3f *position,
v3f *rotation, bool *force_visible) const; v3f *rotation, bool *force_visible) const override;
void clearChildAttachments(); void clearChildAttachments() override;
void clearParentAttachment(); void clearParentAttachment() override;
void addAttachmentChild(int child_id); void addAttachmentChild(int child_id) override;
void removeAttachmentChild(int child_id); void removeAttachmentChild(int child_id) override;
ClientActiveObject *getParent() const; ClientActiveObject *getParent() const override;
const std::unordered_set<int> &getAttachmentChildIds() const const std::unordered_set<int> &getAttachmentChildIds() const override
{ return m_attachment_child_ids; } { return m_attachment_child_ids; }
void updateAttachments(); void updateAttachments() override;
void removeFromScene(bool permanent); void removeFromScene(bool permanent) override;
void addToScene(ITextureSource *tsrc, scene::ISceneManager *smgr); void addToScene(ITextureSource *tsrc, scene::ISceneManager *smgr) override;
inline void expireVisuals() inline void expireVisuals()
{ {
m_visuals_expired = true; m_visuals_expired = true;
} }
void updateLight(u32 day_night_ratio); void updateLight(u32 day_night_ratio) override;
void setNodeLight(const video::SColor &light); void setNodeLight(const video::SColor &light);
@ -254,7 +254,7 @@ public:
void updateNodePos(); void updateNodePos();
void step(float dtime, ClientEnvironment *env); void step(float dtime, ClientEnvironment *env) override;
void updateTexturePos(); void updateTexturePos();
@ -268,14 +268,14 @@ public:
void updateBonePosition(); void updateBonePosition();
void processMessage(const std::string &data); void processMessage(const std::string &data) override;
bool directReportPunch(v3f dir, const ItemStack *punchitem=NULL, bool directReportPunch(v3f dir, const ItemStack *punchitem=NULL,
float time_from_last_punch=1000000); float time_from_last_punch=1000000) override;
std::string debugInfoText(); std::string debugInfoText() override;
std::string infoText() std::string infoText() override
{ {
return m_prop.infotext; return m_prop.infotext;
} }

View File

@ -578,7 +578,7 @@ public:
m_saturation_pixel.set(&saturation, services); m_saturation_pixel.set(&saturation, services);
} }
void onSetMaterial(const video::SMaterial &material) void onSetMaterial(const video::SMaterial &material) override
{ {
video::ITexture *texture = material.getTexture(0); video::ITexture *texture = material.getTexture(0);
if (texture) { if (texture) {