Esempio n. 1
0
    def suitExplode(self):
        pos = self.getPart('body').find('**/joint_head').getPos(render) + (0, 0, 2)

        # Force the loser suit to use UnlitGeneric shader, workaround for the has_mat() assertion
        BSPUtility.applyUnlitOverride(self)

        CIGlobals.makeExplosion(pos, 0.5, soundVol = 0.32)
Esempio n. 2
0
 def __init__(self):
     Entity.__init__(self)
     self.setLightOff(1)
     self.hide(CIGlobals.ShadowCameraBitmask)
     BSPUtility.applyUnlitOverride(self)
     
     self.system = None
     self.spawnflags = 0
    def start(self):
        super(JugglingBalls, self).start()
        self.setupHips()
        self.build()
        self.placeProp(self.hips, self.gag)
        self.soundInterval = self.getSoundTrack(0.7, self.gag, 7.7)

        BSPUtility.applyUnlitOverride(self.gag)

        propInterval = Sequence()
        propInterval.append(ActorInterval(self.gag, 'chan'))
        if self.avatar == base.localAvatar:
            propInterval.append(Func(self.setHealAmount))
            propInterval.append(Func(self.healNearbyAvatars, 25))
        propInterval.append(Func(self.cleanupGag))
        propInterval.append(Func(self.reset))
        self.track = Parallel(ActorInterval(self.avatar, 'juggle'),
                              propInterval, Func(self.soundInterval.start))
        self.track.start()
Esempio n. 4
0
 def load(self):
     Entity.load(self)
     
     entnum = self.cEntity.getEntnum()
     loader = base.bspLoader
     
     ptfFile = loader.getEntityValue(entnum, "file")
     scale = loader.getEntityValueFloat(entnum, "scale")
     self.spawnflags = loader.getEntityValueInt(entnum, "spawnflags")
     self.system = ParticleLoader.loadParticleEffect(ptfFile)
     BSPUtility.applyUnlitOverride(self.system)
     self.system.setLightOff(1)
     self.system.setScale(scale)
     
     self.setPos(self.cEntity.getOrigin())
     self.setHpr(self.cEntity.getAngles())
     self.reparentTo(render)
     
     if self.spawnflags & self.StartsEnabled:
         self.Start()
Esempio n. 5
0
    def __init__(self):
        Entity.__init__(self)
        Rope.__init__(self)

        self.hide(CIGlobals.ShadowCameraBitmask)
        BSPUtility.applyUnlitOverride(self)