HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Extend the life of summons

03-23-2008, 08:16 PM#1
burningice95
I am making a spell (in GUI) that extends the life of summoned units. The way I am doing this is pausing their expiration timer, starting a timer, and when that timer expires, resuming their expiration timer.

Summoned = Group of all the units who i want to pause the timers for

Trigger:
Unit Group - Pick every unit in Summoned and do (Actions)
Collapse Loop - Actions
Unit - Pause the expiration timer for (Picked unit)
Custom script: set udg_Index = GetUnitIndex(GetEnumUnit())
Countdown Timer - Start Summonedtimer[Index] as a One-shot timer that will expire in 45.00 seconds
Trigger - Add to (Circle Expire) the event (Time - Summonedtimer[Index] expires)

The GetUnitIndex() is a function from PUI, which gives every unit a unique number.

However, in the Circle Expire trigger, I have no way to tell which one of the timers expired, since it has so many events, i cannot tell which one of them fired it. Is there a way for me to do this?
03-23-2008, 08:32 PM#2
Captain Griffen
Loop through each of them and see which timer is the expired one (GetExpiredTimer()).