# [Trigger]Help with a "water wall" spell

Status
Not open for further replies.

#### Marsunpaisti

Level 3
So, I would like to create a "water wall" type spell, which makes the hero shoot a "wall of water" from behind him to in front of him. I have created a dummy unit with a shockwave based skill where its projeticle has been changed to waterfall but I have no idea how to calculate the positions for the dummies so that they are in a line behind the hero.

#### Starquizer

Level 16
So, I would like to create a "water wall" type spell, which makes the hero shoot a "wall of water" from behind him to in front of him. I have created a dummy unit with a shockwave based skill where its projeticle has been changed to waterfall but I have no idea how to calculate the positions for the dummies so that they are in a line behind the hero.

Get the facing of your hero which will be a real value the represent angle then add 180 degree and when creating the dummy unit, create it at the caster position offset by r and the new angle which will be the hero facing angle + 180 then let that dummy unit cast the spell towards the hero facing angle.

#### Smiddle

Level 8
• I can't find my trousers. Please help.
• Events
• Unit - A unit starts the effect of an ability
• Conditions
• (Ability being cast) Equal to Water Wall
• Actions
• Set Point[1] = (Position of (Triggering unit))
• Set Point[2] = ((Position of (Triggering unit)) offset by X towards ((Facing of (Triggering unit)) + 180) degrees
• Unit - Create 1 Dummy for (Owner of (Triggering unit)) at Point[2]
• Unit - Add Water Wall Ability to (Last created unit)
• Unit - Add a 0.01 expiration timer to (Last created unit)
• Unit - Order (Last created unit) to Tauren Chieftain - Shockwave Point[1]
• Custom script: call RemoveLocation(udg_Point[1])
• Custom script: call RemoveLocation(udg_Point[2])
Variables:
Point - Point (duh)
X - A real, which is how long away from the caster the dummy should be created.
Water Wall - The hero ability.
Water Wall Ability - Dummy ability, based on Shockwave.

#### Starquizer

Level 16
I don't know why it doesn't work but it seems logical to me that what I have said is right. Well try making the variable of the point not of array type; I know it wouldn't make difference but just try.

#### Starquizer

Level 16
ok here you are but its vauge and I used the same spell for the caster and the dummy also the caster is the dummy which will result in chain cast, you take the idea and change the spell as you see fit. here is the triggers.

• Untitled Trigger 001
• Events
• Unit - A unit Starts the effect of an ability
• Conditions
• Actions
• Set castpoint = (Target point of ability being cast)
• Set dummypoint = ((Position of (Triggering unit)) offset by 256.00 towards ((Angle from (Position of (Triggering unit)) to castpoint) + 180.00) degrees)
• Unit - Create 1 Tauren Chieftain for Player 1 (Red) at dummypoint facing Default building facing degrees
• Hero - Learn skill for (Last created unit): Orc Tauren Chieftain - Shockwave
• Unit - Order (Last created unit) to Orc Tauren Chieftain - Shockwave castpoint
• Trigger - Turn off (This trigger)
• -------- remove Turn off, I just added it so the trigger stops creating anymore unit --------
Also note that there are two versions of shock wave when matching the conditions.

Last edited:

#### Marsunpaisti

Level 3
Yes but that trigger just creates one unit behind the hero, when i need many units in a straight line behind the hero.

#### Starquizer

Level 16
Yes but that trigger just creates one unit behind the hero, when i need many units in a straight line behind the hero.

What do you mean by: 'i need many units in a straight line behind the hero' ?

#### Super-Sheep

Level 20
He needs a WALL. You know Diablo 2, fire wall? So, he needs that one unit and then many units in front of it. So it makes a WALL.

#### Starquizer

Level 16
He needs a WALL. You know Diablo 2, fire wall? So, he needs that one unit and then many units in front of it. So it makes a WALL.

OK that explains much, if that what he really needs. I thought he want the wall come from the caster bach toward forward and damaging any enemy it encounter, like Beast Master - stampede ability.

#### Marsunpaisti

Level 3
OK that explains much, if that what he really needs. I thought he want the wall come from the caster bach toward forward and damaging any enemy it encounter, like Beast Master - stampede ability.

Yes, kind of like that but only one big wave of the shockwaves coming and all of them come at the same time.

#### Starquizer

Level 16
Yes, kind of like that but only one big wave of the shockwaves coming and all of them come at the same time.

Have you tried changing the field of the Shockwave ability for the dummy unit, make a bigger area of effect so that it matches the size of the missile.

#### Just_Spectating

Level 38
It wouldn't look like a wall Starquizer.

He just wants the Positions of the Dummy units.

Smiddle has the right idea.

#### Marsunpaisti

Level 3
In my opinion, it would look really ugly.

By the way, would it be possible to do it so. That first i would create an unit behind the hero, then make it face the hero and then create units with polar offset in a line based on the unit?

#### Just_Spectating

Level 38
thats the gist of it.

You set the offset by about like 250? behind the unit (so like, Facing degrees of triggering unit + 180) or something, (facing triggering unit degrees), then after that action, (Facing of Last Created unit + 90) with offsets of like 250, 500, 750, Then you go the other way (Facing of Last Created unit -90) and add your integers by 750 so that it can reset to the middle and go left, (1000, 1250, 1500)

#### Smiddle

Level 8
thats the gist of it.

You set the offset by about like 250? behind the unit (so like, Facing degrees of triggering unit + 180) or something, (facing triggering unit degrees), then after that action, (Facing of Last Created unit + 90) with offsets of like 250, 500, 750, Then you go the other way (Facing of Last Created unit -90) and add your integers by 750 so that it can reset to the middle and go left, (1000, 1250, 1500)

Yes, that's it.

It will be easier to make it if you want an odd number of dummies.

Continuation of my previous trigger:

• I can't find my trousers. Please help.
• Events
• Unit - A unit starts the effect of an ability
• Conditions
• (Ability being cast) Equal to Water Wall
• Actions
• Set Point[1] = (Position of (Triggering unit))
• Set Point[2] = ((Position of (Triggering unit)) offset by X towards ((Facing of (Triggering unit)) + 180) degrees
• Unit - Create 1 Dummy for (Owner of (Triggering unit)) at Point[2]
• Unit - Add Water Wall Ability to (Last created unit)
• Unit - Add a 0.01 expiration timer to (Last created unit)
• Unit Group - Add (Last created unit) to Dummy_Unit_Group
• For every (Integer A) from 1 to Y, do (Actions)
• Set Point[3] = Point[3] offset by Z towards ((Facing of (Triggering unit)) + 90) degrees
• Unit - Create 1 Dummy for (Owner of (Triggering unit)) at Point[2]
• Unit - Add Water Wall Ability to (Last created unit)
• Unit - Add a 0.01 expiration timer to (Last created unit)
• Unit Group - Add (Last created unit) to Dummy_Unit_Group
• call RemoveLocation(udg_Point[3]
• For every (Integer A) from 1 to Y, do (Actions)
• Set Point[3] = Point[3] offset by Z towards ((Facing of (Triggering unit)) - 90) degrees
• Unit - Create 1 Dummy for (Owner of (Triggering unit)) at Point[2]
• Unit - Add Water Wall Ability to (Last created unit)
• Unit - Add a 0.01 expiration timer to (Last created unit)
• Unit Group - Add (Last created unit) to Dummy_Unit_Group
• call RemoveLocation(udg_Point[3]
• Unit Group - Pick every unit in Dummy_Unit_Group and do (Actions)
• Unit - Order (Picked unit) to Tauren Chieftain - Shockwave Point[1]
• Custom script: call RemoveLocation(udg_Point[1])
• Custom script: call RemoveLocation(udg_Point[2])
• Unit Group - Destroy Dummy_Unit_Group
Variables:
Point - Point (duh)
X - A real, which is how long away from the caster the dummy should be created.
Y - Equal to HALF of total number of dummies - 1. For example, if you want a total of 5 dummies, Y should be 2. If you want a total of 9 dummies, Y should be 4.
Z - Space between every Dummy.
Water Wall - The hero ability.
Water Wall Ability - Dummy ability, based on Shockwave.
Dummy_Unit_Group - A unit group to which the Dummies are added.

#### Marsunpaisti

Level 3
Ok solved, but now I got another problem. How can I make the waterfall effect show up when the dummy casts. Now when the dummy casts the skill only a ripple will show on the ground (when shockwave casts it creates a small ripple).

#### Starquizer

Level 16
Ok solved, but now I got another problem. How can I make the waterfall effect show up when the dummy casts. Now when the dummy casts the skill only a ripple will show on the ground (when shockwave casts it creates a small ripple).

I think its unsolvable because Shockwave always creates a ripple in the ground even if you set the effects to null.

#### Smiddle

Level 8
I think its unsolvable because Shockwave always creates a ripple in the ground even if you set the effects to null.

I don't think he said anything about removing the ripple (which you can use Carrion Swarm for btw), he just said that no effect showed up.

Which one were you trying to use? Crushing Wave missile?

#### Marsunpaisti

Level 3
I tried to use the doodad waterfall

#### Marsunpaisti

Level 3
By the way, the spell you made, made the water effects all move into same point, when i would like them to go forward from behind the hero like a wall.

#### Smiddle

Level 8
By the way, the spell you made, made the water effects all move into same point, when i would like them to go forward from behind the hero like a wall.

Oh, I know what's wrong. Wait a minute and I'll fix it.

Edit:
• I can't find my trousers. Please help.
• Events
• Unit - A unit starts the effect of an ability
• Conditions
• (Ability being cast) Equal to Water Wall
• Actions
• Set Point[1] = (Position of (Triggering unit))
• Set Point[2] = ((Position of (Triggering unit)) offset by X towards ((Facing of (Triggering unit)) + 180) degrees
• Unit - Create 1 Dummy for (Owner of (Triggering unit)) at Point[2]
• Unit - Add Water Wall Ability to (Last created unit)
• Unit - Add a 0.01 expiration timer to (Last created unit)
• Unit Group - Add (Last created unit) to Dummy_Unit_Group
• For every (Integer A) from 1 to Y, do (Actions)
• Set Point[3] = Point[3] offset by Z towards ((Facing of (Triggering unit)) + 90) degrees
• Unit - Create 1 Dummy for (Owner of (Triggering unit)) at Point[2]
• Unit - Add Water Wall Ability to (Last created unit)
• Unit - Add a 0.01 expiration timer to (Last created unit)
• Unit Group - Add (Last created unit) to Dummy_Unit_Group
• call RemoveLocation(udg_Point[3]
• For every (Integer A) from 1 to Y, do (Actions)
• Set Point[3] = Point[3] offset by Z towards ((Facing of (Triggering unit)) - 90) degrees
• Unit - Create 1 Dummy for (Owner of (Triggering unit)) at Point[2]
• Unit - Add Water Wall Ability to (Last created unit)
• Unit - Add a 0.01 expiration timer to (Last created unit)
• Unit Group - Add (Last created unit) to Dummy_Unit_Group
• call RemoveLocation(udg_Point[3]
• Unit Group - Pick every unit in Dummy_Unit_Group and do (Actions)
• Set Point[4] = (Position of (Picked unit)) offset by 180 towards (Facing of (Triggering unit)) degrees
• Unit - Order (Picked unit) to Tauren Chieftain - Shockwave Point[1]
• Custom script: call RemoveLocation(udg_Point[4])
• Custom script: call RemoveLocation(udg_Point[1])
• Custom script: call RemoveLocation(udg_Point[2])
• Unit Group - Destroy Dummy_Unit_Group
Variables:
Point - Point (duh)
X - A real, which is how long away from the caster the dummy should be created.
Y - Equal to HALF of total number of dummies - 1. For example, if you want a total of 5 dummies, Y should be 2. If you want a total of 9 dummies, Y should be 4.
Z - Space between every Dummy.
Water Wall - The hero ability.
Water Wall Ability - Dummy ability, based on Shockwave.
Dummy_Unit_Group - A unit group to which the Dummies are added.

Status
Not open for further replies.

### Similar threads

Replies
13
Views
744
Replies
13
Views
974
Replies
1
Views
633
[Trigger] wall of knockback
Replies
6
Views
614
Replies
4
Views
845