tweak again
This commit is contained in:
parent
1f76362cf4
commit
fdfd7e816a
@ -57,9 +57,6 @@ local nametag = {
|
||||
|
||||
function nametag:on_step(dtime)
|
||||
local wielder = self.wielder
|
||||
wielder:set_nametag_attributes({
|
||||
color = {a = 0, r = 0, g = 0, b = 0}
|
||||
})
|
||||
if wielder == nil then
|
||||
self.object:remove()
|
||||
elseif minetest.get_player_by_name(wielder:get_player_name()) == nil then
|
||||
@ -85,6 +82,14 @@ local function step()
|
||||
end
|
||||
minetest.after(10, step)
|
||||
|
||||
minetest.register_globalstep(function(player)
|
||||
for _, player in pairs(minetest.get_connected_players()) do
|
||||
player:set_nametag_attributes({
|
||||
color = {a = 0, r = 0, g = 0, b = 0}
|
||||
})
|
||||
end
|
||||
end)
|
||||
|
||||
minetest.register_on_joinplayer(function(player)
|
||||
if not player.tag then
|
||||
player:set_nametag_attributes({
|
||||
|
Loading…
x
Reference in New Issue
Block a user