/** * Starts the <code>ViewAppState</code> by attaching it to the specified <code>MasterApplication * </code>. * * @param app The jME-based <code>MasterApplication</code> that will be hosting this <code> * ViewAppState</code>. */ public void start(MasterApplication app) { // Do not proceed if the AppState is initialized or the parameter is // null. if (!isInitialized() && app != null) { // Set the app and get the next available ID. this.app = app; this.id = app.getNextId(); // Update the names of the root and GUI Node in the // MasterApplication's scene graph. rootNode.setName("root-" + id); guiNode.setName("gui-" + id); // Now proceed with the normal start procedure. super.start(app); } return; }