Rename the mod to "weirdores"
|
@ -1,59 +0,0 @@
|
||||||
minetest.register_craftitem("ruby:ruby", {
|
|
||||||
description = "Ruby",
|
|
||||||
inventory_image = "ruby_ruby.png",
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_node("ruby:stone_with_ruby", {
|
|
||||||
description = "Rubies in Stone",
|
|
||||||
tiles = {"default_stone.png^ruby_mineral_ruby.png"},
|
|
||||||
is_ground_content = true,
|
|
||||||
groups = {cracky=1},
|
|
||||||
drop = "ruby:ruby",
|
|
||||||
sounds = default.node_sound_stone_defaults(),
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_node("ruby:rubyblock", {
|
|
||||||
description = "Ruby Block",
|
|
||||||
tiles = {"ruby_ruby_block.png"},
|
|
||||||
-- light_source = LIGHT_MAX, --TODO make Ruby lamp
|
|
||||||
is_ground_content = true,
|
|
||||||
groups = {cracky=1,level=2},
|
|
||||||
sounds = default.node_sound_stone_defaults(),
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_ore({
|
|
||||||
ore_type = "scatter",
|
|
||||||
ore = "ruby:stone_with_ruby",
|
|
||||||
wherein = "default:stone",
|
|
||||||
clust_scarcity = 18*18*18,
|
|
||||||
clust_num_ores = 4,
|
|
||||||
clust_size = 3,
|
|
||||||
height_min = -5119,
|
|
||||||
height_max = -1024,
|
|
||||||
})
|
|
||||||
|
|
||||||
|
|
||||||
minetest.register_ore({
|
|
||||||
ore_type = "scatter",
|
|
||||||
ore = "ruby:stone_with_ruby",
|
|
||||||
wherein = "default:stone",
|
|
||||||
clust_scarcity = 12*12*12,
|
|
||||||
clust_num_ores = 4,
|
|
||||||
clust_size = 3,
|
|
||||||
height_min = -31000,
|
|
||||||
height_max = -5120,
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_craft({
|
|
||||||
output = 'ruby:rubyblock',
|
|
||||||
recipe = {
|
|
||||||
{'ruby:ruby', 'ruby:ruby', 'ruby:ruby'},
|
|
||||||
{'ruby:ruby', 'ruby:ruby', 'ruby:ruby'},
|
|
||||||
{'ruby:ruby', 'ruby:ruby', 'ruby:ruby'},
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
|
|
||||||
-- This is for compatibility with the original version of the mod, which was a patch to default game
|
|
||||||
minetest.register_alias("default:stone_with_ruby","ruby:stone_with_ruby")
|
|
||||||
minetest.register_alias("default:ruby","ruby:ruby")
|
|
|
@ -12,9 +12,9 @@ local is_antigravity = function(pos)
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
|
|
||||||
minetest.register_node("ruby:antigravity",{
|
minetest.register_node("weirdores:antigravity",{
|
||||||
description = "Antigravity",
|
description = "Antigravity",
|
||||||
tiles = {"ruby_antigravity.png"},
|
tiles = {"weirdores_antigravity.png"},
|
||||||
is_ground_content = true,
|
is_ground_content = true,
|
||||||
groups = {anti=1,level=2},
|
groups = {anti=1,level=2},
|
||||||
sounds = default.node_sound_stone_defaults(),
|
sounds = default.node_sound_stone_defaults(),
|
||||||
|
@ -24,7 +24,6 @@ minetest.register_node("ruby:antigravity",{
|
||||||
on_destruct = function(pos)
|
on_destruct = function(pos)
|
||||||
for i, a in ipairs(antigravities) do
|
for i, a in ipairs(antigravities) do
|
||||||
if a.x == pos.x and a.y == pos.y and a.z == pos.z then
|
if a.x == pos.x and a.y == pos.y and a.z == pos.z then
|
||||||
print("Removing..."..i)
|
|
||||||
table.remove(antigravities,i)
|
table.remove(antigravities,i)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
@ -48,7 +47,7 @@ minetest.register_globalstep(function(dtime)
|
||||||
end)
|
end)
|
||||||
|
|
||||||
minetest.register_abm({
|
minetest.register_abm({
|
||||||
nodenames={"ruby:antigravity"},
|
nodenames={"weirdores:antigravity"},
|
||||||
interval = 5,
|
interval = 5,
|
||||||
chance = 1,
|
chance = 1,
|
||||||
action = function(pos, node)
|
action = function(pos, node)
|
||||||
|
@ -66,7 +65,7 @@ minetest.register_abm({
|
||||||
{x=0,y=0,z=0}, {x=0,y=0,z=0},
|
{x=0,y=0,z=0}, {x=0,y=0,z=0},
|
||||||
10, 10,
|
10, 10,
|
||||||
.1, 1,
|
.1, 1,
|
||||||
false, "ruby_particle_mese.png")
|
false, "weirdores_particle_mese.png")
|
||||||
|
|
||||||
if not is_antigravity({x=pos.x, y=pos.y+1, z=pos.z}) then
|
if not is_antigravity({x=pos.x, y=pos.y+1, z=pos.z}) then
|
||||||
table.insert(antigravities,pos)
|
table.insert(antigravities,pos)
|
||||||
|
@ -75,11 +74,13 @@ minetest.register_abm({
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craft({
|
minetest.register_craft({
|
||||||
output = 'ruby:antigravity',
|
output = 'weirdores:antigravity',
|
||||||
recipe = {
|
recipe = {
|
||||||
{'default:mese_crystal','default:mese_crystal','default:mese_crystal'},
|
{'default:mese_crystal','default:mese_crystal','default:mese_crystal'},
|
||||||
{'default:mese_crystal','ruby:antimeseblock','default:mese_crystal'},
|
{'default:mese_crystal','weirdores:antimeseblock','default:mese_crystal'},
|
||||||
{'default:mese_crystal','default:mese_crystal','default:mese_crystal'},
|
{'default:mese_crystal','default:mese_crystal','default:mese_crystal'},
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
minetest.register_alias("ruby:antigravity","weirdores:antigravity")
|
||||||
|
|
|
@ -1,14 +1,14 @@
|
||||||
|
|
||||||
-- ITEMS --
|
-- ITEMS --
|
||||||
|
|
||||||
minetest.register_craftitem("ruby:antimese", {
|
minetest.register_craftitem("weirdores:antimese", {
|
||||||
description = "Antimese Crystal",
|
description = "Antimese Crystal",
|
||||||
inventory_image = "ruby_antimese.png",
|
inventory_image = "weirdores_antimese.png",
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_node("ruby:antimeseblock", {
|
minetest.register_node("weirdores:antimeseblock", {
|
||||||
description = "Antimese Block",
|
description = "Antimese Block",
|
||||||
tiles = {"ruby_antimese_block.png"},
|
tiles = {"weirdores_antimese_block.png"},
|
||||||
is_ground_content = true,
|
is_ground_content = true,
|
||||||
groups = {anti=1,level=2},
|
groups = {anti=1,level=2},
|
||||||
sounds = default.node_sound_stone_defaults(),
|
sounds = default.node_sound_stone_defaults(),
|
||||||
|
@ -18,9 +18,9 @@ minetest.register_node("ruby:antimeseblock", {
|
||||||
local APS = 0.25 -- Antimese Pickaxe Speed
|
local APS = 0.25 -- Antimese Pickaxe Speed
|
||||||
local APU = 100 -- Antimese Pickaxe Uses
|
local APU = 100 -- Antimese Pickaxe Uses
|
||||||
|
|
||||||
minetest.register_tool("ruby:pick_antimese", {
|
minetest.register_tool("weirdores:pick_antimese", {
|
||||||
description = "Antimese Pickaxe",
|
description = "Antimese Pickaxe",
|
||||||
inventory_image = "ruby_tool_antimesepick.png",
|
inventory_image = "weirdores_tool_antimesepick.png",
|
||||||
tool_capabilities = {
|
tool_capabilities = {
|
||||||
full_punch_interval = 0.7,
|
full_punch_interval = 0.7,
|
||||||
max_drop_level=3,
|
max_drop_level=3,
|
||||||
|
@ -38,20 +38,20 @@ minetest.register_tool("ruby:pick_antimese", {
|
||||||
-- CRAFTING --
|
-- CRAFTING --
|
||||||
|
|
||||||
minetest.register_craft({
|
minetest.register_craft({
|
||||||
output = 'ruby:pick_antimese',
|
output = 'weirdores:pick_antimese',
|
||||||
recipe = {
|
recipe = {
|
||||||
{'ruby:antimese', 'ruby:antimese', 'ruby:antimese'},
|
{'weirdores:antimese', 'weirdores:antimese', 'weirdores:antimese'},
|
||||||
{'', 'default:stick', ''},
|
{'', 'default:stick', ''},
|
||||||
{'', 'default:stick', ''},
|
{'', 'default:stick', ''},
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_craft({
|
minetest.register_craft({
|
||||||
output = 'ruby:antimeseblock',
|
output = 'weirdores:antimeseblock',
|
||||||
recipe = {
|
recipe = {
|
||||||
{'ruby:antimese', 'ruby:antimese', 'ruby:antimese'},
|
{'weirdores:antimese', 'weirdores:antimese', 'weirdores:antimese'},
|
||||||
{'ruby:antimese', 'ruby:antimese', 'ruby:antimese'},
|
{'weirdores:antimese', 'weirdores:antimese', 'weirdores:antimese'},
|
||||||
{'ruby:antimese', 'ruby:antimese', 'ruby:antimese'},
|
{'weirdores:antimese', 'weirdores:antimese', 'weirdores:antimese'},
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -60,7 +60,7 @@ minetest.register_craft({
|
||||||
-- Ruby block + Mese block --> Antimese
|
-- Ruby block + Mese block --> Antimese
|
||||||
minetest.register_abm({
|
minetest.register_abm({
|
||||||
nodenames={"default:mese"},
|
nodenames={"default:mese"},
|
||||||
neighbors={"ruby:rubyblock"},
|
neighbors={"weirdores:rubyblock"},
|
||||||
interval = 5.0,
|
interval = 5.0,
|
||||||
chance = 5,
|
chance = 5,
|
||||||
action = function(pos,node,active_object_count,active_object_count_wider)
|
action = function(pos,node,active_object_count,active_object_count_wider)
|
||||||
|
@ -70,26 +70,26 @@ minetest.register_abm({
|
||||||
{x=-100,y=-100,z=-100}, {x=100,y=100,z=10},
|
{x=-100,y=-100,z=-100}, {x=100,y=100,z=10},
|
||||||
1, 1,
|
1, 1,
|
||||||
.1,10,
|
.1,10,
|
||||||
false, "ruby_particle_ruby.png")
|
false, "weirdores_particle_ruby.png")
|
||||||
minetest.add_particlespawner(100, 1,
|
minetest.add_particlespawner(100, 1,
|
||||||
pos, pos,
|
pos, pos,
|
||||||
{x=-10,y=-10,z=-10}, {x=10,y=10,z=10},
|
{x=-10,y=-10,z=-10}, {x=10,y=10,z=10},
|
||||||
{x=-100,y=-100,z=-100}, {x=100,y=100,z=100},
|
{x=-100,y=-100,z=-100}, {x=100,y=100,z=100},
|
||||||
1, 1,
|
1, 1,
|
||||||
.1,10,
|
.1,10,
|
||||||
false, "ruby_particle_mese.png")
|
false, "weirdores_particle_mese.png")
|
||||||
local r = 2 -- Radius for destroying
|
local r = 2 -- Radius for destroying
|
||||||
for x = pos.x-r, pos.x+r, 1 do
|
for x = pos.x-r, pos.x+r, 1 do
|
||||||
for y = pos.y-r, pos.y+r, 1 do
|
for y = pos.y-r, pos.y+r, 1 do
|
||||||
for z = pos.z-r, pos.z+r, 1 do
|
for z = pos.z-r, pos.z+r, 1 do
|
||||||
local cpos = {x=x,y=y,z=z}
|
local cpos = {x=x,y=y,z=z}
|
||||||
if minetest.env:get_node(cpos).name == "ruby:rubyblock" then
|
if minetest.env:get_node(cpos).name == "weirdores:rubyblock" then
|
||||||
local e = minetest.env:add_item(cpos,{name="ruby:antimese"})
|
local e = minetest.env:add_item(cpos,{name="weirdores:antimese"})
|
||||||
e:setvelocity({x=0,y=10,z=0})
|
e:setvelocity({x=0,y=10,z=0})
|
||||||
end
|
end
|
||||||
-- The commented part allows to randomly destroy nodes around
|
-- The commented part allows to randomly destroy nodes around
|
||||||
if --[[math.random(0,1) == 1
|
if --[[math.random(0,1) == 1
|
||||||
or]] minetest.env:get_node(cpos).name == "ruby:rubyblock"
|
or]] minetest.env:get_node(cpos).name == "weirdores:rubyblock"
|
||||||
or minetest.env:get_node(cpos).name == "default:mese" then
|
or minetest.env:get_node(cpos).name == "default:mese" then
|
||||||
minetest.env:remove_node(cpos)
|
minetest.env:remove_node(cpos)
|
||||||
end
|
end
|
||||||
|
@ -100,8 +100,11 @@ minetest.register_abm({
|
||||||
})
|
})
|
||||||
|
|
||||||
-- ALIASES --
|
-- ALIASES --
|
||||||
-- This is for compatibility with older versions of the mod, where antimese was anticrystal
|
-- This is for compatibility with older versions of the mod, "the ruby mod"
|
||||||
minetest.register_alias("ruby:anticrystal","ruby:antimese")
|
minetest.register_alias("ruby:anticrystal","weirdores:antimese")
|
||||||
minetest.register_alias("ruby:anticrystalblock","ruby:antimeseblock")
|
minetest.register_alias("ruby:anticrystalblock","weirdores:antimeseblock")
|
||||||
minetest.register_alias("ruby:pick_anticrystal", "ruby:pick_antimese")
|
minetest.register_alias("ruby:pick_anticrystal", "weirdores:pick_antimese")
|
||||||
|
minetest.register_alias("ruby:antimese","weirdores:antimese")
|
||||||
|
minetest.register_alias("ruby:antimeseblock","weirdores:antimeseblock")
|
||||||
|
minetest.register_alias("ruby:pick_antimese", "weirdores:pick_antimese")
|
||||||
|
|
|
@ -0,0 +1,66 @@
|
||||||
|
minetest.register_craftitem("weirdores:ruby", {
|
||||||
|
description = "Ruby",
|
||||||
|
inventory_image = "weirdores_ruby.png",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("weirdores:stone_with_ruby", {
|
||||||
|
description = "Rubies in Stone",
|
||||||
|
tiles = {"default_stone.png^weirdores_mineral_ruby.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=1},
|
||||||
|
drop = "weirdores:ruby",
|
||||||
|
sounds = default.node_sound_stone_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("weirdores:rubyblock", {
|
||||||
|
description = "Ruby Block",
|
||||||
|
tiles = {"weirdores_ruby_block.png"},
|
||||||
|
-- light_source = LIGHT_MAX, --TODO make Ruby lamp
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=1,level=2},
|
||||||
|
sounds = default.node_sound_stone_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_ore({
|
||||||
|
ore_type = "scatter",
|
||||||
|
ore = "weirdores:stone_with_ruby",
|
||||||
|
wherein = "default:stone",
|
||||||
|
clust_scarcity = 18*18*18,
|
||||||
|
clust_num_ores = 4,
|
||||||
|
clust_size = 3,
|
||||||
|
height_min = -5119,
|
||||||
|
height_max = -1024,
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
minetest.register_ore({
|
||||||
|
ore_type = "scatter",
|
||||||
|
ore = "weirdores:stone_with_ruby",
|
||||||
|
wherein = "default:stone",
|
||||||
|
clust_scarcity = 12*12*12,
|
||||||
|
clust_num_ores = 4,
|
||||||
|
clust_size = 3,
|
||||||
|
height_min = -31000,
|
||||||
|
height_max = -5120,
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'weirdores:rubyblock',
|
||||||
|
recipe = {
|
||||||
|
{'weirdores:ruby', 'weirdores:ruby', 'weirdores:ruby'},
|
||||||
|
{'weirdores:ruby', 'weirdores:ruby', 'weirdores:ruby'},
|
||||||
|
{'weirdores:ruby', 'weirdores:ruby', 'weirdores:ruby'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
-- This is for compatibility with the original version of the mod, which was a patch to default game
|
||||||
|
minetest.register_alias("default:stone_with_ruby","weirdores:stone_with_ruby")
|
||||||
|
minetest.register_alias("default:ruby","weirdores:ruby")
|
||||||
|
|
||||||
|
|
||||||
|
-- for old versions which were called "ruby"...
|
||||||
|
minetest.register_alias("ruby:ruby","weirdores:ruby")
|
||||||
|
minetest.register_alias("ruby:stone_with_ruby","weirdores:stone_with_ruby")
|
||||||
|
minetest.register_alias("ruby:rubyblock","weirdores:rubyblock")
|
||||||
|
|
Before Width: | Height: | Size: 560 B After Width: | Height: | Size: 560 B |
Before Width: | Height: | Size: 751 B After Width: | Height: | Size: 751 B |
Before Width: | Height: | Size: 454 B After Width: | Height: | Size: 454 B |
Before Width: | Height: | Size: 339 B After Width: | Height: | Size: 339 B |
Before Width: | Height: | Size: 374 B After Width: | Height: | Size: 374 B |
Before Width: | Height: | Size: 150 B After Width: | Height: | Size: 150 B |
Before Width: | Height: | Size: 150 B After Width: | Height: | Size: 150 B |
Before Width: | Height: | Size: 393 B After Width: | Height: | Size: 393 B |
Before Width: | Height: | Size: 513 B After Width: | Height: | Size: 513 B |
Before Width: | Height: | Size: 277 B After Width: | Height: | Size: 277 B |