• 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.

Dummy Toggleable Ability Without Buffs

Status
Not open for further replies.
Level 6
Joined
Sep 19, 2005
Messages
169
So basically, I haven't worked with abilities for a loooong time. All I want is a ability that is toggleable like defend, is detectable by their order string, and doesn't have a buff. I'm already using one based off the defend ability and it works, but when duplicating the ability and changing it's ID and order strings, when toggling one of the abilities on a unit it will occasionally turn the other ability on or off.

Both the working defend ability and the other I'm trying to create will need to be on the same unit. I tried immolation, which works, but even when deleting the immo buff from the ability it still shows as a buff. Removing all abilities from the unit after using the ability hasn't worked either. So what abillity can I use that doesn't have any buffs and will work as a toggleable dummy ability?
 
Level 14
Joined
Aug 8, 2010
Messages
1,022
Use 2 copies of channel, the one is ON, the other OFF.
  • Trigg1
    • Events
      • Unit - A unit Learns a skill
    • Conditions
      • (Learned Hero Skill) Equal to Human YourSkillON
    • Actions
      • Set Caster = (Triggering unit)
      • Trigger - Turn on TurnTheOFFability <gen>
      • Trigger - Turn on TurnTheONability <gen>
  • TurnTheOFFability
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to YourSkillON
    • Actions
      • Unit - Add YourSkillOFF to Caster
      • Unit - Remove YourSkillON Caster
      • Trigger - Turn off YourEffect <gen>
  • TurnTheONability
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to YourSkillOFF
    • Actions
      • Unit - Add YourSkillON to Caster
      • Unit - Remove YourSkillOFF from Caster
      • Trigger - Turn on YourEffect <gen>
the trigger 'YourEffect' = the effect of your ability! :)
 
Your problem occurs because of sharing the BASE order id by spells you have used. It doesn't matter that you change string order Id while base order Id is still the same for both and you can do nothing about it. The only ability that is flexible enough is channel, ability mentioned already by CoLd Bon3 above.

About buffs and effect. Warcraft Editor is a bit wierd, isn't it?
It doens't really matter that you remove the buff from ability, because if you do so, wc3 engine will use default one anyways.
The idea is to remove the effect of buff. To do this, go to Buff/Effect section, find buff you are willing to negate and remove all special effects contained by it.

Back to the topic. The best option proves to be channel manipulating. Although already said, ^poster above havent told you the most important thing. Since channel ability does not own any effect itself you have to trigger this ability, but the thing that I want to underline here is the base order id field, since it allows you to change the id not the string order for given spell thus enabling you do use channel practicaly for every spell/triggered ability (hero can have all spells based on channel). I hope you know what the other important fields from channel ability contains and what is their meaning.

@CoLd Bon3
You do not need to create separate triggers. Use function if/then/else.
  • Init
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
    • Actions
      • If (All conditions are true) then do (Then Actions) else do (Else actions)
        • If - Conditions
          • (Ability being cast) Equal to TurnOn
        • Then - Actions
          • Unit - Add YourSkillON to Caster
          • Unit - Remove YourSkillOFF Caster
          • <other actions stuff>
        • Else - Actions
          • If (All conditions are true) then do (Then Actions) else do (Else actions)
            • If - Conditions
              • (Ability being cast) Equal to TurnOff
            • Then - Actions
              • Unit - Add YourSkillOFF to Caster
              • Unit - Remove YourSkillON Caster
              • <other actions stuff>
            • Else - Actions
 
Status
Not open for further replies.
Top