Update inventory texture too
[oweals/minetest.git] / src / mapblock.h
index 18b679cfc9fcee0bc426f26094de2fe1abea5482..e7fd932b8e2395e7613a53a8f91bdc98fd69fefd 100644 (file)
@@ -38,6 +38,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
 
 class Map;
 class NodeMetadataList;
+class IGameDef;
 
 #define BLOCK_TIMESTAMP_UNDEFINED 0xffffffff
 
@@ -118,7 +119,7 @@ public:
 class MapBlock /*: public NodeContainer*/
 {
 public:
-       MapBlock(Map *parent, v3s16 pos, bool dummy=false);
+       MapBlock(Map *parent, v3s16 pos, IGameDef *gamedef, bool dummy=false);
        ~MapBlock();
        
        /*virtual u16 nodeContainerId() const
@@ -391,12 +392,13 @@ public:
                                getNodeParentNoEx(p + face_dir),
                                face_dir);
        }*/
-       u8 getFaceLight2(u32 daynight_ratio, v3s16 p, v3s16 face_dir)
+       u8 getFaceLight2(u32 daynight_ratio, v3s16 p, v3s16 face_dir,
+                       INodeDefManager *nodemgr)
        {
                return getFaceLight(daynight_ratio,
                                getNodeParentNoEx(p),
                                getNodeParentNoEx(p + face_dir),
-                               face_dir);
+                               face_dir, nodemgr);
        }
        
 #ifndef SERVER // Only on client
@@ -587,6 +589,8 @@ private:
        Map *m_parent;
        // Position in blocks on parent
        v3s16 m_pos;
+
+       IGameDef *m_gamedef;
        
        /*
                If NULL, block is a dummy block.