• Check out the results of the Techtree Contest #19!
  • Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!

[Solved] Save unit's order and later issue it

Status
Not open for further replies.
Level 4
Joined
Feb 9, 2010
Messages
48
Greetings,

I'm trying to create a trigger that would do the following:

1) Save unit's current order
2) Issue unit to activate mana shield
3) Load saved order and make the unit execute it

So for example:
Unit has an order to attack-move to some location. Trigger occurs, unit activates the mana shield and proceeds to attack-move.

The question is how to make this work. I believe there is 'order' variable, which would allow me to save the order, but I don't know how to make the unit do the saved order.
 
You use one of this depending one the Type of Order (Ground, Unit, No target, built ...)
  • Custom script:call IssueTargetOrderBJ( udg_Unit, udg_Order, udg_Target )
  • Custom script:call IssuePointOrderLocBJ( udg_Unit, udg_Order, udg_Loc )
  • Custom script:call IssueImmediateOrderBJ( udg_Unit, udg_Order )
  • Custom script:call IssueTargetDestructableOrder( udg_Unit, udg_Order, udg_Tree )
  • Custom script:call IssueTargetItemOrder( udg_Unit, udg_Order, udg_Item )
  • Custom script: call IssueTrainOrderByIdBJ( udg_Unit, udg_Order )
udg_Order is a String.
 
Greetings,

I'm trying to create a trigger that would do the following:

1) Save unit's current order
2) Issue unit to activate mana shield
3) Load saved order and make the unit execute it

So for example:
Unit has an order to attack-move to some location. Trigger occurs, unit activates the mana shield and proceeds to attack-move.

The question is how to make this work. I believe there is 'order' variable, which would allow me to save the order, but I don't know how to make the unit do the saved order.
Here is my flawless template for you. Priest would buff itself before engaging your order.
Available orders: move (point and unit), patrol (point and unit), attack (point and unit), smart (point and unit).

According to your request this template meets all your requirements. + I've made some kind of AI here: If saved current order was attack unit and target of order is dead or invisible, then the priest just move on the point of unit.
 

Attachments

Orders are integer though... Not all orders have a string equivalent, eg Want of Illusion.
Indeed, Orders are at the End ID's (Numbers), but you don't get the ID with GUI.
The functions i Posted are from the Blizzard-J API, which don't contain ID-Orders except for Building, Techs and Training.
 
Status
Not open for further replies.
Back
Top