2019-12-30 06:07:56 +00:00
|
|
|
from .OrthoWalk import *
|
2019-11-02 22:27:54 +00:00
|
|
|
|
|
|
|
class TwoDWalk(OrthoWalk):
|
|
|
|
notify = DirectNotifyGlobal.directNotify.newCategory('TwoDWalk')
|
|
|
|
BROADCAST_POS_TASK = 'TwoDWalkBroadcastPos'
|
|
|
|
|
|
|
|
def doBroadcast(self, task):
|
|
|
|
dt = globalClock.getDt()
|
|
|
|
self.timeSinceLastPosBroadcast += dt
|
|
|
|
if self.timeSinceLastPosBroadcast >= self.broadcastPeriod:
|
|
|
|
self.timeSinceLastPosBroadcast = 0
|
|
|
|
self.lt.cnode.broadcastPosHprFull()
|
|
|
|
return Task.cont
|