Example #1
0
        protected override void Initialize()
        {
            base.Initialize();
            this.scene = (GameScene)this.Owner.Scene;
            this.soundManager = WaveServices.GetService<SoundManager>();

            this.topMargin = this.transform2D.Rectangle.Height / 2;

            this.SetState(KiteStates.TakeOff);
        }
        protected override void Initialize()
        {
            base.Initialize();

            if (!this.isInitialized)
            {
                this.soundManager = WaveServices.GetService<SoundManager>();

                if (WaveServices.ScreenContextManager != null)
                {
                    WaveServices.ScreenContextManager.OnActivatingScene += this.ScreenContextManager_OnActivatingScene;
                    WaveServices.ScreenContextManager.OnDesactivatingScene += this.ScreenContextManager_OnDesactivatingScene;
                }

                this.kiteBehavior.OnStateChanged += this.KiteBehavior_OnStateChanged;

                this.UpdateCustomLayerEntities();

                this.SetState(this.InitialState);
            }
        }
Example #3
0
        protected override void Initialize()
        {
            base.Initialize();
            this.soundManager = WaveServices.GetService<SoundManager>();

            this.virtualScreenManager = this.Owner.Scene.VirtualScreenManager;

            this.topMargin = this.transform2D.Rectangle.Height / 2;

            this.SetState(KiteStates.TakeOff);

            this.SetNewColor();
        }