def __init__(self): Nametag.__init__(self) Clickable3d.__init__(self, 'Nametag3d') self.distance = 0 self.billboardOffset = 3 self.doBillboardEffect()
def update(self): self.contents.node().removeAllChildren() Nametag.update(self) if self.cell is not None: self.reposition() self.updateClickRegion() elif self.region is not None: self.region.setActive(False)
def destroy(self): self.ignoreAll() if self.chatBalloonAnimTrack is not None: self.chatBalloonAnimTrack.finish() self.chatBalloonAnimTrack = None Nametag.destroy(self) Clickable3d.destroy(self)
def __init__(self): Nametag.__init__(self) Clickable2d.__init__(self, 'Nametag2d') MarginVisible.__init__(self) self.actualChatText = '' self.arrow = None self.textNodePath = None self.contents.setScale(self.CONTENTS_SCALE) self.hideThought() self.accept('MarginVisible-update', self.update)
def destroy(self): self.ignoreAll() Nametag.destroy(self) if self.textNodePath is not None: self.textNodePath.removeNode() self.textNodePath = None if self.arrow is not None: self.arrow.removeNode() self.arrow = None Clickable2d.destroy(self)
def __init__(self): Nametag.__init__(self) Clickable3d.__init__(self, 'Nametag3d') self.distance = 0 self.billboardOffset = 3 self.doBillboardEffect() self.chatBalloonAnimTrack = None
def update(self): self.contents.node().removeAllChildren() Nametag.update(self) if self.cell is not None: # We're in the margin display. Reposition our content, and update # the click region: self.reposition() self.updateClickRegion() else: # We aren't in the margin display. Disable the click region if one # is present: if self.region is not None: self.region.setActive(False)
def setChatText(self, chatText): self.actualChatText = chatText Nametag.setChatText(self, chatText)
def setAvatar(self, avatar): Nametag.setAvatar(self, avatar) Clickable3d.setAvatar(self, avatar)
def destroy(self): self.ignoreAll() Nametag.destroy(self) Clickable3d.destroy(self)
def update(self): self.contents.node().removeAllChildren() Nametag.update(self)
def update(self): self.removeContents() Nametag.update(self)