Example #1
0
        public override void LoadContent(IServiceProvider services)
        {
            base.LoadContent(services);
            var content = (ContentManager)services.GetService(typeof(ContentManager));

            var texture = content.Load<Texture2D>(@"Sprites\SpaceShip");
            var sprite = new StaticSprite(new Vector2(2.0f, 6.0f),  texture, Name + "_Sprite", new Rectangle(0, 0, 128, 386));

            SceneNode.Attach(sprite);
        }
Example #2
0
        public override void LoadContent(IServiceProvider services)
        {
            base.LoadContent(services);
            var content = (ContentManager)services.GetService(typeof(ContentManager));

            var texture = content.Load<Texture2D>(@"Sprites\Chain");
            var sprite = new StaticSprite(new Vector2(1.0f), texture, Name + "_Sprite");

            SceneNode.Attach(sprite);
        }