Warcraft III resources & community, 2003–2006 · archived

Triggered Ability -- Stupify

10 posts
#1

Triggered Ability -- Stupify

I can't see what is wrong with this, can you?

Stupify
    Events
        Unit - A unit Begins casting an ability
    Conditions
        (Ability being cast) Equal to Stupify 
    Actions
        Wait 0.50 seconds
        Set StupifyTarget = (Position of (Target unit of ability being cast))
        Special Effect - Create a special effect at StupifyTarget using Doodads\Cinematic\Lightningbolt\Lightningbolt.mdl
        Special Effect - Create a special effect at StupifyTarget using Abilities\Spells\Human\Thunderclap\ThunderClapCaster.mdl
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Level of Stupify  for (Casting unit)) Equal to 1
            Then - Actions
                Hero - Modify Intelligence of (Targeted unit): Subtract 1
            Else - Actions
                Hero - Modify Intelligence of (Targeted unit): Subtract (Random integer number between 1 and 2)
#2
not targeted unit,but
Target unit of ability being cast
#3
VampireKBnot targeted unit,but
Target unit of ability being cast

Thank you for the quick reply.
#4
stupefy is the correct spelling and set your variable before the wait action
#5
Also, the wait sux, the Begins Casting instead of Stats the Effect sux, the 2 leaking SFX sux, the leaking location sux, and the Casting Unit instead of Triggering Unit sux. fix those, and youll be good to go.
#6
PurplePootAlso, the wait sux, the Begins Casting instead of Stats the Effect sux, the 2 leaking SFX sux, the leaking location sux, and the Casting Unit instead of Triggering Unit sux. fix those, and youll be good to go.


This is why I need help, lol.

Also, Stupify is an alternative spelling.
#7
This is why I need help, lol.


oh, i'll help you!

1. Change trigger condition to more approciate
2. Fix leaking SFX
3. Fix location leak
4. Change unit from Casting Unit to more approciate

hope that helps (haha)
#8
Well, first, get rid of that damn wait

Second, change the event to

A Unit Starts the Effect of an Ability

Third, change the two lines where it mods the intelligence to

Set int of TRIGGERING UNIT to x

Fourth, at the end of the trigger saying

Custom Script: call RemoveLocation( udg_StupifyTarget )

Fifth, assign those two effects to variables or something, and destroy them using

Destroy (effect)

at the end of the trigger.
#9
Okay, I tried to make it better and make myself not look like an idiot.

Stupify
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Stupify 
    Actions
        Set StupifyTarget = (Position of (Target unit of ability being cast))
        Special Effect - Create a special effect at StupifyTarget using Doodads\Cinematic\Lightningbolt\Lightningbolt.mdl
        Set StupifyEffect[1] = (Last created special effect)
        Special Effect - Create a special effect at StupifyTarget using Abilities\Spells\Human\Thunderclap\ThunderClapCaster.mdl
        Set StupifyEffect[2] = (Last created special effect)
        Custom script:   call RemoveLocation( udg_StupifyTarget )
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Level of Stupify  for (Triggering unit)) Equal to 1
            Then - Actions
                Hero - Modify Intelligence of (Target unit of ability being cast): Subtract 1
            Else - Actions
                Hero - Modify Intelligence of (Target unit of ability being cast): Subtract (Random integer number between 1 and 2)
        Wait 2.00 seconds
        For each (Integer A) from 1 to 2, do (Actions)
            Loop - Actions
                Special Effect - Destroy StupifyEffect[(Integer A)]
#10
Aye, you fixed it now :D