• 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.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

detect when unit wants to drop item OR give item to unit

Status
Not open for further replies.
the problem is that i would like to detect it when unit is ordered to give item to another unit or to drop item to location

i think the only solution would be a special event,maybe if JASS has it...


here are some other events that i cant find too
i saw that there is a fast select unit event in this map
https://www.hiveworkshop.com/forums...3d-146077/?prev=of=downloads_month&order=DESC

and i also can´t find how to detect when "computer" is ordering unit to do something

like when shop is ordered to select a hero,is it impossible to detect???
 
I'm afraid you can't detect that. I tried retrieving the orders for each ocassion and I got no results.

For the shop sharing, it is automatical, so again, you can't detect that. You need to manually select a hero and then you can have it, but I guess that would make no sense.
Try this:
  • Trigger
  • Events
    • Time - Every 0.5 seconds of game-time
  • Conditions
  • Actions
    • Custom script: set bj_wantDestroyGroup = true
    • Unit Group - Pick every unit in (Units of type Shop) and do (Actions)
      • Loop - Actions
        • Custom script: if GetUnitCurrentOrder(GetEnumUnit()) == 852566 then
        • -------- Action here --------
        • Custom script: endif
Didn't test it though; and yes, periodic event would seem like the only solution to get this detected.
 
Status
Not open for further replies.
Back
Top