Changing the order of icons shown?

Status
Not open for further replies.
Level 6
Joined
May 7, 2009
Messages
228
Suppose I have a bunch of abilities that all have the default icon spot of 0,0 (top left corner). In game, the order they appear in is the order they were added to the unit.

Now the question: How do I change this order during the game? I thought that if I removed the abilities and added them back in the desired order, I could change it that way.
However, this doesn't work. After a great deal of debugging, I have come to the conclusion that Warcraft always goes by the order in which each ability was added the first time.

So what can I do? How do I change the order?


Basically, I want my abilities to always appear in alphabetical order. So I guess I don't need to change the order per se. The problem stems from adding new abilities to the unit later in the game.
For example, suppose, the unit gets A, B, and D at the start. If I later give it C, they will appear in the order A, B, D, C. Even if I remove D before adding C, and then add it in afterwards, it will still appear in this order.
Now I could add A,B,C,D,... at the start and immediately remove them, ensuring that later additions will always appear in order. However, my map has 102 abilities, and doing so tends to create lag.:cgrin:
Any ideas?
 
Level 14
Joined
Apr 20, 2009
Messages
1,543
Suppose I have a bunch of abilities that all have the default icon spot of 0,0 (top left corner). In game, the order they appear in is the order they were added to the unit.

Now the question: How do I change this order during the game? I thought that if I removed the abilities and added them back in the desired order, I could change it that way.
However, this doesn't work. After a great deal of debugging, I have come to the conclusion that Warcraft always goes by the order in which each ability was added the first time.

So what can I do? How do I change the order?


Basically, I want my abilities to always appear in alphabetical order. So I guess I don't need to change the order per se. The problem stems from adding new abilities to the unit later in the game.
For example, suppose, the unit gets A, B, and D at the start. If I later give it C, they will appear in the order A, B, D, C. Even if I remove D before adding C, and then add it in afterwards, it will still appear in this order.
Now I could add A,B,C,D,... at the start and immediately remove them, ensuring that later additions will always appear in order. However, my map has 102 abilities, and doing so tends to create lag.:cgrin:
Any ideas?

are you sure you setted the icon coordinate to the correct one?
and not only the normal position but also the research position and the turn off position if they have one.... also are these abilities unit abilities or hero abilities?

then don't forget that 0,0 isn't always left top because you also have the default move, attack, hold position etc buttons... which means they will change position to a different coordinate if you try to put it in the same position...

example of how it works exactly is found here:

http://world-editor-tutorials.thehelper.net/cat_usersubmit.php?view=38305
 
Level 6
Joined
May 7, 2009
Messages
228
They are unit abilities

Yes, they are all 0,0. In fact, all of the abilities are copies of each other, with only the name, icon, orderstring, and tooltip changed, since they are dummies.

As for the Attack, Move, Defend stuff, it doesn't matter since they are for buildings only.


Anyway, I think I've found a different solution, although any insight into the problem would still be appreciated.
 
Status
Not open for further replies.
Top