コード例 #1
0
 public static void main(String[] args) throws SlickException {
   AppGameContainer app = new AppGameContainer(new DungeonGardenGame());
   app.setAlwaysRender(true);
   app.setDisplayMode(800, 600, false);
   app.setMaximumLogicUpdateInterval(40);
   app.start();
 }
コード例 #2
0
  public static void main(String[] args) throws SlickException {
    AppGameContainer app = new AppGameContainer(new SetupClass("Setup Test"));
    app.setDisplayMode(800, 600, false);
    app.setAlwaysRender(true);
    app.setTargetFrameRate(60);

    app.start();
  }
コード例 #3
0
ファイル: Game.java プロジェクト: hadenbarrow/Ship-Shooter
 public static void main(String[] args) throws SlickException {
   AppGameContainer app = new AppGameContainer(new Game(TITLE));
   app.setDisplayMode(Screen.SCREEN_W, Screen.SCREEN_H, false);
   app.setAlwaysRender(true);
   app.setTargetFrameRate(60);
   app.setShowFPS(true);
   app.start();
 }
コード例 #4
0
 public static void main(String[] args) {
   LoadingList.setDeferredLoading(true);
   try {
     AppGameContainer app = new AppGameContainer(new DragonGame());
     app.setDisplayMode(width, height, fullscreen);
     app.setShowFPS(false);
     app.setMouseGrabbed(false);
     app.setTargetFrameRate(60);
     app.setAlwaysRender(true);
     app.setUpdateOnlyWhenVisible(true);
     app.start();
   } catch (SlickException e) {
     e.printStackTrace();
   }
 }
コード例 #5
0
  public static void main(String[] args) throws SlickException {
    TankzGame tankz = new TankzGame("Tankz");
    AppGameContainer container = new AppGameContainer(tankz);
    container.setDisplayMode(
        Math.round(container.getScreenWidth() * 0.7f),
        Math.round(container.getScreenHeight() * 0.8f),
        false);
    container.setAlwaysRender(true);
    // container.setDisplayMode(1920, 1200, true);
    // container.setTargetFrameRate(60);
    // container.setMaximumLogicUpdateInterval(1);
    // container.setMinimumLogicUpdateInterval(1);

    container.setMusicOn(false);
    container.setMusicVolume(0.1f);
    container.setSoundOn(false);
    container.setSoundVolume(0.1f);

    container.start();
  }
コード例 #6
0
ファイル: JumpNRunClient.java プロジェクト: TheCrasher/rgb4
  /** @param args */
  public static void main(String[] args) {

    ClientGame clientGame = new ClientGame();

    // initialize (gfx) settings depending on game type
    if (clientGame != null) {

      try {

        AppGameContainer gc = new AppGameContainer(clientGame);
        gc.setDisplayMode(Settings.SCREENWIDTH, Settings.SCREENHEIGHT, false);
        gc.setVSync(true);
        gc.setSmoothDeltas(true);
        gc.setAlwaysRender(true);
        gc.setUpdateOnlyWhenVisible(false);
        gc.setMaximumLogicUpdateInterval(30);
        gc.setTargetFrameRate(60);
        gc.start();
      } catch (SlickException e) {
        e.printStackTrace();
      }
    }
  }