• 0

    posted a message on Status bars without boss bar? + Galaxy syntax.

    I haven't found anything in the trigger editor that allows the boss bar to be changed (other than the potrait / race).

    Anybody have some other input on this?

    Posted in: Miscellaneous Development
  • 0

    posted a message on Status bars without boss bar? + Galaxy syntax.

    I've been working on creating a hero / unit fixed health bar without using the boss bar prototype. I don't particularly like the frame's aesthetics, and my UI would be a little ambiguous in places where I wanted to use the boss bar for an actual enemy. I tried using a progress bar widget, but it was also not particularly good looking and had some map startup updating problems. Right now I've settled on using an image and a manual handler for updating the size.

    Question: Is using an image in this circumstance a good practice? Is there any way to change the appearance of a progress bar?

    I've run into a problem with using an image, however; In order to accurately scale the width of the image to the unit's health, I need to use a formula that returns healthBarWidth * (Unit Health / Unit Health Max). All of my attempts to use a custom script in the editor return a syntax error that I'm not sure how to troubleshoot with vague error handling and limited knowledge of the language.

    Assuming that using an image is a good choice, what is the problem with this script?

    DialogControlSetSize(gv_healthBarImage, PlayerGroupAll(), UnitGetPropertyInt(gv_Hero, c_unitPropLife, c_unitPropCurrent), gv_healthBarHeight);
    

    UnitGetPropertyInt(gv_Hero, c_unitPropLife, c_unitPropCurrent) is the custom script I'm using, the rest is generated code from the editor.

    Link to the map (including the unused progress bar widget test and its problems), if it helps. http://ftp.nerfdusk.com/magss/POC_StatusBars_Images.SC2Map http://ftp.nerfdusk.com/magss/POC_StatusBars.SC2Map

    Thanks for any assistance.

    Posted in: Miscellaneous Development
  • To post a comment, please or register a new account.