• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

How to create flexible aura in one spell

Status
Not open for further replies.
Level 11
Joined
Jul 17, 2013
Messages
544
Hi i want unit to have 1 aura spell but this aura should have like 3 modes for e.g offensive mode gives +10 dmg to nearby units and player can click button to switch it to defensive aura +3 armor or can aswell click it again to switch it to +10% attack speed aura. how can i do that? what should i base my spell on and what should i do at triggers
 
Level 20
Joined
Jul 10, 2009
Messages
479
Easiest way would be to show two abilities on the hero. One active aura and another ability to toggle the auras.
I recommend that, because it requires the least mapping knowledge.

You would have to:
1. Create separate abilities for all desired auras in the object editor (based on trueshot aura/ devotion aura/ Unholy aura to achieve your desired effects)
2. Create an ability without effect in the obejct editor, which will function as Aura Toggler (e.g. Dummy ability based on the spell "Channel")
3. Create a trigger that removes the current aura from a unit and adds the next aura, whenever the Toggle ability is used.

You might have to give the toggle ability a cooldown to prevent aura stacking due to an aura buff removing delay (not sure about that).
 
Level 11
Joined
Jul 17, 2013
Messages
544
Easiest way would be to show two abilities on the hero. One active aura and another ability to toggle the auras.
I recommend that, because it requires the least mapping knowledge.

You would have to:
1. Create separate abilities for all desired auras in the object editor (based on trueshot aura/ devotion aura/ Unholy aura to achieve your desired effects)
2. Create an ability without effect in the obejct editor, which will function as Aura Toggler (e.g. Dummy ability based on the spell "Channel")
3. Create a trigger that removes the current aura from a unit and adds the next aura, whenever the Toggle ability is used.

You might have to give the toggle ability a cooldown to prevent aura stacking due to an aura buff removing delay (not sure about that).
sounds easy so far, but the number 3 might be a bit problematic for me how to excatly trigger the abilities to be removed in order? like it removes attack aura then adds defend then when player clicks again it removes defend and adds speed aura. then speed is removed and attack is added
 
Level 20
Joined
Jul 10, 2009
Messages
479
You can check, which aura the unit currently has, by looking at the ability level. If a unit doesn't have an ability, then the level for that ability on the unit is 0. Otherwise it's 1 or higher.

Your trigger would look like this:

  • Aura Toggle
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to <Your toggle ability>
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Level of <Aura1> for (Triggering unit)) Greater or Equal to 1
        • Then - Actions
          • Unit - Remove <Aura1> from (Triggering unit)
          • Unit - Add <Aura2> to (Triggering unit)
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Level of <Aura2> for (Triggering unit)) Greater or Equal to 1
            • Then - Actions
              • Unit - Remove <Aura2> from (Triggering unit)
              • Unit - Add <Aura3> to (Triggering unit)
            • Else - Actions
              • Unit - Remove <Aura3> from (Triggering unit)
              • Unit - Add <Aura1> to (Triggering unit)
 
Status
Not open for further replies.
Top