HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

constructing unit?

11-17-2010, 10:14 PM#1
Aco
hey,
how can i referr to the unit which is building the "constructing structure" in the trigger editor?
11-18-2010, 04:50 PM#2
xZetH
Constructing structure. Responding to "A unit begins construction" unit event. Refers to the unit whose construction has begun.

Constructed structure. Responding to "A unit finishes construction" unit event. Refers to the unit whose construction has finished.
11-21-2010, 01:26 PM#3
[VDM]Amn
i got it
get the human worker abilities on your unit
it fires the event 'unit starts the effect of an ability' when is ordered to build

target unit of ability being cast is your building
triggering unit is your guy
11-21-2010, 01:35 PM#4
[VDM]Amn
or else ...
there's a function to convert unit types to orders
so you can match who has this current order when the event 'begins construction' is fired

Set a = (String((Order((Unit-type of (Constructing structure)))))) //if you build an Arcane Vault this gets 'arcanevault' just like the order the worker gets
Set your_guy = random 1 unit from units within 500 of triggering unit matching order of matching unit equal to a

good luck
11-22-2010, 09:58 AM#5
DioD
this wont work you know, repair wont trigger event.
11-24-2010, 06:54 AM#6
[VDM]Amn
really, the human worker does fire the event starts the effect of an ability with Repair ability
he's special (?)