1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-09-15 18:57:08 +00:00

Tool specific pointing and blocking pointable type (#13992)

This commit is contained in:
cx384 2024-01-22 18:27:08 +01:00 committed by GitHub
parent fb461d21a5
commit 5958714309
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
39 changed files with 676 additions and 67 deletions

View file

@ -663,3 +663,23 @@ minetest.register_node("testnodes:post_effect_color_shaded_true", {
is_ground_content = false,
groups = {dig_immediate=3},
})
-- Pointability
-- Register wrapper for compactness
local function register_pointable_test_node(name, description, pointable)
local texture = "testnodes_"..name..".png"
minetest.register_node("testnodes:"..name, {
description = S(description),
tiles = {texture},
drawtype = "glasslike_framed",
paramtype = "light",
walkable = false,
pointable = pointable,
groups = {dig_immediate=3, [name.."_test"]=1},
})
end
register_pointable_test_node("pointable", "Pointable Node", true)
register_pointable_test_node("not_pointable", "Not Pointable Node", false)
register_pointable_test_node("blocking_pointable", "Blocking Pointable Node", "blocking")