2019-11-02 17:27:54 -05:00
|
|
|
from pandac.PandaModules import *
|
2019-12-30 00:07:56 -06:00
|
|
|
from .DistributedNPCToon import *
|
2019-11-02 17:27:54 -05:00
|
|
|
|
|
|
|
class DistributedNPCFlippyInToonHall(DistributedNPCToon):
|
|
|
|
|
|
|
|
def __init__(self, cr):
|
|
|
|
DistributedNPCToon.__init__(self, cr)
|
|
|
|
|
|
|
|
def getCollSphereRadius(self):
|
|
|
|
return 4
|
|
|
|
|
|
|
|
def initPos(self):
|
|
|
|
self.clearMat()
|
|
|
|
self.setScale(1.25)
|
|
|
|
|
|
|
|
def handleCollisionSphereEnter(self, collEntry):
|
|
|
|
if self.allowedToTalk():
|
|
|
|
base.cr.playGame.getPlace().fsm.request('quest', [self])
|
|
|
|
self.sendUpdate('avatarEnter', [])
|
|
|
|
self.nametag3d.setDepthTest(0)
|
|
|
|
self.nametag3d.setBin('fixed', 0)
|
|
|
|
self.lookAt(base.localAvatar)
|
|
|
|
else:
|
|
|
|
place = base.cr.playGame.getPlace()
|
|
|
|
if place:
|
|
|
|
place.fsm.request('stopped')
|
|
|
|
self.dialog = TeaserPanel.TeaserPanel(pageName='quests', doneFunc=self.handleOkTeaser)
|