Hey, i have some custom UI where i have weapon [1] icon displayed near unit portrait, however if my unit getting hidden extra weapons via behaviour some of them appearing before this primary weapon and as a result i have wrong icon displayed in unit status. Can someone explain me how weapons in array getting their indexes? (i tried weapon names, range and order in wich they have been added but i cannot understand what priority using sc2)
In my experience it was impossible to control the order weapons are displayed in, if you're adding/removing weapons.
The only way to fix the order was to add to the unit all the weapons that the unit could ever have, and disable+hide the ones that should start inactive. Then when you activate/deactivate weapons they will show in the right order.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Hey, i have some custom UI where i have weapon [1] icon displayed near unit portrait, however if my unit getting hidden extra weapons via behaviour some of them appearing before this primary weapon and as a result i have wrong icon displayed in unit status. Can someone explain me how weapons in array getting their indexes? (i tried weapon names, range and order in wich they have been added but i cannot understand what priority using sc2)
@abvdzh: Go
In my experience it was impossible to control the order weapons are displayed in, if you're adding/removing weapons. The only way to fix the order was to add to the unit all the weapons that the unit could ever have, and disable+hide the ones that should start inactive. Then when you activate/deactivate weapons they will show in the right order.