Exemplo n.º 1
0
 public Meteorite(AnimatedSprite sprite, Texture2D spriteMask, Vector2 playerPosition, Vector2 playerSpeed)
 {
     Sprite = sprite;
     SpriteMask = spriteMask;
     SetRandomPosition(playerPosition);
     CalculateVelocity(playerPosition, playerSpeed);
 }
Exemplo n.º 2
0
        public void LoadContent(SpriteBatch sb, ContentManager content)
        {
            Texture2D animSpr = content.Load<Texture2D>("Sprites/Spaceship/spaceship");
            Sprite = new AnimatedSprite(animSpr, new Point(460, 214), Point.Zero, new Point(1, 1), 20);

            brokenShip1 = content.Load<Texture2D>("Sprites/Spaceship/broken_ship1");
            brokenShip2 = content.Load<Texture2D>("Sprites/Spaceship/broken_ship2");
        }
Exemplo n.º 3
0
 public void LoadContent(SpriteBatch sb, ContentManager content)
 {
     Texture2D animSpr = content.Load<Texture2D>("Sprites/Player/astronaut");
     Sprite = new AnimatedSprite(animSpr, new Point(32, 45), Point.Zero, new Point(1, 1), 20);
     move = content.Load<SoundEffect>("Sounds/move");
     moveEffect = move.CreateInstance();
     moveEffect.IsLooped = true;
     moveEffect.Volume = 0.3f;
 }
        public void LoadContent(SpriteBatch sb, ContentManager content)
        {
            //HUD stuffs
            HUDFont = content.Load<SpriteFont>("Fonts/HUDFont");
            Arrow = content.Load<Texture2D>("Sprites/HUD/arrow");
            ObjectiveArrow = content.Load<Texture2D>("Sprites/HUD/objective_arrow");
            BigBlank = content.Load<Texture2D>("Sprites/HUD/big_blank");
            Controls = content.Load<Texture2D>("Sprites/HUD/controls");

            //Background stuffs
            bgList.Add(Background1 = content.Load<Texture2D>("Sprites/Backgrounds/background1"));
            bgList.Add(Background2 = content.Load<Texture2D>("Sprites/Backgrounds/background2"));
            bgList.Add(Background3 = content.Load<Texture2D>("Sprites/Backgrounds/background3"));
            bgList.Add(Background4 = content.Load<Texture2D>("Sprites/Backgrounds/background4"));

            //Items
            Ai = content.Load<Texture2D>("Sprites/Items/ai");
            Engine = content.Load<Texture2D>("Sprites/Items/engine");
            Welder = content.Load<Texture2D>("Sprites/Items/welder");
            Pickup = content.Load<SoundEffect>("Sounds/pick_up");
            Repair = content.Load<SoundEffect>("Sounds/repair");

            //Meteor
            Texture2D meteorSprite = content.Load<Texture2D>("Sprites/Meteorite/meteorite");
            Meteor = new AnimatedSprite(meteorSprite, new Point(32, 64), Point.Zero, new Point(1, 1), 20);

            MeteorMask = content.Load<Texture2D>("Sprites/Meteorite/meteorite_mask");
        }