HUD issues

Started by ffomega, November 27, 2016, 10:53:29 PM

Previous topic - Next topic
I wanted to create a HUD sprite sheet in which all my HUD assets were in a single place.  Hearts, magic meter, rupee icons, action icons, item slot icons, etc.  I started out by creating .dat files for all the HUD's different assets, figuring that's what I needed to do.

I tried editing the individual HUD scripts to look for the single HUD image, and that didn't work--nothing showed up at all.

Then, I undid the changes to the HUD scripts I had made and tried going back to the defaults from the LttP resource pack and the hearts now do not display correctly.  I had to recreate the hearts image, using a slightly different version of the original that came with LttP resource pack.

The thing I am wondering now is:

For the hearts and all other HUD assets, does each asset have to be its own individual image in order for the script to successfully recognize it?  Is it possible to use a singular image with all the needed assets in it for a HUD to be correctly created using the scripts provided by default?
My tilesets page can be found here:
http://absolute-hyrule-tutorials.solarus-games.org/

There is no restriction on the images to be used in HUD elements. Several scripts can access the same image if they want.
The problem you have must come from something else. Do you have errors in the console?

There are no errors.  However I did play around with the hearts script a bit, and had to add some comments to the code in order for me to better understand what part of the image file draws the hearts.  I think I have solved the issue on the hearts.  As for why the HUD was not properly displaying, I am not sure what happened.  All I did was move the scripts for the HUD files around.

That being said, I will most likely be using the Mystery of Solarus' heart system rather than the default LttP script for quarter heart damage
My tilesets page can be found here:
http://absolute-hyrule-tutorials.solarus-games.org/