Fixed chat studder
This commit is contained in:
parent
c8221f94a1
commit
153cf0f204
5
init.lua
5
init.lua
@ -2,6 +2,7 @@ local block_sounds = {}
|
||||
local player_name = {}
|
||||
local handler = {}
|
||||
local sound = {}
|
||||
local chats = {}
|
||||
|
||||
minetest.register_node("mysoundblocks:block", {
|
||||
description = "Sound Block",
|
||||
@ -264,9 +265,11 @@ end
|
||||
|
||||
-- display text
|
||||
if (sound_chat == "chat" or sound_chat == "both")
|
||||
and block_text then
|
||||
and block_text
|
||||
and block_text ~= chats[p] then
|
||||
|
||||
minetest.chat_send_player(p, block_text)
|
||||
chats[p] = block_text
|
||||
end
|
||||
|
||||
-- play sound
|
||||
|
Loading…
x
Reference in New Issue
Block a user