diff options
author | R3R3R3 <24302636+R3R3R3@users.noreply.github.com> | 2020-02-10 19:38:48 +0100 |
---|---|---|
committer | R3R3R3 <24302636+R3R3R3@users.noreply.github.com> | 2020-02-10 19:54:38 +0100 |
commit | d63d32b42ba9a8e397b572e17bf7735a0792ab36 (patch) | |
tree | e16ac455d188020d7fac29b94f4067c41a8a458a /signs | |
parent | d2c7abd98b33007f5fd21558147b4c3f60cec69b (diff) | |
download | display_modpack_no_craft-d63d32b42ba9a8e397b572e17bf7735a0792ab36.tar.gz display_modpack_no_craft-d63d32b42ba9a8e397b572e17bf7735a0792ab36.zip |
Override on_punch for poster node definition
The signs_api `register_sign`'s default `on_punch` sets a sign's formspec to the
sign editor. If we protect a poster and then punch/break it, subsequent attempts
to view the poster will briefly cause the the sign editor to display before the
actual poster formspec. Small, but annoying.
Diffstat (limited to 'signs')
-rw-r--r-- | signs/nodes.lua | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/signs/nodes.lua b/signs/nodes.lua index b04c463..df3da54 100644 --- a/signs/nodes.lua +++ b/signs/nodes.lua @@ -210,6 +210,9 @@ local models = { on_construct = display_api.on_construct, on_rightclick = display_poster, on_receive_fields = on_receive_fields_poster, + on_punch = function(pos, node, player, pointed_thing) + display_api.update_entities(pos) + end, }, }, label_small = { |