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

[JASS] Damage Detection of any kind

Status
Not open for further replies.

genkidesuka

G

genkidesuka

Hey guys,

I'm making a Stealth spell incredibly similar to the World of Warcraft spell that Rogues have. The essentials are that it decreases movement speed on activation (instead of increasing as traditional Wind Walk does), and will break if ANY damage is taken.

I've got the reduced movement speed down (I hope) but still am lacking the damage detection. I'm fairly new to JASS so there's probably some simple solution that I'll bang my head against the wall about later, but could you guys humor me please?
 
The really complicated damage detection Blizzard has made:
  • Events
  • Unit - A Unit is damaged
  • Conditions
  • Triggering Unit has Stealth buff Equal to True
 
shift klick movement speed bonus and insert -20 or something :)
read the whole post next time, okay :P

anyhow, there is no A unit Takes damage event, so this is a common trick to make this work in GUI atleast

  • Trigger 1
  • Events
    • Unit - A unit Learns a Skill
  • Conditions
    • (Learned skill) Equal to Stealth
    • ((Learning unit) is in StealthGroup) Equal to False
  • Actions
    • Unit Group - Add (Learning unit) to Stealth Group
    • Trigger - Add to Trigger 2 <gen> the event ((Learning unit) Takes damage)
  • Trigger 2
  • Events
  • Conditions
    • ((Triggering unit) has Stealth buff) Equal to True)
  • Actions
    • Unit - Remove Stealth buff from (Triggering unit)
take those as examples and turn them into better JASS triggers :P
 
dont get why the event is when the unit learn the skill and why u have that group


  • Trigger
    • Events
      • Unit - "Unit" Takes Damage
    • Conditions
      • (Damage taken) Greater than (>) 0.00
    • Actions
      • Unit - Remove Stealth buff from (Triggering unit)
  • Other Trigger
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to (==) "Stealth"
    • Actions
      • Trigger - Add to "trigger" the event (Unit - (Triggering unit) Takes Damage)
 
Status
Not open for further replies.
Back
Top