def onActivate(self, entity, suit):
     ActivateTrapGag.onActivate(self, entity, suit)
     x, y, z = entity.getPos(render)
     sinkPos01 = Point3(x, y, z - 3.1)
     sinkPos02 = Point3(x, y, z - 9.1)
     dropPos = Point3(x, y, z + 15)
     landPos = Point3(x, y, z)
     suit.d_disableMovement()
     suit.setPos(x, y, z)
     entTrack = Sequence(
         Wait(2.4), LerpScaleInterval(entity, 0.8, GagGlobals.PNT3NEAR0))
     suitTrack = Sequence(
         Wait(0.9), LerpPosInterval(suit, 0.9, sinkPos01),
         LerpPosInterval(suit, 0.4, sinkPos02), Func(suit.setPos, dropPos),
         Func(suit.hide), Wait(1.1), Func(suit.show),
         Func(suit.setPos, dropPos),
         Parallel(LerpPosInterval(suit, 0.3, landPos),
                  Func(suit.play, 'slip-forward')),
         Func(self.damageSuit, suit), Func(suit.d_enableMovement))
     animTrack = Sequence(ActorInterval(suit, 'flail'),
                          ActorInterval(suit, 'flail', startTime=1.1),
                          Wait(0.7),
                          ActorInterval(suit, 'slip-forward', duration=2.1))
     soundTrack = Sequence(Wait(0.7), SoundInterval(self.hitSfx, node=suit),
                           Wait(0.1),
                           SoundInterval(self.activateSfx, node=suit))
     Parallel(entTrack, suitTrack, animTrack, soundTrack).start()
 def onActivate(self, entity, suit):
     ActivateTrapGag.onActivate(self, entity, suit)
     x, y, z = entity.getPos(render)
     sinkPos = Point3(x, y, z - 9.1)
     dropPos = Point3(x, y, z + 15)
     landPos = Point3(x, y, z)
     suit.d_disableMovement()
     suit.setPos(x, y, z)
     entTrack = Sequence(Wait(0.4), Func(entity.setColor, Vec4(0, 0, 0, 1)), Wait(0.4), LerpScaleInterval(entity, 0.8, GagGlobals.PNT3NEAR0))
     suitTrack = Sequence(
         self.getSplicedLerpAnimsTrack(suit, 'flail', 0.7, 0.25),
         Wait(0.2), 
         LerpPosInterval(suit, 0.4, sinkPos), 
         Func(suit.setPos, dropPos),
         Func(suit.hide),
         ActorInterval(suit, 'neutral', duration=0.5), 
         Wait(0.75), 
         Func(suit.show),
         Parallel(LerpPosInterval(suit, 0.3, landPos), Func(suit.play, 'slip-forward')),
         SoundInterval(self.activateSfx, node = suit), 
         Func(self.damageSuit, suit),
         Func(suit.d_enableMovement) 
     )
     soundTrack = Sequence(SoundInterval(self.hitSfx, node = suit), Wait(0.8))
     Parallel(entTrack, suitTrack, soundTrack).start()
示例#3
0
 def onActivate(self, entity, suit):
     ActivateTrapGag.onActivate(self, entity, suit)
     slidePos = entity.getPos(render)
     slidePos.setY(slidePos.getY() - 5.1)
     moveTrack = Sequence(Wait(0.1), LerpPosInterval(self.gag, 0.1, slidePos))
     animTrack = Sequence(ActorInterval(self.gag, 'banana', startTime=3.1), Wait(1.1), LerpScaleInterval(self.gag, 1, Point3(0.01, 0.01, 0.01)))
     suitTrack = ActorInterval(suit, 'slip-backward')
     soundTrack = Sequence(SoundInterval(self.slipSfx, duration=0.55, node=suit), SoundInterval(self.activateSfx, node=suit))
     Parallel(moveTrack, animTrack, suitTrack, soundTrack).start()
示例#4
0
 def onActivate(self, entity, suit):
     ActivateTrapGag.onActivate(self, entity, suit)
     x, y, z = entity.getPos(render)
     sinkPos = Point3(x, y, z - 9.1)
     dropPos = Point3(x, y, z + 15)
     landPos = Point3(x, y, z)
     suit.d_disableMovement()
     suit.setPos(x, y, z)
     entTrack = Sequence(Wait(0.4), Func(entity.setColor, Vec4(0, 0, 0, 1)), Wait(0.4), LerpScaleInterval(entity, 0.8, GagGlobals.PNT3NEAR0))
     suitTrack = Sequence(self.getSplicedLerpAnimsTrack(suit, 'flail', 0.7, 0.25), Wait(0.2), LerpPosInterval(suit, 0.4, sinkPos), Func(suit.setPos, dropPos), Func(suit.hide), ActorInterval(suit, 'neutral', duration=0.5), Wait(0.75), Func(suit.show), Parallel(LerpPosInterval(suit, 0.3, landPos), Func(suit.play, 'slip-forward')), SoundInterval(self.activateSfx, node=suit), Func(self.damageSuit, suit), Func(suit.d_enableMovement))
     soundTrack = Sequence(SoundInterval(self.hitSfx, node=suit), Wait(0.8))
     Parallel(entTrack, suitTrack, soundTrack).start()
示例#5
0
 def onActivate(self, entity, suit):
     ActivateTrapGag.onActivate(self, entity, suit)
     slidePos = entity.getPos(render)
     slidePos.setY(slidePos.getY() - 5.1)
     moveTrack = Sequence(Wait(0.1),
                          LerpPosInterval(self.gag, 0.1, slidePos))
     animTrack = Sequence(
         ActorInterval(self.gag, 'banana', startTime=3.1), Wait(1.1),
         LerpScaleInterval(self.gag, 1, Point3(0.01, 0.01, 0.01)))
     suitTrack = ActorInterval(suit, 'slip-backward')
     soundTrack = Sequence(
         SoundInterval(self.slipSfx, duration=0.55, node=suit),
         SoundInterval(self.activateSfx, node=suit))
     Parallel(moveTrack, animTrack, suitTrack, soundTrack).start()
示例#6
0
 def onActivate(self, entity, suit):
     ActivateTrapGag.onActivate(self, entity, suit)
     x, y, z = entity.getPos(render)
     sinkPos01 = Point3(x, y, z - 3.1)
     sinkPos02 = Point3(x, y, z - 9.1)
     dropPos = Point3(x, y, z + 15)
     landPos = Point3(x, y, z)
     suit.d_disableMovement()
     suit.setPos(x, y, z)
     entTrack = Sequence(Wait(2.4), LerpScaleInterval(entity, 0.8, GagGlobals.PNT3NEAR0))
     suitTrack = Sequence(Wait(0.9), LerpPosInterval(suit, 0.9, sinkPos01), LerpPosInterval(suit, 0.4, sinkPos02), Func(suit.setPos, dropPos), Func(suit.hide), Wait(1.1), Func(suit.show), Func(suit.setPos, dropPos), Parallel(LerpPosInterval(suit, 0.3, landPos), Func(suit.play, 'slip-forward')), Func(self.damageSuit, suit), Func(suit.d_enableMovement))
     animTrack = Sequence(ActorInterval(suit, 'flail'), ActorInterval(suit, 'flail', startTime=1.1), Wait(0.7), ActorInterval(suit, 'slip-forward', duration=2.1))
     soundTrack = Sequence(Wait(0.7), SoundInterval(self.hitSfx, node=suit), Wait(0.1), SoundInterval(self.activateSfx, node=suit))
     Parallel(entTrack, suitTrack, animTrack, soundTrack).start()