Exemplo n.º 1
0
        public void Draw(SpriteBatch spriteBatch, float totalSeconds, Camera camera)
        {
            time += totalSeconds;

            explosionSystem.Draw(spriteBatch, explosion, camera);

            spriteBatch.Begin();

            sparkSystem.Draw(spriteBatch, camera, spark);
            sparkSystem.Update(totalSeconds);

            if (sparkSystem.CheckIfDone())
            {
                smokeSystem.DrawAndUpdate(spriteBatch, camera, smoke, totalSeconds);
            }

            spriteBatch.End();
        }
Exemplo n.º 2
0
        public void Draw(SpriteBatch spriteBatch, float totalSeconds, Camera camera)
        {
            time += totalSeconds;



            spriteBatch.Begin();
            foreach (ExplosionSystem es in explosions)
            {
                es.Draw(spriteBatch, explosion, camera);
            }
            foreach (SparkSystem ss in sparks)
            {
                ss.Update(totalSeconds);
                ss.Draw(spriteBatch, camera, spark);
            }

            foreach (SmokeSystem smokeSystem in smokes)
            {
                smokeSystem.DrawAndUpdate(spriteBatch, camera, smoke, totalSeconds);
            }

            spriteBatch.End();
        }