]> git.lizzy.rs Git - minetest.git/blobdiff - src/tile.cpp
Changed the Heal Amount of Apples from 6 to 2
[minetest.git] / src / tile.cpp
index 27f86c732081366e986db4c5f4ffc949ac4313b0..73f2a85ea5c61bb545bf9964a28bbf248155a4ff 100644 (file)
@@ -495,11 +495,25 @@ void TextureSource::buildMainAtlas()
        core::dimension2d<u32> atlas_dim(1024,1024);
        video::IImage *atlas_img =
                        driver->createImage(video::ECF_A8R8G8B8, atlas_dim);
-       assert(atlas_img);
+       //assert(atlas_img);
+       if(atlas_img == NULL)
+       {
+               dstream<<"TextureSource::buildMainAtlas(): Failed to create atlas "
+                               "image; not building texture atlas."<<std::endl;
+               return;
+       }
 
        /*
-               A list of stuff to add. This should contain as much of the
-               stuff shown in game as possible, to minimize texture changes.
+               A list of stuff to include in the texture atlas.
+
+               It is a single-dimensional texture atlas due to the need to tile
+               textures.
+               
+               It should contain as much of the stuff shown in game as possible,
+               to minimize texture changes.
+
+               It fills up quickly, so do not add anything that isn't contained
+               in most MapBlocks. E.g. mese isn't suitable but stone is.
        */
 
        core::array<std::string> sourcelist;
@@ -518,13 +532,10 @@ void TextureSource::buildMainAtlas()
        sourcelist.push_back("cobble.png");
        sourcelist.push_back("mossycobble.png");
        sourcelist.push_back("gravel.png");
+       sourcelist.push_back("jungletree.png");
        
        sourcelist.push_back("stone.png^mineral_coal.png");
        sourcelist.push_back("stone.png^mineral_iron.png");
-       sourcelist.push_back("mud.png^mineral_coal.png");
-       sourcelist.push_back("mud.png^mineral_iron.png");
-       sourcelist.push_back("sand.png^mineral_coal.png");
-       sourcelist.push_back("sand.png^mineral_iron.png");
        
        // Padding to disallow texture bleeding
        s32 padding = 16;