June 2013
Beginner
352 pages
9h 5m
English
Every jMonkeyEngine game has a so-called context type. The context type specifies whether the game opens an OpenGL window, renders on a canvas, or runs "headless"—without drawing anything to the screen.
main() method when you app.start() the application:public static void main(String[] args) {
AppSettings settings = new AppSettings(true);
settings.setTitle("My Cool Game");
SettingsTest app = new SettingsTest();
app.setSettings(settings);
app.start(JmeContext.Type.Headless); // switch context type
}The game loop executes in a so-called headless context; this means no video is rendered. We'll look at examples where you would switch context types.
Read now
Unlock full access