Tranquilize ability

BuryAutumn

New Member
Reaction score
3
I made an ability that uses a dummy unit to but an enemy to sleep, but instead of putting the enemy to sleep, it gets stunned. My damage skill used to initiate the trigger is "Storm Bolt" but I took away the buffs and stun time so that the enemy would only get sleep.

How do I fix this?

Code:
Tranquilize
    Events
        Unit - A unit Begins casting an ability
    Conditions
        (Ability being cast) Equal to Tranquilize 
    Actions
        Unit - Create 1 tranquilizedummy for (Triggering player) at (Position of (Triggering unit)) facing Default building facing degrees
        Unit - Order (Last created unit) to Undead Dreadlord - Sleep (Target unit of ability being cast)
        Wait 10.00 seconds
        Unit - Remove (Last created unit) from the game
 

Jagan

New Member
Reaction score
30
Don't base it off of Storm Bolt. Use Chain Lightning instead.

Try this:

Code:
Tranquilize
    Events
        Unit - A unit Starts the effects of an ability
    Conditions
        (Ability being cast) Equal to Tranquilize 
    Actions
        Set Tranquilize_Caster = (Triggering unit)
        Set Tranquilize_Caster_Loc = Position of (Tranquilize_Caster)
        Unit - Create 1 tranquilizedummy for Owner of (Tranquilize_Caster) at Tranquilize_Caster_Loc facing Default building facing degrees
        Unit - Order (Last created unit) to Undead Dreadlord - Sleep (Target unit of ability being cast)
        Add a 2.00 second Generic expiration timer to last created unit
        Custom script: call RemoveLocation(udg_Tranquilize_Caster_Loc)

100th Post!!
 

Builder Bob

Live free or don't
Reaction score
249
Storm Bolt with stun duration 0 will stun the target for infinite seconds instead of 0 seconds.

If all you want is a projectile, use Shadow Strike instead.
To avoid the damage text from shadow strike, set
Data - initial damage to 0.01
Stats - Duration - Hero to 0.01
Stats - Duration - Unit to 0.01
And all the rest to 0
 

LmmcDarkY

New Member
Reaction score
1
Custom script: call RemoveLocation(udg_Tranquilize_Caster_Loc)
[/CODE] what this one means ????
 

Accname

2D-Graphics enthusiast
Reaction score
1,464
he is removing the point variable Tranquilize_Caster_Loc. you've got to remove point variables to avoid leaks. here's a turtorial about leaks if you dont know about them: Link
 

BuryAutumn

New Member
Reaction score
3
No, the unit still won't fall asleep after I cast the ability.

I put a casting time for both abilities but no luck. I tried taking the casting time off too.
 

Mike889

New Member
Reaction score
15
Remember that the sleep ability makes the target unit invulnerable!
To change this put "Stun Duration" to 0.01 on the sleep skill!

Also, you haven't given the sleep ability for the dummy.
 

BuryAutumn

New Member
Reaction score
3
I put the Stun Duration to .01. The dummy unit has the ability.

I don't know why it's not working. The target unit gets the damage and the dummy unit is created, so why won't it work? :/
 

duyen

New Member
Reaction score
214
If you set the duration of the stun on storm bolt to 0, it just makes it permanent, set it to 0.01 instead.
 

Nexor

...
Reaction score
74
the dummy does have enough mana to cast it?

and instead of "begins casting", use "starts the effects"
 

Builder Bob

Live free or don't
Reaction score
249
Well, no.
I just want the ability to work for both units.

then why don't you just use the ability sleep without triggering anything?


Edit: I've attached a working Tranquilizer Shot with projectile graphics for you. You'll find the changes I've made in the Object Editor under Units/Abilities/Buffs and in the Trigger Editor.
 

BuryAutumn

New Member
Reaction score
3
The problem with your ability is that it won't do the damage I want.

Let me break it down.

I want to make an ability that will do some damage and then but the target to sleep, but I can't seem to get it right.
 

darkRae

Ueki Fan (Ueki is watching you)
Reaction score
173
Well, here's some question:

1) What's your Storm Bolt missile speed?
I get the feeling that the speed causes the Bolt to arrive when the target unit is 'invulnerable'

2) What's your current trigger?
To put it simply, you just need to cast a Storm Bolt with 0.01 stun duration with the damage you want, and use a dummy unit to cast the Sleep ability you want with 0.01 stun duration.

The problem might lie in 1).
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      • Ghan
        Administrator - Servers are fun

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top