Add support for Aurum.
parent
babd508a35
commit
ca1c77696a
|
@ -0,0 +1,5 @@
|
||||||
|
root = true
|
||||||
|
|
||||||
|
[*]
|
||||||
|
indent_style = space
|
||||||
|
indent_size = 4
|
|
@ -5,6 +5,7 @@ local get_node = elevator.get_node
|
||||||
local homedecor_path = minetest.get_modpath("homedecor")
|
local homedecor_path = minetest.get_modpath("homedecor")
|
||||||
local mineclone_path = core.get_modpath("mcl_core") and mcl_core
|
local mineclone_path = core.get_modpath("mcl_core") and mcl_core
|
||||||
local default_path = core.get_modpath("default") and default
|
local default_path = core.get_modpath("default") and default
|
||||||
|
local aurum_path = core.get_modpath("aurum") and aurum
|
||||||
|
|
||||||
local moditems = {} -- local table to hold substitutes
|
local moditems = {} -- local table to hold substitutes
|
||||||
|
|
||||||
|
@ -46,7 +47,7 @@ if mineclone_path then
|
||||||
moditems.el_motor_gfx = "elevator_motor_mcl.png"
|
moditems.el_motor_gfx = "elevator_motor_mcl.png"
|
||||||
moditems.el_shaft_gfx = "elevator_shaft_mcl.png"
|
moditems.el_shaft_gfx = "elevator_shaft_mcl.png"
|
||||||
moditems.el_box_gfx = "elevator_box_mcl.png"
|
moditems.el_box_gfx = "elevator_box_mcl.png"
|
||||||
|
moditems.steel_block_image = "default_steel_block.png"
|
||||||
elseif default_path then
|
elseif default_path then
|
||||||
moditems.el_shaft_groups = {cracky=2,oddly_breakable_by_hand=0} -- removing ability to destroy by hand to prevent accidental breakage of whole elevators
|
moditems.el_shaft_groups = {cracky=2,oddly_breakable_by_hand=0} -- removing ability to destroy by hand to prevent accidental breakage of whole elevators
|
||||||
moditems.el_motor_groups = {cracky=1}
|
moditems.el_motor_groups = {cracky=1}
|
||||||
|
@ -56,6 +57,21 @@ elseif default_path then
|
||||||
moditems.el_motor_gfx = "elevator_motor.png"
|
moditems.el_motor_gfx = "elevator_motor.png"
|
||||||
moditems.el_shaft_gfx = "elevator_shaft.png"
|
moditems.el_shaft_gfx = "elevator_shaft.png"
|
||||||
moditems.el_box_gfx = "elevator_box.png"
|
moditems.el_box_gfx = "elevator_box.png"
|
||||||
|
moditems.steel_block_image = "default_steel_block.png"
|
||||||
|
elseif aurum_path then
|
||||||
|
moditems.el_shaft_groups = {dig_pick = 2}
|
||||||
|
moditems.el_motor_groups = {dig_pick = 1}
|
||||||
|
moditems.elevator_groups = {dig_pick = 1}
|
||||||
|
moditems.elevator_special_groups = {not_in_creative_inventory=1}
|
||||||
|
moditems.sounds_stone = aurum.sounds.stone
|
||||||
|
moditems.el_motor_gfx = "elevator_motor.png"
|
||||||
|
moditems.el_shaft_gfx = "elevator_shaft.png"
|
||||||
|
moditems.el_box_gfx = "elevator_box.png"
|
||||||
|
moditems.steel_block_image = "aurum_ore_white.png^[colorize:#cbcdcd:255^aurum_ore_bumps.png^aurum_ore_block.png"
|
||||||
|
end
|
||||||
|
|
||||||
|
if minetest.global_exists("screwdriver") then
|
||||||
|
moditems.on_rotate_disallow = screwdriver.disallow
|
||||||
end
|
end
|
||||||
|
|
||||||
minetest.register_node("elevator:shaft", {
|
minetest.register_node("elevator:shaft", {
|
||||||
|
@ -63,7 +79,7 @@ minetest.register_node("elevator:shaft", {
|
||||||
tiles = { moditems.el_shaft_gfx },
|
tiles = { moditems.el_shaft_gfx },
|
||||||
drawtype = "nodebox",
|
drawtype = "nodebox",
|
||||||
paramtype = "light",
|
paramtype = "light",
|
||||||
on_rotate = screwdriver.disallow,
|
on_rotate = moditems.on_rotate_disallow,
|
||||||
sunlight_propagates = true,
|
sunlight_propagates = true,
|
||||||
groups = moditems.el_shaft_groups,
|
groups = moditems.el_shaft_groups,
|
||||||
sounds = moditems.sounds_stone(),
|
sounds = moditems.sounds_stone(),
|
||||||
|
@ -100,8 +116,8 @@ minetest.register_node("elevator:shaft", {
|
||||||
minetest.register_node("elevator:motor", {
|
minetest.register_node("elevator:motor", {
|
||||||
description = "Elevator Motor",
|
description = "Elevator Motor",
|
||||||
tiles = {
|
tiles = {
|
||||||
"default_steel_block.png",
|
moditems.steel_block_image,
|
||||||
"default_steel_block.png",
|
moditems.steel_block_image,
|
||||||
moditems.el_motor_gfx,
|
moditems.el_motor_gfx,
|
||||||
moditems.el_motor_gfx,
|
moditems.el_motor_gfx,
|
||||||
moditems.el_motor_gfx,
|
moditems.el_motor_gfx,
|
||||||
|
@ -162,8 +178,8 @@ minetest.register_node("elevator:elevator_box", {
|
||||||
},
|
},
|
||||||
|
|
||||||
tiles = {
|
tiles = {
|
||||||
"default_steel_block.png",
|
moditems.steel_block_image,
|
||||||
"default_steel_block.png",
|
moditems.steel_block_image,
|
||||||
moditems.el_box_gfx,
|
moditems.el_box_gfx,
|
||||||
moditems.el_box_gfx,
|
moditems.el_box_gfx,
|
||||||
moditems.el_box_gfx,
|
moditems.el_box_gfx,
|
||||||
|
@ -212,7 +228,7 @@ for _,mode in ipairs({"on", "off"}) do
|
||||||
sunlight_propagates = false,
|
sunlight_propagates = false,
|
||||||
paramtype = "light",
|
paramtype = "light",
|
||||||
paramtype2 = "facedir",
|
paramtype2 = "facedir",
|
||||||
on_rotate = screwdriver.disallow,
|
on_rotate = moditems.on_rotate_disallow,
|
||||||
|
|
||||||
selection_box = {
|
selection_box = {
|
||||||
type = "fixed",
|
type = "fixed",
|
||||||
|
@ -230,8 +246,8 @@ for _,mode in ipairs({"on", "off"}) do
|
||||||
},
|
},
|
||||||
|
|
||||||
tiles = on and {
|
tiles = on and {
|
||||||
"default_steel_block.png",
|
moditems.steel_block_image,
|
||||||
"default_steel_block.png",
|
moditems.steel_block_image,
|
||||||
moditems.el_box_gfx,
|
moditems.el_box_gfx,
|
||||||
moditems.el_box_gfx,
|
moditems.el_box_gfx,
|
||||||
moditems.el_box_gfx,
|
moditems.el_box_gfx,
|
||||||
|
|
26
crafts.lua
26
crafts.lua
|
@ -2,6 +2,7 @@
|
||||||
local technic_path = minetest.get_modpath("technic")
|
local technic_path = minetest.get_modpath("technic")
|
||||||
local chains_path = minetest.get_modpath("chains")
|
local chains_path = minetest.get_modpath("chains")
|
||||||
local mineclone_path = core.get_modpath("mcl_core") and mcl_core
|
local mineclone_path = core.get_modpath("mcl_core") and mcl_core
|
||||||
|
local aurum_path = core.get_modpath("aurum") and aurum
|
||||||
|
|
||||||
if mineclone_path then
|
if mineclone_path then
|
||||||
minetest.register_craft({
|
minetest.register_craft({
|
||||||
|
@ -29,7 +30,32 @@ if mineclone_path then
|
||||||
{"mcl_core:paper", "mcl_core:gold_ingot", "mcl_core:paper"}
|
{"mcl_core:paper", "mcl_core:gold_ingot", "mcl_core:paper"}
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
elseif aurum_path then
|
||||||
|
minetest.register_craft({
|
||||||
|
output = "elevator:elevator",
|
||||||
|
recipe = {
|
||||||
|
{"aurum_ore:iron_ingot", "group:glass", "aurum_ore:iron_ingot"},
|
||||||
|
{"aurum_ore:iron_ingot", "aurum_ore:mana_bean", "aurum_ore:iron_ingot"},
|
||||||
|
{"aurum_ore:iron_ingot", "group:glass", "aurum_ore:iron_ingot"},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = "elevator:shaft",
|
||||||
|
recipe = {
|
||||||
|
{"group:glass", "aurum_ore:iron_ingot"},
|
||||||
|
{"group:wood", "group:glass"},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = "elevator:motor",
|
||||||
|
recipe = {
|
||||||
|
{"aurum_ore:gold_ingot", "aurum_ore:iron_ingot", "aurum_ore:gold_ingot"},
|
||||||
|
{"aurum_ore:iron_block", "aurum_cook:oven", "aurum_ore:iron_block"},
|
||||||
|
{"aurum_ore:gold_ingot", "aurum_ore:mana_bean", "aurum_ore:gold_ingot"}
|
||||||
|
},
|
||||||
|
})
|
||||||
elseif technic_path and chains_path then
|
elseif technic_path and chains_path then
|
||||||
minetest.register_craft({
|
minetest.register_craft({
|
||||||
output = "elevator:elevator",
|
output = "elevator:elevator",
|
||||||
|
|
4
mod.conf
4
mod.conf
|
@ -1,3 +1,3 @@
|
||||||
name = elevator
|
name = elevator
|
||||||
description = An entity-based elevator allowing fast realtime travel in Minetest. Supports Minetest Game and MineClone2.
|
description = An entity-based elevator allowing fast realtime travel in Minetest. Supports Minetest Game, MineClone2, and Aurum
|
||||||
optional_depends = default, technic, homedecor, chains, farming, mcl_core, mcl_sounds
|
optional_depends = default, technic, homedecor, chains, farming, mcl_core, mcl_sounds, aurum, screwdriver
|
||||||
|
|
Loading…
Reference in New Issue