Cleanup in content_mapblock (#5746)
[oweals/minetest.git] / src / content_cao.h
index 19fecdde53558e7d4fcd0902866ae62a68d022f2..412cdff12eaeb1b1827ee4ae51f92a33f4c4ed4f 100644 (file)
@@ -102,6 +102,8 @@ private:
        float m_anim_timer;
        ItemGroupList m_armor_groups;
        float m_reset_textures_timer;
+       std::string m_previous_texture_modifier; // stores texture modifier before punch update
+       std::string m_current_texture_modifier;  // last applied texture modifier
        bool m_visuals_expired;
        float m_step_distance_counter;
        u8 m_last_light;
@@ -132,7 +134,7 @@ public:
 
        bool getCollisionBox(aabb3f *toset) const;
 
-       bool collideWithObjects();
+       bool collideWithObjects() const;
 
        aabb3f *getSelectionBox();
 
@@ -144,19 +146,8 @@ public:
 
        scene::ISceneNode *getSceneNode();
 
-       scene::IMeshSceneNode *getMeshSceneNode();
-
        scene::IAnimatedMeshSceneNode *getAnimatedMeshSceneNode();
 
-       WieldMeshSceneNode *getWieldMeshSceneNode();
-
-       scene::IBillboardSceneNode *getSpriteSceneNode();
-
-       inline bool isPlayer() const
-       {
-               return m_is_player;
-       }
-
        inline bool isLocalPlayer() const
        {
                return m_is_local_player;
@@ -198,7 +189,9 @@ public:
 
        void updateTexturePos();
 
-       void updateTextures(const std::string &mod);
+       // std::string copy is mandatory as mod can be a class member and there is a swap
+       // on those class members
+       void updateTextures(std::string mod);
 
        void updateAnimation();