- Joined
- Mar 22, 2009
- Messages
- 172
I am trying to implement a mostly scripted unit training system. Since you are unable to manipulate a unit's training speed directly, I am trying to figure out how to manipulate the interface to reflect what I am doing instead.
Currently, when you start training, it spawns the corresponding unit, paused and at 10% health, which builds up too 100% over the duration. However, once it hits 100%, I need to be able to cancel the first unit in the queue, which appears impossible. The only thing I can think of is to register the queue as it is constructed, then each time it needs to change, clear the whole queue and rebuild it from the saved data.
Is there a way to directly remove a unit from the training queue?
Currently, when you start training, it spawns the corresponding unit, paused and at 10% health, which builds up too 100% over the duration. However, once it hits 100%, I need to be able to cancel the first unit in the queue, which appears impossible. The only thing I can think of is to register the queue as it is constructed, then each time it needs to change, clear the whole queue and rebuild it from the saved data.
Is there a way to directly remove a unit from the training queue?