HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Custom Value Check after death?

04-07-2007, 09:51 PM#1
Falitian
So I'm working on a spell (In GUI, converting to Jass for MUI) and Ive run into a problem. The Spell is supposed to work with the hero's other two mine-setting spells the hero has. The Spell is to throw a bomb into an area and do damage, but can also be thrown at one of the hero's own mines and then have the same AOE damage be triggered in addition to the effects of the mine when the mine is triggered. I used Acid Bomb as a base for this as it is able to target a specific unit, and still do damage to the area. The spell that is initially cast is a dummy spell that does nothing but trigger the triggers below.

The spells that are cast:
The Big One (real) - Acid Bomb (does damage and all that such)
The Big One (ward) - Acid Bomb with no damage but has visuals
Thunder Clap (The Big One) - Thunder Clap that has the damage and effects I want the mines to have of triggering after being hit by The Big One

When the dummy spell targets an enemy:
Hidden information:
Trigger:
Enemy
Collapse Events
Unit - A unit Starts the effect of an ability
Collapse Conditions
(Ability being cast) Equal to The Big One
((Owner of (Target unit of ability being cast)) is an enemy of (Owner of (Triggering unit))) Equal to True
Collapse And - All (Conditions) are true
Collapse Conditions
(Unit-type of (Target unit of ability being cast)) Not equal to Goblin Land Mine (rank 1)
(Unit-type of (Target unit of ability being cast)) Not equal to Goblin Land Mine (rank 2)
(Unit-type of (Target unit of ability being cast)) Not equal to Goblin Land Mine (rank 3)
(Unit-type of (Target unit of ability being cast)) Not equal to Goblin Land Mine (rank 4)
(Unit-type of (Target unit of ability being cast)) Not equal to Goblin Land Mine (rank 5)
(Unit-type of (Target unit of ability being cast)) Not equal to Snare (rank 1)
(Unit-type of (Target unit of ability being cast)) Not equal to Snare (rank 2)
(Unit-type of (Target unit of ability being cast)) Not equal to Snare (rank 3)
(Unit-type of (Target unit of ability being cast)) Not equal to Snare (rank 4)
(Unit-type of (Target unit of ability being cast)) Not equal to Snare (rank 5)
Collapse Actions
Unit - Create 1 caster for (Owner of (Triggering unit)) at (Position of (Triggering unit)) facing Default building facing (270.0) degrees
Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
Unit - Add The Big One (real) to (Last created unit)
Unit - Set level of The Big One (real) for (Last created unit) to (Level of The Big One for (Triggering unit))
Unit - Order (Last created unit) to Neutral Alchemist - Acid Bomb (Target unit of ability being cast)


When the dummy spell targets a ward (the mines)
Hidden information:
Trigger:
Ward GUI
Collapse Events
Unit - A unit Starts the effect of an ability
Collapse Conditions
(Ability being cast) Equal to The Big One
Collapse Or - Any (Conditions) are true
Collapse Conditions
(Unit-type of (Target unit of ability being cast)) Equal to Goblin Land Mine (rank 1)
(Unit-type of (Target unit of ability being cast)) Equal to Goblin Land Mine (rank 2)
(Unit-type of (Target unit of ability being cast)) Equal to Goblin Land Mine (rank 3)
(Unit-type of (Target unit of ability being cast)) Equal to Goblin Land Mine (rank 4)
(Unit-type of (Target unit of ability being cast)) Equal to Goblin Land Mine (rank 5)
(Unit-type of (Target unit of ability being cast)) Equal to Snare (rank 1)
(Unit-type of (Target unit of ability being cast)) Equal to Snare (rank 2)
(Unit-type of (Target unit of ability being cast)) Equal to Snare (rank 3)
(Unit-type of (Target unit of ability being cast)) Equal to Snare (rank 4)
(Unit-type of (Target unit of ability being cast)) Equal to Snare (rank 5)
Collapse Actions
Set bigonecasterloc = (Position of (Triggering unit))
Set bigonemineloc = (Position of (Target unit of ability being cast))
Set bigoneminetarget = (Target unit of ability being cast)
Set bigonelvl = (Level of (Ability being cast) for (Triggering unit))
Unit - Create 1 caster for (Owner of (Triggering unit)) at bigonecasterloc facing Default building facing (270.0) degrees
Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
Unit - Add The Big One (ward) to (Last created unit)
Unit - Set level of The Big One (ward) for (Last created unit) to bigonelvl
Unit - Order (Last created unit) to Neutral Alchemist - Acid Bomb bigoneminetarget
Unit - Set the custom value of bigoneminetarget to (Level of (Ability being cast) for (Triggering unit))


When the dummy spell targets an ally
Hidden information:
Trigger:
Allies
Collapse Events
Unit - A unit Begins casting an ability
Collapse Conditions
(Ability being cast) Equal to The Big One
((Owner of (Target unit of ability being cast)) is an enemy of (Owner of (Triggering unit))) Equal to False
(Unit-type of (Target unit of ability being cast)) Not equal to Goblin Land Mine (rank 1)
(Unit-type of (Target unit of ability being cast)) Not equal to Goblin Land Mine (rank 2)
(Unit-type of (Target unit of ability being cast)) Not equal to Goblin Land Mine (rank 3)
(Unit-type of (Target unit of ability being cast)) Not equal to Goblin Land Mine (rank 4)
(Unit-type of (Target unit of ability being cast)) Not equal to Goblin Land Mine (rank 5)
(Unit-type of (Target unit of ability being cast)) Not equal to Snare (rank 1)
(Unit-type of (Target unit of ability being cast)) Not equal to Snare (rank 2)
(Unit-type of (Target unit of ability being cast)) Not equal to Snare (rank 3)
(Unit-type of (Target unit of ability being cast)) Not equal to Snare (rank 4)
(Unit-type of (Target unit of ability being cast)) Not equal to Snare (rank 5)
Collapse Actions
Unit - Order (Triggering unit) to Stop


The effects that occur when the mine is triggered
Hidden information:
Trigger:
Boom
Collapse Events
Unit - A unit Dies
Collapse Conditions
Collapse Or - Any (Conditions) are true
Collapse Conditions
(Unit-type of (Dying unit)) Equal to Goblin Land Mine (rank 1)
(Unit-type of (Dying unit)) Equal to Goblin Land Mine (rank 2)
(Unit-type of (Dying unit)) Equal to Goblin Land Mine (rank 3)
(Unit-type of (Dying unit)) Equal to Goblin Land Mine (rank 4)
(Unit-type of (Dying unit)) Equal to Goblin Land Mine (rank 5)
(Unit-type of (Dying unit)) Equal to Snare (rank 1)
(Unit-type of (Dying unit)) Equal to Snare (rank 2)
(Unit-type of (Dying unit)) Equal to Snare (rank 3)
(Unit-type of (Dying unit)) Equal to Snare (rank 4)
(Unit-type of (Dying unit)) Equal to Snare (rank 5)
Collapse Actions
Game - Display to (All players) for 30.00 seconds the text: This is a working m...
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
(Custom value of (Triggering unit)) Equal to 1
Collapse Then - Actions
Unit - Create 1 caster for (Owner of (Triggering unit)) at (Position of (Triggering unit)) facing (Position of (Triggering unit))
Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
Unit - Add Thunder Clap Big Boom to (Last created unit)
Unit - Set level of Thunder Clap Big Boom for (Last created unit) to 1
Unit - Order (Last created unit) to Human Mountain King - Thunder Clap
Game - Display to (All players) for 30.00 seconds the text: This is a working m...
Else - Actions
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
(Custom value of (Triggering unit)) Equal to 2
Collapse Then - Actions
Unit - Create 1 caster for (Owner of (Triggering unit)) at (Position of (Triggering unit)) facing (Position of (Triggering unit))
Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
Unit - Add Thunder Clap Big Boom to (Last created unit)
Unit - Set level of Thunder Clap Big Boom for (Last created unit) to 2
Unit - Order (Last created unit) to Human Mountain King - Thunder Clap
Game - Display to (All players) for 30.00 seconds the text: This is a working m...
Else - Actions
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
(Custom value of (Triggering unit)) Equal to 3
Collapse Then - Actions
Unit - Create 1 caster for (Owner of (Triggering unit)) at (Position of (Triggering unit)) facing (Position of (Triggering unit))
Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
Unit - Add Thunder Clap Big Boom to (Last created unit)
Unit - Set level of Thunder Clap Big Boom for (Last created unit) to 3
Unit - Order (Last created unit) to Human Mountain King - Thunder Clap
Game - Display to (All players) for 30.00 seconds the text: This is a working m...
Else - Actions
Collapse If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Collapse If - Conditions
(Custom value of (Triggering unit)) Equal to 4
Collapse Then - Actions
Unit - Create 1 caster for (Owner of (Triggering unit)) at (Position of (Triggering unit)) facing (Position of (Triggering unit))
Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
Unit - Add Thunder Clap Big Boom to (Last created unit)
Unit - Set level of Thunder Clap Big Boom for (Last created unit) to 4
Unit - Order (Last created unit) to Human Mountain King - Thunder Clap
Game - Display to (All players) for 30.00 seconds the text: This is a working m...
Else - Actions



The Problems I'm running into is that when the mines are triggered I don;t get any response. The trigger never runs. Another minor issue is that no matter how I configure the spells, the targets always end up with the default Acid Bomb buff when it is cast on them, even though I have created custom buffs and set them to be added in the spell. And finally, this could be just a settings issue, but for some reason, when the dummy caster casts the The big One spell on enemy targets, the targeted unit takes no damage, but the ones around him do, and yes, I have set both the primary and secondary damage fields. What confuses me about this, is that when I have it directly cast by the hero itself, the spell does full damage to the target and enemies nearby.
04-09-2007, 10:31 PM#2
Moss
So you never see the message "This is a working m..."?

Where do the Goblin Landmines/Snares get their custom value set?

What do you mean by:
Quote:
when I have it directly cast by the hero itself, the spell does full damage

Perhaps the reason why you haven't gotten any responses to this post is because it is confusing to understand the whole thing.
04-10-2007, 01:43 AM#3
Falitian
ohh, sorry I should have edited. I finally remedied the problem by using values 100+ instead of 1-10, because I think the default custom value was interacting with my system