Пример #1
0
        public virtual void Draw(SpriteBatch spriteBatch)
        {
            foreach (KeyValuePair <string, Entity.Entity> entity in Entity.EntityManager.Entities)
            {
                Entity.Entity curEntity = entity.Value;

                if (curEntity.Scene == this)
                {
                    if (shown)
                    {
                        curEntity.Draw(spriteBatch);
                    }
                }
            }
        }
Пример #2
0
        public virtual void Update(GameTime gameTime)
        {
            foreach (KeyValuePair <string, Entity.Entity> entity in Entity.EntityManager.Entities)
            {
                Entity.Entity curEntity = entity.Value;

                if (curEntity.Scene == this)
                {
                    if (shown)
                    {
                        curEntity.Update(gameTime);
                    }
                }
            }
        }