• 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.
  • It's time for the first HD Modeling Contest of 2025. Join the theme discussion for Hive's HD Modeling Contest #7! Click here to post your idea!

Creating Mark of the Wild

Level 4
Joined
Oct 9, 2024
Messages
59
I want to create a skill like Inner Fire capable of being auto-cast but modified, I want it to be a skill that instead of increasing damage and armor increases all the hero's attributes, level 1 increasing the attributes by 3, level 2 by 6 and level 3 increasing by 9, with a duration of 30 seconds and costing 50 mana, as far as I know without using triggers it is not possible to do.
 
Level 28
Joined
Sep 26, 2009
Messages
2,543
Yes, it is not possible. There is no ability in object editor that would add hero stats and be autocast. Triggering such ability is very straightforward, I think the hardest part is actually choosing which autocast ability would serve as a base for your Mark of the Wild ability - reason being that if a unit already has buff from the original autocast ability, then your caster won't autocast the Mark of the Wild on that unit. However it is still possible to manually cast Wild of the Mark on that unit and it will have both buffs.

For example, I've based Mark of the Wild off Bloodlust ability. When potential target already had Bloodlust buff, my hero would not autocast Mark of the Wild on that unit.

So it is important to choose which ability to base your custom ability off in order to minimize this autocast issue.

As for the actual ability:
In object editor:
1. Create your custom autocast ability
  • give it descriptions, custom buff, etc.
  • just make sure it can target only heroes

2. Create an ability based off hero ability Attribute Bonus
  • Set 'Stats - Hero ability' to False
  • make sure that each level has set 'Level N - Data - Hide button' to True
  • This way even if you add the bonus to a unit, the ability button will not be visible.

In trigger editor:
  • Create a variable, I will call it MarkUnitGroup. This variable's Variable Type is 'Unit Group'
  • Create two triggers - one will react to a unit casting the ability and add the hidden attribute bonus. Second trigger will periodically check all units that had the buff and if they no longer have it, it removes the attribute bonus from them.
  • Mark Cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Mark of the Wild
    • Actions
      • Unit - Add Mark of the Wild - Stat Bonus to (Target unit of ability being cast)
      • Unit - Set level of Mark of the Wild - Stat Bonus for (Target unit of ability being cast) to (Level of (Ability being cast) for (Triggering unit))
      • Unit Group - Add (Target unit of ability being cast) to MarkUnitGroup
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Mark Loop <gen> is on) Not equal to True // this is boolean comparison: Trigger - Trigger Is On
        • Then - Actions
          • Trigger - Turn on Mark Loop <gen>
        • Else - Actions
  • Mark Loop
    • Events
      • Time - Every 0.20 seconds of game time
    • Conditions
    • Actions
      • Unit Group - Pick every unit in MarkUnitGroup and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has buff Mark of the Wild ) Not equal to True
            • Then - Actions
              • Unit - Remove Mark of the Wild - Stat Bonus from (Picked unit)
              • Unit Group - Remove (Picked unit) from MarkUnitGroup.
            • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (MarkUnitGroup is empty) Equal to True
        • Then - Actions
          • Trigger - Turn off (This trigger)
        • Else - Actions
 
Top