Update() public method

public Update ( ) : void
return void
Esempio n. 1
0
        public override void Update(GameTime gametime)
        {
            manager.Update();

            sm.Update();

            bg.Update();

            if (i > 3 * 60)
            {
                console.wipe();
                i = 0;
            }
            else
            {
                if (console.log.Count > 0)
                {
                    i++;
                }
            }

            if (!manager.paused)
            {
                player.Update();
                camera.Update();

                foreach (GameObject t in tiles)
                {
                    t.Update();
                }

                foreach (GameObject t in deco)
                {
                    t.Update();
                }

                List <Destroyable> staticPickups = new List <Destroyable>();
                staticPickups = pickups.ToList();
                foreach (GameObject t in staticPickups)
                {
                    t.Update();
                }

                List <Enemy> staticEnemies = new List <Enemy>();
                staticEnemies = enemies.ToList();
                foreach (Enemy g in staticEnemies)
                {
                    g.Update();
                }

                List <Danmaku> staticProjectiles = new List <Danmaku>();
                staticProjectiles = projectiles.ToList();
                foreach (Danmaku d in staticProjectiles)
                {
                    d.Update();
                }

                foreach (Trigger t in triggers)
                {
                    t.Update();
                }

                boss.Update();
                attackoverlay.Update();
            }
            base.Update(gametime);
        }