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:
------------------------
#include "settings.h"
#include "profiler.h"
#include "log.h"
+#include "mapnode_contentfeatures.h" // For init_contentfeatures
+#include "content_mapnode.h" // For content_mapnode_init
// This makes textures
ITextureSource *g_texturesource = NULL;
These are needed for unit tests at least.
*/
- // Initial call with g_texturesource not set.
- init_mapnode();
+ // Initialize content feature table
+ init_contentfeatures();
+ // Initialize mapnode content without textures (with g_texturesource=NULL)
+ content_mapnode_init();
// Must be called before g_texturesource is created
// (for texture atlas making)
init_mineral();
Preload some textures and stuff
*/
- init_mapnode(); // Second call with g_texturesource set
+ // Initialize mapnode content with textures (with g_texturesource!=NULL)
+ content_mapnode_init();
/*
GUI stuff
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");
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));
break;
// Initialize mapnode again to enable changed graphics settings
- init_mapnode();
+ // Initialize content feature table
+ init_contentfeatures();
+ // Initialize mapnode content with textures (with g_texturesource!=NULL)
+ content_mapnode_init();
/*
Run game