本文整理汇总了Java中org.newdawn.slick.Game类的典型用法代码示例。如果您正苦于以下问题:Java Game类的具体用法?Java Game怎么用?Java Game使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Game类属于org.newdawn.slick包,在下文中一共展示了Game类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: runAsApplication
import org.newdawn.slick.Game; //导入依赖的package包/类
/**
* Start the game as an application
*
* @param game The game to be started
* @param width The width of the window
* @param height The height of the window
* @param fullscreen True if the window should be fullscreen
*/
public static void runAsApplication(Game game, int width, int height, boolean fullscreen) {
try {
AppGameContainer container = new AppGameContainer(game, width, height, fullscreen);
container.start();
} catch (Exception e) {
e.printStackTrace();
}
}
示例2: closeRequested
import org.newdawn.slick.Game; //导入依赖的package包/类
/**
* @see org.newdawn.slick.Game#closeRequested()
*/
public boolean closeRequested() {
// To run Cleanup at window close
de.tu_darmstadt.gdi1.gorillas.main.Game.cleanupOnExit();
return true;
}
示例3: runAsApplication
import org.newdawn.slick.Game; //导入依赖的package包/类
/**
* Start the game as an application
*
* @param game The game to be started
* @param width The width of the gui
* @param height The height of the gui
* @param fullscreen True if the gui should be fullscreen
*/
public static void runAsApplication(Game game, int width, int height, boolean fullscreen) {
try {
AppGameContainer container = new AppGameContainer(game, width, height, fullscreen);
container.start();
} catch (Exception e) {
e.printStackTrace();
}
}
示例4: TWLTestAppGameContainer
import org.newdawn.slick.Game; //导入依赖的package包/类
public TWLTestAppGameContainer(Game game) throws SlickException {
super(game, 640, 480, false);
}
示例5: Container
import org.newdawn.slick.Game; //导入依赖的package包/类
/**
* Create a new container wrapping a game
*
* @param game The game to be wrapped
* @throws SlickException Indicates a failure to initialise the display
*/
public Container(Game game) throws SlickException {
super(game);
}