diff options
author | h-v-smacker <hans-von-smacker+github@gmail.com> | 2018-04-02 04:03:40 +0300 |
---|---|---|
committer | h-v-smacker <hans-von-smacker+github@gmail.com> | 2018-04-02 04:03:40 +0300 |
commit | 083c0a0befee5a770d9c8724cedaa770939be040 (patch) | |
tree | 0c0c42bf65b110ba374ce1da0171636a786d4ff7 /extranodes/trampoline.lua | |
parent | 5b88292652dc0f763c149f0dc544a337089e90d4 (diff) |
one-way conducting tube and cleanup
Diffstat (limited to 'extranodes/trampoline.lua')
-rw-r--r-- | extranodes/trampoline.lua | 94 |
1 files changed, 94 insertions, 0 deletions
diff --git a/extranodes/trampoline.lua b/extranodes/trampoline.lua new file mode 100644 index 0000000..d36e356 --- /dev/null +++ b/extranodes/trampoline.lua @@ -0,0 +1,94 @@ +-- bouncy-bouncy +-- this adds two useful kinds of nodes. Two fall damage dampeners (50% and 100%) +-- and a trampoline. Unlike on the mushroom spores from ethereal, players can +-- freely jump on the dampeners. +-- The latex foam adds use to sulphur, and may be employed for something else later. + +local S = rawget(_G, "intllib") and intllib.Getter() or function(s) return s end + + +minetest.register_craftitem(":technic:latex_foam", { + description = S("Latex Foam"), + inventory_image = "technic_latex_foam.png", +}) + +minetest.register_node(":technic:fall_dampener_50", { + description = S("Fall Dampener 50%"), + drawtype = "nodebox", + node_box = { + type = "fixed", + fixed = {-0.5,-0.5,-0.5,0.5,0,0.5} + }, + collision_box = { + type = "fixed", + fixed = {-0.5,-0.5,-0.5,0.5,0,0.5} + }, + selection_box = { + type = "fixed", + fixed = {-0.5,-0.5,-0.5,0.5,0,0.5} + }, + tiles = { "technic_fall_dampener_top.png", + "technic_fall_dampener_bottom.png", + "technic_fall_dampener_side.png", + "technic_fall_dampener_side.png", + "technic_fall_dampener_side.png", + "technic_fall_dampener_side.png"}, + groups = {crumbly = 3, fall_damage_add_percent = -50}, + sounds = default.node_sound_dirt_defaults(), +}) + +minetest.register_node(":technic:fall_dampener_100", { + description = S("Fall Dampener 100%"), + drawtype = "normal", + tiles = {"technic_fall_dampener_top.png", + "technic_fall_dampener_bottom.png", + "technic_fall_dampener_side.png", + "technic_fall_dampener_side.png", + "technic_fall_dampener_side.png", + "technic_fall_dampener_side.png"}, + groups = {crumbly = 3, fall_damage_add_percent = -100}, + sounds = default.node_sound_dirt_defaults(), +}) + +minetest.register_node(":technic:trampoline", { + description = S("Trampoline"), + drawtype = "normal", + tiles = {"technic_trampoline_top.png", + "technic_fall_dampener_bottom.png", -- cost cuts + "technic_trampoline_side.png", + "technic_trampoline_side.png", + "technic_trampoline_side.png", + "technic_trampoline_side.png"}, + groups = {crumbly = 3, bouncy = 100, fall_damage_add_percent = -100}, + sounds = {footstep = {name = "trampoline_boing", gain = 1.0}} +}) + + +minetest.register_craft({ + output = "technic:fall_dampener_50", + recipe = { + { "", "", ""}, + { "technic:raw_latex", "technic:raw_latex", "technic:raw_latex"}, + { "technic:latex_foam", "technic:latex_foam", "technic:latex_foam"}, + } +}) + +minetest.register_craft({ + output = "technic:fall_dampener_100", + recipe = { + { "technic:raw_latex", "technic:raw_latex", "technic:raw_latex"}, + { "technic:latex_foam", "technic:latex_foam", "technic:latex_foam"}, + { "technic:latex_foam", "technic:latex_foam", "technic:latex_foam"}, + } +}) + +minetest.register_craft({ + output = "technic:trampoline", + recipe = { + { "dye:green", "dye:green", "dye:green"}, + { "technic:rubber", "technic:rubber", "technic:rubber"}, + { "technic:rubber", "technic:rubber", "technic:rubber"}, + } +}) + + |