• 🏆 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!

[Trigger] Custom Aura Trigger

Status
Not open for further replies.
Level 2
Joined
Mar 11, 2008
Messages
6
I am working on a custom aura using triggers and I just can't seem to figure out why one part doesn't work.

  • Events
    • Unit - A unit Learns a skill
  • Conditions
    • (Learned Hero Skill) Equal to Force Aura 1
    • ((Triggering unit) is A Hero) Equal to True
  • Actions
    • Unit - Add Force Aura Stamina 1 to (Triggering unit)
    • Unit - Add Force Aura Speed 1 to (Triggering unit)
    • Unit - Add Force Aura Power 1 to (Triggering unit)
    • Unit - Add Force Aura Constitution 1 to (Triggering unit)
    • Hero - Learn skill for (Triggering unit): Force Aura Constitution 1
    • Hero - Learn skill for (Triggering unit): Force Aura Power 1
    • Hero - Learn skill for (Triggering unit): Force Aura Speed 1
    • Hero - Learn skill for (Triggering unit): Force Aura Stamina 1
    • Unit - Add Force Aura 2 to (Triggering unit)
What I have done is make 5 custom auras, Force Aura 1-5, which is the skill you actually see on the hero, and Force Aura Stamina, Speed, Power, and Constition, all 1-5. Also, 1-5 does NOT refer to the level of the spell but an individual spell I used to represent levels because I do not know how to make a condition based on the level of a spell. When a hero picks Force Aura 1, which is the only skill I actually gave to the hero, I want Force Aura 2 to become a researchable skill, so that the next time the hero levels he will be able to choose Force Aura 2, but the action: Unit - Add Force Aura 2 to (Triggering unit) doesn't do that. I thought that is what it would do but I seem to be mistaken so if anyone could let me know how to make it so that when a hero learns the skill Force Aura 1, Force Aura 2 is given to him, I would be very appreciative. Thanks in advance.
 
Level 3
Joined
Aug 24, 2007
Messages
77
With the Add Force Aura 2 why not just give Force Aura multiple levels and detect the level of the skill at the start of the trigger and do the suitable actions according to the level, that should work.

Edit: To find an ability's level go to Conditions -> Integer Conditions -> Unit - Level of Ability for Unit, or if your JASS coding it you can call it via GetUnitAbilityLevel(whichUnit, abilcode)
 
Last edited:
Level 2
Joined
Mar 25, 2008
Messages
8
  • (Level of [COLOR="Red"]Your Ability[/COLOR] for ([COLOR="Red"]Your unit[/COLOR]) Greater than 0
Condition to detect lvl of ability.

Anyway your trigger is some have "bad":

Instead of Triggering unit use Learning Hero, also I think that you don't need condition
  • ((Triggering unit) is A Hero) Equal to True
since only heroes lvl up and learn skills (abilities).

  • Events
  • Unit - A unit Learns a skill
  • Conditions
  • (Learned Hero Skill) Equal to Force Aura 1
  • Actions
  • Unit - Add Force Aura Stamina 1 to (Learning Hero)
  • Unit - Add Force Aura Speed 1 to (Learning Hero)
  • Unit - Add Force Aura Power 1 to (Learning Hero)
  • Unit - Add Force Aura Constitution 1 to (Learning Hero)
Make your Force Aura 1 level up ability (multiple lvls) and set lvls of other auras with triggers (Unit-Set level of Ability).

I am n00b too, but i think that should work.:grin:
 
Status
Not open for further replies.
Top