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

Passive Trigger Abilities : How?

Status
Not open for further replies.
Level 4
Joined
Feb 23, 2009
Messages
99
I know how to do trigger abilities, but how do I make triggers with passive abilities such as bash, critical strike etc.
Example :
If a unit bashes the target, the hero will make an illusion.
How to make that?
 
You need to make a custom bash and an attack detection system, so that you detect any normal attack made (the abnormal would be the "miss!").

First off, get "Critical Strike", set all of its values to 0.
Then, get Storm Bolt of Mountain King, set its values to 0, except for the duration of the stun, which will be equal to the duration of your bash (e.g. 0.7 seconds stun). Mana cost to 0, and "Stats - Hero Ability" set it to "False"
After that, create a dummy unit (search for a tutorial on dummy units) and add the abilities - normal: "Locust, Invulnerable, The modified "Storm Bolt", Inventory (Hero)".

Trigger 1

[I will not enhance the trigger with attack detection system, cause it's really messy to write it down within a whole thread - try searching for a tutorial]
The idea though is:

Events
A unit is attacked
Conditions
(Level of (Your modified Critical Strike)) for (Attacking unit) Not Equal to 0 (or Equal to 1/2/3/4 - based on the levels of the skill)
(Random Integer number between 1 and 100) Less than or Equal to X [X is your chance to bash the target and create the illusion, for 20% chance, place to X the number "20"]
Actions
Set Point1 = (Position of (Attacked unit))
Unit - Create 1 dummy at Point1 for (Owner of (Hero1)) facing default building degrees
Unit - Order (Last created unit) to Human Mountain King - Storm Bolt (Attacked unit)
Hero - Create Wand of Illusion and give it to (Last created unit)
Hero - Order (Last created unit) to use (Last created item) on (Attacked unit)
Unit - Add a 0.8 generic expiration timer to (Last created unit)
Custom script: call RemoveLocation (udg_Point1)
 
Status
Not open for further replies.
Top