nametag: Fix issue with chat balloon text

This commit is contained in:
John Cote 2026-01-27 21:48:56 -05:00
parent e3701c2cf4
commit f502426644
No known key found for this signature in database
GPG Key ID: A5250CCD017DFCA5
1 changed files with 4 additions and 0 deletions

View File

@ -18,6 +18,7 @@
#include "sceneGraphReducer.h"
#include "cullBinAttrib.h"
#include "cullFaceAttrib.h"
#include "depthWriteAttrib.h"
////////////////////////////////////////////////////////////////////
// Function: ChatBalloon::Constructor
@ -170,6 +171,9 @@ generate(const std::string &text, TextFont *font, float wordwrap,
PandaNode *text_parent_node = (PandaNode *)NULL;
// This is required for modern Panda3D.
text_geom_node->set_attrib(DepthWriteAttrib::make(DepthWriteAttrib::M_off));
if (for_3d) {
// If this is to be a 3-d chat balloon, we have to decal the text
// onto the middle piece.