Falling sand and gravel
[oweals/minetest.git] / src / main.cpp
index b25b2fa350d47096229c1a9e8bbb439a6727be27..0646494fcf51fbcfd4f48059f1c036bc33facb98 100644 (file)
@@ -334,11 +334,6 @@ TODO: Add a long step function to objects that is called with the time
 Map:
 ----
 
-TODO: Mineral and ground material properties
-      - This way mineral ground toughness can be calculated with just
-           some formula, as well as tool strengths. Sounds too.
-         - There are TODOs in appropriate files: material.h, content_mapnode.h
-
 TODO: Flowing water to actually contain flow direction information
       - There is a space for this - it just has to be implemented.
 
@@ -365,11 +360,6 @@ SUGG: Restart irrlicht completely when coming back to main menu from game.
 
 TODO: Merge bahamada's audio stuff (clean patch available)
 
-TODO: Move content_features to mapnode_content_features.{h,cpp} or so
-
-TODO: Fix item use() stuff; dropping a stack of cooked rats and eating
-      it gives 3 hearts and consumes all the rats.
-
 Making it more portable:
 ------------------------
  
@@ -390,11 +380,11 @@ Doing currently:
 */
 
 #ifdef NDEBUG
-       #ifdef _WIN32
+       /*#ifdef _WIN32
                #pragma message ("Disabling unit tests")
        #else
                #warning "Disabling unit tests"
-       #endif
+       #endif*/
        // Disable unit tests
        #define ENABLE_TESTS 0
 #else
@@ -440,9 +430,6 @@ Doing currently:
 #include "profiler.h"
 #include "log.h"
 
-// This makes textures
-ITextureSource *g_texturesource = NULL;
-
 /*
        Settings.
        These are loaded from the config file.
@@ -1278,9 +1265,7 @@ int main(int argc, char *argv[])
                These are needed for unit tests at least.
        */
        
-       // Initial call with g_texturesource not set.
-       init_mapnode();
-       // Must be called before g_texturesource is created
+       // Must be called before texturesource is created
        // (for texture atlas making)
        init_mineral();
 
@@ -1431,9 +1416,6 @@ int main(int argc, char *argv[])
        // Create game callback for menus
        g_gamecallback = new MainGameCallback(device);
        
-       // Create texture source
-       g_texturesource = new TextureSource(device);
-
        /*
                Speed tests (done after irrlicht is loaded to get timer)
        */
@@ -1478,12 +1460,6 @@ int main(int argc, char *argv[])
        skin->setColor(gui::EGDC_3D_HIGH_LIGHT, video::SColor(255,0,0,0));
        skin->setColor(gui::EGDC_3D_SHADOW, video::SColor(255,0,0,0));
        
-       /*
-               Preload some textures and stuff
-       */
-
-       init_mapnode(); // Second call with g_texturesource set
-
        /*
                GUI stuff
        */
@@ -1547,6 +1523,7 @@ int main(int argc, char *argv[])
                                menudata.fancy_trees = g_settings->getBool("new_style_leaves");
                                menudata.smooth_lighting = g_settings->getBool("smooth_lighting");
                                menudata.clouds_3d = g_settings->getBool("enable_3d_clouds");
+                               menudata.opaque_water = g_settings->getBool("opaque_water");
                                menudata.creative_mode = g_settings->getBool("creative_mode");
                                menudata.enable_damage = g_settings->getBool("enable_damage");
 
@@ -1620,6 +1597,7 @@ int main(int argc, char *argv[])
                                g_settings->set("new_style_leaves", itos(menudata.fancy_trees));
                                g_settings->set("smooth_lighting", itos(menudata.smooth_lighting));
                                g_settings->set("enable_3d_clouds", itos(menudata.clouds_3d));
+                               g_settings->set("opaque_water", itos(menudata.opaque_water));
                                g_settings->set("creative_mode", itos(menudata.creative_mode));
                                g_settings->set("enable_damage", itos(menudata.enable_damage));
                                
@@ -1655,9 +1633,6 @@ int main(int argc, char *argv[])
                        if(device->run() == false)
                                break;
                        
-                       // Initialize mapnode again to enable changed graphics settings
-                       init_mapnode();
-
                        /*
                                Run game
                        */