• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Hero - Mystic

This bundle is marked as useful / simple. Simplicity is bliss, low effort and/or may contain minor bugs.
The mytic is an enigmatic character from the darkest depths of the bowels of the earth. She manipulates shadows, and the unknown allowing her to cast otherworldly spells.


[Trigger=Path of Mystery Cast]
Path Cast
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Path of Mystery
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
P_Skip Equal to 0
Then - Actions
Trigger - Turn on Path Loop <gen>
Else - Actions
Set P_Times = (P_Times + 1)
Set P_Skip = (P_Skip + 1)
Set P_Off[P_Times] = True
-------- Caster/Point Config --------
Set P_Caster[P_Times] = (Casting unit)
Set P_Level[P_Times] = (Level of Path of Mystery for P_Caster[P_Times])
Set P_Point[0] = (Position of P_Caster[P_Times])
Set P_Point[1] = (Target point of ability being cast)
-------- Movement Config --------
Set P_Angle[P_Times] = (Angle from P_Point[0] to P_Point[1])
Set P_Distance[P_Times] = (Distance between P_Point[0] and P_Point[1])
Set P_Speed[P_Times] = (((Real(P_Level[P_Times])) x 10.00) + 20.00)
Set P_Effect[P_Times] = 0
-------- Movement Effects --------
Animation - Change P_Caster[P_Times]'s animation speed to 300.00% of its original speed
Animation - Change P_Caster[P_Times]'s vertex coloring to (100.00%, 100.00%, 100.00%) with 50.00% transparency
Animation - Play P_Caster[P_Times]'s walk animation
Special Effect - Create a special effect attached to the weapon of P_Caster[P_Times] using Abilities\Weapons\AvengerMissile\AvengerMissile.mdl
Set P_Sfx[P_Times] = (Last created special effect)
Unit - Turn collision for P_Caster[P_Times] Off
-------- Leak Cleanup --------
Custom script: call RemoveLocation(udg_P_Point[0])
Custom script: call RemoveLocation(udg_P_Point[1])
[/trigger]

[trigger=Path of Mystery Loop]Path Loop
Events
Time - Every 0.03 seconds of game time
Conditions
Actions
For each (Integer P) from 1 to P_Times, do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
P_Off Equal to True
Then - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
P_Distance Less than or equal to 0.00
Then - Actions
Animation - Change P_Caster's vertex coloring to (100.00%, 100.00%, 100.00%) with 0.00% transparency
Animation - Change P_Caster[P_Times]'s animation speed to 100.00% of its original speed
Special Effect - Destroy P_Sfx
Unit - Turn collision for P_Caster On
Set P_Off = False
Set P_Skip = (P_Skip - 1)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
P_Skip Equal to 0
Then - Actions
Set P_Times = 0
Trigger - Turn off Path Loop <gen>
Else - Actions
Else - Actions
Set P_Distance = (P_Distance - P_Speed)
Set P_Point[2] = (Position of P_Caster)
Set P_Point[3] = (P_Point[2] offset by P_Speed towards P_Angle degrees)
Unit - Move P_Caster instantly to P_Point[3]
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Terrain pathing at P_Point[3] of type Walkability is off) Equal to True
Then - Actions
Set P_Distance = 0.00
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
P_Effect Equal to 3
Then - Actions
Special Effect - Create a special effect at P_Point[2] using Abilities\Weapons\WingedSerpentMissile\WingedSerpentMissile.mdl
Special Effect - Destroy (Last created special effect)
Set P_Effect = 0
Else - Actions
Set P_Effect = (P_Effect + 1)
Custom script: call RemoveLocation(udg_P_Point[2])
Custom script: call RemoveLocation(udg_P_Point[3])
Else - Actions
[/trigger]


[trigger=Mastery of Shadows]
Shadow Aura
Events
Unit - A unit Is attacked
Conditions
((Attacked unit) has buff Shadow Mastery) Equal to True
Actions
Set S_Caster = (Attacked unit)
Set S_Target = (Attacking unit)
Set S_Level = (Level of Mastery of Shadows for S_Caster)
Set S_Chance = (S_Level x 3)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Random integer number between 1 and 100) Less than or equal to S_Chance
Then - Actions
Set S_Damage = (S_Level x 60)
Set S_Point[0] = (Position of S_Target)
Unit - Cause S_Caster to damage S_Target, dealing (Real(S_Damage)) damage of attack type Hero and damage type Shadow Strike
For each (Integer A) from 1 to 3, do (Actions)
Loop - Actions
For each (Integer B) from 1 to 10, do (Actions)
Loop - Actions
Set S_Point[1] = (S_Point[0] offset by (40.00 + ((Real((Integer A))) x 40.00)) towards (36.00 x (Real((Integer B)))) degrees)
Special Effect - Create a special effect at S_Point[1] using Abilities\Spells\Undead\DeathCoil\DeathCoilSpecialArt.mdl
Custom script: call RemoveLocation(udg_S_Point[1])
Custom script: call RemoveLocation(udg_S_Point[0])
Custom script: call RemoveLocation(udg_S_Point[2])
Else - Actions
[/trigger]


[trigger=Mystic Domain Cast]Domain Cast
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Mystic Domain
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
D_Skip Equal to 0
Then - Actions
Trigger - Turn on Domain Loop <gen>
Else - Actions
Set D_Times = (D_Times + 1)
Set D_Skip = (D_Skip + 1)
Set D_Off[D_Times] = True
-------- Caster/Point Config --------
Set D_Caster[D_Times] = (Casting unit)
Set D_Level[D_Times] = (Level of Mystic Domain for D_Caster[D_Times])
Set D_Point[0] = (Position of D_Caster[D_Times])
-------- Effects Config --------
Set D_Aoe[D_Times] = 400.00
Set D_Duration[D_Times] = (8.00 x (Real(D_Level[D_Times])))
Set D_Interval[D_Times] = 1.00
-------- Wall Creation --------
Unit - Create 1 Mystic Domain for (Owner of D_Caster[D_Times]) at D_Point[0] facing Default building facing degrees
Set D_Domain[D_Times] = (Last created unit)
Unit - Set level of Mystic Domain Aura for D_Domain[D_Times] to D_Level[D_Times]
Unit - Set level of Mystic Domain Aura 2 for D_Domain[D_Times] to D_Level[D_Times]
For each (Integer A) from 1 to 5, do (Actions)
Loop - Actions
For each (Integer B) from 1 to 20, do (Actions)
Loop - Actions
Set D_Point[1] = (D_Point[0] offset by D_Aoe[D_Times] towards (18.00 x (Real((Integer B)))) degrees)
Set D_Height[D_Times] = ((Real((Integer A))) x 100.00)
Unit - Create 1 Mystic Wall for (Owner of D_Caster[D_Times]) at D_Point[1] facing Default building facing degrees
Set D_Dummy[D_Times] = (Last created unit)
Animation - Change D_Dummy[D_Times] flying height to D_Height[D_Times] at 0.00
Unit - Add a D_Duration[D_Times] second Generic expiration timer to D_Dummy[D_Times]
Custom script: call RemoveLocation(udg_D_Point[1])
Custom script: call RemoveLocation(udg_D_Point[0])
[/trigger]
[trigger=Mystic Domain Loop]Domain Loop
Events
Time - Every 1.00 seconds of game time
Conditions
Actions
For each (Integer D) from 1 to D_Times, do (Actions)
Loop - Actions
Set D_Duration[D] = (D_Duration[D] - D_Interval[D])
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
D_Off[D] Equal to True
Then - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
D_Duration[D] Less than or equal to 0.00
Then - Actions
Unit - Remove D_Domain[D] from the game
Set D_Skip = (D_Skip - 1)
Set D_Off[D] = False
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
D_Skip Equal to 0
Then - Actions
Set D_Times = 0
Trigger - Turn off Domain Loop <gen>
Else - Actions
Else - Actions
Set D_Point[2] = (Position of D_Domain[D])
Set D_Point[3] = (D_Point[2] offset by (Random real number between 0.00 and D_Aoe[D]) towards (Random angle) degrees)
Special Effect - Create a special effect at D_Point[3] using Abilities\Spells\Items\AIre\AIreTarget.mdl
Special Effect - Destroy (Last created special effect)
Else - Actions
[/trigger]


[trigger=True Mysticism Cast]Conflag
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to True Mysticism
Actions
Set Conflag_Caster = (Casting unit)
Set Conflag_Point[0] = (Target point of ability being cast)
Set Conflag_Level = (Level of Path of Mystery for Conflag_Caster)
Set Conflag_Damage = (200 + (Intelligence of Conflag_Caster (Include bonuses)))
Set Conflag_Group = (Units within 350.00 of Conflag_Point[0] matching ((((Matching unit) belongs to an ally of (Owner of Conflag_Caster)) Equal to False) and ((((Matching unit) is Magic Immune) Equal to False) and (((Matching unit) is dead) Equal to False))))
Unit - Create 1 Mysticism Dummy for (Owner of Conflag_Caster) at Conflag_Point[0] facing Default building facing degrees
Set Conflag_Dummy = (Last created unit)
Unit - Order Conflag_Dummy to Neutral Pit Lord - Howl Of Terror
Unit - Add a 3.00 second Generic expiration timer to Conflag_Dummy
For each (Integer A) from 1 to 20, do (Actions)
Loop - Actions
Set Conflag_Point[1] = (Conflag_Point[0] offset by (Random real number between 0.00 and 350.00) towards (Random angle) degrees)
Special Effect - Create a special effect at Conflag_Point[1] using Abilities\Spells\Human\MarkOfChaos\MarkOfChaosTarget.mdl
Special Effect - Destroy (Last created special effect)
Special Effect - Create a special effect at Conflag_Point[1] using Abilities\Spells\Undead\Possession\PossessionMissile.mdl
Special Effect - Destroy (Last created special effect)
Custom script: call RemoveLocation(udg_Conflag_Point[1])
Unit Group - Pick every unit in Conflag_Group and do (Actions)
Loop - Actions
Unit - Cause Conflag_Caster to damage (Picked unit), dealing (Real(Conflag_Damage)) damage of attack type Spells and damage type Fire
Custom script: call RemoveLocation(udg_Conflag_Point[0])
Custom script: call DestroyGroup(udg_Conflag_Group)
[/trigger]



Path of Mystery - The Mystic partially shifts from reality, becoming only a shadow of the physical world. Whilst in this form the Mystic has incredible speed. The Mystic charges to the target point.

Mastery of Shadows - The Mystic has trained long and hard in the darkest depths of the earth, heightening her senses and perfecting her utilization of shadows. Gives a percentage chance when attacked for the Mystic to conjure up a small blast of shadow, which swallows up the attacker dealing damage.

Mystic Domain - The Mystic creates a ring around herself, in which her and her allies are empowered. Increases health regeneration, movespeed and attack speed to those within.

True Mysticism - Blasts the target area with a surge of Mystic Energy, dealing 200 + Intelligence of the caster and reducing their attack damage by 60% for 15 seconds.




Keywords:
Hero, Mystic, Mysticism, Naga, Magic, Curse
Contents

Hero: Mystic (Map)

Reviews
7 November 2015 Bribe: Rejecting due to the status of this resource being "needs fix" for years. 12:11, 17th Jun 2010 Hanky: I found some leaks in the trigger Domain Loop. Also you got one not necessary RemoveLocation function in the trigger...

Moderator

M

Moderator

7 November 2015
Bribe: Rejecting due to the status of this resource being "needs fix" for years.

12:11, 17th Jun 2010
Hanky:
I found some leaks in the trigger Domain Loop. Also you got one not necessary RemoveLocation function in the trigger Shadow Aura. After you have fixed those things message me or one of the other spell moderators.
 
Level 19
Joined
Feb 25, 2009
Messages
2,004
- Multiple usage of Interger A/B causes leaks (errors, bugs), use local integer veriables.

  • Set D_Point[2] = (Position of D_Domain[D])
  • Set D_Point[3] = (D_Point[2] offset by (Random real number between 0.00 and D_Aoe[D]) towards (Random angle) degrees)
Was never cleared.

- You can make "Conflag_Damage" a real, not transform it when a unit is damaged.

  • Set S_Chance = (S_Level x 3)
Can be a constant which is initialiazied in the begining of the map. Try to use an array veriable and make the condition like that:
  • (Random integer number between 1 and 100) Less than or equal to S_Chance[S_Level]
  • Special Effect - Create a special effect at S_Point[1] using Abilities\Spells\Undead\DeathCoil\DeathCoilSpecialArt.mdl
This effect is not destroyed, this might cause lag after sometime.

- As mentioned above, use (Triggering Unit) instead of (Casting Unit)
 
Last edited:
Level 5
Joined
Dec 8, 2008
Messages
102
I hate GUI and cant understand why you dont learn basics of jass^^, but spells are very eye-candy and triggers seem clean, i only saw 2 things. Usage of integer A/B, which is realy inefficient cause you call this variable over an function (GetLoopAInte...) and thats less efficient if you just use an integer variable for all your loops : ), and besides, sometimes if u use B in A, it will bug due to some reason. And the second thing is a location / effect leak (mortar- said it), if you fix the leak, it will surely get approved
 
Top