worldofDeath
New Member
- Reaction score
- 47
Hellow all at the moment im working on a spell. And im haveing trouble making it go around the caster Kinda like you stand in the middel and in front on the sides it makes a big wall out of the ground going up. What i need it to do is if a unit trys going up this hill they will slide down and take damage. This is want i have so far but it doesnt work around the caster just to one side. And the hill only goes to one side of the hero. HELP!
And where they come down.
This abi is based off of warstomp. There is no point where the spell is casted.
Code:
Mountain of Destruction
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to MOD
Actions
Set MOD_Caster = (Triggering unit)
Set MOD_Loc[1] = (Position of MOD_Caster)
Set MOD_Loc[2] = ((Position of (Triggering unit)) offset by (100.00, 360.00))
Set MOD_Loc[3] = ((Position of (Triggering unit)) offset by (100.00, 260.00))
Set MOD_Loc[4] = ((Position of (Triggering unit)) offset by (100.00, 160.00))
Set MOD_Loc[5] = ((Position of (Triggering unit)) offset by (100.00, 90.00))
For each (Integer A) from 1 to 5, do (Actions)
Loop - Actions
Set MOD_Loc[((Integer A) + 5)] = (MOD_Loc[1] offset by ((Real((Integer A))) x 350.00) towards (Angle from MOD_Loc[2] to MOD_Loc[3]) degrees)
Set MOD_Loc[((Integer A) + 5)] = (MOD_Loc[1] offset by ((Real((Integer A))) x 350.00) towards (Angle from MOD_Loc[3] to MOD_Loc[4]) degrees)
Custom script: set bj_wantDestroyGroup = true
Unit Group - Pick every unit in (Units within 349.00 of MOD_Loc[2] matching ((((Matching unit) is A structure) Not equal to True) and ((((Matching unit) is A ground unit) Equal to True) and ((((Matching unit) is alive) Equal to True) and (((Matching unit) belongs to an enemy of (Owner of MO and do (Actions)
Loop - Actions
Unit - Cause MOD_Caster to damage (Picked unit), dealing 175.00 damage of attack type Spells and damage type Normal
Environment - Create a 5.00 second Temporary crater deformation at MOD_Loc[2] with radius 230.00 and depth -90.00
Environment - Create a 5.00 second Temporary crater deformation at MOD_Loc[3] with radius 230.00 and depth -90.00
Environment - Create a 5.00 second Temporary crater deformation at MOD_Loc[4] with radius 230.00 and depth -90.00
Environment - Create a 5.00 second Temporary crater deformation at MOD_Loc[5] with radius 230.00 and depth -90.00
Wait 0.45 seconds
Countdown Timer - Start MOD_Timer as a Repeating timer that will expire in 0.03 seconds
Wait 2.00 seconds
Countdown Timer - Pause MOD_Timer
Custom script: call RemoveLocation(udg_MOD_Loc[1])
Custom script: call RemoveLocation(udg_MOD_Loc[2])
Custom script: call RemoveLocation(udg_MOD_Loc[3])
Custom script: call RemoveLocation(udg_MOD_Loc[4])
Custom script: call RemoveLocation(udg_MOD_Loc[5])
For each (Integer A) from 1 to 5, do (Custom script: call RemoveLocation(udg_MOD_Loc[GetForLoopIndexA() + 2]))
And where they come down.
Code:
Push off Mountain
Events
Time - MOD_Timer expires
Conditions
Actions
For each (Integer A) from 1 to 5, do (Actions)
Loop - Actions
Custom script: set bj_wantDestroyGroup = true
Unit Group - Pick every unit in (Units within 349.00 of MOD_Loc[((Integer A) + 5)] matching ((((Matching unit) is A structure) Not equal to True) and ((((Matching unit) is A ground unit) Equal to True) and ((((Matching unit) is alive) Equal to True) and (((Matching unit) belongs to an enemy and do (Actions)
Loop - Actions
Set MOD_Picked_Unit_Loc[1] = (Position of (Picked unit))
Set MOD_Picked_Unit_Loc[2] = (MOD_Picked_Unit_Loc[1] offset by 15.00 towards (Angle from MOD_Loc[((Integer A) + 5)] to MOD_Picked_Unit_Loc[1]) degrees)
Unit - Move (Picked unit) instantly to MOD_Picked_Unit_Loc[2]
Special Effect - Create a special effect attached to the chest of (Picked unit) using Abilities\Spells\Human\FlakCannons\FlakTarget.mdl
Special Effect - Destroy (Last created special effect)
Destructible - Pick every destructible within 180.00 of MOD_Picked_Unit_Loc[1] and do (Destructible - Kill (Picked destructible))
Custom script: call RemoveLocation(udg_MOD_Picked_Unit_Loc[1])
Custom script: call RemoveLocation(udg_MOD_Picked_Unit_Loc[2])
This abi is based off of warstomp. There is no point where the spell is casted.