Example #1
0
        /// <summary>
        /// Allows the game to perform any initialization it needs to before starting to run.
        /// This is where it can query for any required services and load any non-graphic
        /// related content.  Calling base.Initialize will enumerate through any components
        /// and initialize them as well.
        /// </summary>
        protected override void Initialize()
        {
            // TODO: Add your initialization logic here
            inputManager.Initialize();
            screenManager.Initialize();
            firstScreen.Initialize(screenManager);
            firstScreen.Activate();

            base.Initialize();
        }
Example #2
0
        //private bool screenIsLoaded = false;
        public override void Update(GameTime gameTime)
        {
            if (isOnlyScreen)
            {
                this.Close();

                screenToLoad.Initialize(this.Manager);
                screenToLoad.Activate();

                this.Game.ResetElapsedTime();
            }


            //if (nextDot <= gameTime.TotalGameTime)
            //{
            //    dots.Add('.');
            //    nextDot = gameTime.TotalGameTime.Add(dotInterval);
            //    if (dots.Count >= 10)
            //        dots.Clear();
            //}

            //if (screenToLoad.IsConnected) // && loadingTask.IsCompleted)
            //{
            //    //if (!charIsSelected)
            //    //{
            //    //    //Random rnd = new Random();
            //    //    screenToLoad.SelectCharacter((ushort)rnd.Next(1, UInt16.MaxValue));
            //    //}
            //    //else if (screenToLoad.IsLoaded)
            //    //{
            //    screenToLoad.Activate();
            //    isLoadCompleated = true;
            //    this.Close();
            //    //}
            //}
        }