• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Faceless Void - Spell Pack v1.5

This bundle is marked as useful / simple. Simplicity is bliss, low effort and/or may contain minor bugs.
  • Like
Reactions: -Derp- and mateuspv
I've been playing Faceless Void on Dota and i really love the hero so i decided to make that hero in my ways. I've made all his skills but i kinda combined his evasion and bash in one skill and add a new skill named momentum rush. I've tested many times and i didn't find a bug so if you find any bugs, please leave a comment and i will fix it. Also i've changed the effects of the skills like chromosphere, time lock.


I checked out the link you sent me and i guess i fixed it. So any leak remained? :)

I've removed Momentum Rush again, and added backtrack and time lock in different skills. Also i've cleaned leaks. Here you can use two Faceless Voids in same time and see if any bug occurs.

I've fixed Time Walk too. Now it's MUI.

Time Walk
  • time walk cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Time Walk
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • TS_indexsize Equal to 0
        • Then - Actions
          • Trigger - Turn on time walk loop <gen>
        • Else - Actions
      • Set TS_indexsize = (TS_indexsize + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • TS_indexsize Greater than TS_indexmax
        • Then - Actions
          • Set TS_index[TS_indexsize] = TS_indexsize
          • Set TS_indexmax = TS_indexsize
        • Else - Actions
      • Set temp_int_TS = TS_index[TS_indexsize]
      • Set caster[temp_int_TS] = (Triggering unit)
      • Set TS_pointloc1 = (Position of caster[temp_int_TS])
      • Set TS_point_spell_being_cast[temp_int_TS] = (Target point of ability being cast)
      • Set TS_speed[temp_int_TS] = 60.00
      • Set TS_facing[temp_int_TS] = (Angle from TS_pointloc1 to TS_point_spell_being_cast[temp_int_TS])
      • Trigger - Run freeze all enemies <gen> (ignoring conditions)
      • Animation - Change caster[temp_int_TS]'s vertex coloring to (20.00%, 20.00%, 20.00%) with 40.00% transparency
      • Unit - Make caster[temp_int_TS] Invulnerable
      • Unit - Turn collision for caster[temp_int_TS] Off
      • Custom script: call RemoveLocation(udg_TS_pointloc1)
      • Custom script: call RemoveLocation(udg_TS_pointloc2)
  • time walk loop
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • For each (Integer TS_loop) from 1 to TS_indexsize, do (Actions)
        • Loop - Actions
          • Set temp_int_TS = TS_index[TS_loop]
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • caster[temp_int_TS] Not equal to No unit
            • Then - Actions
              • Set TS_pointloc1 = (Position of caster[temp_int_TS])
              • Set TS_pointloc2 = (TS_pointloc1 offset by TS_speed[temp_int_TS] towards TS_facing[temp_int_TS] degrees)
              • Set distance_between[temp_int_TS] = (Distance between TS_pointloc1 and TS_point_spell_being_cast[temp_int_TS])
              • Unit - Move caster[temp_int_TS] instantly to TS_pointloc2, facing TS_facing[temp_int_TS] degrees
              • Custom script: call RemoveLocation(udg_TS_pointloc1)
              • Custom script: call RemoveLocation(udg_TS_pointloc2)
            • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (caster[temp_int_TS] is in (Units within 70.00 of TS_point_spell_being_cast[temp_int_TS])) Equal to True
            • Then - Actions
              • Unit - Create 1 stun aoe dummy for (Owner of caster[temp_int_TS]) at TS_point_spell_being_cast[temp_int_TS] facing Default building facing degrees
              • Unit - Add a 0.50 second Generic expiration timer to (Last created unit)
              • Hero - Create stun aoe and give it to (Last created unit)
              • Unit - Set level of stun aoe for (Last created unit) to (Level of Time Walk for caster[temp_int_TS])
              • Hero - Order (Last created unit) to use (Last created item)
              • Animation - Change caster[temp_int_TS]'s vertex coloring to (100.00%, 100.00%, 100.00%) with 0.00% transparency
              • Special Effect - Create a special effect at TS_point_spell_being_cast[temp_int_TS] using Abilities\Spells\Items\TomeOfRetraining\TomeOfRetrainingCaster.mdl
              • Special Effect - Destroy (Last created special effect)
              • Unit - Make caster[temp_int_TS] Vulnerable
              • Unit - Turn collision for caster[temp_int_TS] On
              • Custom script: call RemoveLocation(udg_TS_point_spell_being_cast[udg_temp_int_TS])
              • Trigger - Run unfreeze all enemies <gen> (checking conditions)
              • Set TS_index[TS_loop] = TS_index[TS_indexsize]
              • Set TS_index[TS_indexsize] = temp_int_TS
              • Set TS_indexsize = (TS_indexsize - 1)
              • Set TS_loop = (TS_loop - 1)
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • TS_indexsize Equal to 0
                • Then - Actions
                  • Trigger - Turn off (This trigger)
                  • Skip remaining actions
                • Else - Actions
            • Else - Actions
  • freeze all enemies
    • Events
    • Conditions
    • Actions
      • Set unit_group = (Units within 400.00 of (Position of caster[temp_int_TS]) matching ((((Matching unit) is A structure) Equal to False) and (((Matching unit) belongs to an enemy of (Owner of caster[temp_int_TS])) Equal to True)))
      • Unit Group - Pick every unit in unit_group and do (Actions)
        • Loop - Actions
          • Animation - Change (Picked unit)'s animation speed to 0.00% of its original speed
          • Unit - Pause (Picked unit)
          • Unit Group - Add (Picked unit) to unit_group_TW
      • Custom script: call DestroyGroup(udg_unit_group)
  • unfreeze all enemies
    • Events
    • Conditions
    • Actions
      • Unit Group - Pick every unit in unit_group_TW and do (Actions)
        • Loop - Actions
          • Animation - Change (Picked unit)'s animation speed to 100.00% of its original speed
          • Unit - Unpause (Picked unit)
      • Unit Group - Remove all units from unit_group_TW
  • [/hidden]
Chronosphere
  • chronosphere cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Chronosphere
    • Actions
      • Set maxindex_CH = (maxindex_CH + 1)
      • Set hero_CH[maxindex_CH] = (Triggering unit)
      • Set counter_chrono[maxindex_CH] = 0
      • Unit - Create 1 chromosphere for (Owner of hero_CH[maxindex_CH]) at (Target point of ability being cast) facing Default building facing degrees
      • Set dummy_effect[maxindex_CH] = (Last created unit)
      • Trigger - Turn on chronosphere loop <gen>
      • If ((Level of Chronosphere for hero_CH[maxindex_CH]) Equal to 1) then do (Wait 6.00 seconds) else do (Do nothing)
      • If ((Level of Chronosphere for hero_CH[maxindex_CH]) Equal to 2) then do (Wait 8.00 seconds) else do (Do nothing)
      • If ((Level of Chronosphere for hero_CH[maxindex_CH]) Equal to 3) then do (Wait 10.00 seconds) else do (Do nothing)
      • Set readindex_CH = (readindex_CH + 1)
      • Unit - Remove dummy_effect[readindex_CH] from the game
      • Unit Group - Pick every unit in unit_group_chro[readindex_CH] and do (Actions)
        • Loop - Actions
          • Set frozen_enemies[readindex_CH] = (Picked unit)
          • Animation - Change frozen_enemies[readindex_CH]'s animation speed to 100.00% of its original speed
          • Unit - Unpause frozen_enemies[readindex_CH]
      • Custom script: call DestroyGroup(udg_unit_group_chro[udg_maxindex_CH])
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • readindex_CH Equal to maxindex_CH
        • Then - Actions
          • Set readindex_CH = 0
          • Set maxindex_CH = 0
        • Else - Actions
  • chronosphere loop
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • Set point2_chronosphere[maxindex_CH] = (Position of dummy_effect[maxindex_CH])
      • Set unit_group_chro[maxindex_CH] = (Units within 400.00 of point2_chronosphere[maxindex_CH] matching ((Unit-type of (Matching unit)) Not equal to Faceless Void))
      • Unit Group - Pick every unit in unit_group_chro[maxindex_CH] and do (Actions)
        • Loop - Actions
          • Set frozen_enemies[maxindex_CH] = (Picked unit)
          • Animation - Change frozen_enemies[maxindex_CH]'s animation speed to 0.00% of its original speed
          • Unit - Pause frozen_enemies[maxindex_CH]
      • Custom script: call RemoveLocation(udg_point2_chronosphere[udg_maxindex_CH])
      • Set point2_chronosphere[(maxindex_CH - 1)] = (Position of dummy_effect[(maxindex_CH - 1)])
      • Set unit_group_chro[(maxindex_CH - 1)] = (Units within 400.00 of point2_chronosphere[(maxindex_CH - 1)] matching ((Unit-type of (Matching unit)) Not equal to Faceless Void))
      • Unit Group - Pick every unit in unit_group_chro[(maxindex_CH - 1)] and do (Actions)
        • Loop - Actions
          • Set frozen_enemies[readindex_CH] = (Picked unit)
          • Animation - Change frozen_enemies[readindex_CH]'s animation speed to 0.00% of its original speed
          • Unit - Pause frozen_enemies[readindex_CH]
      • Custom script: call RemoveLocation(udg_point2_chronosphere[udg_maxindex_CH])
  • [/hidden]
Backtrack
  • backtrack learn
    • Events
      • Unit - A unit Learns a skill
    • Conditions
      • (Learned Hero Skill) Equal to Backtrack
    • Actions
      • Trigger - Add to backtrack <gen> the event (Unit - (Triggering unit) Takes damage)
  • backtrack
    • Events
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Random integer number between 0 and 100) Less than or equal to (5 + ((Level of Backtrack for (Triggering unit)) x 5))
        • Then - Actions
          • Set damage_taken = (Damage taken)
          • Special Effect - Create a special effect attached to the chest of (Triggering unit) using Abilities\Weapons\WingedSerpentMissile\WingedSerpentMissile.mdl
          • Special Effect - Destroy (Last created special effect)
          • Unit - Set life of (Triggering unit) to ((Life of (Triggering unit)) + damage_taken)
        • Else - Actions
  • [/hidden]
Time Lock
  • time lock event
    • Events
      • Unit - A unit Learns a skill
    • Conditions
      • (Learned Hero Skill) Equal to Time Lock
    • Actions
      • Unit Group - Pick every unit in (Units in (Playable map area) matching (((Matching unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to True)) and do (Actions)
        • Loop - Actions
          • Trigger - Add to time lock <gen> the event (Unit - (Picked unit) Takes damage)
  • time lock
    • Events
    • Conditions
      • (Level of Time Lock for (Damage source)) Greater than 0
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) has buff Time Lock ) Equal to True
        • Then - Actions
          • Unit Group - Add (Triggering unit) to unit_group_TL
          • Trigger - Turn on time lock loop <gen>
        • Else - Actions
  • time lock loop
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • Unit Group - Pick every unit in unit_group_TL and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has buff Time Lock ) Equal to True
            • Then - Actions
              • Special Effect - Create a special effect attached to the chest of (Picked unit) using Abilities\Spells\Undead\AbsorbMana\AbsorbManaBirthMissile.mdl
              • Special Effect - Destroy (Last created special effect)
            • Else - Actions
              • Unit Group - Remove (Picked unit) from unit_group_TL
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Number of units in unit_group_TL) Equal to 0
                • Then - Actions
                  • Trigger - Turn off (This trigger)
                • Else - Actions
  • [/hidden]
Keywords:
faceless void, time lock, chromosphere, dota, time lost, darkterror, time walk, backtrack
Contents

Faceless Void Spell Pack v1.3 (Map)

Reviews
12th Dec 2015 IcemanBo: Too long as NeedsFix. Rejected. 15:59, 2nd Aug 2012 Magtheridon96: Check this out too. There's a section before the end that teaches how to make perfect MUI spells. The method outlined in the rest of the tutorial...

Moderator

M

Moderator

12th Dec 2015
IcemanBo: Too long as NeedsFix. Rejected.

15:59, 2nd Aug 2012
Magtheridon96:

Check this out too.
There's a section before the end that teaches how to make perfect MUI spells.

The method outlined in the rest of the tutorial should NOT be used in public resources.
It doesn't work for dynamic wait times.

Also, never constantly repeat things in paranthesis like (Last created unit).

ALWAYS, and I mean ALWAYS store them into temp variables and use those variables instead.
 
While you've correctly gone about creating delays, what you haven't done is make any of these spells MUI, You also lack configurables which really is needed for every spell, and particularly a spell pack.

You're leaking unit groups and locations all over the auction though you do remove some location variables, you don't actually set them in the first place
you use object data to deal damage.

While it shows promise you still need to learn a lot more about making spells, I'd suggest going over tutorials again and filling in these things in particular.
 
Tip:

Try posting the triggers in the description inside [trigger][/trigger] tags so people who don't have access to the editor at a certain time can help you. (People on iPads, people who use switch between OS's, people on phones, etc...)

This would also help lazy people :3
(And people who have custom editors like me, which take time to load the trigger editor due to all the mods.)
 
Level 6
Joined
Apr 16, 2011
Messages
158
Bug:
Time Shift: hero is gone beyond the limits of the map, sometimes just keep walking without stopping


Effects:
you can use the following effects to be more like dota,if you will, of course :)
Time lock: AbsorbManaBirthMissile.mdl
Chromosphere:
http://www.hiveworkshop.com/forums/pastebin_data/ktvkt3/_files/Chronosphere.mdx

New
Dummy Chromosphere: Movement - heght =~ 250
will cause your ball does not get so buried
 
Last edited:
Level 33
Joined
Mar 27, 2008
Messages
8,035
And to be honest i don't know what MUI is.
You wanna know ?
Do you really wanna know ?
Are you prepare ?

Okay, put 2 Faceless Void in that map and order them to cast any same ability at the same time (like if you order Unit A cast Time Warp, order Unit B to cast Time Warp too), the last cast would bug out.
What kind of bug ?
You will find out.

MUI stands for Multi-unit Instanceability, it's a property for a trigger that is able to support certain spells/systems for more than 1 unit casting it at a time.
Now your spell will bug if there's more than 1 unit cast this spell at a time.

And yes, all your spells are not MUI.
 
Level 11
Joined
Jun 28, 2011
Messages
540
Hey iceteaftw.


So a leak is any bit of information that is not removed once used. Locations like (Position of Unit), (Center of Region) leak. Groups leak as well. There's a whole bunch of things that you have to watch out for. If there's too many leaks the game's performance will drop and eventually become unplayable.

MUI, as said above, stands for multi-unit instanceability. It's a fancy little word that means multiple units can do a thing and it will work.

Now, on to the triggers.

---

Time shift trigger:

  • Set facing_of_caster = (Angle from (Position of caster[writeindex_TS]) to (Target point of ability being cast))
This leaks as you're not using your variable, 'position of cast[writeindex_TS]', but the function. As with '(Target point of ability being cast)', you need to put your variable 'reach_point' there instead. It should look like this:

  • Set facing_of_caster = (Angle from position_of_caster[writeindex_TS] to reach_point[writeindex_TS])
---

  • Animation - Change (Triggering unit)'s vertex coloring to (40.00%, 40.00%, 40.00%) with 40.00% transparency
  • Unit - Make (Triggering unit) Invulnerable
  • Unit - Turn collision for (Triggering unit) Off
You could replace the (Triggering unit) with your variable 'caster[writeindex_TS]'. It will function the same and run more efficiently.

---

You have to destroy the 'unit_group' variable else it will leak. Since you're using a variable, destroy it with the following:

  • freeze all enemies
    • Events
    • Conditions
    • Actions
      • Set unit_group = (Units within 400.00 of (Position of caster[writeindex_TS]) matching ((((Matching unit) is A structure) Equal to False) and (((Matching unit) belongs to an enemy of (Owner of caster[writeindex_TS])) Equal to True)))
      • Unit Group - Pick every unit in unit_group and do (Actions)
        • Loop - Actions
          • Animation - Change (Picked unit)'s animation speed to 0.00% of its original speed
          • Unit - Pause (Picked unit)
      • Custom script: call DestroyGroup(udg_unit_group)
---

You could probably merge the four triggers into two triggers. I'm not 100% on that one though.

---

The following leaks two locations:

  • Unit - Move caster[writeindex_TS] instantly to ((Position of caster[writeindex_TS]) offset by 50.00 towards (Angle from (Position of caster[writeindex_TS]) to reach_point[writeindex_TS]) degrees)
You need to set (Position of caster[writeindex_TS]) as your location variable, and another location as the offset. You must destroy the variable later on as well.

Example:

  • Set Point2 = (position_of_caster[writeindex_TS] offset by 50.00 towards (Angle from position_of_caster[writeindex_TS] to reach_point[writeindex_TS]) degrees)
  • Unit - Move caster[writeindex_TS] instantly to Point2
  • Custom script: call RemoveLocation(udg_Point2)
---

You're leaking one location here:

  • (Distance between (Position of caster[writeindex_TS]) and reach_point[writeindex_TS]) Less than 100.00
Just replace it with your position_of_caster[writeindex_TS] variable.

---

You should move the 'call DestroyGroup' function outside of the group loop so it runs properly.

  • Unit Group - Pick every unit in unit_group and do (Actions)
    • Loop - Actions
      • Animation - Change (Picked unit)'s animation speed to 100.00% of its original speed
      • Unit - Unpause (Picked unit)
      • Custom script: call DestroyGroup(udg_unit_group)
  • --->
  • Unit Group - Pick every unit in unit_group and do (Actions)
    • Loop - Actions
      • Animation - Change (Picked unit)'s animation speed to 100.00% of its original speed
      • Unit - Unpause (Picked unit)
  • Custom script: call DestroyGroup(udg_unit_group)
---

Chronosphere trigger:

come inside trigger:

Try to avoid using .01 intervals. .03 is the lowest you should ever need.

  • Time - Every 0.01 seconds of game time
  • --->
  • Time - Every 0.03 seconds of game time
The groups leak four times as well, one location and one group for the two of them. You need to destroy both of them, like this:

  • Actions
    • Set Point2 = (Position of dummy_effect[writeindex_TS])
    • Set unit_group_chro[maxindex_CH] = (Units within 400.00 of Point2 matching ((Unit-type of (Matching unit)) Not equal to Faceless Void))
    • Unit Group - Pick every unit in unit_group_chro[maxindex_CH] and do (Actions)
      • Loop - Actions
    • Custom script: call RemoveLocation(udg_Point2)
    • Custom script: call DestroyGroup(udg_unit_group)
    • Set Point2 = (Position of dummy_effect[(maxindex_CH - 1)])
    • Set unit_group_chro[(maxindex_CH - 1)] = (Units within 400.00 of Point2 matching ((Unit-type of (Matching unit)) Not equal to Faceless Void))
    • Unit Group - Pick every unit in unit_group_chro[(maxindex_CH - 1)] and do (Actions)
      • Loop - Actions
    • Custom script: call DestroyGroup(udg_unit_group)
    • Custom script: call RemoveLocation(udg_Point2)
To ensure that those units have the animation speed reset when the spell is done, add them to another indexed unit group, when the spell is done pick up all in the indexed unit group, reset their animation speeds and clear the group. Do not destroy re-usable groups.

---

You should turn off the loop when the spell is done as well.

---

Backtrack trigger:

  • Unit Group - Pick every unit in (Units in (Playable map area) matching ((Unit-type of (Matching unit)) Equal to Faceless Void)) and do (Actions)
    • Loop - Actions
      • Trigger - Add to damaged <gen> the event (Unit - (Picked unit) Takes damage)
  • --->
  • Trigger - Add to damaged <gen> the event (Unit - (Triggering unit) Takes damage)
---

Damaged trigger:

This trigger can be simplified to the following:

  • damaged
    • Events
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Random integer number between 0 and 100) Less than or equal to (5 + ((Level of Backtrack for (Triggering unit)) x 5))
        • Then - Actions
          • Set damage_taken = (Damage taken)
          • Special Effect - Create a special effect attached to the chest of (Triggering unit) using Abilities\Weapons\WingedSerpentMissile\WingedSerpentMissile.mdl
          • Special Effect - Destroy (Last created special effect)
          • Unit - Set life of (Triggering unit) to ((Life of (Triggering unit)) + damage_taken)
        • Else - Actions
 
Last edited:
Level 4
Joined
Aug 2, 2012
Messages
20
Bug:
Time Shift: hero is gone beyond the limits of the map, sometimes just keep walking without stopping


Effects:
you can use the following effects to be more like dota,if you will, of course :)
Time lock: AbsorbManaBirthMissile.mdl
Chromosphere:
http://www.hiveworkshop.com/forums/pastebin_data/ktvkt3/_files/Chronosphere.mdx

New
Dummy Chromosphere: Movement - heght =~ 250
will cause your ball does not get so buried

I've fixed time walk and added the effects you told me. :)
 
Level 11
Joined
Jun 28, 2011
Messages
540
Hey, sorry for the delay.

---

Time Shift:

time walk cast:

  • Set facing_of_caster = (Angle from (Position of caster[writeindex_TS]) to reach_point[writeindex_TS])
This still isn't using your 'position_of_caster' variable, it's using the function, (Position of Unit) which will leak.

You need to replace it with your variable, like this:

  • Set facing_of_caster = (Angle from position_of_caster[writeindex_TS] to reach_point[writeindex_TS])
---

Your freeze/unfreeze unit group can be overwritten. A way around this is:
  • freeze all enemies
    • Events
    • Conditions
    • Actions
      • Set unit_group = (Units within 400.00 of (Position of caster[writeindex_TS]) matching ((((Matching unit) is A structure) Equal to False) and (((Matching unit) belongs to an enemy of (Owner of caster[writeindex_TS])) Equal to True)))
      • Unit Group - Pick every unit in unit_group and do (Actions)
        • Loop - Actions
          • Animation - Change (Picked unit)'s animation speed to 0.00% of its original speed
          • Unit - Pause (Picked unit)
          • Unit Group - Add (Picked unit) to Timewalk_Group
      • Custom script: call DestroyGroup(udg_unit_group)
  • unfreeze all enemies
    • Events
    • Conditions
    • Actions
      • Unit Group - Pick every unit in Timewalk_Group and do (Actions)
        • Loop - Actions
          • Animation - Change (Picked unit)'s animation speed to 100.00% of its original speed
          • Unit - Unpause (Picked unit)
      • Unit Group - Remove all units from Timewalk_Group
---

xRokP.jpg


I had cast this spell with more than 2 units at the same time and this is the result. At least one is faded out and invulnerable. You can't use Magtheridon96's 'MUI with Waits' with a looping trigger, unless you loop through all of the 'writeindexes'.

Hanky's indexing tutorial will show you how to do this.


---

Chronosphere:

  • Unit - Create 1 chromosphere for (Owner of hero_CH[maxindex_CH]) at (Target point of ability being cast) facing Default building facing degrees
Replace the (Target point of ability being cast) with a variable and then destroy it, like so:

  • Set point2 = (Target point of ability being cast)
  • Unit - Create 1 chromosphere for (Owner of hero_CH[maxindex_CH]) at point2 facing Default building facing degrees
  • Custom script: call RemoveLocation(udg_point2)
---

Backtrack looks good.

---

Timelock:

  • Unit Group - Pick every unit in (Units in (Playable map area) matching (((Matching unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to True)) and do (Actions)
    • Loop - Actions
      • Trigger - Add to time lock <gen> the event (Unit - (Picked unit) Takes damage)
This can be simplified into:

  • Trigger - Add to time lock <gen> the event (Unit - (Triggering unit) Takes damage)
---

  • (Unit-type of (Damage source)) Equal to Faceless Void
This should probably be change to:

  • (Level of Time Lock for (Damage source)) Greater than 0
---

  • Set attacked_unit = (Triggering unit)
Instead of doing this (which makes the spell non-MUI), add the unit to a unit group.

  • time lock
    • Events
    • Conditions
      • (Level of Time Lock for (Damage source)) Greater than 0
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) has buff Time Lock ) Equal to True
        • Then - Actions
          • Unit Group - Add (Triggering unit) to Timelock_Group
          • Trigger - Turn on time lock loop <gen>
        • Else - Actions
  • time lock loop
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • Unit Group - Pick every unit in Timelock_Group and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has buff Time Lock ) Equal to True
            • Then - Actions
              • Special Effect - Create a special effect attached to the chest of (Picked unit) using Abilities\Spells\Undead\AbsorbMana\AbsorbManaBirthMissile.mdl
              • Special Effect - Destroy (Last created special effect)
            • Else - Actions
              • Unit Group - Remove (Picked unit) from Timelock_Group
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Number of units in Timelock_Group) Equal to 0
                • Then - Actions
                  • Trigger - Turn off (This trigger)
                • Else - Actions
---

P.S. You don't have to name the variables exactly as I did.
 
Level 11
Joined
Jun 28, 2011
Messages
540
Your timewalk doesn't actually use a wait, so it kind of defeats the purpose of using Maggy's method.

Here's the easiest MUI-version I could find for your timewalk, it's a mix of Hanky's and Maggy's methods. It works and is simple, but Hanky's method is more efficient:


  • time walk cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Time Walk
    • Actions
      • Set writeindex_TS = (writeindex_TS + 1)
      • Set caster[writeindex_TS] = (Triggering unit)
      • Set position_of_caster[writeindex_TS] = (Position of caster[writeindex_TS])
      • Set reach_point[writeindex_TS] = (Target point of ability being cast)
      • Set facing_of_caster = (Angle from (Position of caster[writeindex_TS]) to reach_point[writeindex_TS])
      • Trigger - Run freeze all enemies <gen> (ignoring conditions)
      • Trigger - Turn on time walk loop <gen>
      • Animation - Change caster[writeindex_TS]'s vertex coloring to (40.00%, 40.00%, 40.00%) with 40.00% transparency
      • Unit - Make caster[writeindex_TS] Invulnerable
      • Unit - Turn collision for caster[writeindex_TS] Off
  • time walk loop
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • For each (Integer AAinteger) from 1 to writeindex_TS, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • caster[AAinteger] Not equal to No unit
            • Then - Actions
              • Set point2 = ((Position of caster[AAinteger]) offset by 50.00 towards (Angle from (Position of caster[AAinteger]) to reach_point[AAinteger]) degrees)
              • Unit - Move caster[AAinteger] instantly to point2
              • Custom script: call RemoveLocation(udg_point2)
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (caster[AAinteger] is in (Units within 70.00 of reach_point[AAinteger])) Equal to True
                • Then - Actions
                  • Set readindex_TS = (readindex_TS + 1)
                  • Unit - Create 1 stun aoe dummy for (Owner of caster[AAinteger]) at position_of_caster[AAinteger] facing Default building facing degrees
                  • Set dummy_TS[AAinteger] = (Last created unit)
                  • Unit - Add a 1.00 second Generic expiration timer to dummy_TS[AAinteger]
                  • Hero - Create stun aoe and give it to dummy_TS[AAinteger]
                  • Set item_stun_aoe[AAinteger] = (Last created item)
                  • Unit - Set level of stun aoe for dummy_TS[AAinteger] to (Level of Time Walk for caster[AAinteger])
                  • Hero - Order dummy_TS[AAinteger] to use item_stun_aoe[AAinteger]
                  • Animation - Change caster[AAinteger]'s vertex coloring to (100.00%, 100.00%, 100.00%) with 0.00% transparency
                  • Special Effect - Create a special effect at reach_point[AAinteger] using Abilities\Spells\Items\TomeOfRetraining\TomeOfRetrainingCaster.mdl
                  • Special Effect - Destroy (Last created special effect)
                  • Unit - Make caster[AAinteger] Vulnerable
                  • Unit - Turn collision for caster[AAinteger] On
                  • Custom script: call RemoveLocation(udg_reach_point[udg_AAinteger])
                  • Custom script: call RemoveLocation(udg_position_of_caster[udg_AAinteger])
                  • Trigger - Run unfreeze all enemies <gen> (checking conditions)
                  • Set caster[AAinteger] = No unit
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • writeindex_TS Equal to readindex_TS
                    • Then - Actions
                      • Game - Display to (All players) the text: grr
                      • Set writeindex_TS = 0
                      • Set readindex_TS = 0
                      • Trigger - Turn off (This trigger)
                    • Else - Actions
                • Else - Actions
            • Else - Actions


Note that above is a quick fix and still contains the location leaks I mentioned earlier.
 
Level 11
Joined
Jun 28, 2011
Messages
540
Sorry for the delay, again.

---

time lock event:

  • Unit Group - Pick every unit in (Units in (Playable map area) matching (((Matching unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to True)) and do (Actions)
    • Loop - Actions
      • Trigger - Add to time lock <gen> the event (Unit - (Picked unit) Takes damage)
I don't know if that's the best way of doing things. (Sorry if I told you to do it the wrong way before, I misread it.) Notably because if a unit is created after level 3 it won't trigger on the unit. You could use either a damage detection system or a 'unit takes damage' event and get the attacker. I'm not proficient with this function in particular so you may need to ask a mod for clarification.

(From what I understand, 'Unit is attacked' is frowned upon, but, meh.)

As a side note the group leaks above, you need to destroy it.

---

chronosphere loop:

The trigger isn't actually MUI.
  • Unit Group - Pick every unit in unit_group_chro[maxindex_CH] and do (Actions)
    • Loop - Actions
      • Set frozen_enemies[maxindex_CH] = (Picked unit)
      • Animation - Change frozen_enemies[maxindex_CH]'s animation speed to 0.00% of its original speed
      • Unit - Pause frozen_enemies[maxindex_CH]
  • //
  • //
  • >unit_group_chro[maxindex_CH]
The way you're doing it however makes it very difficult for an error to ever arise. You need to loop through the groups to make it MUI. In a worst-case scenario units will be able to run all but the last two spheres created, assuming there's 3 or more created at the same time.

---

Timewalk:

  • Set unit_group = (Units within 400.00 of (Position of caster[temp_int_TS]) matching ((((Matching unit) is A structure) Equal to False) and (((Matching unit) belongs to an enemy of (Owner of caster[temp_int_TS])) Equal to True)))
Location leak, switch your variable. You probably should merge this trigger with the cast trigger.

---

As a side note, static variables should be set in an initialization trigger. Nitpickers tend to prefer it that way. (In the grand scheme of things though it is not important)
 
Last edited:
Top