1. Are you planning to upload your awesome spell or system to Hive? Please review the rules here.
    Dismiss Notice
  2. Join Texturing Contest #30 now in a legendary battle of mythological creatures!
    Dismiss Notice
  3. The Aftermath has been revealed for the 19th Terraining Contest! Be sure to check out the Results and see what came out of it.
    Dismiss Notice
  4. Melee Mapping Contest #3 - Results are out! Congratulate the winners and check plenty of new 4v4 melee maps designed for this competition!
    Dismiss Notice
  5. The winners of our cinematic soundtrack competition have been decided! Step by the Music Contest #11 - Results to check the entries and congratulate the winners!
    Dismiss Notice
  6. Check out the Staff job openings thread.
    Dismiss Notice

Savior's Aura v1.1

Submitted by Empirean
This bundle is marked as approved. It works and satisfies the submission rules.
Hi, this is my first spell and is also my entry for the Zephyr Contest #11. The poll is up so i think its ok to upload it in this section. The spell is very simple i hope its approvable.


Tooltip

Emits an aura that heals nearby allied units whenever the bearer of the aura is attacked. Also allows you to force enemy units within 250 radius to attack you.

Level 1 - Heals nearby units based on 30% of the bearer's strength.
Level 2 - Heals nearby units based on 60% of the bearer's strength.
Level 3 - Heals nearby units based on 90% of the bearer's strength.
Level 4 - Heals nearby units based on 120% of the bearer's strength.

Area of Effect: 500
Units that has this ability will not be healed by this aura.



The Code

  • SaviorAuraTriggerConfiguration
    • Events
      • Time - Elapsed game time is 0.00 seconds
    • Conditions
    • Actions
      • -------- set the ability that will be the basis for the aura --------
      • -------- - --------
      • Set SA_A_PassiveAbility = Savior's Aura (Container)
      • Set SA_A_ActiveAbility = Savior's Aura (Active)
      • -------- - --------
      • -------- set the buff that the ability will emit --------
      • -------- - --------
      • Set SA_BF_Buff = Savior's Aura
      • -------- - --------
      • -------- if set to true, the amount healed will be based on the percentage of strength of the hero --------
      • -------- if set to false, the number will directly heal units --------
      • -------- please note that 20% is 20.00 and not 0.2 --------
      • -------- - --------
      • Set SA_B_UseStat = True
      • -------- - --------
      • Set SA_R_Heal[1] = 30.00
      • Set SA_R_Heal[2] = 60.00
      • Set SA_R_Heal[3] = 90.00
      • Set SA_R_Heal[4] = 120.00
      • -------- - --------
      • -------- special effects configurables --------
      • -------- attachment point --------
      • -------- - --------
      • Set SA_S_Attach = origin
      • -------- - --------
      • -------- special effects attached to unit --------
      • -------- - --------
      • Set SA_S_SFX = Abilities\Spells\Undead\VampiricAura\VampiricAuraTarget.mdl
      • -------- - --------
      • -------- Area of effect of the aura --------
      • -------- - --------
      • Set SA_R_AoE[1] = 500.00
      • Set SA_R_AoE[2] = 500.00
      • Set SA_R_AoE[3] = 500.00
      • Set SA_R_AoE[4] = 500.00
      • -------- - --------
      • -------- list abilities that unlearns all hero skills --------
      • -------- SA_A_Total is the total number of abilities that can unlearn the spell --------
      • -------- - --------
      • Set SA_I_Total = 1
      • -------- - --------
      • Set SA_A_Unlearn[1] = Tome of Retraining
      • -------- - --------
      • -------- Disable spellbook --------
      • -------- - --------
      • For each (Integer SA_I_TempInt) from 1 to 12, do (Actions)
        • Loop - Actions
          • -------- - --------
          • -------- Disable the spellbook --------
          • -------- - --------
          • Player - Disable SA_A_PassiveAbility for (Player(SA_I_TempInt))
      • Custom script: set bj_wantDestroyGroup=true
      • -------- - --------
      • -------- Check if any there are units that already learnt the ability --------
      • -------- - --------
      • Unit Group - Pick every unit in (Units in (Playable map area)) and do (Actions)
        • Loop - Actions
          • -------- - --------
          • -------- add the picked unit into a variable --------
          • -------- - --------
          • Set SA_U_Picked = (Picked unit)
          • -------- - --------
          • -------- Check if the unit has leveled the ability --------
          • -------- - --------
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Level of SA_A_ActiveAbility for SA_U_Picked) Greater than 0
            • Then - Actions
              • -------- - --------
              • -------- add the actual aura to the picked unit --------
              • -------- - --------
              • Unit - Add SA_A_PassiveAbility to SA_U_Picked
            • Else - Actions


  • SaviorAuraEffect
    • Events
      • Game - damageEventTrigger becomes Equal to 1.00
    • Conditions
      • (Level of SA_A_ActiveAbility for target) Greater than 0
      • (source belongs to an enemy of (Owner of target)) Equal to True
    • Actions
      • -------- - --------
      • -------- Set the attacked unit --------
      • -------- - --------
      • Set SA_U_AtkUnit = target
      • -------- - --------
      • -------- Determine the owner of the unit --------
      • -------- - --------
      • Set SA_PL_Player = (Owner of SA_U_AtkUnit)
      • -------- - --------
      • -------- set the level of the ability into a variable --------
      • -------- - --------
      • Set SA_I_Level = (Level of SA_A_ActiveAbility for SA_U_AtkUnit)
      • -------- - --------
      • -------- Checks on what value should be applied on the aura's healing effect --------
      • -------- - --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • SA_B_UseStat Equal to True
        • Then - Actions
          • -------- - --------
          • -------- if this is applied then the heal value is equal to a certain percentage of the attacked unit's strength --------
          • -------- - --------
          • Set SA_R_HealAmt = ((Real((Strength of SA_U_AtkUnit (Include bonuses)))) x (SA_R_Heal[SA_I_Level] x 0.01))
        • Else - Actions
          • -------- - --------
          • -------- if this is applied, then the heal amount is equal to the predefined value in the trigger configuration --------
          • -------- - --------
          • Set SA_R_HealAmt = SA_R_Heal[SA_I_Level]
      • -------- - --------
      • -------- sets the position of the attacked units into a variable --------
      • -------- - --------
      • Set SA_P_AtkPos = (Position of SA_U_AtkUnit)
      • -------- - --------
      • -------- selects the valid units that can be healed --------
      • -------- - --------
      • Set SA_UG_UnitGroup = (Units within SA_R_AoE[SA_I_Level] of SA_P_AtkPos)
      • -------- - --------
      • -------- heals the picked units --------
      • -------- - --------
      • Unit Group - Pick every unit in SA_UG_UnitGroup and do (Actions)
        • Loop - Actions
          • Set SA_U_Picked = (Picked unit)
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (SA_U_Picked is dead) Equal to False
              • (SA_U_Picked belongs to an ally of SA_PL_Player) Equal to True
              • (SA_U_Picked is A structure) Equal to False
              • (SA_U_Picked is Magic Immune) Equal to False
              • (SA_U_Picked has buff SA_BF_Buff) Equal to True
              • (Level of SA_A_PassiveAbility for SA_U_Picked) Less than 1
            • Then - Actions
              • -------- - --------
              • -------- sets the picked unit into a variable --------
              • -------- its ok to recycle this variable isn't it? --------
              • -------- - --------
              • -------- - --------
              • -------- Heals the picked unit --------
              • -------- - --------
              • Unit - Set life of SA_U_Picked to ((Life of SA_U_Picked) + SA_R_HealAmt)
              • -------- - --------
              • -------- Add some visuals --------
              • -------- - --------
              • Special Effect - Create a special effect attached to the SA_S_Attach of SA_U_Picked using SA_S_SFX
              • -------- - --------
              • -------- destroy visuals to prevent leaks --------
              • -------- - --------
              • Special Effect - Destroy (Last created special effect)
            • Else - Actions
          • Set SA_U_Picked = No unit
      • -------- - --------
      • -------- Clean up --------
      • -------- - --------
      • -------- SA_UG_UnitGroup.Clear(); --------
      • -------- Clear the unit group --------
      • -------- - --------
      • Unit Group - Remove all units from SA_UG_UnitGroup
      • -------- - --------
      • -------- Destroy the instance of the unit group --------
      • -------- - --------
      • Custom script: call DestroyGroup(udg_SA_UG_UnitGroup)
      • -------- - --------
      • -------- Destroy the point --------
      • -------- - --------
      • Custom script: call RemoveLocation(udg_SA_P_AtkPos)



credits

Dat-C3 - for adding damage detection and for helping on a lot of stuff.
looking_for_help aka eey - for his damage detection system.


Keywords:
holy,passive,savior,aura,human,heal
Contents

Savior's Aura (Map)

Reviews
Moderator
19:33, 9th Jan 2015 IcemanBo: Simple concept. Code works fine. Approved. http://www.hiveworkshop.com/forums/spells-569/saviors-aura-v1-1-a-256071/index2.html#post2638132
  1. Mythic

    Mythic

    Joined:
    Apr 24, 2012
    Messages:
    7,531
    Resources:
    45
    Models:
    32
    Icons:
    2
    Maps:
    3
    Spells:
    6
    Tutorials:
    2
    Resources:
    45
    This entry is rather simple, but awesome. :3
     
  2. Empirean

    Empirean

    Joined:
    Jun 20, 2014
    Messages:
    385
    Resources:
    8
    Spells:
    8
    Resources:
    8
    thanks you cakemaster
     
  3. Dat-C3

    Dat-C3

    Joined:
    Mar 15, 2012
    Messages:
    2,453
    Resources:
    10
    Models:
    1
    Maps:
    5
    Spells:
    3
    Tutorials:
    1
    Resources:
    10
    You already got my vote. =)
     
  4. Empirean

    Empirean

    Joined:
    Jun 20, 2014
    Messages:
    385
    Resources:
    8
    Spells:
    8
    Resources:
    8
    Thank you Dat-C3
     
  5. mogulkhan1Axe

    mogulkhan1Axe

    Joined:
    Nov 9, 2011
    Messages:
    268
    Resources:
    2
    Spells:
    2
    Resources:
    2
    Very Nice dude 5/5 very cool spell keep it coming!!

    :thumbs_up::thumbs_up::thumbs_up::thumbs_up::thumbs_up:
     
  6. Empirean

    Empirean

    Joined:
    Jun 20, 2014
    Messages:
    385
    Resources:
    8
    Spells:
    8
    Resources:
    8
    Thank you mogulkhan1Axe
     
  7. Dat-C3

    Dat-C3

    Joined:
    Mar 15, 2012
    Messages:
    2,453
    Resources:
    10
    Models:
    1
    Maps:
    5
    Spells:
    3
    Tutorials:
    1
    Resources:
    10
    I figured while I am at it fixing your other spell, I hope you don't mind if I help you here as well. :thumbs_up:

    Was it your intention so whenever a unit is about to hit a unit under this aura that it triggers? I think its better if they were damaged first then start it because someone can spam stop and force your triggers to run even though no damage was taken at all. A nasty bug with unit is attacked since it catches the unit "as" it is attacking and not when it actually attacked.

    Damage Detection systems fix this bug
     
  8. Empirean

    Empirean

    Joined:
    Jun 20, 2014
    Messages:
    385
    Resources:
    8
    Spells:
    8
    Resources:
    8
    if u do that its actually ur disadvantage since the spell is only triggered when attacked by enemy unit. but yeah a DDS will surely fix it.
     
  9. Dat-C3

    Dat-C3

    Joined:
    Mar 15, 2012
    Messages:
    2,453
    Resources:
    10
    Models:
    1
    Maps:
    5
    Spells:
    3
    Tutorials:
    1
    Resources:
    10
    Accidents happen and sometimes the unit might attack twice just for targeting purposes or stuns.

    Like I said about that example, here it is.

    • Events
    • Conditions
    • Actions
    • Set SA_UG_UnitGroup = (Units within SA_R_AoE[SA_I_Level] of SA_P_AtkPos)
    • -------- heals the picked units --------
    • Unit Group - Pick every unit in SA_UG_UnitGroup and do (Actions)
      • Loop - Actions
        • Set SA_U_Picked = (Picked unit)
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • (SA_U_Picked is dead) Equal to False
            • (SA_U_Picked belongs to an ally of SA_PL_Player) Equal to True
            • (SA_U_Picked is A structure) Equal to False
            • (SA_U_Picked is Magic Immune) Equal to False
            • (SA_U_Picked has buff SA_BF_Buff) Equal to True
            • (Level of SA_A_PassiveAbility for SA_U_Picked) Less than 1
          • Then - Actions
            • -------- - --------
            • -------- sets the picked unit into a variable --------
            • -------- its ok to recycle this variable isn't it? --------
            • -------- - --------
            • -------- - --------
            • -------- Heals the picked unit --------
            • -------- - --------
            • Unit - Set life of SA_U_Picked to ((Life of SA_U_Picked) + SA_R_HealAmt)
            • -------- - --------
            • -------- Add some visuals --------
            • -------- - --------
            • Special Effect - Create a special effect attached to the SA_S_Attach of SA_U_Picked using SA_S_SFX
            • -------- - --------
            • -------- destroy visuals to prevent leaks --------
            • -------- - --------
            • Special Effect - Destroy (Last created special effect)
          • Else - Actions
        • Set SA_U_Picked = No unit


    I have also uploaded the fixed version of your aura if you'd or anyone else would like it.
     

    Attached Files:

  10. Empirean

    Empirean

    Joined:
    Jun 20, 2014
    Messages:
    385
    Resources:
    8
    Spells:
    8
    Resources:
    8
    oh... i see that's thats how to create a flexible unit group. thanks for showing me this. i haven't read the DDS and i feel very sleepy. ill upload ur version of the spell. thanks alot
     
  11. Dat-C3

    Dat-C3

    Joined:
    Mar 15, 2012
    Messages:
    2,453
    Resources:
    10
    Models:
    1
    Maps:
    5
    Spells:
    3
    Tutorials:
    1
    Resources:
    10
    As always SallyAnna... Glad to be of help. =)
     
  12. Empirean

    Empirean

    Joined:
    Jun 20, 2014
    Messages:
    385
    Resources:
    8
    Spells:
    8
    Resources:
    8
    Thanks alot, this should be approvable? no?
     
  13. Mythic

    Mythic

    Joined:
    Apr 24, 2012
    Messages:
    7,531
    Resources:
    45
    Models:
    32
    Icons:
    2
    Maps:
    3
    Spells:
    6
    Tutorials:
    2
    Resources:
    45
    Don't forget DestroyGroup in case.
     
  14. Empirean

    Empirean

    Joined:
    Jun 20, 2014
    Messages:
    385
    Resources:
    8
    Spells:
    8
    Resources:
    8
    this one? ->
    • Custom script: call DestroyGroup(udg_SA_UG_UnitGroup)
     
  15. Dat-C3

    Dat-C3

    Joined:
    Mar 15, 2012
    Messages:
    2,453
    Resources:
    10
    Models:
    1
    Maps:
    5
    Spells:
    3
    Tutorials:
    1
    Resources:
    10
    Code to copy
    • SaviorAuraEffect
      • Events
        • Game - damageEventTrigger becomes Equal to 1.00
      • Conditions
        • (Level of SA_A_ActiveAbility for target) Greater than 0
        • (source belongs to an enemy of (Owner of target)) Equal to True
      • Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • damageType Equal to PHYSICAL
          • Then - Actions
            • -------- Actions for PHYSICAL damage --------
            • -------- - --------
            • -------- Set the attacked unit --------
            • -------- - --------
            • Set SA_U_AtkUnit = target
            • -------- - --------
            • -------- Determine the owner of the unit --------
            • -------- - --------
            • Set SA_PL_Player = (Owner of SA_U_AtkUnit)
            • -------- - --------
            • -------- set the level of the ability into a variable --------
            • -------- - --------
            • Set SA_I_Level = (Level of SA_A_ActiveAbility for SA_U_AtkUnit)
            • -------- - --------
            • -------- Checks on what value should be applied on the aura's healing effect --------
            • -------- - --------
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • SA_B_UseStat Equal to True
              • Then - Actions
                • -------- - --------
                • -------- if this is applied then the heal value is equal to a certain percentage of the attacked unit's strength --------
                • -------- - --------
                • Set SA_R_HealAmt = ((Real((Strength of SA_U_AtkUnit (Include bonuses)))) x (SA_R_Heal[SA_I_Level] x 0.01))
              • Else - Actions
                • -------- - --------
                • -------- if this is applied, then the heal amount is equal to the predefined value in the trigger configuration --------
                • -------- - --------
                • Set SA_R_HealAmt = SA_R_Heal[SA_I_Level]
            • -------- - --------
            • -------- sets the position of the attacked units into a variable --------
            • -------- - --------
            • Set SA_P_AtkPos = (Position of SA_U_AtkUnit)
            • -------- - --------
            • -------- selects the valid units that can be healed --------
            • -------- - --------
            • Set SA_UG_UnitGroup = (Units within SA_R_AoE[SA_I_Level] of SA_P_AtkPos)
            • -------- - --------
            • -------- heals the picked units --------
            • -------- - --------
            • Unit Group - Pick every unit in SA_UG_UnitGroup and do (Actions)
              • Loop - Actions
                • Set SA_U_Picked = (Picked unit)
                • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  • If - Conditions
                    • (SA_U_Picked is dead) Equal to False
                    • (SA_U_Picked belongs to an ally of SA_PL_Player) Equal to True
                    • (SA_U_Picked is A structure) Equal to False
                    • (SA_U_Picked is Magic Immune) Equal to False
                    • (SA_U_Picked has buff SA_BF_Buff) Equal to True
                    • (Level of SA_A_PassiveAbility for SA_U_Picked) Less than 1
                  • Then - Actions
                    • -------- - --------
                    • -------- sets the picked unit into a variable --------
                    • -------- its ok to recycle this variable isn't it? --------
                    • -------- - --------
                    • -------- - --------
                    • -------- Heals the picked unit --------
                    • -------- - --------
                    • Unit - Set life of SA_U_Picked to ((Life of SA_U_Picked) + SA_R_HealAmt)
                    • -------- - --------
                    • -------- Add some visuals --------
                    • -------- - --------
                    • Special Effect - Create a special effect attached to the SA_S_Attach of SA_U_Picked using SA_S_SFX
                    • -------- - --------
                    • -------- destroy visuals to prevent leaks --------
                    • -------- - --------
                    • Special Effect - Destroy (Last created special effect)
                  • Else - Actions
                • Set SA_U_Picked = No unit
            • -------- - --------
            • -------- Clean up --------
            • -------- - --------
            • -------- SA_UG_UnitGroup.Clear(); --------
            • -------- Clear the unit group --------
            • -------- - --------
            • Unit Group - Remove all units from SA_UG_UnitGroup
            • -------- - --------
            • -------- Destroy the instance of the unit group --------
            • -------- - --------
            • Custom script: call DestroyGroup(udg_SA_UG_UnitGroup)
            • -------- - --------
            • -------- Destroy the point --------
            • -------- - --------
            • Custom script: call RemoveLocation(udg_SA_P_AtkPos)
            • -------- End of Actions for PHYISCAL damage --------
          • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • damageType Equal to SPELL
              • Then - Actions
                • -------- Actions for SPELL damage --------
                • -------- End of Actions for SPELL damage --------
              • Else - Actions
                • -------- Actions for CODE damage --------
                • -------- End of Actions for CODE damage --------


    Shouldn't double-run now.
     

    Attached Files:

  16. Empirean

    Empirean

    Joined:
    Jun 20, 2014
    Messages:
    385
    Resources:
    8
    Spells:
    8
    Resources:
    8
    its ok now Dat-C3
     
  17. Quilnez

    Quilnez

    Joined:
    Oct 12, 2011
    Messages:
    3,180
    Resources:
    37
    Icons:
    2
    Tools:
    1
    Maps:
    7
    Spells:
    21
    Tutorials:
    2
    JASS:
    4
    Resources:
    37
    Review emerges!

    Trigger:

      • Time - Elapsed game time is 0.00 seconds

      Personally, I would prefer to follow the convention to preload everything at the loading screen:
      • Map initialization

      • Set SA_U_AtkUnit = target

      I think you can just use variable target.

      • Unit Group - Remove all units from SA_UG_UnitGroup

      Unneeded because you are destroying the group afterwards.

      • SaviorAuraLearn
        • Events
          • Unit - A unit Learns a skill
        • Conditions
          • (Level of SA_A_ActiveAbility for (Triggering unit)) Greater than (>) 0
          • (Learned Hero Skill) Equal to (==) Savior's Aura (Active)
        • Actions
          • ...


      =>

      • SaviorAuraLearn
        • Events
          • Unit - A unit Learns a skill
        • Conditions
          • (Level of SA_A_ActiveAbility for (Triggering unit)) Equal to (==) 1
          • (Learned Hero Skill) Equal to (==) SA_A_ActiveAbility
        • Actions
          • ...

      Check the condition.

    Object datas & miscs:
    • I don't get how this ability can even be categorized as an "aura". This doesn't directly affect units around the Hero, doesn't give any buff/effect to those units. This is more like a just another passive ability. Not being harsh, but I will disqualify this entry if I was a judge there.
      But actually, that's not a matter for now.
    • This ability is way too overpowered. You should add something like a chance for the effect to be triggered. As example, Hero has 5% to heal nearby allies when attacked.
      I believe this is one big minus to your score in the contest.
    • Using two additional dummy abilities (passive and disabled spellbook) is a neat method how to add buff to all units around easily. Nice one!
    • There is nothing wrong with object datas

    Rating:
    I don't think the concept is that outstanding. But I like your clean coding style, and it's rather flawless. It's MUI, leakless, and well-coded with some neat additional tricks to avoid extra bunch of codes.

    3/5 for now and vote for Approved
     
  18. Mythic

    Mythic

    Joined:
    Apr 24, 2012
    Messages:
    7,531
    Resources:
    45
    Models:
    32
    Icons:
    2
    Maps:
    3
    Spells:
    6
    Tutorials:
    2
    Resources:
    45
    But the condition being == 1 will block out the skill on levels 2-4.