예제 #1
0
        public void DrawScene(SceneInstance scene)
        {
            InstanceCollection instances = scene.Instances;

            //instances.SortByDepth();

            //draw sprites
            foreach (Instance inst in instances)
            {
                DrawSprite(inst.Sprite, inst.Position, inst.ImageAngle, inst.ScaleX, inst.ScaleY, inst.ImageIndex);
            }
        }
예제 #2
0
        public void DrawScene(SceneInstance scene)
        {
            InstanceCollection instances = scene.Instances;

            //instances.SortByDepth();

            //draw sprites
            foreach (Instance inst in instances)
            {
                DrawSprite(inst.Sprite, inst.Position, inst.ImageAngle, inst.ScaleX, inst.ScaleY, inst.ImageIndex, inst.Offset.X, inst.Offset.Y, scene.ViewPosition.X - scene.ViewOrigin.X, scene.ViewPosition.Y - scene.ViewOrigin.Y);
                if (scene.UsesPhysics && DrawCollisionBounds)
                {
                    DrawCollision(inst, scene.ViewPosition.X - scene.ViewOrigin.X, scene.ViewPosition.Y - scene.ViewOrigin.Y);
                }
            }
        }