HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

trigger based doom

05-10-2006, 06:41 AM#1
Mystic Prophet
ok, since Doom is hardcoded to not work on creeps above level 5, and it seems I can't change that through the use of the object editor or the gameplay constants; I decided to trigger the spell.

However I can't think of any way to detect a buff on a unit that's all ready dead. I tried this trigger and it didn't work.

Trigger:
Doom
Collapse Events
Unit - A unit Dies
Collapse Conditions
((Triggering unit) has buff Soul Burn) Equal to True
Collapse Actions
Set temp_point = (Position of (Triggering unit))
Unit - Create 1 Doom Guard for Player 1 (Red) at temp_point facing Default building facing (270.0) degrees
Point - Remove temp_point

If anyone knows how I can detect when A dying unit has a buff, it would be greatly apreciated.
05-10-2006, 07:37 AM#2
kaldoreielf
Trigger:
Test
Collapse Events
Unit - A unit Dies
Collapse Conditions
((Dying unit) has buff Soul Burn) Equal to True
Collapse Actions
Game - Display to (All players) the text: TEST

See if it shows TEST, if it does, run the other trigger(s)
05-10-2006, 08:12 AM#3
Mystic Prophet
ya i tried that. my trigger has a text message in the actions, but i didn't post it cause it wasn't relevant.
05-10-2006, 08:18 AM#4
kaldoreielf
So it shows TEST? If so, just run the other triggers!
05-10-2006, 08:49 AM#5
Vuen
Quote:
Originally Posted by kaldoreielf
So it shows TEST? If so, just run the other triggers!

No, he means it doesn't; he knows it doesn't work because his test message was not shown.

What you do is, whenever Doom gets cast, attach a custom value to the target unit (you'll want the owner of the caster in there) via a gamecache. Then when it dies, check this data instead of the buff. You can ignore the buff completely; it will only be for show.
05-10-2006, 09:17 AM#6
StockBreak
A dying unit cannot be detected trought a buff. You can simple avoid this problem by using variabiles:

- A unit starts the effect of Doom
- Set "VarDoomer" -> Casting Unit
- Set "VarDoomed" -> Target

...

- "VarDoomed" dies -> All the triggers you want!

U can use abilities such as "Soul Burn" or "Unholy Frenzy + Silence" to emulate Doom, just remember that they're dispellable, Doom is not!
Oh, another thing! You can use an array instead of a single variabile if the cooldown of the spell is quite short, avoiding overlapping problems.
05-10-2006, 10:27 AM#7
Mystic Prophet
thanks for both your ideas. I decided to go with custom values since using a variable array would have been tricky in this situation.

anyway I got it working now with these two triggers.

Trigger:
Collapse doom values
Collapse Events
Unit - A unit Starts the effect of an ability
Collapse Conditions
(Ability being cast) Equal to Soul Burn
Collapse Actions
Unit - Set the custom value of (Target unit of ability being cast) to (Player number of (Owner of (Triggering unit)))
Collapse Doom
Collapse Events
Unit - A unit Dies
Collapse Conditions
Collapse And - All (Conditions) are true
Collapse Conditions
(Custom value of (Dying unit)) Greater than or equal to 1
(Custom value of (Dying unit)) Less than or equal to 12
Collapse Actions
Set temp_point = (Position of (Dying unit))
Unit - Create 1 DUMMY for (Player((Custom value of (Dying unit)))) at temp_point facing Default building facing (270.0) degrees
Unit - Order (Last created unit) to Human Archmage - Summon Water Elemental
Point - Remove temp_point
Unit - Remove (Last created unit) from the game

using the same custom value as the player number I got this to run remarkably well. I think i'll disable the spawn on heroes since im only going to have it last 1 min on them.

thanks again for your help.
05-10-2006, 10:49 AM#8
poz
There is a spell called Parasite which has almost the same effect of Doom with an exception that it wont silence the target. Maybe you can try that for your case.
05-10-2006, 11:57 AM#9
Mystic Prophet
Ya I thought of parasite after I had allready solved my problem. That probably would have required a dummy unit casting silence in order to emulate the doom effect. I'll keep that in consideration if I decide I want the demons to spawn from heroes as well.
05-10-2006, 01:58 PM#10
st33m
Also if you want it to be unremoveable, I'm sure theres a way to check if the unit loses the buff and then readd it with a dummy unit.