Beispiel #1
0
 public GamePlayState(bool restart)
 {
     hudBar        = new Sprite("hudbar", new Vector2(0, 480 * 0.85f));
     CurrentWeapon = new Sprite("pistolhud", new Vector2(550, 422.5f));
     CurrentFace   = new Sprite("face1", new Vector2(640 / 2 - 40, 480 - 67.5f));
     ScreenBuffer.Initialize();
     Player.Initialize();
     rayCaster = new RayCaster(true);
 }
Beispiel #2
0
        public GamePlayState()
        {
            //HUD
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/hudbar.png", "hudbar");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/pistol.png", "pistol");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/pistolhud.png", "pistolhud");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/machinehud.png", "machinehud");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/minihud.png", "minihud");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/pistolfire.png", "pistolfire");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/machine.png", "machinegun");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/machinefire.png", "machinegunfire");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/mini.png", "mini");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/minifire.png", "minifire");

            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/face0.png", "face0");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/face1.png", "face1");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/face2.png", "face2");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/face3.png", "face3");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/face4.png", "face4");

            //SPRITES
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy1.png", "enemy1");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy11.png", "enemy11");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy12.png", "enemy12");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy13.png", "enemy13");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy2.png", "enemy2");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy21.png", "enemy21");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy22.png", "enemy22");


            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/clip.png", "clip");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/firstaid.png", "firstaid");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/lamp.png", "lamp");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/machinegun.png", "machinegun2");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/chaingun.png", "chaingun");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/pillar.png", "pillar");

            //AUDIO
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/pistol.wav", "pistol");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/machine.wav", "machine");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/mini.wav", "mini");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/open.wav", "open");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/close.wav", "close");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/die.wav", "die");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/hurt.wav", "hurt");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/clip.wav", "clip");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/health.wav", "health");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/weaponpickup.wav", "weaponpickup");

            hudBar = new Sprite("hudbar", new Vector2(0, 480 * 0.85f));
            CurrentWeapon = new Sprite("pistolhud", new Vector2(550, 422.5f));
            CurrentFace = new Sprite("face1", new Vector2(640 / 2 - 40, 480 - 67.5f));
            ScreenBuffer.Initialize();
            Player.Initialize();
            rayCaster = new RayCaster();

        }
Beispiel #3
0
        public GamePlayState()
        {
            //HUD
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/hudbar.png", "hudbar");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/pistol.png", "pistol");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/pistolhud.png", "pistolhud");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/machinehud.png", "machinehud");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/minihud.png", "minihud");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/pistolfire.png", "pistolfire");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/machine.png", "machinegun");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/machinefire.png", "machinegunfire");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/mini.png", "mini");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/minifire.png", "minifire");

            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/face0.png", "face0");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/face1.png", "face1");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/face2.png", "face2");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/face3.png", "face3");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/hud/face4.png", "face4");

            //SPRITES
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy1.png", "enemy1");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy11.png", "enemy11");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy12.png", "enemy12");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy13.png", "enemy13");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy2.png", "enemy2");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy21.png", "enemy21");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/enemy22.png", "enemy22");


            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/clip.png", "clip");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/firstaid.png", "firstaid");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/lamp.png", "lamp");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/machinegun.png", "machinegun2");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/chaingun.png", "chaingun");
            ContentManager.LoadTexture(GameUtils.GetAppPath() + "/content/sprites/pillar.png", "pillar");

            //AUDIO
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/pistol.wav", "pistol");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/machine.wav", "machine");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/mini.wav", "mini");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/open.wav", "open");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/close.wav", "close");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/die.wav", "die");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/hurt.wav", "hurt");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/clip.wav", "clip");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/health.wav", "health");
            ContentManager.LoadSound(GameUtils.GetAppPath() + "/content/audio/weaponpickup.wav", "weaponpickup");

            hudBar        = new Sprite("hudbar", new Vector2(0, 480 * 0.85f));
            CurrentWeapon = new Sprite("pistolhud", new Vector2(550, 422.5f));
            CurrentFace   = new Sprite("face1", new Vector2(640 / 2 - 40, 480 - 67.5f));
            ScreenBuffer.Initialize();
            Player.Initialize();
            rayCaster = new RayCaster();
        }
Beispiel #4
0
 public GamePlayState(bool restart)
 {
     hudBar = new Sprite("hudbar", new Vector2(0, 480 * 0.85f));
     CurrentWeapon = new Sprite("pistolhud", new Vector2(550, 422.5f));
     CurrentFace = new Sprite("face1", new Vector2(640 / 2 - 40, 480 - 67.5f));
     ScreenBuffer.Initialize();
     Player.Initialize();
     rayCaster = new RayCaster(true);
 }