From b85df95bb226d6a2dd5acad410f4f57794e81733 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Tue, 29 Aug 2017 00:13:18 +0200 Subject: [PATCH] Add dummy nodes: Activator rail, detector rail --- mods/ENTITIES/mcl_minecarts/rails.lua | 80 ++++++++++++++++++ .../textures/mcl_minecarts_rail_activator.png | Bin 0 -> 285 bytes .../mcl_minecarts_rail_activator_powered.png | Bin 0 -> 281 bytes .../textures/mcl_minecarts_rail_detector.png | Bin 0 -> 319 bytes .../mcl_minecarts_rail_detector_powered.png | Bin 0 -> 321 bytes .../mcl_minecarts/textures/rail_detector.png | Bin 283 -> 0 bytes .../textures/rail_detector_powered.png | Bin 277 -> 0 bytes mods/MISC/mcl_wip/init.lua | 4 + tools/Texture_Conversion_Table.csv | 4 + 9 files changed, 88 insertions(+) create mode 100644 mods/ENTITIES/mcl_minecarts/textures/mcl_minecarts_rail_activator.png create mode 100644 mods/ENTITIES/mcl_minecarts/textures/mcl_minecarts_rail_activator_powered.png create mode 100644 mods/ENTITIES/mcl_minecarts/textures/mcl_minecarts_rail_detector.png create mode 100644 mods/ENTITIES/mcl_minecarts/textures/mcl_minecarts_rail_detector_powered.png delete mode 100644 mods/ENTITIES/mcl_minecarts/textures/rail_detector.png delete mode 100644 mods/ENTITIES/mcl_minecarts/textures/rail_detector_powered.png diff --git a/mods/ENTITIES/mcl_minecarts/rails.lua b/mods/ENTITIES/mcl_minecarts/rails.lua index 36f1d4317..ca1007716 100644 --- a/mods/ENTITIES/mcl_minecarts/rails.lua +++ b/mods/ENTITIES/mcl_minecarts/rails.lua @@ -76,6 +76,67 @@ register_rail("mcl_minecarts:golden_rail_on", ) +-- Activator rail (off) +register_rail("mcl_minecarts:activator_rail", + {"mcl_minecarts_rail_activator.png", "default_rail_curved.png^[colorize:#FF0000:96", "default_rail_t_junction.png^[colorize:#FF0000:96", "default_rail_crossing.png^[colorize:#FF0000:96"}, + { + description = "Activator Rail", + _doc_items_longdesc = "Rails can be used to build transport tracks for minecarts. Activator rails are used to activate special minecarts.", + _doc_items_usagehelp = railuse .. "\n" .. "To make this rail activate minecarts, power it with redstone power and send a minecart over this piece of rail.", + mesecons = { + conductor = { + state = mesecon.state.off, + onstate = "mcl_minecarts:activator_rail_on", + }, + }, + } +) + +-- Activator rail (on) +register_rail("mcl_minecarts:activator_rail_on", + {"mcl_minecarts_rail_activator_powered.png", "default_rail_curved.png^[colorize:#FF0000:128", "default_rail_t_junction.png^[colorize:#FF0000:128", "default_rail_crossing.png^[colorize:#FF0000:128"}, + { + _doc_items_create_entry = false, + mesecons = { + conductor = { + state = mesecon.state.on, + offstate = "mcl_minecarts:activator_rail", + }, + }, + }, + false +) + +-- Detector rail (off) +register_rail("mcl_minecarts:detector_rail", + {"mcl_minecarts_rail_detector.png", "default_rail_curved.png^[colorize:#FFFFFF:96", "default_rail_t_junction.png^[colorize:#FFFFFF:96", "default_rail_crossing.png^[colorize:#FFFFFF:96"}, + { + description = "Detector Rail", + _doc_items_longdesc = "Rails can be used to build transport tracks for minecarts. A detector rail is able to detect a minecart above it and powers redstone mechanisms.", + _doc_items_usagehelp = railuse .. "\n" .. "To detect a minecart and provide redstone power, connect it to redstone trails or redstone mechanisms and send any minecart over the rail.", + mesecons = { + receptor = { + state = mesecon.state.off, + }, + }, + } +) + +-- Detector rail (on) +register_rail("mcl_minecarts:detector_rail_on", + {"mcl_minecarts_rail_detector_powered.png", "default_rail_curved.png^[colorize:#FFFFFF:128", "default_rail_t_junction.png^[colorize:#FFFFFF:128", "default_rail_crossing.png^[colorize:#FFFFFF:128"}, + { + _doc_items_create_entry = false, + mesecons = { + receptor = { + state = mesecon.state.on, + }, + }, + }, + false +) + + -- Crafting minetest.register_craft({ output = 'mcl_minecarts:rail 16', @@ -95,6 +156,25 @@ minetest.register_craft({ } }) +minetest.register_craft({ + output = "mcl_minecarts:activator_rail 6", + recipe = { + {"mcl_core:iron_ingot", "mcl_core:stick", "mcl_core:iron_ingot"}, + {"mcl_core:iron_ingot", "mesecons_torch:mesecon_torch_on", "mcl_core:iron_ingot"}, + {"mcl_core:iron_ingot", "mcl_core:stick", "mcl_core:iron_ingot"}, + } +}) + +minetest.register_craft({ + output = "mcl_minecarts:detector_rail 6", + recipe = { + {"mcl_core:iron_ingot", "", "mcl_core:iron_ingot"}, + {"mcl_core:iron_ingot", "mesecons_pressureplates:pressure_plate_stone_off", "mcl_core:iron_ingot"}, + {"mcl_core:iron_ingot", "mesecons:redstone", "mcl_core:iron_ingot"}, + } +}) + + -- Aliases if minetest.get_modpath("doc") then doc.add_entry_alias("nodes", "mcl_minecarts:golden_rail", "nodes", "mcl_minecarts:golden_rail_on") diff --git a/mods/ENTITIES/mcl_minecarts/textures/mcl_minecarts_rail_activator.png b/mods/ENTITIES/mcl_minecarts/textures/mcl_minecarts_rail_activator.png new file mode 100644 index 0000000000000000000000000000000000000000..15f2cdba6b4ee679079694ef87c19fec26d759bb GIT binary patch literal 285 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!73?$#)eFPFP2=EDU1=60Lo;o@@|NsBDwY4n_ zb1^kFRaRD>SDDb6pjSG-xUVTiy5n4hw!XzC4{NtiVywV6}JxBLkb1s+b+S S|1qGu7(8A5T-G@yGywpMjAv&6 literal 0 HcmV?d00001 diff --git a/mods/ENTITIES/mcl_minecarts/textures/mcl_minecarts_rail_activator_powered.png b/mods/ENTITIES/mcl_minecarts/textures/mcl_minecarts_rail_activator_powered.png new file mode 100644 index 0000000000000000000000000000000000000000..ad072f425d5f64ae9de87cead8942ec7728a0b36 GIT binary patch literal 281 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!73?$#)eFPFP2=EDU{r~?zkm>2^siUJ~YinB= z=3;7Us;sO$uQH)C%daNhC&}BoiI;aeGjjnGlcAwrc{Fz*$e@xSzhDLipl$?U_{iAn z0+j3Uba4!+U`$R35o2LeW@KYaXHzgpN=WeSfAL~Q)~1F=?b^@Ru3mFv0b3wVN(4;?tLxaNRv>+&ZI%BvrG0_kbM5K_2POcO96NAerrg#| z$*XQMvAz3pcK7zE**OeSJBqHITB^p#^XJ|F#se>yuN+WfTVdSA!Vp=ZeuzDDZ!*wL N44$rjF6*2UngFCJZ0!I5 literal 0 HcmV?d00001 diff --git a/mods/ENTITIES/mcl_minecarts/textures/mcl_minecarts_rail_detector.png b/mods/ENTITIES/mcl_minecarts/textures/mcl_minecarts_rail_detector.png new file mode 100644 index 0000000000000000000000000000000000000000..4595df3a40778882f7cf34e61e54dca6ae811334 GIT binary patch literal 319 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!63?wyl`GbL!Yk*IP>;M1%flN%gCD-iBUaNmYV9JLTTVv$5+1`43@Xb4&xA8hAYoCDUpOiYG` zddHe09svy!FA4GsX88Xfh#&yY_|Fh8mvR=UWQwPYV@L&~u0QJ{XGNaosDgbtcmA)? z&gYHt5AvEB)bMF^#n__ORg0 z&TF@Les*ep{$BonZT$^xnbU7=CBNCcmj*hLZZB4vS zVVFy2mfyU}1Z8DqQ&ZC!o?ikFrTKupHDDYN%h3 z;Bz#2*Q1>ljqEFf&PF~>VlgZ@D*AbiXb)G^``VuC3xkb+UAp#_ciW`r87hBEPsbS@ zli0hTvFky^^{*C+tUXh2E6=*9EEF;M1%Jv}{jbaZTOZENCv z3d3AFv;5{&CMYW_o0^&?d0RK}@|Kqr_w{tNG&W6VX3k(@%FWBlPKYdEV#@6OH5X_O zV@Z%-FoVOh8)-mJyQhm|NCji;`F5se1s;|QZ`5{t{r`U}`(4}b!4DOb#H!q8yb#|q z-}mU_YmX!O3Z|)@m07OC%<{Nf?(-G5j(@yXnV0tHoZe-ZxcbiYWIO)@GoG$mQrf2D zzd$JJdTAtsYsb|Wf@v=V8