diff options
author | Perttu Ahola <celeron55@gmail.com> | 2011-06-25 04:25:14 +0300 |
---|---|---|
committer | Perttu Ahola <celeron55@gmail.com> | 2011-06-25 04:25:14 +0300 |
commit | 7538b4c6201675c566c98b21c8ecddb798a14943 (patch) | |
tree | e61cbdb7c2d9fedd41e2793860aa26553c545f56 /src/content_mapnode.cpp | |
parent | 47e4eda4bb87cd9dc20dddf81ca473b523eeb150 (diff) | |
download | minetest-7538b4c6201675c566c98b21c8ecddb798a14943.tar.gz minetest-7538b4c6201675c566c98b21c8ecddb798a14943.tar.bz2 minetest-7538b4c6201675c566c98b21c8ecddb798a14943.zip |
New map generator added (and SQLite, messed up the commits at that time...) (import from temporary git repo)
Diffstat (limited to 'src/content_mapnode.cpp')
-rw-r--r-- | src/content_mapnode.cpp | 32 |
1 files changed, 29 insertions, 3 deletions
diff --git a/src/content_mapnode.cpp b/src/content_mapnode.cpp index ec236c63d..403fb66d3 100644 --- a/src/content_mapnode.cpp +++ b/src/content_mapnode.cpp @@ -36,6 +36,7 @@ void content_mapnode_init() // Read some settings bool new_style_water = g_settings.getBool("new_style_water"); bool new_style_leaves = g_settings.getBool("new_style_leaves"); + bool invisible_stone = g_settings.getBool("invisible_stone"); u8 i; ContentFeatures *f = NULL; @@ -48,6 +49,8 @@ void content_mapnode_init() f->is_ground_content = true; f->dug_item = std::string("MaterialItem ")+itos(CONTENT_COBBLE)+" 1"; setStoneLikeDiggingProperties(f->digging_properties, 1.0); + if(invisible_stone) + f->solidness = 0; // For debugging, hides regular stone i = CONTENT_GRASS; f = &content_features(i); @@ -81,11 +84,21 @@ void content_mapnode_init() i = CONTENT_SAND; f = &content_features(i); f->setAllTextures("sand.png"); + f->setInventoryTextureCube("sand.png", "sand.png", "sand.png"); f->param_type = CPT_MINERAL; f->is_ground_content = true; f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; setDirtLikeDiggingProperties(f->digging_properties, 1.0); + i = CONTENT_GRAVEL; + f = &content_features(i); + f->setAllTextures("gravel.png"); + f->setInventoryTextureCube("gravel.png", "gravel.png", "gravel.png"); + f->param_type = CPT_MINERAL; + f->is_ground_content = true; + f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + setDirtLikeDiggingProperties(f->digging_properties, 1.75); + i = CONTENT_TREE; f = &content_features(i); f->setAllTextures("tree.png"); @@ -146,6 +159,7 @@ void content_mapnode_init() i = CONTENT_WOOD; f = &content_features(i); f->setAllTextures("wood.png"); + f->setInventoryTextureCube("wood.png", "wood.png", "wood.png"); f->is_ground_content = true; f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; setWoodLikeDiggingProperties(f->digging_properties, 0.75); @@ -153,6 +167,7 @@ void content_mapnode_init() i = CONTENT_MESE; f = &content_features(i); f->setAllTextures("mese.png"); + f->setInventoryTextureCube("mese.png", "mese.png", "mese.png"); f->is_ground_content = true; f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; setStoneLikeDiggingProperties(f->digging_properties, 0.5); @@ -160,6 +175,7 @@ void content_mapnode_init() i = CONTENT_CLOUD; f = &content_features(i); f->setAllTextures("cloud.png"); + f->setInventoryTextureCube("cloud.png", "cloud.png", "cloud.png"); f->is_ground_content = true; f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; @@ -190,7 +206,8 @@ void content_mapnode_init() i = CONTENT_WATERSOURCE; f = &content_features(i); - f->setInventoryTexture("water.png"); + //f->setInventoryTexture("water.png"); + f->setInventoryTextureCube("water.png", "water.png", "water.png"); if(new_style_water) { f->solidness = 0; // drawn separately, makes no faces @@ -229,7 +246,7 @@ void content_mapnode_init() f->wall_mounted = true; f->air_equivalent = true; f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; - f->light_source = LIGHT_MAX; + f->light_source = LIGHT_MAX-1; f->digging_properties.set("", DiggingProperties(true, 0.0, 0)); i = CONTENT_SIGN_WALL; @@ -280,7 +297,16 @@ void content_mapnode_init() f->param_type = CPT_NONE; f->is_ground_content = true; f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; - setStoneLikeDiggingProperties(f->digging_properties, 1.0); + setStoneLikeDiggingProperties(f->digging_properties, 0.9); + + i = CONTENT_MOSSYCOBBLE; + f = &content_features(i); + f->setAllTextures("mossycobble.png"); + f->setInventoryTextureCube("mossycobble.png", "mossycobble.png", "mossycobble.png"); + f->param_type = CPT_NONE; + f->is_ground_content = true; + f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + setStoneLikeDiggingProperties(f->digging_properties, 0.8); i = CONTENT_STEEL; f = &content_features(i); |