Mana Burst v1.0

This bundle is marked as useful / simple. Simplicity is bliss, low effort and/or may contain minor bugs.
Hi this is my 3rd MUI spell here in Hive's ! :)

Description:
Hero use his stored energy after a few moment he release it and throw it to his target and deals magic damage. Damage base on his max mana.

Level 1 - 50+10% of his max mana as magic damage.
Level 2 - 75+20% of his max mana as magic damage.
Level 3 - 100+30% of his max mana as magic damage.
Level 4 - 125+40% of his max mana as magic damage.



  • Mana Burst Init
    • Events
      • Map initialization
    • Conditions
    • Actions
      • -------- -------------------------------- --------
      • -------- CONFIGURATIONS --------
      • -------- -------------------------------- --------
      • -------- The Ability we will use --------
      • Set MB_Ability = Mana Burst
      • -------- -------------------------------- --------
      • -------- How Much Percentage we will get on Max mana of the Caster --------
      • -------- 0.10 = 10% 0.20 = 20% so on --------
      • Set MB_Percentage[1] = 0.10
      • Set MB_Percentage[2] = 0.20
      • Set MB_Percentage[3] = 0.30
      • Set MB_Percentage[4] = 0.40
      • -------- -------------------------------- --------
      • -------- Here we set the base damage of the spell. --------
      • Set MB_BaseDamage[1] = 50.00
      • Set MB_BaseDamage[2] = 75.00
      • Set MB_BaseDamage[3] = 100.00
      • Set MB_BaseDamage[4] = 125.00
      • -------- -------------------------------- --------
      • -------- How fast the missile moving --------
      • Set MB_Speed = 25.00
      • -------- -------------------------------- --------
      • -------- Set false if you dont want to see the damage. --------
      • Set MB_FloatingText = True
      • -------- -------------------------------- --------
      • -------- The special effect when spell end. --------
      • Set MB_SpecialEffects = Abilities\Spells\Other\Charm\CharmTarget.mdl
      • -------- -------------------------------- --------
      • -------- Where we attach the special effect --------
      • Set MB_SpecialEffectsAttachment = origin
      • -------- -------------------------------- --------
      • -------- Area of Effect of the spell --------
      • Set MB_AoE = 500.00
      • -------- -------------------------------- --------
      • -------- Set true if the target is alive --------
      • Set MB_Alive = True
      • -------- -------------------------------- --------
      • -------- Set false if the target is not a structure/building --------
      • Set MB_Structures = False
      • -------- -------------------------------- --------
      • -------- Set if the target is enemy of the caster --------
      • Set MB_Enemies = True
      • -------- -------------------------------- --------
      • -------- We set the Unit type of the missile. --------
      • Set MB_DummyType = MB_Dummy
      • -------- END OF CONFIGURATION. --------
      • -------- -------------------------------- --------
      • -------- -------------------------------- --------
      • -------- -------------------------------- --------
      • -------- DONT TOUCH THIS :) --------
      • Trigger - Add to Mana Burst Loop <gen> the event (Time - Every 0.03 seconds of game time)
      • -------- DONT TOUCH THIS :) --------
      • -------- -------------------------------- --------

  • Mana Burst
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to MB_Ability
    • Actions
      • Set MB_Index = (MB_Index + 1)
      • Set MB_Caster[MB_Index] = (Triggering unit)
      • Set MB_Target[MB_Index] = (Target unit of ability being cast)
      • Set MB_CasterPoint[MB_Index] = (Position of MB_Caster[MB_Index])
      • Set MB_TargetPoint[MB_Index] = (Position of MB_Target[MB_Index])
      • Set MB_AbilityLevel[MB_Index] = (Level of MB_Ability for MB_Caster[MB_Index])
      • Set MB_Caster2[MB_Index] = (Triggering player)
      • Unit - Create 1 MB_DummyType for MB_Caster2[MB_Index] at MB_CasterPoint[MB_Index] facing (Facing of MB_Caster[MB_Index]) degrees
      • Set MB_Dummy[MB_Index] = (Last created unit)
      • Set MB_DummyPoint[MB_Index] = (Position of MB_Dummy[MB_Index])
      • Custom script: call RemoveLocation(udg_MB_CasterPoint[udg_MB_Index])
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • MB_Index Equal to 1
        • Then - Actions
          • Trigger - Turn on Mana Burst Loop <gen>
        • Else - Actions

  • Mana Burst Loop
    • Events
    • Conditions
    • Actions
      • For each (Integer MB_Integer) from 1 to MB_Index, do (Actions)
        • Loop - Actions
          • Set MB_DummyPoint[MB_Integer] = (Position of MB_Dummy[MB_Integer])
          • Set MB_TargetPoint[MB_Integer] = (Position of MB_Target[MB_Integer])
          • Set MB_TempPoint[MB_Integer] = (MB_DummyPoint[MB_Integer] offset by MB_Speed towards (Angle from MB_DummyPoint[MB_Integer] to MB_TargetPoint[MB_Integer]) degrees)
          • Set MB_FinalDamage[MB_Integer] = (MB_BaseDamage[MB_AbilityLevel[MB_Integer]] + ((Max mana of MB_Caster[MB_Integer]) x (MB_Percentage[MB_Integer] x (Real(MB_AbilityLevel[MB_Integer])))))
          • Unit - Move MB_Dummy[MB_Integer] instantly to MB_TempPoint[MB_Integer]
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Distance between MB_DummyPoint[MB_Integer] and MB_TargetPoint[MB_Integer]) Less than or equal to 75.00
            • Then - Actions
              • Set MB_TargetGroups[MB_Integer] = (Units within MB_AoE of MB_TargetPoint[MB_Integer])
              • Unit Group - Pick every unit in MB_TargetGroups[MB_Integer] and do (Actions)
                • Loop - Actions
                  • Set MB_PickedUnits[MB_Integer] = (Picked unit)
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • (MB_PickedUnits[MB_Integer] is A structure) Equal to MB_Structures
                      • (MB_PickedUnits[MB_Integer] is alive) Equal to MB_Alive
                      • (MB_PickedUnits[MB_Integer] belongs to an enemy of MB_Caster2[MB_Integer]) Equal to MB_Enemies
                    • Then - Actions
                      • Unit - Cause MB_Caster[MB_Integer] to damage MB_PickedUnits[MB_Integer], dealing MB_FinalDamage[MB_Integer] damage of attack type Spells and damage type Normal
                      • Special Effect - Create a special effect attached to the MB_SpecialEffectsAttachment of MB_PickedUnits[MB_Integer] using MB_SpecialEffects
                      • Special Effect - Destroy (Last created special effect)
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • MB_FloatingText Equal to True
                        • Then - Actions
                          • Floating Text - Create floating text that reads ((String(MB_FinalDamage[MB_Integer])) + Damage!) above MB_PickedUnits[MB_Integer] with Z offset 0.00, using font size 15.00, color (0.00%, 0.00%, 100.00%), and 0.00% transparency
                          • Floating Text - Set the velocity of (Last created floating text) to 64.00 towards 90.00 degrees
                          • Floating Text - Change (Last created floating text): Disable permanence
                          • Floating Text - Change the lifespan of (Last created floating text) to 5.00 seconds
                          • Floating Text - Change the fading age of (Last created floating text) to 4.00 seconds
                        • Else - Actions
                    • Else - Actions
                  • Set MB_PickedUnits[MB_Integer] = No unit
              • Custom script: call DestroyGroup(udg_MB_TargetGroups[udg_MB_Integer])
              • Unit - Remove MB_Dummy[MB_Integer] from the game
              • Custom script: call RemoveLocation(udg_MB_DummyPoint[udg_MB_Integer])
              • Custom script: call RemoveLocation(udg_MB_TargetPoint[udg_MB_Integer])
              • Custom script: call RemoveLocation(udg_MB_TempPoint[udg_MB_Integer])
              • Set MB_Caster[MB_Integer] = MB_Caster[MB_Index]
              • Set MB_CasterPoint[MB_Integer] = MB_CasterPoint[MB_Index]
              • Set MB_Dummy[MB_Integer] = MB_Dummy[MB_Index]
              • Set MB_DummyPoint[MB_Integer] = MB_DummyPoint[MB_Index]
              • Set MB_Target[MB_Integer] = MB_Target[MB_Index]
              • Set MB_TargetPoint[MB_Integer] = MB_TargetPoint[MB_Index]
              • Set MB_TempPoint[MB_Integer] = MB_TempPoint[MB_Index]
              • Set MB_AbilityLevel[MB_Integer] = MB_AbilityLevel[MB_Index]
              • Set MB_FinalDamage[MB_Integer] = MB_FinalDamage[MB_Index]
              • Set MB_PickedUnits[MB_Integer] = MB_PickedUnits[MB_Index]
              • Set MB_Caster2[MB_Integer] = MB_Caster2[MB_Index]
              • Set MB_Index = (MB_Index - 1)
              • Set MB_Integer = (MB_Integer - 1)
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • MB_Index Equal to 0
                • Then - Actions
                  • Trigger - Turn off (This trigger)
                • Else - Actions
            • Else - Actions
Keywords:
IamDL, Mana,Burst,Mana Burst
Contents

Just another Warcraft III map (Map)

Reviews
12th Dec 2015 IcemanBo: For long time as NeedsFix. Rejected. 04:23, 24th Jan 2015 IcemanBo: http://www.hiveworkshop.com/forums/spells-569/mana-burst-v1-0-a-260220/#post2644015
Level 13
Joined
Jul 16, 2012
Messages
680
good...

but you forgot to save the picked unit in Unit Group
if you done, just null it

  • Unit - Create 1 MB_DummyType for (Owner of MB_Caster[MB_Index]) at MB_CasterPoint[MB_Index] facing (Facing of MB_Caster[MB_Index]) degrees
Instead using Owner of Caster, should be use Triggering Player ^^

remove this...
  • Set MB_Caster[MB_Integer] = No unit
  • Set MB_Dummy[MB_Integer] = No unit
dont null it
 
Level 7
Joined
Mar 6, 2014
Messages
203
good...

but you forgot to save the picked unit in Unit Group
if you done, just null it

  • Unit - Create 1 MB_DummyType for (Owner of MB_Caster[MB_Index]) at MB_CasterPoint[MB_Index] facing (Facing of MB_Caster[MB_Index]) degrees
Instead using Owner of Caster, should be use Triggering Player ^^

remove this...
  • Set MB_Caster[MB_Integer] = No unit
  • Set MB_Dummy[MB_Integer] = No unit
dont null it

Thx ill update ASAP :)

Edit: Updated!
 
Level 13
Joined
Jul 16, 2012
Messages
680
  • Set MB_TargetGroups[MB_Integer] = (Units within MB_AoE of MB_TargetPoint[MB_Integer] matching ((((Matching unit) is A structure) Equal to MB_Structures) and ((((Matching unit) is alive) Equal to MB_Alive) and (((Matching unit) belongs to an enemy of (Owner of MB_Caster[MB_Integer])) Equal to
9.9 so long..... put it in ITE those conditions...


  • Set MB_PickedUnits[MB_Integer] = No unit
->
  • Unit Group - Pick every unit in MB_TargetGroups[MB_Integer] and do (Actions)
    • Loop - Actions
      • Set MB_PickedUnits[MB_Integer] = (Picked unit)
        • Unit - Cause MB_Caster[MB_Integer] to damage MB_PickedUnits[MB_Integer], dealing MB_FinalDamage[MB_Integer] damage of attack type Spells and damage type Normal
        • Special Effect - Create a special effect attached to the MB_SpecialEffectsAttachment of (Picked unit) using MB_SpecialEffects
        • Special Effect - Destroy (Last created special effect)
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • MB_FloatingText Equal to True
        • Then - Actions
          • Floating Text - Create floating text that reads ((String(MB_FinalDamage[MB_Integer])) + Damage!) above (Picked unit) with Z offset 0.00, using font size 15.00, color (0.00%, 0.00%, 100.00%), and 0.00% transparency
          • Floating Text - Set the velocity of (Last created floating text) to 64.00 towards 90.00 degrees
          • Floating Text - Change (Last created floating text): Disable permanence
          • Floating Text - Change the lifespan of (Last created floating text) to 5.00 seconds
          • Floating Text - Change the fading age of (Last created floating text) to 4.00 seconds
        • Set MB_PickedUnits[MB_Integer] = No unit
and last...
the TriggeringPlayer must be put it in a variable ^^ sorry i forgot...
 
Last edited:
Level 7
Joined
Mar 6, 2014
Messages
203
  • Set MB_TargetGroups[MB_Integer] = (Units within MB_AoE of MB_TargetPoint[MB_Integer] matching ((((Matching unit) is A structure) Equal to MB_Structures) and ((((Matching unit) is alive) Equal to MB_Alive) and (((Matching unit) belongs to an enemy of (Owner of MB_Caster[MB_Integer])) Equal to
9.9 so long..... put it in ITE those conditions...

  • Set MB_PickedUnits[MB_Integer] = No unit
->
  • Unit Group - Pick every unit in MB_TargetGroups[MB_Integer] and do (Actions)
    • Loop - Actions
      • Set MB_PickedUnits[MB_Integer] = (Picked unit)
        • Unit - Cause MB_Caster[MB_Integer] to damage MB_PickedUnits[MB_Integer], dealing MB_FinalDamage[MB_Integer] damage of attack type Spells and damage type Normal
        • Special Effect - Create a special effect attached to the MB_SpecialEffectsAttachment of (Picked unit) using MB_SpecialEffects
        • Special Effect - Destroy (Last created special effect)
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • MB_FloatingText Equal to True
        • Then - Actions
          • Floating Text - Create floating text that reads ((String(MB_FinalDamage[MB_Integer])) + Damage!) above (Picked unit) with Z offset 0.00, using font size 15.00, color (0.00%, 0.00%, 100.00%), and 0.00% transparency
          • Floating Text - Set the velocity of (Last created floating text) to 64.00 towards 90.00 degrees
          • Floating Text - Change (Last created floating text): Disable permanence
          • Floating Text - Change the lifespan of (Last created floating text) to 5.00 seconds
          • Floating Text - Change the fading age of (Last created floating text) to 4.00 seconds
        • Set MB_PickedUnits[MB_Integer] = No unit
and last...
the TriggeringPlayer must be put it in a variable ^^ sorry i forgot...


Updated!
 
Level 13
Joined
Jul 16, 2012
Messages
680
you miss this... those Picked unit
  • Special Effect - Create a special effect attached to the MB_SpecialEffectsAttachment of (Picked unit) using MB_SpecialEffects
  • Floating Text - Create floating text that reads ((String(MB_FinalDamage[MB_Integer])) + Damage!) above (Picked unit) with Z offset 0.00, using font size 15.00, color (0.00%, 0.00%, 100.00%), and 0.00% transparency
 
Level 7
Joined
Mar 6, 2014
Messages
203
you miss this... those Picked unit
  • Special Effect - Create a special effect attached to the MB_SpecialEffectsAttachment of (Picked unit) using MB_SpecialEffects
  • Floating Text - Create floating text that reads ((String(MB_FinalDamage[MB_Integer])) + Damage!) above (Picked unit) with Z offset 0.00, using font size 15.00, color (0.00%, 0.00%, 100.00%), and 0.00% transparency

Updated again -.-" hope there's nothing wrong with that
 
Level 9
Joined
Feb 15, 2013
Messages
372
A suggestion, how about current mana instead? :p.

Yeah, i agree. If max mana the damage will be very high ._.
If the unit have 2000 mana, and 125 + 40% is 925 damage
And if you uses as 10/20/30/40% of current mana will be lesser damage. In the same time, you can also set the percentage higher :)
Don't need to care me, im just continue the suggestions of Mythic :/
 
Please add import instructions.

All your point variables do not need to be array.


  • (Distance between MB_DummyPoint[MB_Integer] and MB_TargetPoint[MB_Integer]) < 75.00
->
  • (Distance between MB_DummyPoint[MB_Integer] and MB_TargetPoint[MB_Integer]) < MB_Speed

  • Set MB_Caster2[]
^That's an inproper name for a player variable.

All points don't need to be indexed, nor deindex.

"PickedUnits" is just a temp unit variable. No array needed. No deindexing needed.

No need to index the temp unit group.

Only use variables with array if really needed!

The final damage only needs to be calculated once, not each iteration. It can be directly be done onCast, as it would make most sense I think.

  • -------- Set true if the target is alive --------
  • Set MB_Alive = True
The target is always alive onCast. It more means, that the spell will cancel if target dies.
 
Top