• 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.

Little Problem

Status
Not open for further replies.
Level 12
Joined
Aug 22, 2008
Messages
911
Greetings Empire,

A problem, I have, and as minor as it is it's very annoying.

I'd like the Editor to pick each ghoul in the region BlightedAlley and do the following:

Unit Group - Pick every unit in (Units in BlightedAlley <gen> matching ((Unit-type of (Picked unit)) Equal to Ghoul)) and do (Actions)
Loop - Actions
Unit - Set life of (Matching unit) to 75.00%
Unit - Order (Matching unit) to Undead Ghoul - Cannibalize

Why doesn't this work?
Thank you, Empire, and good day.
 
Level 5
Joined
Nov 14, 2007
Messages
161
your both right, he flipped flopped them both. matching unit comes after the "matching ((Unit-type of (MATCHING unit)) Equal to...."
and picked is the unit getting selected. essentially your backwards:

Unit Group - Pick every unit in (Units in BlightedAlley <gen> matching ((Unit-type of (Matching unit)) Equal to Ghoul)) and do (Actions)
Loop - Actions
Unit - Set life of (Picked unit) to 75.00%
Unit - Order (Picked unit) to Undead Ghoul - Cannibalize
 
Status
Not open for further replies.
Top