• 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.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

[Spell] How to Hero gain mana in melee attacks and spells?

Status
Not open for further replies.

calebelima00

Banned
Level 1
Joined
Sep 17, 2013
Messages
2
I want to create a skill that when my hero attack (auto attack) or when he uses specific skills, he wins mana every attack ... It may be in any unit and any building. Please respond and I thank.
 
Last edited by a moderator:
Be sure NOT to double post, someone will answer when they have a moment.

  • Refund Mana (Spell Cast)
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to (==) Ability1ThatShouldRefundMana
    • Actions
      • Set TempUnit = (Triggering unit)
      • Set TempReal = 5.00 //Amount of Mana it should refund.
      • Unit - Set mana of TempUnit to ((Mana of TempUnit) + TempReal)
I don't recommend the Attacks Trigger as if you spam S, you'll get full mana very quickly. Use a DDS(Damage Detection System), you can search on here to find one.

  • Refund Mana (Attack)
    • Events
      • Unit - A unit Is attacked
    • Conditions
    • Actions
      • Set TempUnit = (Attacking unit)
        • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • (Unit-type of TempUnit) Equal to (==) YourUnitWhoGainsManaOnAttack
          • Then - Actions
            • Set TempReal = 5.00 // Amount to Refund
            • Unit - Set mana of TempUnit to ((Mana of TempUnit) + TempReal)
          • Else - Actions
 
Status
Not open for further replies.
Back
Top