HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Trigger/Spell Help Please

03-05-2007, 01:06 AM#1
Dil999
In my free time I make spells, but I've been working on this one for awhile and I cant seem to get it to work.

The CastingUnit variable is just.. the casting unit. I made it to make sure there would be no mistakes for what triggering unit was.
The UnitsInArea variable is an integer i used to find out how many dummies i should create
The Dummies variable is my dummies
The DrainedUnits variable is my units being affected by the drain from the dummy

Basically, this spell does this:
Creates a dummy for every unit in 300 range of casted ability
Causes each dummy to lifedrain (just for the appearance) a random unit within 300 of it
Waits 2 seconds
Deals damage to the lifedrained unit equal to its distance away from the dummy
(All dummies are located in the center of the casted ability)]


Edit: Ignore the disabled trigger below the Arcane Leash trigger, It doesnt do anything
The Dummy ability for the hero is Blizzard, with 0 shards and 1 wave, 0 duration and damage.. etc
The dummy ability for the dummy is life drain
Attached Images
File type: jpgScreenshottrig.jpg (219.9 KB)
03-05-2007, 01:42 AM#2
wantok
My guess is that its not registering that the units have the buff when you try to add the units to the group. Try putting a short wait after you cast the drain life and see if it works then.

Also if you right click on the trigger name in the trigger functions window and select save as text, you can paste it here between trigger tags to look like this:
Trigger:
Untitled Trigger 002
Events
Conditions
Actions
03-05-2007, 04:36 PM#3
WNxCryptic
Blizzard does not have any trackable buffs, so that unit group will always be empty...You'll need to base it off a different AOE spell, I believe flame strike's buff is trackable though, so you might use it as your base ability.
03-05-2007, 05:56 PM#4
grim001
what? blizzard puts a buff on enemies, I've based spells off it before
03-05-2007, 06:20 PM#5
wantok
He's not checking for the blizzard buff anyways. He's checking for drain life. The problem is that when he tries to add the units to the group they haven't had a chance to get the buff yet.
03-05-2007, 07:14 PM#6
WNxCryptic
lol..I get what you're talking about now..sorry, got misguided...

Grim: Blizzard has a buff, but its not trackable with triggers.

Just add the wait in as Wantok suggested, my presumption is the same as his: that the trigger is firing off before the buff can be registered.
03-05-2007, 07:57 PM#7
Dil999
Thanks, thing is, the dummies dont even spawn in the first place.
I added a food limit on the dummies so I can see if they spawn, and nothing changes when I cast the spell. Im 100% sure that the events and conditions are set for the right spell.. any ideas?
Edit: Nevermind, i found the problem with no units spawning. Blizzard has to have atleast one shard and one wave or else the trigger editor doesnt count it as being cast.

The dummies (when spawned) dont cast. Any ideas?
03-06-2007, 12:36 AM#8
wantok
I would say that there are two possible reasons why the dummy units don't cast.

1. You don't have them casting the right ability or haven't given them the right ability.

2. The dummy units are not being added to the group because the game hasn't registered that the dummy units were created yet when you try to create the group.

The first option seems more likely to me. You could try adding another wait in between the creation of the dummy units action and the adding them to the group action to check the second.
03-06-2007, 12:44 AM#9
Dil999
The dummies have he ability, and I checked this by running a simper trigger with it.

Anyways I redid the ability so it only targets one select unit, and it works fine.

Trigger:
Arcane Leash
Collapse Events
Unit - A unit Begins casting an ability
Collapse Conditions
(Ability being cast) Equal to Arcane Leash
Collapse Actions
Set CastingUnit_ArcaneLeash = (Triggering unit)
Set CastedUnit_ArcaneLeash = (Target unit of ability being cast)
Wait 3.00 seconds
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
(Level of Arcane Leash for CastingUnit_ArcaneLeash) Equal to 1
Collapse Then - Actions
Unit - Cause CastingUnit_ArcaneLeash to damage CastedUnit_ArcaneLeash, dealing ((Distance between (Position of CastedUnit_ArcaneLeash) and (Position of CastingUnit_ArcaneLeash)) / 4.00) damage of attack type Spells and damage type Normal
Collapse Else - Actions
Do nothing
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
(Level of Arcane Leash for CastingUnit_ArcaneLeash) Equal to 2
Collapse Then - Actions
Unit - Cause CastingUnit_ArcaneLeash to damage CastedUnit_ArcaneLeash, dealing ((Distance between (Position of CastedUnit_ArcaneLeash) and (Position of CastingUnit_ArcaneLeash)) / 3.00) damage of attack type Spells and damage type Normal
Collapse Else - Actions
Do nothing
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
(Level of Arcane Leash for CastingUnit_ArcaneLeash) Equal to 3
Collapse Then - Actions
Unit - Cause CastingUnit_ArcaneLeash to damage CastedUnit_ArcaneLeash, dealing ((Distance between (Position of CastedUnit_ArcaneLeash) and (Position of CastingUnit_ArcaneLeash)) / 2.00) damage of attack type Spells and damage type Normal
Collapse Else - Actions
Do nothing
03-06-2007, 12:59 AM#10
grim001
Quote:
Originally Posted by WNxCryptic
Grim: Blizzard has a buff, but its not trackable with triggers.

What does "not trackable with triggers" mean? Because I've done spells where an effect happens when it detects the Blizzard buff on the unit