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

simple trigger

Status
Not open for further replies.
Level 4
Joined
Nov 3, 2009
Messages
28
Hi people, I deal with this map project development http://epicwar.com/maps/114893/, and have very little skill in editing maps would be very grateful for your assistance in creating an upgrade, now describe the principle: when attacking any unit horde has a chance (eg 20%) fall into a state of insanity), I honestly have a whole head broke in trying to implement it, and I understand that without knowing the triggers, it is impossible, in general, asking for your help

english by google translator :D
 
re

a simpler explained to - I need a skill as ultimate in bristeback in DotA
with the chance I could catch - it can be done through random integer number condition, but the problem is that I have not found the actions "add buff to unit", only remove, But maybe there's an easier way to implement it, without triggers??
 
One method is to use a Dummy unit with a casted ability.
For example, you want your unit to have a 20% chance to gain a 10% damage buff.

To do this, you'd need to make a dummy spell based on something like Inner Fire, to give the 10% damage bonus. And of course, a dummy unit (invisible "behind the scenes" caster).
You also need a Global Variable that is a "point" type variable. Here, I used the variable name "temppoint".
Then, add a trigger like so:

  • Events
    • Unit - A unit is attacked
  • Conditions
    • Unit Type of (Attacking Unit) = <Your Unit>
  • Actions
    • If / Then / Else
      • If (Conditions)
        • (Random Integer between 1 and 100) less than or equal to 20
      • Then (Then Actions)
        • Set temppoint = Position of (Attacking Unit)
        • Unit - Create 1 <Dummy Unit> for (Owner of Attacking Unit) at temppoint facing default building degrees.
        • Unit - Add ability <Dummy Spell> to (Last Created Unit)
        • Unit - Add a 2.00 second generic expiration timer to (Last Created Unit)
        • Unit - Order (Last Created Unit) to Human - Priest Inner Fire (Attacking Unit)
        • Custom script: call RemoveLocation(udg_temppoint)
      • Else (Else Actions)
Obviously, if you wanted it to give an attack speed boost, use something like Bloodlust, and change the Order to Orc - Shaman Blood Lust as appropriate.
 
You can also go to the Unit's "Model File" field and use Shift+Double Click to be able to type in your own value for the model file.

In there just type _
This makes the model file totally blank (invisible).
Also, give your dummy unit the ability "Locust" - this will make the unit unselectable, have no collision and invulnerable. It will still be affected by the expiration timer though, which is what we want.

My B.net name is Lord_Damage by the way.
 
Status
Not open for further replies.
Back
Top