Fixed mapgen, added ores

This commit is contained in:
cale 2016-01-06 12:53:30 +01:00
parent 55dea851ee
commit 222216a882
25 changed files with 412 additions and 10 deletions

View File

@ -208,7 +208,7 @@ minetest.register_node("default:water_source", {
liquid_alternative_source = "default:water_source",
liquid_viscosity = 3,
groups = {liquid=3, water = 1},
post_effect_color = {a=100, r=0, g=64, b=200},
post_effect_color = {a=50, r=0, g=64, b=200},
})
minetest.register_node("default:water_flowing", {
@ -435,7 +435,7 @@ default.register_wool("black")
minetest.register_node("default:stone", {
description = "Stone",
tiles = {"default_stone.png"},
groups = {cracky = 3},
groups = {cracky = 3, stone= 1},
drop = "default:stone_item 5",
})
@ -513,3 +513,18 @@ minetest.register_node("default:stone_with_ruby", {
groups = {cracky = 1},
drop = "default:ruby",
})
-- rail
minetest.register_node("default:rail", {
description = "Rail",
drawtype = "raillike",
tiles = {"default_rail.png", "default_rail_curve.png",
"default_rail_t.png", "default_rail_cross.png"},
inventory_image = "default_rail.png",
wield_image = "default_rail.png",
paramtype = "light",
walkable = false,
groups = {choppy = 1, attached_node = 1},
})

View File

@ -208,7 +208,7 @@ minetest.register_node("default:water_source", {
liquid_alternative_source = "default:water_source",
liquid_viscosity = 3,
groups = {liquid=3, water = 1},
post_effect_color = {a=100, r=0, g=64, b=200},
post_effect_color = {a=50, r=0, g=64, b=200},
})
minetest.register_node("default:water_flowing", {
@ -435,7 +435,7 @@ default.register_wool("black")
minetest.register_node("default:stone", {
description = "Stone",
tiles = {"default_stone.png"},
groups = {cracky = 3},
groups = {cracky = 3, stone= 1},
drop = "default:stone_item 5",
})
@ -513,3 +513,18 @@ minetest.register_node("default:stone_with_ruby", {
groups = {cracky = 1},
drop = "default:ruby",
})
-- rail
minetest.register_node("default:rail", {
description = "Rail",
drawtype = "raillike",
tiles = {"default_rail.png", "default_rail_curve.png",
"default_rail_t.png", "default_rail_cross.png"},
inventory_image = "default_rail.png",
wield_image = "default_rail.png",
paramtype = "light",
walkable = false,
groups = {choppy = 1, attached_node = 1},
})

Binary file not shown.

After

Width:  |  Height:  |  Size: 303 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 421 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 436 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 433 B

16
mods/lava/LICENSE.txt Normal file
View File

@ -0,0 +1,16 @@
License for Code
----------------
Copyright (C) 2016 cd2 (cdqwertz) <cdqwertz@gmail.com>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation; either version 2.1 of the License, or
(at your option) any later version.
http://www.gnu.org/licenses/lgpl-2.1.html
License for Media
-----------------
CC-BY-SA 3.0 UNPORTED. Created by cd2 (cdqwertz)

71
mods/lava/init.lua Normal file
View File

@ -0,0 +1,71 @@
minetest.register_node("lava:lava_source", {
description = "Lava Source",
drawtype = "liquid",
tiles = {"lava_lava.png"},
walkable = false,
pointable = false,
diggable = false,
buildable = false,
buildable_to = true,
paramtype = "light",
alpha = 160,
drowning = 1,
liquidtype = "source",
liquid_alternative_flowing = "lava:lava_flowing",
liquid_alternative_source = "lava:lava_source",
liquid_viscosity = 6,
groups = {liquid=3, lava = 1},
post_effect_color = {a=100, r=200, g=64, b=0},
damage_per_second = 4 * 2,
light_source = 10,
})
minetest.register_node("lava:lava_flowing", {
description = "Lava Flowing",
tiles = {"lava_lava.png"},
special_tiles = {
{
name = "lava_lava.png",
backface_culling = false,
},
{
name = "lava_lava.png",
backface_culling = true,
},
},
walkable = false,
drawtype = "flowingliquid",
pointable = false,
diggable = false,
buildable = false,
buildable_to = true,
alpha = 160,
drowning = 1,
paramtype = "light",
liquidtype = "flowing",
liquid_alternative_flowing = "lava:lava_flowing",
liquid_alternative_source = "lava:lava_source",
liquid_viscosity = 6,
groups = {liquid=3, not_in_creative_inventory=1, lava = 1},
post_effect_color = {a=100, r=200, g=64, b=0},
damage_per_second = 4 * 2,
light_source = 10,
})
minetest.register_node("lava:basalt", {
description = "Basalt",
tiles = {"lava_basalt.png"},
groups = {cracky = 3, stone = 1},
})
minetest.register_abm({
nodenames = {"group:lava"},
neighbors = {"group:water"},
interval = 1.0,
chance = 1,
action = function(pos, node, active_object_count, active_object_count_wider)
minetest.set_node(pos, {name = "lava:basalt"})
end,
})
minetest.register_alias("mapgen_lava_source", "lava:lava_source")

71
mods/lava/init.lua~ Normal file
View File

@ -0,0 +1,71 @@
minetest.register_node("lava:lava_source", {
description = "Lava Source",
drawtype = "liquid",
tiles = {"lava_lava.png"},
walkable = false,
pointable = false,
diggable = false,
buildable = false,
buildable_to = true,
paramtype = "light",
alpha = 160,
drowning = 1,
liquidtype = "source",
liquid_alternative_flowing = "lava:lava_flowing",
liquid_alternative_source = "lava:lava_source",
liquid_viscosity = 6,
groups = {liquid=3, lava = 1},
post_effect_color = {a=100, r=200, g=64, b=0},
damage_per_second = 4 * 2,
light_source = 10,
})
minetest.register_node("lava:lava_flowing", {
description = "Lava Flowing",
tiles = {"lava_lava.png"},
special_tiles = {
{
name = "lava_lava.png",
backface_culling = false,
},
{
name = "lava_lava.png",
backface_culling = true,
},
},
walkable = false,
drawtype = "flowingliquid",
pointable = false,
diggable = false,
buildable = false,
buildable_to = true,
alpha = 160,
drowning = 1,
paramtype = "light",
liquidtype = "flowing",
liquid_alternative_flowing = "lava:lava_flowing",
liquid_alternative_source = "lava:lava_source",
liquid_viscosity = 6,
groups = {liquid=3, not_in_creative_inventory=1, lava = 1},
post_effect_color = {a=100, r=200, g=64, b=0},
damage_per_second = 4 * 2,
light_source = 10,
})
minetest.register_node("lava:basalt", {
description = "Basalt",
tiles = {"lava_basalt.png"},
groups = {cracky = 3, stone = 1},
})
minetest.register_abm({
nodenames = {"group:lava"},
neighbors = {"group:water"},
interval = 1.0,
chance = 1,
action = function(pos, node, active_object_count, active_object_count_wider)
minetest.set_node(pos, {name = "lava:basalt"})
end,
})
minetest.register_alias("mapgen_lava_source", "lava:lava_source")

Binary file not shown.

After

Width:  |  Height:  |  Size: 324 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 310 B

View File

@ -1,7 +1,7 @@
legendary_items = {}
legendary_items.register_rare_weapon = function(name, forlevel, def)
minetest.register_tool(":legendary_items:"..name, {
description = def.description.."\n For Level: ".. tostring(forlevel).. "\n Damage: " .. tostring(def.damage),
description = def.description.."\n For Level: ".. tostring(forlevel).. "\n Damage: " .. tostring(def.damage) .. "\n Rare Item",
inventory_image = def.inventory_image,
wield_scale = def.wield_scale,
tool_capabilities = {
@ -11,6 +11,17 @@ legendary_items.register_rare_weapon = function(name, forlevel, def)
})
end
-- rare
legendary_items.register_rare_weapon("old_hammer", 3, {
description = "Old Hammer",
inventory_image = "legendary_items_old_hammer.png",
wield_scale = {x = 2, y = 2, z =1},
damage = 20,
})
-- super rare
minetest.register_craftitem("legendary_items:paper", {
description = "The Legendary Paper",
inventory_image = "legendary_items_paper.png",

View File

@ -1,7 +1,7 @@
legendary_items = {}
legendary_items.register_rare_weapon = function(name, forlevel, def)
minetest.register_tool(":legendary_items:"..name, {
description = def.description.."\n For Level: ".. tostring(forlevel).. "\n Damage: " .. tostring(def.damage),
description = def.description.."\n For Level: ".. tostring(forlevel).. "\n Damage: " .. tostring(def.damage) .. "\n Rare Item",
inventory_image = def.inventory_image,
wield_scale = def.wield_scale,
tool_capabilities = {
@ -11,6 +11,17 @@ legendary_items.register_rare_weapon = function(name, forlevel, def)
})
end
-- rare
legendary_items.register_rare_weapon("old_hammer", 3, {
description = "Old Hammer",
inventory_image = "legendary_items_old_hammer.png",
wield_scale = {x = 2, y = 2, z =1},
damage = 20,
})
-- super rare
minetest.register_craftitem("legendary_items:paper", {
description = "The Legendary Paper",
inventory_image = "legendary_items_paper.png",

Binary file not shown.

After

Width:  |  Height:  |  Size: 297 B

View File

@ -5,9 +5,16 @@ minetest.register_node("quests:quest_block", {
on_punch = function(pos, node, player, pointed_thing)
local meta = minetest.get_meta(pos)
if meta:get_string("item") ~= "" then
return
end
local items = {"default:dirt", "default:sand", "default:iron_lump", "default:stone_item", "default:string"}
local item = items[math.random(5)]
meta:set_string("infotext", "Bring me some " .. item .. ", pls :)")
if minetest.registered_nodes[item] then
meta:set_string("infotext", "Bring me some " .. minetest.registered_nodes[item].description .. ", pls :)")
else
meta:set_string("infotext", "Bring me some " .. minetest.registered_craftitems[item].description .. ", pls :)")
end
meta:set_string("item", item)
end,
@ -20,7 +27,7 @@ minetest.register_node("quests:quest_block", {
end
if itemstack:to_table().name == meta:get_string("item") then
meta:set_string("infotext", "Thank you!")
player:get_inventory():add_item("main", {name = "default:xp"})
player:get_inventory():add_item("main", {name = "default:xp",count = math.random(10, 30)})
minetest.add_particlespawner({
amount = 500,
time = 5,

View File

@ -5,9 +5,16 @@ minetest.register_node("quests:quest_block", {
on_punch = function(pos, node, player, pointed_thing)
local meta = minetest.get_meta(pos)
if meta:get_string("item") ~= "" then
return
end
local items = {"default:dirt", "default:sand", "default:iron_lump", "default:stone_item", "default:string"}
local item = items[math.random(5)]
meta:set_string("infotext", "Bring me some " .. item .. ", pls :)")
if minetest.registered_nodes[item] then
meta:set_string("infotext", "Bring me some " .. minetest.registered_nodes[item].description .. ", pls :)")
else
meta:set_string("infotext", "Bring me some " .. minetest.registered_craftitems[item].description .. ", pls :)")
end
meta:set_string("item", item)
end,
@ -20,7 +27,7 @@ minetest.register_node("quests:quest_block", {
end
if itemstack:to_table().name == meta:get_string("item") then
meta:set_string("infotext", "Thank you!")
player:get_inventory():add_item("main", {name = "default:xp"})
player:get_inventory():add_item("main", {name = "default:xp",count = math.random(10, 30)})
minetest.add_particlespawner({
amount = 500,
time = 5,

16
mods/torch/LICENSE.txt Normal file
View File

@ -0,0 +1,16 @@
License for Code
----------------
Copyright (C) 2016 cd2 (cdqwertz) <cdqwertz@gmail.com>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation; either version 2.1 of the License, or
(at your option) any later version.
http://www.gnu.org/licenses/lgpl-2.1.html
License for Media
-----------------
CC-BY-SA 3.0 UNPORTED. Created by cd2 (cdqwertz)

56
mods/torch/init.lua Normal file
View File

@ -0,0 +1,56 @@
minetest.register_node("torch:torch", {
description = "Torch",
tiles = {"torch_wood.png"},
drawtype = "mesh",
mesh = "torch_torch.obj",
groups = {crumbly = 3},
paramtype = "light",
paramtype2 = "facedir",
light_source = 14,
walkable = false,
inventory_image = "torch_torch_inv.png",
wield_image = "torch_torch_inv.png",
})
minetest.register_abm({
nodenames = {"torch:torch"},
interval = 10.0,
chance = 1,
action = function(pos, node, active_object_count, active_object_count_wider)
pos.y = pos.y + 0.2
minetest.add_particlespawner({
amount = 10,
time = 10,
minpos = pos,
maxpos = pos,
minvel = {x=0, y=0.1, z=0},
maxvel = {x=0, y=0, z=0},
minacc = {x=0, y=0, z=0},
maxacc = {x=0, y=0, z=0},
minexptime = 1,
maxexptime = 1,
minsize = 1,
maxsize = 1,
collisiondetection = false,
vertical = false,
texture = "torch_flame.png",
})
minetest.add_particlespawner({
amount = 50,
time = 10,
minpos = pos,
maxpos = pos,
minvel = {x=0, y=0.5, z=0},
maxvel = {x=0, y=0, z=0},
minacc = {x=0, y=0, z=0},
maxacc = {x=0, y=0, z=0},
minexptime = 1,
maxexptime = 1,
minsize = 3,
maxsize = 3,
collisiondetection = false,
vertical = false,
texture = "torch_smoke.png",
})
end,
})

56
mods/torch/init.lua~ Normal file
View File

@ -0,0 +1,56 @@
minetest.register_node("torch:torch", {
description = "Torch",
tiles = {"torch_wood.png"},
drawtype = "mesh",
mesh = "torch_torch.obj",
groups = {crumbly = 3},
paramtype = "light",
paramtype2 = "facedir",
light_source = 14,
walkable = false,
inventory_image = "torch_torch_inv.png",
wield_image = "torch_torch_inv.png",
})
minetest.register_abm({
nodenames = {"torch:torch"},
interval = 10.0,
chance = 1,
action = function(pos, node, active_object_count, active_object_count_wider)
pos.y = pos.y + 0.2
minetest.add_particlespawner({
amount = 10,
time = 10,
minpos = pos,
maxpos = pos,
minvel = {x=0, y=0.1, z=0},
maxvel = {x=0, y=0, z=0},
minacc = {x=0, y=0, z=0},
maxacc = {x=0, y=0, z=0},
minexptime = 1,
maxexptime = 1,
minsize = 1,
maxsize = 1,
collisiondetection = false,
vertical = false,
texture = "torch_flame.png",
})
minetest.add_particlespawner({
amount = 50,
time = 10,
minpos = pos,
maxpos = pos,
minvel = {x=0, y=0.5, z=0},
maxvel = {x=0, y=0, z=0},
minacc = {x=0, y=0, z=0},
maxacc = {x=0, y=0, z=0},
minexptime = 1,
maxexptime = 1,
minsize = 3,
maxsize = 3,
collisiondetection = false,
vertical = false,
texture = "torch_smoke.png",
})
end,
})

View File

@ -0,0 +1,10 @@
# Blender MTL File: 'None'
# Material Count: 1
newmtl None
Ns 0
Ka 0.000000 0.000000 0.000000
Kd 0.8 0.8 0.8
Ks 0.8 0.8 0.8
d 1
illum 2

View File

@ -0,0 +1,40 @@
# Blender v2.69 (sub 0) OBJ File: ''
# www.blender.org
mtllib torch_torch.mtl
o Cube.001
v -0.075000 -0.555968 1.002726
v -0.075000 -0.619360 0.866779
v 0.075000 -0.619360 0.866779
v 0.075000 -0.555968 1.002726
v -0.075000 0.220916 0.159460
v -0.075000 0.157523 0.023513
v 0.075000 0.157523 0.023513
v 0.075000 0.220916 0.159460
vt 0.159707 0.720916
vt 0.295653 0.657523
vt -0.366779 -0.119360
vt -0.502726 -0.055968
vt 0.425000 0.657523
vt 0.575000 0.657523
vt 0.575000 -0.119360
vt 0.425000 -0.119360
vt 0.575000 0.720916
vt 0.425000 0.720916
vt 0.425000 -0.055968
vt 0.575000 -0.055968
vt 0.425000 0.497274
vt 0.425000 0.633221
vt 0.575000 0.633221
vt 0.575000 0.497274
vt 0.575000 0.159707
vt 0.575000 0.295653
vt 0.425000 0.295653
vt 0.425000 0.159707
usemtl None
s off
f 5/1 6/2 2/3 1/4
f 6/5 7/6 3/7 2/8
f 7/2 8/1 4/4 3/3
f 8/9 5/10 1/11 4/12
f 1/13 2/14 3/15 4/16
f 8/17 7/18 6/19 5/20

Binary file not shown.

After

Width:  |  Height:  |  Size: 216 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 265 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 286 B