From dfa43d6c0c662409da4c026a676a39f82d36ef06 Mon Sep 17 00:00:00 2001 From: Jude Melton-Houghton Date: Thu, 5 May 2022 10:57:53 -0400 Subject: [PATCH] Make modpack mostly independent from MTG (#607) --- LICENSE.txt | 6 ++ mesecons_blinkyplant/init.lua | 2 +- mesecons_blinkyplant/mod.conf | 2 +- mesecons_button/init.lua | 6 +- mesecons_button/mod.conf | 2 +- mesecons_commandblock/init.lua | 4 +- mesecons_commandblock/mod.conf | 2 +- mesecons_delayer/init.lua | 4 +- mesecons_delayer/mod.conf | 2 +- mesecons_detector/init.lua | 42 ++++++----- mesecons_detector/mod.conf | 2 +- .../textures/mesecons_detector_side.png | Bin 0 -> 350 bytes mesecons_extrawires/corner.lua | 4 +- mesecons_extrawires/crossover.lua | 8 +- mesecons_extrawires/doublecorner.lua | 2 +- mesecons_extrawires/mesewire.lua | 31 ++++++-- mesecons_extrawires/mod.conf | 2 +- mesecons_extrawires/tjunction.lua | 4 +- mesecons_extrawires/vertical.lua | 6 +- mesecons_fpga/init.lua | 2 +- mesecons_fpga/mod.conf | 2 +- mesecons_gamecompat/compat_mtg.lua | 71 ++++++++++++++++++ mesecons_gamecompat/init.lua | 15 ++++ mesecons_gamecompat/mod.conf | 3 + mesecons_gates/init.lua | 2 +- mesecons_gates/mod.conf | 2 +- mesecons_hydroturbine/init.lua | 10 +-- mesecons_hydroturbine/mod.conf | 2 +- mesecons_insulated/init.lua | 4 +- mesecons_insulated/mod.conf | 2 +- mesecons_lamp/init.lua | 10 +-- mesecons_lamp/mod.conf | 2 +- mesecons_lightstone/init.lua | 30 ++++---- mesecons_lightstone/mod.conf | 2 +- mesecons_luacontroller/init.lua | 4 +- mesecons_luacontroller/mod.conf | 2 +- mesecons_materials/init.lua | 2 +- mesecons_materials/mod.conf | 2 +- mesecons_microcontroller/init.lua | 2 +- mesecons_microcontroller/mod.conf | 2 +- mesecons_movestones/init.lua | 12 +-- mesecons_movestones/mod.conf | 2 +- mesecons_mvps/init.lua | 25 ------ mesecons_noteblock/init.lua | 29 ++++--- mesecons_noteblock/mod.conf | 2 +- mesecons_pistons/init.lua | 18 ++--- mesecons_pistons/mod.conf | 2 +- mesecons_powerplant/init.lua | 2 +- mesecons_powerplant/mod.conf | 2 +- mesecons_pressureplates/init.lua | 6 +- mesecons_pressureplates/mod.conf | 2 +- mesecons_random/init.lua | 16 ++-- mesecons_random/mod.conf | 2 +- mesecons_receiver/init.lua | 6 +- mesecons_receiver/mod.conf | 2 +- mesecons_solarpanel/init.lua | 2 +- mesecons_solarpanel/mod.conf | 2 +- mesecons_stickyblocks/init.lua | 2 +- mesecons_stickyblocks/mod.conf | 2 +- mesecons_switch/init.lua | 4 +- mesecons_switch/mod.conf | 2 +- mesecons_torch/init.lua | 6 +- mesecons_torch/mod.conf | 2 +- mesecons_walllever/init.lua | 6 +- mesecons_walllever/mod.conf | 2 +- mesecons_wires/init.lua | 8 +- mesecons_wires/mod.conf | 2 +- 67 files changed, 285 insertions(+), 187 deletions(-) create mode 100644 mesecons_detector/textures/mesecons_detector_side.png create mode 100644 mesecons_gamecompat/compat_mtg.lua create mode 100644 mesecons_gamecompat/init.lua create mode 100644 mesecons_gamecompat/mod.conf diff --git a/LICENSE.txt b/LICENSE.txt index 0d2fd18..5df6546 100644 --- a/LICENSE.txt +++ b/LICENSE.txt @@ -1,6 +1,12 @@ The LGPLv3 applies to all code in this project. The CC-BY-SA-3.0 license applies to textures and any other content in this project which is not source code. +The file mesecons_detector/textures/mesecons_detector_side.png is an unmodified copy of +"default_steel_block.png" by Jean-Patrick Guerrero , which can be found at +. +"default_steel_block.png" is licensed under a CC BY-SA 3.0 license. This license can be found later in this document, and can also be found at +. The artwork is reportedly copyright (C) 2010-2018 kilbith. + ================================================================= GNU LESSER GENERAL PUBLIC LICENSE diff --git a/mesecons_blinkyplant/init.lua b/mesecons_blinkyplant/init.lua index 4e46750..28cb054 100644 --- a/mesecons_blinkyplant/init.lua +++ b/mesecons_blinkyplant/init.lua @@ -26,7 +26,7 @@ mesecon.register_node("mesecons_blinkyplant:blinky_plant", { paramtype = "light", is_ground_content = false, walkable = false, - sounds = default.node_sound_leaves_defaults(), + sounds = mesecon.node_sound.leaves, selection_box = { type = "fixed", fixed = {-0.3, -0.5, -0.3, 0.3, -0.5+0.7, 0.3}, diff --git a/mesecons_blinkyplant/mod.conf b/mesecons_blinkyplant/mod.conf index 8332c95..3f23448 100644 --- a/mesecons_blinkyplant/mod.conf +++ b/mesecons_blinkyplant/mod.conf @@ -1,2 +1,2 @@ name = mesecons_blinkyplant -depends = default, mesecons +depends = mesecons, mesecons_gamecompat diff --git a/mesecons_button/init.lua b/mesecons_button/init.lua index 9a189c8..7c70923 100644 --- a/mesecons_button/init.lua +++ b/mesecons_button/init.lua @@ -52,7 +52,7 @@ minetest.register_node("mesecons_button:button_off", { minetest.sound_play("mesecons_button_push", { pos = pos }, true) minetest.get_node_timer(pos):start(1) end, - sounds = default.node_sound_stone_defaults(), + sounds = mesecon.node_sound.stone, mesecons = {receptor = { state = mesecon.state.off, rules = mesecon.rules.buttonlike_get @@ -93,7 +93,7 @@ minetest.register_node("mesecons_button:button_on", { groups = {dig_immediate=2, not_in_creative_inventory=1, mesecon_needs_receiver = 1}, drop = 'mesecons_button:button_off', description = "Button", - sounds = default.node_sound_stone_defaults(), + sounds = mesecon.node_sound.stone, mesecons = {receptor = { state = mesecon.state.on, rules = mesecon.rules.buttonlike_get @@ -105,6 +105,6 @@ minetest.register_node("mesecons_button:button_on", { minetest.register_craft({ output = "mesecons_button:button_off 2", recipe = { - {"group:mesecon_conductor_craftable","default:stone"}, + {"group:mesecon_conductor_craftable","mesecons_gamecompat:stone"}, } }) diff --git a/mesecons_button/mod.conf b/mesecons_button/mod.conf index 62c1e40..cf67a2e 100644 --- a/mesecons_button/mod.conf +++ b/mesecons_button/mod.conf @@ -1,2 +1,2 @@ name = mesecons_button -depends = default, mesecons, mesecons_receiver +depends = mesecons, mesecons_gamecompat, mesecons_receiver diff --git a/mesecons_commandblock/init.lua b/mesecons_commandblock/init.lua index fbab54b..c96cfe8 100644 --- a/mesecons_commandblock/init.lua +++ b/mesecons_commandblock/init.lua @@ -189,7 +189,7 @@ minetest.register_node("mesecons_commandblock:commandblock_off", { after_place_node = after_place, on_receive_fields = receive_fields, can_dig = can_dig, - sounds = default.node_sound_stone_defaults(), + sounds = mesecon.node_sound.stone, mesecons = {effector = { action_on = commandblock_action_on }}, @@ -206,7 +206,7 @@ minetest.register_node("mesecons_commandblock:commandblock_on", { after_place_node = after_place, on_receive_fields = receive_fields, can_dig = can_dig, - sounds = default.node_sound_stone_defaults(), + sounds = mesecon.node_sound.stone, mesecons = {effector = { action_off = commandblock_action_off }}, diff --git a/mesecons_commandblock/mod.conf b/mesecons_commandblock/mod.conf index 66f847d..68cdc9e 100644 --- a/mesecons_commandblock/mod.conf +++ b/mesecons_commandblock/mod.conf @@ -1,2 +1,2 @@ name = mesecons_commandblock -depends = default, mesecons +depends = mesecons, mesecons_gamecompat diff --git a/mesecons_delayer/init.lua b/mesecons_delayer/init.lua index f2f4b9c..bc95806 100644 --- a/mesecons_delayer/init.lua +++ b/mesecons_delayer/init.lua @@ -69,7 +69,7 @@ local def = { sunlight_propagates = true, is_ground_content = false, delayer_time = delaytime[i], - sounds = default.node_sound_stone_defaults(), + sounds = mesecon.node_sound.stone, on_blast = mesecon.on_blastnode, drop = "mesecons_delayer:delayer_off_1", } @@ -169,6 +169,6 @@ minetest.register_craft({ output = "mesecons_delayer:delayer_off_1", recipe = { {"mesecons_torch:mesecon_torch_on", "group:mesecon_conductor_craftable", "mesecons_torch:mesecon_torch_on"}, - {"default:cobble","default:cobble", "default:cobble"}, + {"mesecons_gamecompat:cobble","mesecons_gamecompat:cobble", "mesecons_gamecompat:cobble"}, } }) diff --git a/mesecons_delayer/mod.conf b/mesecons_delayer/mod.conf index a6604ed..33a2ef5 100644 --- a/mesecons_delayer/mod.conf +++ b/mesecons_delayer/mod.conf @@ -1,2 +1,2 @@ name = mesecons_delayer -depends = default, mesecons +depends = mesecons, mesecons_gamecompat diff --git a/mesecons_detector/init.lua b/mesecons_detector/init.lua index 0a97684..d460936 100644 --- a/mesecons_detector/init.lua +++ b/mesecons_detector/init.lua @@ -1,3 +1,5 @@ +local side_texture = mesecon.texture.steel_block or "mesecons_detector_side.png" + local GET_COMMAND = "GET" -- Object detector @@ -64,7 +66,7 @@ local object_detector_digiline = { } minetest.register_node("mesecons_detector:object_detector_off", { - tiles = {"default_steel_block.png", "default_steel_block.png", "jeija_object_detector_off.png", "jeija_object_detector_off.png", "jeija_object_detector_off.png", "jeija_object_detector_off.png"}, + tiles = {side_texture, side_texture, "jeija_object_detector_off.png", "jeija_object_detector_off.png", "jeija_object_detector_off.png", "jeija_object_detector_off.png"}, paramtype = "light", is_ground_content = false, walkable = true, @@ -76,13 +78,13 @@ minetest.register_node("mesecons_detector:object_detector_off", { }}, on_construct = object_detector_make_formspec, on_receive_fields = object_detector_on_receive_fields, - sounds = default.node_sound_stone_defaults(), + sounds = mesecon.node_sound.stone, digiline = object_detector_digiline, on_blast = mesecon.on_blastnode, }) minetest.register_node("mesecons_detector:object_detector_on", { - tiles = {"default_steel_block.png", "default_steel_block.png", "jeija_object_detector_on.png", "jeija_object_detector_on.png", "jeija_object_detector_on.png", "jeija_object_detector_on.png"}, + tiles = {side_texture, side_texture, "jeija_object_detector_on.png", "jeija_object_detector_on.png", "jeija_object_detector_on.png", "jeija_object_detector_on.png"}, paramtype = "light", is_ground_content = false, walkable = true, @@ -94,7 +96,7 @@ minetest.register_node("mesecons_detector:object_detector_on", { }}, on_construct = object_detector_make_formspec, on_receive_fields = object_detector_on_receive_fields, - sounds = default.node_sound_stone_defaults(), + sounds = mesecon.node_sound.stone, digiline = object_detector_digiline, on_blast = mesecon.on_blastnode, }) @@ -102,18 +104,18 @@ minetest.register_node("mesecons_detector:object_detector_on", { minetest.register_craft({ output = 'mesecons_detector:object_detector_off', recipe = { - {"default:steel_ingot", "default:steel_ingot", "default:steel_ingot"}, - {"default:steel_ingot", "mesecons_luacontroller:luacontroller0000", "default:steel_ingot"}, - {"default:steel_ingot", "group:mesecon_conductor_craftable", "default:steel_ingot"}, + {"mesecons_gamecompat:steel_ingot", "mesecons_gamecompat:steel_ingot", "mesecons_gamecompat:steel_ingot"}, + {"mesecons_gamecompat:steel_ingot", "mesecons_luacontroller:luacontroller0000", "mesecons_gamecompat:steel_ingot"}, + {"mesecons_gamecompat:steel_ingot", "group:mesecon_conductor_craftable", "mesecons_gamecompat:steel_ingot"}, } }) minetest.register_craft({ output = 'mesecons_detector:object_detector_off', recipe = { - {"default:steel_ingot", "default:steel_ingot", "default:steel_ingot"}, - {"default:steel_ingot", "mesecons_microcontroller:microcontroller0000", "default:steel_ingot"}, - {"default:steel_ingot", "group:mesecon_conductor_craftable", "default:steel_ingot"}, + {"mesecons_gamecompat:steel_ingot", "mesecons_gamecompat:steel_ingot", "mesecons_gamecompat:steel_ingot"}, + {"mesecons_gamecompat:steel_ingot", "mesecons_microcontroller:microcontroller0000", "mesecons_gamecompat:steel_ingot"}, + {"mesecons_gamecompat:steel_ingot", "group:mesecon_conductor_craftable", "mesecons_gamecompat:steel_ingot"}, } }) @@ -239,7 +241,7 @@ local node_detector_digiline = { } minetest.register_node("mesecons_detector:node_detector_off", { - tiles = {"default_steel_block.png", "default_steel_block.png", "default_steel_block.png", "default_steel_block.png", "default_steel_block.png", "jeija_node_detector_off.png"}, + tiles = {side_texture, side_texture, side_texture, side_texture, side_texture, "jeija_node_detector_off.png"}, paramtype = "light", paramtype2 = "facedir", is_ground_content = false, @@ -251,13 +253,13 @@ minetest.register_node("mesecons_detector:node_detector_off", { }}, on_construct = node_detector_make_formspec, on_receive_fields = node_detector_on_receive_fields, - sounds = default.node_sound_stone_defaults(), + sounds = mesecon.node_sound.stone, digiline = node_detector_digiline, on_blast = mesecon.on_blastnode, }) minetest.register_node("mesecons_detector:node_detector_on", { - tiles = {"default_steel_block.png", "default_steel_block.png", "default_steel_block.png", "default_steel_block.png", "default_steel_block.png", "jeija_node_detector_on.png"}, + tiles = {side_texture, side_texture, side_texture, side_texture, side_texture, "jeija_node_detector_on.png"}, paramtype = "light", paramtype2 = "facedir", is_ground_content = false, @@ -269,7 +271,7 @@ minetest.register_node("mesecons_detector:node_detector_on", { }}, on_construct = node_detector_make_formspec, on_receive_fields = node_detector_on_receive_fields, - sounds = default.node_sound_stone_defaults(), + sounds = mesecon.node_sound.stone, digiline = node_detector_digiline, on_blast = mesecon.on_blastnode, }) @@ -277,18 +279,18 @@ minetest.register_node("mesecons_detector:node_detector_on", { minetest.register_craft({ output = 'mesecons_detector:node_detector_off', recipe = { - {"default:steel_ingot", "group:mesecon_conductor_craftable", "default:steel_ingot"}, - {"default:steel_ingot", "mesecons_luacontroller:luacontroller0000", "default:steel_ingot"}, - {"default:steel_ingot", "default:steel_ingot", "default:steel_ingot"}, + {"mesecons_gamecompat:steel_ingot", "group:mesecon_conductor_craftable", "mesecons_gamecompat:steel_ingot"}, + {"mesecons_gamecompat:steel_ingot", "mesecons_luacontroller:luacontroller0000", "mesecons_gamecompat:steel_ingot"}, + {"mesecons_gamecompat:steel_ingot", "mesecons_gamecompat:steel_ingot", "mesecons_gamecompat:steel_ingot"}, } }) minetest.register_craft({ output = 'mesecons_detector:node_detector_off', recipe = { - {"default:steel_ingot", "group:mesecon_conductor_craftable", "default:steel_ingot"}, - {"default:steel_ingot", "mesecons_microcontroller:microcontroller0000", "default:steel_ingot"}, - {"default:steel_ingot", "default:steel_ingot", "default:steel_ingot"}, + {"mesecons_gamecompat:steel_ingot", "group:mesecon_conductor_craftable", "mesecons_gamecompat:steel_ingot"}, + {"mesecons_gamecompat:steel_ingot", "mesecons_microcontroller:microcontroller0000", "mesecons_gamecompat:steel_ingot"}, + {"mesecons_gamecompat:steel_ingot", "mesecons_gamecompat:steel_ingot", "mesecons_gamecompat:steel_ingot"}, } }) diff --git a/mesecons_detector/mod.conf b/mesecons_detector/mod.conf index 0a43985..6d5a0e6 100644 --- a/mesecons_detector/mod.conf +++ b/mesecons_detector/mod.conf @@ -1,2 +1,2 @@ name = mesecons_detector -depends = default, mesecons, mesecons_materials +depends = mesecons, mesecons_gamecompat, mesecons_materials diff --git a/mesecons_detector/textures/mesecons_detector_side.png b/mesecons_detector/textures/mesecons_detector_side.png new file mode 100644 index 0000000000000000000000000000000000000000..5e421f026e37a1b6629f837d1862621f8abf87c3 GIT binary patch literal 350 zcmV-k0iphhP)CdN%F4pR!lI(0nVFf>)YQPi zz`nk|mzS5;($UPy&dklt&dbT3o}QJJm6MZ`yS%!%xVW#cug}lU(9+E?z=xIq006d0 zL_t&-83n)=3|xuOABX$`z0bQhUdac3FLtR z$Us5*B_Ij21AgF{umAu;#4#J{LcB2`LU-EsfeE3DMEGw-SFQLmNeIjwC~I`XASSsr zI#bgS@`2$UU~kmiscFT78Ve{k%@q1pVZ?Ojn|p{M_g+xtIzx=AZ{2&}3?B|zb$^## wvu<0##69M`?Vr7?#yC;UtXi>$&0+Iv|IVTbVIPc