• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

Issue Order Not listed in the Preset Orders?

Status
Not open for further replies.
Level 11
Joined
Nov 15, 2007
Messages
781
If it's an integer it's ById. The regular IssueOrder deals with strings like 'move', 'stop', 'attack', 'acidbomb', etc. - and as far as I'm aware most uncommon orders don't have a "GUI-friendly" name like that (hence you need to order by ID).
 
Level 12
Joined
May 20, 2009
Messages
822
IssueImmediateOrderById, not IssueTargetOrderById. Target orders, as one might expect, require a target.

This is why I can't be a programmer.

EDIT: Okay so. There is one last thing I need to make this system actually be good, now.

How to make it MUI Compatible...

  • Human Build Icons
    • Events
      • Unit - A unit Is issued an order with no target
    • Conditions
      • Or - Any (Conditions) are true
        • Conditions
          • (Unit-type of (Triggering unit)) Equal to Peasant
    • Actions
      • -------- IF WORKER PRESSED "BUILD" OR "ADVANCED BUILD" --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Or - Any (Conditions) are true
            • Conditions
              • (Issued order) Equal to (Order(manashieldon))
              • (Issued order) Equal to (Order(manashieldoff))
        • Then - Actions
          • -------- Advanced Construction --------
          • Player - Make Town Hall Unavailable for training/construction by (Owner of (Ordered unit))
          • Player - Make Farm Unavailable for training/construction by (Owner of (Ordered unit))
          • Player - Make Barracks Unavailable for training/construction by (Owner of (Ordered unit))
          • Player - Make Altar of Kings Unavailable for training/construction by (Owner of (Ordered unit))
          • Player - Make Lumber Mill Unavailable for training/construction by (Owner of (Ordered unit))
          • Player - Make Blacksmith Unavailable for training/construction by (Owner of (Ordered unit))
          • Player - Make Scout Tower Unavailable for training/construction by (Owner of (Ordered unit))
          • Player - Make Arcane Vault Unavailable for training/construction by (Owner of (Ordered unit))
          • Player - Make Workshop Available for training/construction by (Owner of (Ordered unit))
          • Player - Make Arcane Sanctum Available for training/construction by (Owner of (Ordered unit))
          • Player - Make Gryphon Aviary Available for training/construction by (Owner of (Ordered unit))
          • -------- FORCE "BUILD" KEY --------
          • Custom script: call IssueImmediateOrderById(GetTriggerUnit(), 851994)
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Issued order) Equal to (Order(windwalk))
            • Then - Actions
              • -------- Basic Construction --------
              • Player - Make Workshop Unavailable for training/construction by (Owner of (Ordered unit))
              • Player - Make Arcane Sanctum Unavailable for training/construction by (Owner of (Ordered unit))
              • Player - Make Gryphon Aviary Unavailable for training/construction by (Owner of (Ordered unit))
              • Player - Make Town Hall Available for training/construction by (Owner of (Ordered unit))
              • Player - Make Farm Available for training/construction by (Owner of (Ordered unit))
              • Player - Make Altar of Kings Available for training/construction by (Owner of (Ordered unit))
              • Player - Make Barracks Available for training/construction by (Owner of (Ordered unit))
              • Player - Make Lumber Mill Available for training/construction by (Owner of (Ordered unit))
              • Player - Make Blacksmith Available for training/construction by (Owner of (Ordered unit))
              • Player - Make Scout Tower Available for training/construction by (Owner of (Ordered unit))
              • Player - Make Arcane Vault Available for training/construction by (Owner of (Ordered unit))
              • -------- FORCE "BUILD" KEY --------
              • Custom script: call IssueImmediateOrderById(GetTriggerUnit(), 851994)
            • Else - Actions
In case anyone can help me.

Reason why it's MUI incompatible should be obvious. The tech being disabled will stop other units that already have the order.

Is there another way, probably via JASS, to not show the buttons and not allow them to be clicked?
 
Last edited:
Level 12
Joined
May 20, 2009
Messages
822
Use Chaos to transform the unit into an identical unit with a different build menu.

That'd be pure..."Chaos." Hyuk hyuk hyuk

It's gotta be the same unit, honestly.

Basically...The only way I can see this working is firstly removing the original order to build the structure, then issue the same order using the JASS function, which I think ignores the trigger to set the structure to unavailable...Right? I don't actually know. xD

I had another idea that once the build menu is exited (Figuring it someway to pick up on that, like the build order is issued would definitely do that. Or maybe a different unit is selected would be easier) then re-enable all the buildings. But that wouldn't work if someone is still in a build menu while the order from the opposite build menu is still being issued...

I posted a request in the JASS section, maybe someone there can help me figure it out. xD
 
Level 12
Joined
May 20, 2009
Messages
822
Why would transforming the unit not work?

Because now we've got two separate units. If you have multiple workers selected, that one worker will be singled out. I'd have to do the same thing - checking if the unit has exited the build menu by seeing when the unit is issued an order - to swap it back, but then the order would be lost.

It provides an array of new issues that I have to figure out how to work around which just doesn't appeal to me since I am extremely close to fixing it in the first place.
 
Status
Not open for further replies.
Top