Exemplo n.º 1
0
  public static void main(String[] args) {
    LwjglApplicationConfiguration cfg = new LwjglApplicationConfiguration();
    System.setProperty("org.lwjgl.opengl.Window.undecorated", "true");
    cfg.fullscreen = false;
    cfg.resizable = false;
    cfg.title = "Our First Game";
    cfg.useGL20 = true;

    // get user's desktop screen resolution
    int desktopWidth = java.awt.Toolkit.getDefaultToolkit().getScreenSize().width;
    int desktopHeight = java.awt.Toolkit.getDefaultToolkit().getScreenSize().height;

    // calculate window size...
    int gameWidth = 1920; // default to 1920x1080
    int gameHeight = 1080;
    float gameAspectRatio = (float) gameWidth / (float) gameHeight;
    // if the user doesn't support 1920x1080, go for the greatest width possible (and retain the
    // widescreen aspect ratio)
    if (gameWidth > desktopWidth) {
      gameWidth = desktopWidth;
      gameHeight = (int) ((1.0f / gameAspectRatio) * gameWidth);
    }

    // handle an unlikely scenario where the user has a really high screen resolution (something
    // weird like 500x1500)
    if (gameHeight > desktopHeight) {
      gameWidth = (int) (desktopWidth * gameAspectRatio);
      gameHeight = desktopHeight;
    }

    cfg.width = gameWidth;
    cfg.height = gameHeight;

    new LwjglApplication(new OurFirstGame(), cfg);
  }
Exemplo n.º 2
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.width = 1280;
   config.height = 720;
   config.resizable = false;
   new LwjglApplication(new Skyland(), config);
 }
Exemplo n.º 3
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.title = "Drop";
   config.width = 800;
   config.height = 480;
   new LwjglApplication(new Drop(), config);
 }
Exemplo n.º 4
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.title = "BlackJack!";
   config.height = 772;
   config.width = 1286;
   new LwjglApplication(new BlackJackGame(), config);
 }
Exemplo n.º 5
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.title = "10,000 Leagues above the Sea";
   config.width = 1920;
   config.height = 1080;
   new LwjglApplication(new THLGame(), config);
 }
Exemplo n.º 6
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.title = "Go Go Helicopter";
   config.width = 272;
   config.height = 408;
   new LwjglApplication(new GGHGame(), config);
 }
Exemplo n.º 7
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.title = "Sliding Squares";
   config.width = 240;
   config.height = 320;
   new LwjglApplication(new SlidingSquaresGame(), config);
 }
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.width = MarioBros.V_WIDTH * 2;
   config.height = MarioBros.V_HEIGHT * 2;
   config.title = "Mario Bros";
   new LwjglApplication(new MarioBros(), config);
 }
Exemplo n.º 9
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.title = "MinerWars";
   config.width = 800;
   config.height = 600;
   new LwjglApplication(new MinerWars(), config);
 }
  @BeforeClass
  public static void setUp() {
    duckGame = new DuckGame();

    LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
    config.width = 1280;
    config.height = 720;
    config.resizable = false;
    config.title = "SUPER DUCK INVADERS! - Team Mallard";
    new LwjglApplication(duckGame, config);

    while (duckGame.onGameScreen == false) {
      try {
        Thread.sleep(100);
      } catch (InterruptedException e) {
        e.printStackTrace();
      }
    }
    testRound = new Round(duckGame, Assets.levelOneMap);
    try {
      Thread.sleep(200);
    } catch (InterruptedException e) {
      e.printStackTrace();
    }
  }
 public static void main(String[] arg) {
   GalacticInvaders.instantiateSettings();
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.width = Settings.getWidth();
   config.height = Settings.getHeight();
   new LwjglApplication(new GalacticInvaders(), config);
 }
Exemplo n.º 12
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.width = MyGdxGame.V_WIDTH * MyGdxGame.SCALE;
   config.height = MyGdxGame.V_HEIGHT * MyGdxGame.SCALE;
   config.title = MyGdxGame.TITLE;
   new LwjglApplication(new MyGdxGame(), config);
 }
 public static void main(String[] arg) {
   LwjglApplicationConfiguration cfg = new LwjglApplicationConfiguration();
   cfg.title = "Animus";
   cfg.width = 960;
   cfg.height = 640;
   new LwjglApplication(new Animus(), cfg);
 }
Exemplo n.º 14
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.title = "Burning Maze";
   config.width = 1200;
   config.height = 675;
   new LwjglApplication(new KumQuat(), config);
 }
Exemplo n.º 15
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.title = "Zombie Shooter";
   config.width = 1280;
   config.height = 720;
   new LwjglApplication(new MyGdxGame(), config);
 }
Exemplo n.º 16
0
  public static void main(String[] args) {
    LwjglApplicationConfiguration configuracion = new LwjglApplicationConfiguration();
    configuracion.title = "Box2D Joints";
    configuracion.width = 1024;
    configuracion.height = 768;

    new LwjglApplication(new MyWorld(), configuracion);
  }
Exemplo n.º 17
0
  public static void main(String[] arg) {
    LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();

    config.width = 1280;
    config.height = 720;

    new LwjglApplication(new FlappyBird(), config);
  }
Exemplo n.º 18
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.title = "Texas";
   config.height = 600;
   config.width = 800;
   GUIlibgdx app = new GUIlibgdx();
   new LwjglApplication(app, config);
 }
  public static void main(String[] arg) {

    LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
    config.title = "hello-world";
    config.width = 800;
    config.height = 600;
    new LwjglApplication(new MyGdxGame(), config);
  }
Exemplo n.º 20
0
  public static void main(String[] args) {
    LwjglApplicationConfiguration cfg = new LwjglApplicationConfiguration();
    cfg.title = "SoundHealing";
    cfg.width = 720;
    cfg.height = 1280;

    new LwjglApplication(new MainScene(), cfg);
  }
Exemplo n.º 21
0
  public static void main(String[] args) {
    LwjglApplicationConfiguration cfg = new LwjglApplicationConfiguration();
    cfg.width = 800;
    cfg.height = 600;
    cfg.useGL20 = true; // 90% or more of your desktop users should support GL20

    new LwjglApplication(new SimpleTest(), cfg);
  }
Exemplo n.º 22
0
 /**
  * Runs the game on a desktop computer
  *
  * @param arg command line args -- not used
  */
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.title = Malice.TITLE + " v" + Malice.VERSION;
   config.vSyncEnabled = true;
   config.width = Malice.GAME_WIDTH;
   config.height = Malice.GAME_HEIGHT;
   new LwjglApplication(new Malice(), config);
 }
Exemplo n.º 23
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.title = "Hackathon Game";
   config.useGL30 = false;
   config.width = MainGameClass.WIDTH;
   config.height = MainGameClass.HEIGHT;
   new LwjglApplication(new MainGameClass(), config);
 }
Exemplo n.º 24
0
  public static void main(String[] args) {
    LwjglApplicationConfiguration cfg = new LwjglApplicationConfiguration();
    cfg.title = "TestTileMap";
    cfg.width = 1300;
    cfg.height = 800;

    new LwjglApplication(new HappyPotterMain(), cfg);
  }
Exemplo n.º 25
0
  public static void main(String[] arg) {
    LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();

    config.width = Banna.WIDTH;
    config.height = Banna.HEIGHT;
    config.title = Banna.TITLE;
    new LwjglApplication(new Banna(Banna.WIDTH, Banna.HEIGHT), config);
  }
Exemplo n.º 26
0
 public static void main(String[] arg) {
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.width = 1024;
   config.height = 768;
   WorldView listener = new WorldView();
   LwjglApplication lwjglApplication = new LwjglApplication(listener, config);
   listener.setWidth(config.width);
   listener.setHeigth(config.height);
 }
  public static void main(String[] arg) {
    LwjglApplicationConfiguration cfg = new LwjglApplicationConfiguration();
    cfg.title = "my-gdx-game";
    cfg.useGL30 = false;
    cfg.width = 1280;
    cfg.height = 720;

    new LwjglApplication(new MyGdxGame(), cfg);
  }
Exemplo n.º 28
0
  public static void main(String[] args) {
    LwjglApplicationConfiguration cfg = new LwjglApplicationConfiguration();
    cfg.title = "Motherboard";
    cfg.useGL20 = false;
    cfg.width = 800;
    cfg.height = 600;

    new LwjglApplication(new Game(), cfg);
  }
 public static void main(String[] args) throws Exception {
   LwjglApplicationConfiguration.disableAudio = true;
   LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
   config.width = 800;
   config.height = 600;
   config.title = "Skeleton Viewer";
   config.allowSoftwareMode = true;
   new LwjglApplication(new SkeletonViewer(), config);
 }
Exemplo n.º 30
0
  public static void main(String[] args) {
    LwjglApplicationConfiguration cfg = new LwjglApplicationConfiguration();
    cfg.title = "Musiz";
    cfg.useGL20 = false;
    cfg.width = 800;
    cfg.height = 450;

    new LwjglApplication(new Musiz(), cfg);
  }