# Help with two trigger spells

Status
Not open for further replies.

#### Azure Wrath

Level 2
Howzit. I need some help with two of my trigger spells. If you were by any chance browsing in the spell download sections, you may have seen my spells there, but it was requested that i rather ask for help in the forums.

So anyway, i need help with some triggers in my spells.

The first spell's problem is like this:
The spell has to create a square wall around the area of the casting unit. I'm using this:

Set TGBorderPoints[1] = ((Position of (Casting unit)) offset by (-1000.00, 1000.00))
Set TGBorderPoints[2] = ((Position of (Casting unit)) offset by (1000.00, 1000.00))
Set TGBorderPoints[3] = ((Position of (Casting unit)) offset by (1000.00, -1000.00))
Set TGBorderPoints[4] = ((Position of (Casting unit)) offset by (-1000.00, -1000.00))
For each (Integer A) from 1 to 7, do (Destructible - Create a Stone Wall (Horizontal) at (TGBorderPoints[1] offset by (((Distance between TGBorderPoints[1] and TGBorderPoints[2]) / 7.00) x (Real((Integer A)))) towards (Angle from TGBorderPoints[1] to TGBorderPoints[2]) degrees) facing 270.00 wit
For each (Integer A) from 1 to 7, do (Destructible - Create a Stone Wall (Horizontal) at (TGBorderPoints[3] offset by (((Distance between TGBorderPoints[3] and TGBorderPoints[4]) / 7.00) x (Real((Integer A)))) towards (Angle from TGBorderPoints[3] to TGBorderPoints[4]) degrees) facing 270.00 wit
For each (Integer A) from 1 to 7, do (Destructible - Create a Stone Wall (Vertical) at (TGBorderPoints[2] offset by (((Distance between TGBorderPoints[2] and TGBorderPoints[3]) / 7.00) x (Real((Integer A)))) towards (Angle from TGBorderPoints[2] to TGBorderPoints[3]) degrees) facing 0.00 with sc
For each (Integer A) from 1 to 7, do (Destructible - Create a Stone Wall (Vertical) at (TGBorderPoints[1] offset by (((Distance between TGBorderPoints[1] and TGBorderPoints[4]) / 7.00) x (Real((Integer A)))) towards (Angle from TGBorderPoints[1] to TGBorderPoints[4]) degrees) facing 270.00 with

Now, the problem is that this wall doesn't wanna line up properly. Any ideas? What have i done wrong?

The Second spell's problem is this:
This is a corpse explosion spell that deals damage based on the level of the spell and the corpses maximum health. (note that the spell has 6 levels.) Now, this is what i'm using:

Unit Group - Pick every unit in (Units within 600.00 of GCEPoint matching (((Matching unit) belongs to an enemy of Player 1 (Red)) Equal to True)) and do (Actions)
Loop - Actions
Unit - Set life of (Picked unit) to ((Life of (Picked unit)) - ((Max life of GCETarget) / (100.00 / (90.00 / (7.00 - (Real((Level of Grand Corpse Explosion Old for GCECaster))))))))

I'm using this next one as the secondary damage:

Unit - Set life of (Picked unit) to ((Life of (Picked unit)) - ((Max life of GCETarget) / (100.00 / (60.00 / (7.00 - (Real((Level of Grand Corpse Explosion Old for GCECaster))))))))

#### Sunny_D

Level 6
Azure Wrath said:
Unit Group - Pick every unit in (Units within 600.00 of GCEPoint matching (((Matching unit) belongs to an enemy of Player 1 (Red)) Equal to True)) and do ...

hm... the only thing i can see for now is, that you have to use (picked unit) instead of (matching unit) here. cz i think you want to know if the units in range of the corpse are an enemy of player one, or did i get something wrong??

anyway, this should fix the second trigger if it didnt work yet.

Status
Not open for further replies.

Replies
4
Views
568
Replies
9
Views
671
Replies
13
Views
1K
Replies
6
Views
743
Replies
3
Views
634