0
0
Fork 0

Help texts: Button, redstone lamp, commandblock

This commit is contained in:
Wuzzy 2017-03-11 03:38:08 +01:00
parent bba375e61d
commit 2453d3fa63
3 changed files with 19 additions and 0 deletions

View File

@ -20,6 +20,7 @@ end
local boxes_off = { -4/16, -2/16, 8/16, 4/16, 2/16, 6/16 } -- The button
local boxes_on = { -4/16, -2/16, 8/16, 4/16, 2/16, 7/16 } -- The button
local buttonuse = "Rightclick the button to push it and send a redstone impulse."
minetest.register_node("mesecons_button:button_stone_off", {
drawtype = "nodebox",
tiles = {"default_stone.png"},
@ -40,6 +41,8 @@ minetest.register_node("mesecons_button:button_stone_off", {
},
groups = {handy=1,pickaxey=1, attached_node=1, dig_by_water=1},
description = "Stone Button",
_doc_items_longdesc = "A stone button is a redstone component made out of stone which gives a short impulse to a redstone component behind it when it pushed.",
_doc_items_usagehelp = buttonuse,
on_rightclick = function (pos, node)
mesecon:swap_node(pos, "mesecons_button:button_stone_on")
mesecon:receptor_on(pos, mesecon.rules.buttonlike_get(node))
@ -106,6 +109,8 @@ minetest.register_node("mesecons_button:button_wood_off", {
},
groups = {handy=1,axey=1, attached_node=1, dig_by_water=1},
description = "Wooden Button",
_doc_items_longdesc = "A wooden button is a redstone component made out of wood which gives a short impulse to a redstone component behind it when it pushed.",
_doc_items_usagehelp = buttonuse,
on_rightclick = function (pos, node)
mesecon:swap_node(pos, "mesecons_button:button_wood_on")
mesecon:receptor_on(pos, mesecon.rules.buttonlike_get(node))

View File

@ -176,6 +176,19 @@ end
minetest.register_node("mesecons_commandblock:commandblock_off", {
description = "Command Block",
_doc_items_longdesc =
"Command blocks are mighty redstone components which are able to alter reality itself. In other words, they cause the server to execute server commands when they are supplied with redstone power.",
_doc_items_usagehelp =
[[Initially, a command block does not have any commands and does nothing. Rightclick the command block to edit its commands. Refer to the help entry about server commands to understand how they work. Each line contains a single command, the commands will be executed from top to bottom. The commands DO NOT require a leading slash.
You can optionally use the following placeholders in your commands:
@nearest is replaced by the name of the player nearest to the command block
@farthest is replaced by the name of the player farthest away from the command block
@random is replaced by the name of a random player currently connected
To execute the commands, supply the command block with redstone power once. To execute them again, you have to turn the power off and on again.]],
tiles = {{name="jeija_commandblock_off.png", animation={type="vertical_frames", aspect_w=32, aspect_h=32, length=2}}},
groups = {creative_breakable=1, mesecon_effector_off=1, not_in_creative_inventory=1},
drop = "",

View File

@ -4,6 +4,7 @@ minetest.register_node("mesecons_lightstone:lightstone_off", {
groups = {handy=1, mesecon_effector_off = 1, mesecon = 2},
is_ground_content = false,
description= "Redstone Lamp",
_doc_items_longdesc = "Redstone lamps are simple redstone components which glow brightly (light level 14) when they receive redstone power.",
sounds = mcl_sounds.node_sound_stone_defaults(),
mesecons = {effector = {
action_on = function (pos, node)