forked from Mirrorlandia_minetest/mesetec
remove default dependecy
This commit is contained in:
parent
3165cba518
commit
2dc5e5623b
@ -2,7 +2,7 @@
|
||||
|
||||
License: License: code: LGPL-2.1, media: CC BY-SA-4.0
|
||||
|
||||
Depends: default, mesecons
|
||||
Depends: mesecons
|
||||
|
||||
Version 3.2
|
||||
|
||||
|
125
craft.lua
125
craft.lua
@ -1,125 +0,0 @@
|
||||
minetest.register_craft({
|
||||
output = "mesetec:nodeswitch",
|
||||
recipe = {{"","mesecons:wire_00000000_off",""},
|
||||
{"mesecons_materials:silicon","mesecons_lamp:lamp_off","mesecons_materials:silicon"},
|
||||
{"","default:mese_crystal",""},
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:objdec",
|
||||
recipe = {{"mesecons_materials:silicon","mesecons_solarpanel:solar_panel_off","mesecons_materials:silicon"}
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:light",
|
||||
recipe = {{"mesecons_materials:silicon","mesecons_solarpanel:solar_panel_off","mesecons_materials:silicon"}
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:delayer",
|
||||
recipe = {{"mesecons_delayer:delayer_off_1","default:copper_ingot","mesecons_delayer:delayer_off_1"},
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:oxygen 3",
|
||||
recipe = {{"","mesecons:wire_00000000_off",""},
|
||||
{"default:sand","mesecons_lamp:lamp_off","default:sand"},
|
||||
{"","default:torch",""},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:dmg 3",
|
||||
recipe = {{"","mesecons:wire_00000000_off",""},
|
||||
{"default:sand","mesecons_lamp:lamp_off","default:sand"},
|
||||
{"","default:mese_crystal",""},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:ladder 3",
|
||||
recipe = {{"","mesecons:wire_00000000_off",""},
|
||||
{"default:sand","mesecons_lamp:lamp_off","default:sand"},
|
||||
{"","default:ladder_wood",""},
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:keycard",
|
||||
recipe = {{"mesecons_materials:silicon","mesecons:wire_00000000_off","mesecons_materials:silicon"},
|
||||
{"mesecons_materials:silicon","mesecons_lamp:lamp_off","mesecons_materials:silicon"},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:codelock",
|
||||
recipe = {{"default:steel_ingot","mesecons:wire_00000000_off","default:steel_ingot"},
|
||||
{"default:steel_ingot","mesecons_luacontroller:luacontroller0000","default:steel_ingot"},
|
||||
{"default:steel_ingot","mesecons_lamp:lamp_off","default:steel_ingot"},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:controller",
|
||||
recipe = {{"","mesecons:wire_00000000_off",""},
|
||||
{"default:steel_ingot","mesecons_walllever:wall_lever_off","default:steel_ingot"},
|
||||
{"","default:stick",""},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:hacktool",
|
||||
recipe = {{"mesecons:wire_00000000_off","","mesecons:wire_00000000_off"},
|
||||
{"default:steel_ingot","default:mese_crystal","default:steel_ingot"},
|
||||
{"","default:stick",""},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:objdec",
|
||||
recipe = {{"","mesecons:wire_00000000_off",""},
|
||||
{"","mesecons_detector:object_detector_off",""},
|
||||
{"","mesecons_luacontroller:luacontroller0000",""},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:mtptarget",
|
||||
recipe = {{"default:steel_ingot","mesecons:wire_00000000_off","default:steel_ingot"},
|
||||
{"default:steel_ingot","default:mese_crystal","default:steel_ingot"},
|
||||
{"default:steel_ingot","default:steel_ingot","default:steel_ingot"},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:mtp",
|
||||
recipe = {{"default:steel_ingot","mesecons:wire_00000000_off","default:steel_ingot"},
|
||||
{"default:mese_crystal","mesecons_luacontroller:luacontroller0000","default:mese_crystal"},
|
||||
{"default:steel_ingot","default:steel_ingot","default:steel_ingot"},
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:ptp",
|
||||
recipe = {{"default:steel_ingot","mesecons:wire_00000000_off","default:steel_ingot"},
|
||||
{"default:mese_crystal_fragment","mesecons_detector:object_detector_off","default:mese_crystal_fragment"},
|
||||
{"default:steel_ingot","default:steel_ingot","default:steel_ingot"},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "mesetec:ptptarget",
|
||||
recipe = {{"default:steel_ingot","mesecons:wire_00000000_off","default:steel_ingot"},
|
||||
{"default:mese_crystal_fragment","mesecons_luacontroller:luacontroller0000","default:mese_crystal_fragment"},
|
||||
{"default:steel_ingot","default:steel_ingot","default:steel_ingot"},
|
||||
}
|
||||
})
|
@ -1,2 +0,0 @@
|
||||
default
|
||||
mesecons
|
@ -1 +0,0 @@
|
||||
Extra and usefull mesecons stuff
|
3
init.lua
3
init.lua
@ -1,5 +1,5 @@
|
||||
mesetec={
|
||||
maxlight=default.LIGHT_MAX or 15,
|
||||
maxlight=15,
|
||||
player_teleport={},
|
||||
mtcuser={},
|
||||
mtpuser={},
|
||||
@ -15,7 +15,6 @@ dofile(minetest.get_modpath("mesetec") .. "/tools.lua")
|
||||
dofile(minetest.get_modpath("mesetec") .. "/teleob.lua")
|
||||
dofile(minetest.get_modpath("mesetec") .. "/misc.lua")
|
||||
|
||||
dofile(minetest.get_modpath("mesetec") .. "/craft.lua")
|
||||
|
||||
mesetec.distance=function(p,o)
|
||||
return math.sqrt((p.x-o.x)*(p.x-o.x) + (p.y-o.y)*(p.y-o.y)+(p.z-o.z)*(p.z-o.z))
|
||||
|
39
misc.lua
39
misc.lua
@ -44,10 +44,9 @@ minetest.register_node("mesetec:codelock", {
|
||||
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
mesetec.form2(pos,player)
|
||||
end,
|
||||
tiles = {"default_steel_block.png","default_steel_block.png","default_steel_block.png","default_steel_block.png","default_steel_block.png","mesetec_code.png"},
|
||||
tiles = {"steel_block.png","steel_block.png","steel_block.png","steel_block.png","steel_block.png","mesetec_code.png"},
|
||||
groups = {mesecon_needs_receiver = 1,snappy = 3, not_in_creative_inventory=0},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
is_ground_content = false,
|
||||
is_ground_content = false,
|
||||
mesecons = {receptor = {
|
||||
rules = mesecon.rules.buttonlike_get,
|
||||
state = mesecon.state.off
|
||||
@ -75,10 +74,9 @@ minetest.register_node("mesetec:dmg", {
|
||||
description = "Mese damage block",
|
||||
tiles = {"mesetec_trap.png^[colorize:#f9570001"},
|
||||
alpha=1,
|
||||
inventory_image = "default_lava.png^mesetec_trap2.png",
|
||||
inventory_image = "lava.png^mesetec_trap2.png",
|
||||
groups = {mesecon=2,snappy = 3, not_in_creative_inventory=0},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
is_ground_content = false,
|
||||
is_ground_content = false,
|
||||
drawtype="glasslike",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
@ -112,10 +110,9 @@ minetest.register_node("mesetec:oxygen", {
|
||||
description = "Mese oxygen block",
|
||||
tiles = {"mesetec_trap.png^[colorize:#00a5a201"},
|
||||
alpha=1,
|
||||
inventory_image = "default_river_water.png^mesetec_trap2.png",
|
||||
inventory_image = "river_water.png^mesetec_trap2.png",
|
||||
groups = {mesecon=2,snappy = 3, not_in_creative_inventory=0},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
is_ground_content = false,
|
||||
is_ground_content = false,
|
||||
drawtype="glasslike",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
@ -149,10 +146,9 @@ minetest.register_node("mesetec:ladder", {
|
||||
description = "Mese ladder block",
|
||||
tiles = {"mesetec_trap.png^[colorize:#87878701"},
|
||||
alpha=1,
|
||||
inventory_image = "default_ladder_wood.png^mesetec_trap2.png",
|
||||
inventory_image = "ladder_wood.png^mesetec_trap2.png",
|
||||
groups = {mesecon=2,snappy = 3, not_in_creative_inventory=0},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
is_ground_content = false,
|
||||
is_ground_content = false,
|
||||
drawtype="glasslike",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
@ -184,20 +180,14 @@ minetest.register_node("mesetec:ladder2", {
|
||||
|
||||
minetest.register_node("mesetec:delayer", {
|
||||
description = "Delayer (Punch to change time)",
|
||||
tiles = {"mesetec_delayer.png","default_sandstone_block.png"},
|
||||
tiles = {"mesetec_delayer.png","sandstone_block.png"},
|
||||
groups = {dig_immediate = 2,mesecon=1},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
paramtype = "light",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
drawtype="nodebox",
|
||||
node_box = {
|
||||
type="fixed",
|
||||
fixed={-0.5,-0.5,-0.5,0.5,-0.4,0.5}},
|
||||
mesecons = {conductor = {
|
||||
state = mesecon.state.on,
|
||||
offstate = "mesetec:ladder",
|
||||
rules = mesetec.rules
|
||||
}},
|
||||
on_punch = function(pos, node, player, pointed_thing)
|
||||
if minetest.is_protected(pos, player:get_player_name())==false then
|
||||
local meta = minetest.get_meta(pos)
|
||||
@ -226,7 +216,8 @@ on_punch = function(pos, node, player, pointed_thing)
|
||||
end
|
||||
return false
|
||||
end,
|
||||
mesecons = {effector = {
|
||||
mesecons = {
|
||||
effector = {
|
||||
action_on = function (pos, node)
|
||||
local meta = minetest.get_meta(pos)
|
||||
if meta:get_int("case")==0 then
|
||||
@ -240,10 +231,9 @@ on_punch = function(pos, node, player, pointed_thing)
|
||||
|
||||
minetest.register_node("mesetec:light", {
|
||||
description = "Light check",
|
||||
tiles = {"jeija_solar_panel.png","default_steel_block.png"},
|
||||
tiles = {"mesecons_solarpanel.png","steel_block.png"},
|
||||
groups = {dig_immediate = 2,mesecon=1},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
paramtype = "light",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
drawtype="nodebox",
|
||||
node_box = {
|
||||
@ -251,7 +241,6 @@ minetest.register_node("mesetec:light", {
|
||||
fixed={-0.5,-0.5,-0.5,0.5,-0.4,0.5}},
|
||||
is_ground_content = false,
|
||||
mesecons = {receptor = {
|
||||
rules = mesecon.rules.buttonlike_get,
|
||||
rules = mesetec.rules
|
||||
}},
|
||||
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
|
3
mod.conf
Normal file
3
mod.conf
Normal file
@ -0,0 +1,3 @@
|
||||
name = mesetec
|
||||
description = Extra and usefull mesecons stuff
|
||||
depends = mesecons
|
27
teleob.lua
27
teleob.lua
@ -107,10 +107,9 @@ after_place_node = function(pos, placer)
|
||||
end,
|
||||
|
||||
|
||||
tiles = {"default_steel_block.png"},
|
||||
tiles = {"steel_block.png"},
|
||||
groups = {mesecon=2,snappy = 3, not_in_creative_inventory=0},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
is_ground_content = false,
|
||||
is_ground_content = false,
|
||||
--mesecons = {receptor = {state = "off"}},
|
||||
|
||||
mesecons = {
|
||||
@ -138,10 +137,9 @@ minetest.register_node("mesetec:objdec", {
|
||||
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
mesetec.form1(pos,player,"obj")
|
||||
end,
|
||||
tiles = {"default_steel_block.png","jeija_object_detector_off.png^[transform2"},
|
||||
tiles = {"steel_block.png","jeija_object_detector_off.png^[transform2"},
|
||||
groups = {mesecon=2,snappy = 3, not_in_creative_inventory=0},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
is_ground_content = false,
|
||||
is_ground_content = false,
|
||||
mesecons = {receptor = {state = "off"}},
|
||||
on_construct = function(pos)
|
||||
if not mesecon then return false end
|
||||
@ -168,10 +166,9 @@ minetest.register_node("mesetec:objdec2", {
|
||||
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
mesetec.form1(pos,player,"obj")
|
||||
end,
|
||||
tiles = {"default_steel_block.png","jeija_object_detector_on.png^[transform2"},
|
||||
tiles = {"steel_block.png","jeija_object_detector_on.png^[transform2"},
|
||||
groups = {mesecon=2,snappy = 3, not_in_creative_inventory=1},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
is_ground_content = false,
|
||||
is_ground_content = false,
|
||||
mesecons = {receptor = {state = "on"}},
|
||||
on_timer = function (pos, elapsed)
|
||||
local meta=minetest.get_meta(pos)
|
||||
@ -199,8 +196,7 @@ on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
end,
|
||||
tiles = {"mesetec_ttp.png"},
|
||||
groups = {mesecon=2,snappy = 3, not_in_creative_inventory=0},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
is_ground_content = false,
|
||||
is_ground_content = false,
|
||||
drawtype = "nodebox",
|
||||
paramtype = "light",
|
||||
paramtype2 = "facedir",
|
||||
@ -234,8 +230,7 @@ minetest.register_node("mesetec:mtptarget", {
|
||||
description = "Mese teleport target",
|
||||
tiles = {"mesetec_ttp_target.png"},
|
||||
groups = {mesecon=2,snappy = 3, not_in_creative_inventory=0},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
is_ground_content = false,
|
||||
is_ground_content = false,
|
||||
drawtype = "nodebox",
|
||||
paramtype = "light",
|
||||
paramtype2 = "facedir",
|
||||
@ -256,8 +251,7 @@ minetest.register_node("mesetec:ptp", {
|
||||
description = "Player teleport",
|
||||
tiles = {"mesetec_ptp.png"},
|
||||
groups = {mesecon=2,snappy = 3, not_in_creative_inventory=0},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
is_ground_content = false,
|
||||
is_ground_content = false,
|
||||
mesecons = {effector = {
|
||||
action_on = function (pos, node)
|
||||
local names={}
|
||||
@ -284,8 +278,7 @@ minetest.register_node("mesetec:ptptarget", {
|
||||
description = "Player teleport target",
|
||||
tiles = {"mesetecptp_target.png"},
|
||||
groups = {mesecon=2,snappy = 3, not_in_creative_inventory=0},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
is_ground_content = false,
|
||||
is_ground_content = false,
|
||||
walkable = false,
|
||||
mesecons = {effector = {
|
||||
action_on = function (pos, node)
|
||||
|
BIN
textures/ladder_wood.png
Normal file
BIN
textures/ladder_wood.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.2 KiB |
BIN
textures/lava.png
Normal file
BIN
textures/lava.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.3 KiB |
BIN
textures/river_water.png
Normal file
BIN
textures/river_water.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.2 KiB |
BIN
textures/sandstone_block.png
Normal file
BIN
textures/sandstone_block.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.2 KiB |
BIN
textures/steel_block.png
Normal file
BIN
textures/steel_block.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.0 KiB |
Loading…
Reference in New Issue
Block a user