also remove rank from nametag (#62)

master
Luke aka SwissalpS 2021-12-11 19:47:07 +01:00 committed by GitHub
parent 0847ce546c
commit ad7f6deb6d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 9 additions and 0 deletions

View File

@ -119,6 +119,15 @@ local remove_hud = function(player)
end
hud[playername] = nil
if not xp_redo.disable_nametag then
local is_admin = minetest.check_player_privs(playername, {privs=true})
local is_hidden = minetest.check_player_privs(playername, {hide_nametag=true})
if is_hidden or is_admin then return end
player:set_nametag_attributes({ text = playername })
end
end