• 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.

Rubick the Grand Magus's Spell Steal v1.3

This bundle is marked as useful / simple. Simplicity is bliss, low effort and/or may contain minor bugs.
  • Like
Reactions: deepstrasz
This spell created by me, it's similar to DotA hero {Rubick's Ultimate}.
The spell is GUI and MUI.

Changes :
V1.1
-added configuration
-fixed the duration error
-added a new trigger to change the unit type of the Spell Stealer

V1.2
-added the duration variable and the missile type variable to Spell Config trigger

V1.3
-fixed the missile when casting multiply times to be removed and fixed a bug when casting on a unit that didn't cast a spell and then if you cast the spell on another you wont steal a thing.

Please give me credits if you used it.
BY Storm_hih



Triggers:

1. The unit type of the Spell Stealer, duration of the spell and missile unit type

  • Spell Config
    • Events
      • Map initialization
    • Conditions
    • Actions
      • -------- The unit type of the stealer unit --------
      • Set SpellStealType = Grand Magus
      • -------- The unit type of the missile --------
      • Set SpellStealMissile = Spell Steal Missile
      • -------- The duration each level --------
      • Set SpellStealD[1] = 180.00
      • Set SpellStealD[2] = 240.00
      • Set SpellStealD[3] = 300.00


1.Spells used by units


  • Spell Count
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Unit-type of (Triggering unit)) Not equal to SpellStealType
    • Actions
      • -------- This trigger to store the last ability units casted --------
      • -------- You can here create a conditions of the unwanted spells to be stolen, because right now any spell can including items morph abilities.... etc. --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) is in SpellStealAG) Not equal to True
        • Then - Actions
          • Set SpellStealAC = (SpellStealAC + 1)
          • Set SpellStealAU[SpellStealAC] = (Triggering unit)
          • Unit Group - Add (Triggering unit) to SpellStealAG
          • Set SpellStealA[SpellStealAC] = (Ability being cast)
          • Set SpellStealAL[SpellStealAC] = (Level of SpellStealA[SpellStealAC] for SpellStealAU[SpellStealAC])
          • Set SpellStealW[SpellStealAC] = (Name of SpellStealA[SpellStealAC])
        • Else - Actions
          • For each (Integer Loop) from 1 to SpellStealAC, do (Actions)
            • Loop - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Triggering unit) Equal to SpellStealAU[Loop]
                • Then - Actions
                  • Set SpellStealA[Loop] = (Ability being cast)
                  • Set SpellStealAL[Loop] = (Level of SpellStealA[Loop] for SpellStealAU[Loop])
                  • Set SpellStealW[Loop] = (Name of SpellStealA[Loop])
                • Else - Actions


2.When using Spell Steal

  • Spell Steal
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Spell Steal
    • Actions
      • -------- This trigger when casting Spell Steal --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Triggering unit) is in SpellGroup) Not equal to True
        • Then - Actions
          • -------- Here we store the unit for multiply uses --------
          • Set SpellNumber = (SpellNumber + 1)
          • Unit Group - Add (Triggering unit) to SpellGroup
          • Set SpellStealUN[SpellNumber] = (Triggering unit)
        • Else - Actions
      • For each (Integer Loop3) from 1 to SpellStealC, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Triggering unit) Equal to SpellStealU[Loop3]
            • Then - Actions
              • -------- Here we delete the units from the last times casted Spell Steal --------
              • Set SpellStealU[Loop3] = No unit
              • Unit - Remove SpellM[Loop3] from the game
              • Set SpellM[Loop3] = No unit
            • Else - Actions
      • -------- Here we increase the count of spell steal used times --------
      • Set SpellStealC = (SpellStealC + 1)
      • Set SpellStealU[SpellStealC] = (Triggering unit)
      • Set SpellStealE[SpellStealC] = False
      • Set SpellStealEnd[SpellStealC] = 0
      • For each (Integer Loop) from 1 to SpellStealAC, do (Actions)
        • Loop - Actions
          • -------- Here we check wich unit the target is to know the spell we want to take --------
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Target unit of ability being cast) Equal to SpellStealAU[Loop]
            • Then - Actions
              • -------- Here we set the spell, its name and its level --------
              • Set SpellA[SpellStealC] = SpellStealA[Loop]
              • Set SpellW[SpellStealC] = SpellStealW[Loop]
              • Set SpellL[SpellStealC] = SpellStealAL[Loop]
              • -------- Here is the text that fly from the target containing the name of the spell --------
              • Floating Text - Create floating text that reads SpellStealW[Loop] above SpellStealAU[Loop] with Z offset 25.00, using font size 12.00, color (30.00%, 30.00%, 100.00%), and 0.00% transparency
              • Set SpellStealTe = (Last created floating text)
              • Floating Text - Set the velocity of SpellStealTe to 25.00 towards 90.00 degrees
              • Floating Text - Change SpellStealTe: Disable permanence
              • Floating Text - Change the fading age of SpellStealTe to 3.00 seconds
              • Floating Text - Change the lifespan of SpellStealTe to 5.00 seconds
              • -------- Here we set the position of the missile that come to you --------
              • Set Point[1] = (Position of (Target unit of ability being cast))
              • Set Point[2] = (Position of (Triggering unit))
              • Unit - Create 1 SpellStealMissile for (Owner of (Triggering unit)) at Point[1] facing ((Angle from Point[1] to Point[2]) + 0.00) degrees
              • Set SpellM[SpellStealC] = (Last created unit)
              • -------- Here we make the unit paused to do nothing and we remove its collison to move freely --------
              • Unit - Turn collision for SpellM[SpellStealC] Off
              • Unit - Pause SpellM[SpellStealC]
              • -------- We must check if the spell you will steal is known --------
              • Set SpellKnown[SpellStealC] = True
              • -------- Here we remove the leaks of the points --------
              • Custom script: call RemoveLocation (udg_Point[1])
              • Custom script: call RemoveLocation (udg_Point[2])
            • Else - Actions
      • For each (Integer Loop2) from 1 to SpellNumber, do (Actions)
        • Loop - Actions
          • -------- Here we check the unit if its the same --------
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • SpellStealU[SpellStealC] Equal to SpellStealUN[Loop2]
            • Then - Actions
              • -------- Here we set the begin timer when start (0 means its not counting) --------
              • Set SpellStealBT[Loop2] = 0
              • -------- Here we set the counter starting (0) --------
              • Set SpellStealT[Loop2] = 0.00
              • -------- Here is the timer end --------
              • Set SpellStealTE[Loop2] = SpellStealD[(Level of Spell Steal for SpellStealU[SpellStealC])]
              • -------- Here we set that the info of warning is not made --------
              • Set SpellStealWarning[Loop2] = 0
              • -------- Here we want to know if the spell taken of the target is the same of your stolen one --------
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • SpellA[SpellStealC] Equal to SpellAN[Loop2]
                • Then - Actions
                  • -------- Here we disable it so we don't remove the cooldown --------
                  • Player - Disable SpellA[SpellStealC] for (Owner of SpellStealU[SpellStealC])
                • Else - Actions
                  • -------- Here we remove the old one if the taken one is new --------
                  • Unit - Remove SpellAN[Loop2] from SpellStealU[SpellStealC]
              • -------- If the spell is unknown we will set the last spell you stole is something passive so you can steal any spell right after you casted the spell this time --------
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • SpellKnown[SpellStealC] Not equal to True
                • Then - Actions
                  • Set SpellAN[Loop2] = Critical Strike
                • Else - Actions
            • Else - Actions


3.When you have the Stolen Spell and moving the dummy missile to you


  • Spell Steal Reach
    • Events
      • Time - Every 0.05 seconds of game time
    • Conditions
    • Actions
      • -------- Here is the loop of the Spell Steal --------
      • For each (Integer Loop) from 1 to SpellStealC, do (Actions)
        • Loop - Actions
          • For each (Integer Loop3) from 1 to SpellNumber, do (Actions)
            • Loop - Actions
              • -------- Here we check the unit if its the same with the loop unit, if the timer bagan and if the timer has ended --------
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • SpellStealU[Loop] Equal to SpellStealUN[Loop3]
                  • SpellStealBT[Loop3] Equal to 1
                  • SpellStealEnd[Loop] Equal to 0
                • Then - Actions
                  • -------- Here if the counter is less than the end --------
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • SpellStealT[Loop3] Less than SpellStealTE[Loop3]
                    • Then - Actions
                      • -------- Here we increase the counter with the same event of the trigger time --------
                      • Set SpellStealT[Loop3] = (SpellStealT[Loop3] + 0.05)
                      • -------- Here we check if the counter have only 20 seconds to end and if the warning is not shown yet --------
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • SpellStealT[Loop3] Greater than or equal to (SpellStealTE[Loop3] - 20.00)
                          • SpellStealWarning[Loop3] Not equal to 1
                        • Then - Actions
                          • Set SpellStealWarning[Loop3] = 1
                          • -------- Here we set the owner of the unit --------
                          • Set SpellStealP = (Player group((Owner of SpellStealU[Loop])))
                          • -------- The warning text --------
                          • Game - Display to SpellStealP for 7.00 seconds the text: |c00FF000020 Second...
                          • -------- Removing leaks --------
                          • Custom script: call DestroyForce (udg_SpellStealP)
                        • Else - Actions
                    • Else - Actions
                      • -------- Here if the counter reached the end --------
                      • -------- We have to stop the counter from counting --------
                      • Set SpellStealBT[Loop3] = 0
                      • -------- Here we set that the end is reached --------
                      • Set SpellStealEnd[Loop] = 1
                      • -------- Here we remove the stolen spell --------
                      • Unit - Remove SpellAN[Loop3] from SpellStealU[Loop]
                      • -------- Here we set the last taken spell is nothing --------
                      • Set SpellAN[Loop3] = (Ability being cast)
                • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (SpellM[Loop] is alive) Equal to True
            • Then - Actions
              • -------- Here we checked that the missile is still didn't reach the unit --------
              • -------- Here we set the points to check if the unit is near the missle --------
              • Set Point[1] = (Position of SpellStealU[Loop])
              • Set Point[2] = (Position of SpellM[Loop])
              • Set Point[3] = (Point[2] offset by 20.00 towards (Angle from Point[2] to Point[1]) degrees)
              • Unit - Move SpellM[Loop] instantly to Point[3]
              • -------- Here is the checking group to know if the unit is near --------
              • Set CheckGroup = (Units within 50.00 of Point[3] matching ((Matching unit) Equal to SpellStealU[Loop]))
              • -------- Here we check if the unit is in the group --------
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (CheckGroup is empty) Not equal to True
                • Then - Actions
                  • -------- Here we remove the missile --------
                  • Unit - Remove SpellM[Loop] from the game
                  • -------- Here is the text that appears when the missile reach the unit containing the name of the stolen spell --------
                  • Floating Text - Create floating text that reads SpellW[Loop] above SpellStealU[Loop] with Z offset 25.00, using font size 12.00, color (30.00%, 30.00%, 100.00%), and 0.00% transparency
                  • Set SpellStealTe = (Last created floating text)
                  • Floating Text - Set the velocity of SpellStealTe to 25.00 towards 90.00 degrees
                  • Floating Text - Change SpellStealTe: Disable permanence
                  • Floating Text - Change the fading age of SpellStealTe to 3.00 seconds
                  • Floating Text - Change the lifespan of SpellStealTe to 5.00 seconds
                  • For each (Integer Loop2) from 1 to SpellNumber, do (Actions)
                    • Loop - Actions
                      • -------- Here we have to check if the unit is the same with the loop unit --------
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • SpellStealU[Loop] Equal to SpellStealUN[Loop2]
                        • Then - Actions
                          • -------- Here we begin the timer up you saw --------
                          • Set SpellStealBT[Loop2] = 1
                          • -------- Here we check if the stolen spell is the same spell with the unit --------
                          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                            • If - Conditions
                              • SpellAN[Loop2] Not equal to SpellA[Loop]
                            • Then - Actions
                              • -------- If not we add the new one --------
                              • Unit - Add SpellA[Loop] to SpellStealU[Loop]
                              • Unit - Set level of SpellA[Loop] for SpellStealU[Loop] to SpellL[Loop]
                              • -------- Here we set this new spell as the last spell the unit stoled --------
                              • Set SpellAN[Loop2] = SpellA[Loop]
                            • Else - Actions
                              • -------- If true we must enable it as we disabled it first --------
                              • Player - Enable SpellA[Loop] for (Owner of SpellStealU[Loop])
                              • -------- And we must set the level of the new one --------
                              • Unit - Set level of SpellA[Loop] for SpellStealU[Loop] to SpellL[Loop]
                        • Else - Actions
                • Else - Actions
              • -------- Here we delete all the leaks --------
              • Custom script: call DestroyGroup (udg_CheckGroup)
              • Custom script: call RemoveLocation (udg_Point[1])
              • Custom script: call RemoveLocation (udg_Point[2])
              • Custom script: call RemoveLocation (udg_Point[3])
            • Else - Actions
Contents

Grand Magus's Spell Steal (Map)

Reviews
12th Dec 2015 IcemanBo: Too long as NeedsFix. Rejected. Rubick the Grand Magus's Spell Steal v1.3 | Reviewed by Maker | 16th Jun 2013 NEEDS FIX The looping trigger should be initially off and turned off when the trigger is not...

Moderator

M

Moderator

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


Rubick the Grand Magus's Spell Steal v1.3 | Reviewed by Maker | 16th Jun 2013
NEEDS FIX


126248-albums6177-picture66522.png


  • The looping trigger should be initially off and turned off
    when the trigger is not needed
  • Improve the spell's descripion, what does it do?
126248-albums6177-picture66523.png


  • The dummy doesn't need invulnerability ability, it has Locust
  • Use Skip remaining actions when you have found the correct
    unit in the loop in spell count trigger
    You could avoid many loops with a hashtable
  • Floating texts are shown though black mask and fog of war,
    you could hide them for players who don't have vision over the
    location
126248-albums6177-picture66524.png
[tr]


20:52, 4th Oct 2012
Magtheridon96: In the Cast trigger, since you stored (Triggering unit) into a variable, there's no point in repeating it over and over again inside the loop.
Also, be sure to store the target unit of the ability being cast into a variable so you don't end up repeating the call over and over again.

By the way, instead of storing the unit-type that will have the Spell Steal ability into a variable, you can simply make your second trigger filter out events when the ability being cast is equal to "Spell Steal".

By the way, you should deny a Spell Steal if the level of the stolen ability for the caster is greater than 0.
Currently, If I had "Fireball" and I stole "Fireball", I'd end up having no "Fireball" after the spell steal duration expires.

Another tip, at the end of the loop in the cast-trigger in which you create the missile (under the custom scripts directly), add this line in Custom script:
exitwhen true

Do the same for the last loop in the cast-trigger because after you reset the ability data, it's going to be pointless to continue looping since you're sure that only one instance may contain data for this unit at most.
 
Level 1
Joined
Nov 12, 2012
Messages
2
There were all these things I say to every spell 6
It was first added to the second
It was a spell of not more that three times

Now what do I do


1 - When the Rubik's Sweetheart spell spell damage they can learn to spell handling time, given that not more than 3 seconds (the time it takes on average three times to spell 6 to 9 seconds) (for which no enemy within Who could ever learn to spell hit)

2 - If the spell and spell it aghanim's scepter will need to upgrade your spell 6 Rubik it



3 - Each time the spell 6 is 3% of your spell's even trying to upgrade a spell that she has learned (even if the spell she had learned aghanim.s scepter need to upgrade again to upgrade another 3%) (Just a note is that every time before it will add 3% to 3%)


4 - when the magic happens around the Rubik's cube was given a hero mortred that could be realized in the near mortred except that half-hidden, but shine the Rubik's stick


This spell no one can teach me how to make or build????
 
Last edited:
Level 1
Joined
Nov 12, 2012
Messages
2
# # # This is the text translate.google. Com is translated # # # # #



There were all these things I say to every spell 6
It was first added to the second
It was a spell of not more that three times

Now what do I do


1 - When the Rubik's Sweetheart spell spell damage they can learn to spell handling time, given that not more than 3 seconds (the time it takes on average three times to spell 6 to 9 seconds) (for which no enemy within Who could ever learn to spell hit)

2 - If the spell and spell it aghanim's scepter will need to upgrade your spell 6 Rubik it



3 - Each time the spell 6 is 3% of your spell's even trying to upgrade a spell that she has learned (even if the spell she had learned aghanim.s scepter need to upgrade again to upgrade another 3%) (Just a note is that every time before it will add 3% to 3%)


4 - when the magic happens around the Rubik's cube was given a hero mortred that could be realized in the near mortred except that half-hidden, but shine the Rubik's stick


This spell no one can teach me how to make or build????
 
Top