I think this might be related to the “1.5 texture bug” as discussed here:
discourse.panda3d.org/viewtopic.php?t=4055
However… My what gets screwed up for me are simple TextNodes! That don’t even have textures(or texturestages) applied to them!
So i’m not quite sure how to fix this.
But here is the full rundown:
I’m implementing shadows, from the shadows tutorial. Everything works fine, everything casts a shadow, etc. Nice.
Except… For my characters I have “nameplates” over their heads, made using a TextNode. Here is the code I use:
class NamePlate(NodePath):
""" Nameplate to display text, such as the name of a character or a pawn """
def __init__(self, id, text, borderColor):
NodePath.__init__(self, id)
self.setBillboardPointEye();
namePlate = TextNode(id);
namePlate.setAlign(TextNode.ACenter);
namePlate.setFrameColor(borderColor);
namePlate.setFrameAsMargin(0.4, 0.4, 0.1, 0.1);
namePlate.setFrameLineWidth(4);
namePlate.setFrameCorners(True);
namePlate.setCardColor(1, 1, 1, 0.7);
namePlate.setCardAsMargin(0.4, 0.4, 0.1, 0.1);
namePlate.setCardDecal(True);
namePlate.setText(text);
self.attachNewNode(namePlate)
self.setLightOff()
self.setScale(4)
I then reparent that to the character
However… The background of the textnode is all screwed up! It displays random textures of other things in the scene. And even flips between textures between frames.
I’m not manually loading textures for ANYTHING in the scene.
Everything else except the background of my textnodes looks fine.
Any ideas?