Hi again,
I have a problem with Gbui and GameStates again. My problem is when I load my app with gbui and bss style all is correct, but if I go to some other gamestate using the menu, when I back to the state before, some styles (like the images) are missing, but not all of them.
To activate and deactivate the gbui windows I use this functions (this is from atchnique project, but a little modified):
public void activate() {
super.setActive(true);
// Display the GBUI portion
rootNode.attachChild(BuiSystem.getRootNode());
rootNode.updateRenderState();
GameTaskQueueManager.getManager().update(new Callable<Object>() {
public Object call() throws Exception {
BuiSystem.addWindow(_window);
_window.center();
return null;
}
});
}
public void deactivate() {
// If still active, hide the GBUI portion
if (_window.getRootNode() != null) {
_window.dismiss();
}
rootNode.detachChild(BuiSystem.getRootNode());
super.setActive(false);
}
The BuiSystem.init() function is called in the constructor of the GbuiGameState class.
Thanks.