protected override void OnAddedToScene()
        {
            base.OnAddedToScene();
            burningSkull = new Client.Game.Map.Effects.ClericBurningSkull();
            Scene.Add(burningSkull);

            if (Program.Instance != null)
            {
                var sm        = Program.Instance.SoundManager;
                var idleSound = sm.GetSoundResourceGroup(sm.GetSFX(SFX.ClericIdle1), sm.GetSFX(SFX.ClericIdle2), sm.GetSFX(SFX.ClericIdle3));
                idle = idleSound.PlayLoopedWithIntervals(5, 15, 3f + (float)Game.Random.NextDouble() * 3.0f, new Sound.PlayArgs
                {
                    GetPosition = () => { return(Position); },
                    GetVelocity = () => { if (MotionNPC != null)
                                          {
                                              return(MotionNPC.Velocity);
                                          }
                                          else
                                          {
                                              return(Vector3.Zero);
                                          } }
                });
            }
        }
Example #2
0
 protected override void OnAddedToScene()
 {
     base.OnAddedToScene();
     burningSkull = new Client.Game.Map.Effects.ClericBurningSkull();
     Scene.Add(burningSkull);
 }