projects
/
oweals
/
minetest.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5b03857
)
Enforce hiding nametag
author
est31
<MTest31@outlook.com>
Mon, 18 May 2015 20:41:22 +0000
(22:41 +0200)
committer
est31
<MTest31@outlook.com>
Mon, 18 May 2015 21:10:48 +0000
(23:10 +0200)
Work around irrlicht bug and hide nametag if its alpha is set to 0.
Thanks @TeTpaAka for pointing out workaround.
src/content_cao.cpp
patch
|
blob
|
history
diff --git
a/src/content_cao.cpp
b/src/content_cao.cpp
index b49c64ae85bbc9afd8fa480dfcc6e191e09ef624..d80804d4a0bae3b384521164ea4a324998d2179f 100644
(file)
--- 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);
}
}
}