From d2ca662569427d36642660314668e416bf68f3c8 Mon Sep 17 00:00:00 2001 From: est31 Date: Mon, 18 May 2015 22:41:22 +0200 Subject: [PATCH] Enforce hiding nametag Work around irrlicht bug and hide nametag if its alpha is set to 0. Thanks @TeTpaAka for pointing out workaround. --- src/content_cao.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/content_cao.cpp b/src/content_cao.cpp index b49c64ae8..d80804d4a 100644 --- a/src/content_cao.cpp +++ b/src/content_cao.cpp @@ -1721,6 +1721,11 @@ void GenericCAO::processMessage(const std::string &data) m_nametag_color = readARGB8(is); if (m_textnode != NULL) { m_textnode->setTextColor(m_nametag_color); + + // Enforce hiding nametag, + // because if freetype is enabled, a grey + // shadow can remain. + m_textnode->setVisible(m_nametag_color.getAlpha() > 0); } } } -- 2.25.1