New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom UiTheme results in NullPointerException #204
Comments
Can you provide the full |
Sure, the full buttons.json contains:
The Full buttons.atlas contains:
The confusing thing is, if i replace the path to my json file with |
The issue is that it can't find your texture atlas. Is it in the same directory as your json file? |
In fact, it is. Here a simplified blueprint of my directory tree:
So is there something i'm missing, as i really don't see why it does not work... |
Did you try setting it to |
Quite embarrassing to be honest, but i didn't. And after some bug fixes in my json file everything works now. thanks mate. |
Issue details
When trying to load your custom UiTheme using the AssetManager java exits with a NullPointerException. What i did (simplified):
buttons.atlas
file in my assets directory.buttons.json
-> where i specified the different types of buttons and there respective styling -> here's a example with the button -> default "class":MainMenu.java
file i've created an assetManager and try to load mybuttons.json
file. -> This contains something like that:also i've added the
assetManager.update()
function to myupdate()
function which should load all assets (which it does referring to the console output)When running my program, i get an error message saying:
I've tried to trace this issue back to where it came from but did came closer than to the update function of the AssetManager file.
Version of mini2Dx and/or relevant dependencies
1.9.0
Stacktrace
Please select the affected platforms
The text was updated successfully, but these errors were encountered: