"Entangling Arrows"

P

Paranormal

Guest
So I've been making this custom ability named Entangle. It was based on searing arrows, and changed around so that when you shoot them it entangles them for 1 second. However, theres one thing missing. I want it to be a percent chance to entangle, not just do it on attack. What to do? Kind of a newbie at World Editor so go easy. Thanks.
 
C

Cepheids

Guest
ok let me assume that its going to cost some mana to get this chance to entangle. meaning, sometimes, you spend the mana for nothing?

give searing arrows the entangle buff. use a trigger to check for this buff. create dummy unit to entangle the unit if buff is present.
 
P

Paranormal

Guest
Entangling Arrows

Yes, it will cost 8 mana per shot and most shots it will be wasted. Now, when you talk of these triggers and "dummy units" could you be more specific? I just started making maps a few days ago but I'm a fast learner. thx
 
P

Paranormal

Guest
Oh, and I want to be able to make this specific percent with each level of the spell. For instance, level 1 it will give 15%, level 2 20%...
 

Cloak_Master

Active Member
Reaction score
41
Check out this dummy caster tutorial by Persen. http://www.thehelper.net/forums/showthread.php?t=26751

Ok, so what you want to do is make the searing arrows spell completely balnk except for the eight mana cost. Then, make an integer variable and set it to a random number between 1 and 100. Detect if that integer variable is equal to 10 or less, this will give the effect a 10% chance to fire. When that returns as true, just create a dummy caster to cast a modified entangling roots on the target that lasts a second. Good luck.

Edit: You can also use if/then/elses to detect ability levels.
 
C

Cepheids

Guest
go to searing arrows
under buffs, add entangling roots

- now create a trigger
- event is unit is attacked
- condition is attack is of type whatever unit that can have that spell
- action is wait 1 second (depends on missile speed) then check for the buff
- if theres a buff entangling roots
- -if random number between 1 and 100 is less than (10 + (5 x level of ability of attacker))
- - -create 1 entangler for attacker at position of triggering
- - -order last created unit to entangle triggering unit

actually i suggest black arrows... its better
 

Cloak_Master

Active Member
Reaction score
41
Your'e trigger is nearly identical to mine except it gives messy/nasty buffs. The preffered way is mine, just go with it man.
 
Z

Zelune

Guest
if u want it to be a chance on hit, then why not make it a passive ability?

like take bash and just make the model file into entangling roots
 
P

Paranormal

Guest
Pardon again, but I've made my dummy caster but I dont know how to add the integer thing. Is it under stats of an ability or something you add yourself?
 

Cloak_Master

Active Member
Reaction score
41
In trigger editor, create a variable of the type integer. Then, with a trigger, you will be able to set it to a random value and check it with an if/then/else. Good luck.
 
P

Paranormal

Guest
Ok, So for events I want Any Unit is attacked or my hero(the one with entangle arrows)? Then, editing the variables, the type is buff and initial is entangling roots, then I want to set variable to random number, and check for number with if/then/else? Do I have all this right? and what conditions do I add?
 

Cloak_Master

Active Member
Reaction score
41
You'll want the events a unit is attacked. Then, yoru conditions should check the hero who has the ability. Then modify the percent chance based on the abilities level.
 
C

Cepheids

Guest
Code:
Entangling Arrows
    Events
        Unit - A unit Is attacked
    Conditions
        (Unit-type of (Attacking unit)) Equal to Entangling Archer
    Actions
        Wait ((Distance between (Position of (Attacked unit)) and (Position of (Attacking unit))) / MissileSpeedOfArrow) game-time seconds
        Wait 0.50 game-time seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                ((Attacked unit) has buff Entangling Roots) Equal to True
            Then - Actions
                If ((Random real number between 0.00 and 100.00) Less than or equal to (10.00 x (Real((Level of Entangling Arrows for (Attacking unit)))))) then do (Do nothing) else do (Skip remaining actions)
                Unit - Create 1 Entangler for (Owner of (Attacking unit)) at (Position of (Attacked unit)) facing Default building facing degrees
                Unit - Order (Last created unit) to Night Elf Keeper Of The Grove - Entangling Roots (Attacked unit)
            Else - Actions
 

Cloak_Master

Active Member
Reaction score
41
Heres my version...

Code:
Entangling Roots 2
    Events
        Unit - A unit Is attacked
    Conditions
        (Unit-type of (Attacking unit)) Equal to Shandris (Entangling)
    Actions
        Wait ((Distance between (Position of (Attacking unit)) and (Position of (Attacked unit))) / Missle Speed) game-time seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                And - All (Conditions) are true
                    Conditions
                        (10 x ((Level of Entangling Ability for (Attacking unit)) - 5)) Less than or equal to (Random integer number between 1 and 100)
                        (10 x ((Level of Entangling Ability for (Attacking unit)) - 5)) Greater than 0
            Then - Actions
                Unit - Create 1 Dummy Entangler for (Owner of (Attacking unit)) at (Position of (Attacked unit)) facing Default building facing degrees
                Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
                Unit - Order (Last created unit) to Night Elf Tree Of Life - Entangle (Instant) (Attacked unit)
            Else - Actions
                Do nothing

Edit: Fixed a few things as I realized better ways to do them.

Fundamentally the same, but doesn't check for buffs.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top