triggered Special Effects not showing...

Advena

Just casually observing atm ;)
Reaction score
42
Yo guys, I have a problem.
I have a few spells (the following two in particular) that show their special effects properly/at all.
The special effects assigned to the them in the trigger fail to show, and I can't find the problem. I can't figure it out at all :banghead:

*The first one is based on storm bolt, using a high-speed (like, almost maxed out) projectile with no projectile animation. I take the damage directly from the ability. However, I want it to look like a bolt of lightning from the sky hitting the ground and creating a "thunderclap" effect while the trigger damages the units close to the target.

*The second ability is based on an Aura with 0 in all stat fields (0.01 aoe, self-only). It's meant to create a shield (I have two other triggers realated to that one, but they're not relevant when dealing with the effects so I put them in a spoiler below to save som space and make this look less like a novel) that will make the hero invulnerable a few seconds and heal him a set amount of hp every time someone casts a spell on him. It only works once every 60/40/20 sec tho, using a timer and blablabla :)
I haven't exactly got it to work very good yet, but I will eventually ;)

Anyhow, any spontaneous thoughts about why my effects not showing?

Code:
Thunder Strike
    Events
        Unit - A unit Finishes casting an ability
    Conditions
        (Ability being cast) Equal to Thunder Strike (Thunder Bull)
    Actions
        Set ThunderTarget = (Target unit of ability being cast)
        Wait 0.01 seconds
        Special Effect - Create a special effect attached to the origin of ThunderTarget using Doodads\Cinematic\Lightningbolt\Lightningbolt.mdl
        Special Effect - Destroy (Last created special effect)
        Wait 0.04 seconds
        Unit Group - Pick every unit in (Units in (Region centered at (Position of ThunderTarget) with size (228.00, 228.00))) and do (Actions)
            Loop - Actions
                Unit - Cause (Casting unit) to damage (Picked unit), dealing ((Real((Level of Thunder Strike (Thunder Bull) for (Casting unit)))) x 50.00) damage of attack type Spells and damage type Lightning
        Special Effect - Create a special effect attached to the origin of ThunderTarget using Abilities\Spells\Human\Thunderclap\ThunderClapCaster.mdl
        Special Effect - Destroy (Last created special effect)
        Wait 0.01 seconds
        Special Effect - Create a special effect attached to the origin of ThunderTarget using Abilities\Weapons\Bolt\BoltImpact.mdl
        Special Effect - Destroy (Last created special effect)
_


Code:
StaticShield Setup1
    Events
        Unit - A unit Learns a skill
    Conditions
        (Learned Hero Skill) Equal to Static Shield (Thunder Bull) UNFINISHED
    Actions
        Countdown Timer - Start StaticShield_timer as a Repeating timer that will expire in (60.00 / (Real((Level of Static Shield (Thunder Bull) UNFINISHED for Raur_ThunderBull)))) seconds
        Set StaticShield_On = True
        Special Effect - Create a special effect attached to the chest of Raur_ThunderBull using Abilities\Spells\Orc\LightningShield\LightningShieldTarget.mdl
        Set SFX_StaticShield = (Last created special effect)


StaticShield Setup2
    Events
        Time - StaticShield_timer expires
    Conditions
    Actions
        Set StaticShield_On = True
        Special Effect - Create a special effect attached to the chest of Raur_ThunderBull using Abilities\Spells\Orc\LightningShield\LightningShieldTarget.mdl
_
Code:
Static Shield
    Events
        Unit - A unit Finishes casting an ability
    Conditions
        And - All (Conditions) are true
            Conditions
                StaticShield_On Equal to True
                (Target unit of ability being cast) Equal to Raur_ThunderBull
    Actions
        Special Effect - Create a special effect attached to the origin of ThunderTarget using Abilities\Spells\Orc\Purge\PurgeBuffTarget.mdl
        Special Effect - Destroy (Last created special effect)
        Unit - Make Raur_ThunderBull Invulnerable
        Wait 0.10 seconds
        Unit - Set life of Raur_ThunderBull to ((Life of Raur_ThunderBull) + (50.00 x (Real((Level of Static Shield (Thunder Bull) UNFINISHED for Raur_ThunderBull)))))
        Special Effect - Create a special effect attached to the origin of ThunderTarget using Abilities\Weapons\Bolt\BoltImpact.mdl
        Special Effect - Destroy (Last created special effect)
        Set StaticShield_On = False
        Wait 2.90 seconds
        Unit - Make Raur_ThunderBull Vulnerable
        Special Effect - Destroy SFX_StaticShield
_


+rep for help and any ideas, of course :D


~~
 

ManyTimes

I'm so lonesome I could cry...
Reaction score
293
some special effects cannot be removed just after they are created, try put them in a variable, and destroy later.
 

Advena

Just casually observing atm ;)
Reaction score
42
That's the ting, I've seen (at least some) of those effects used exactly like this,
being destroyed just after creation, and those worked.
I have thought about it tho, so I'll give it a go now. We'll see how it turns out.
+rep anyhow :D

Any other suggestions? There's gotta be ;)
 

waaaks!

Zinctified
Reaction score
255
for the lightning bolt above the sky....you can simply make a chain lightning dummy spell, then let a dummy cast it above...like making it fly...or making the dummy have the movement type to fly and change animation height to 1500...then u can easliy order a dummy to thunder clap to the position of the target
 

trigger_newb

Active Member
Reaction score
3
why do you remove the special effects...
i dont think i've ever removed them...
you can remove them after they're all done..
i think that since your trying to remove the effects too fast so that it wont show or something..
try not remoing it
just leaving at seomthing like this
Code:
create special effect at balbhalbhalbha
 

Psiblade94122

In need of sleep
Reaction score
138
if you leave then, then you will get memory leaks which are bad because after a while, the game's fps will drop permanently because there are leaks.
 

trigger_newb

Active Member
Reaction score
3
of course tahts going to happen, but you should remove them sometime else.. not like .0000001 seconds right after you trigger the se

err try this
why dont you try making variables instead of originating the se on the point of target
so make a variable thast like Point = Point (array) or something then make the set the variable so that the targeted area is the point and then make it so that the create se at point_1 then after you make multiple arrays with the variable, then at the end just remove all the points by typing that jass crap in i think it was like remove_udglocationsomethingsomething.. i remember seeing in a thread

some special effects cannot be removed just after they are created, try put them in a variable, and destroy later.
err woops sorry i didnt see this.. lol
 

Psiblade94122

In need of sleep
Reaction score
138
i know this might lagg some computers, but really if your haveing such a hard time...

a simple solution would be this

Instead of useing specal effects, make dummy units that have the model of the specal effects, give them a expration timer of something like .3 or so, that way you will see it, and the unit would be removed from the game so there wont be lagg from a biuldup of units as specal effects

and the code is

Code:
call RemoveLocation (udg_L)

anything after the udg_ would equal your point variable name, i just happen to use L because its simplistic (only one letter, and its my short hand for location, which in turn follows the code because the code removes the location)

and if you make an array then when you remove it you need the [#] tacked onto the end of the variable <i have to look back on my notes on this, not shure if thats all you need> in the removal process else you will get a compilation error
 

vypur85

Hibernate
Reaction score
803
Hmm... I'm quite sure that thunderclap effect can be removed right after being created.... So maybe its not the removing problem? I mean, he did stated that none of the effect appeared right? So, ya... Maybe its not the removing problem...

(I still think its because of the waits though... :p Err... for the first trigger, why put the waits? They are so short, does it make a difference? 0.06secs in total... Or is it effects cant stack on same unit at the same time? Sorry if i'm wrong... :p)
 

AceHart

Your Friendly Neighborhood Admin
Reaction score
1,495
> I've seen (at least some) of those effects used exactly like this

When you destroy an effect, it simply plays its "death" animation, and disappears.
Now, for most effects that's all they have anyway. A death animation...

Some though are slightly more "complicated".
Flame Strike for example comes with a "birth" animation too.

Well, instantly destroying "death"-only effects is no problem.
Those with more require some extra work... as in, waiting before destroying them.


And, when you select an effect, you get a preview of it in the "model view" of the editor.
If it mentions "animations", it's an effect that needs work.
If it says "death" or, most of the time, just nothing, you can destroy it immediately.
 

Advena

Just casually observing atm ;)
Reaction score
42
Thanks for all the input guys! Sorry I haven't been able to write back 'til now :eek:
I'll try using variables and destroying them later on, as so many said. Or else I might very well go with the "timed units" idea. Haven't had time to even open the map since I posted, so I'll have to look at this thoroughly now :p

I'll get back to y'all when I've fixed it, if I can ;)

Thanks for all the help!
+rep for any and all (I think I got all of you. lemme know, eh?) :D
 

Advena

Just casually observing atm ;)
Reaction score
42
Hi again!
Just thought I'd let y'all know I fixed it now.
But the funny thing is what helped it.

Look at the bold text
Code:
Thunder Strike
    Events
        Unit - A unit [B]Begins casting [/B]an ability
    Conditions
        (Ability being cast) Equal to Thunder Strike (Thunder Bull) UNFINISHED
    Actions
        Set ThunderTarget_Point = (Position of (Target unit of ability being cast))
        Set ThunderTarget_Unit = (Target unit of ability being cast)
        Unit - Pause ThunderTarget_Unit
        Special Effect - Create a special effect at ThunderTarget_Point using Doodads\Cinematic\Lightningbolt\Lightningbolt.mdl
        Set ThunderStrike_SFX1 = (Last created special effect)
        Unit Group - Pick every unit in (Units in (Region centered at (Position of ThunderTarget_Unit) with size (228.00, 228.00))) and do (Actions)
            Loop - Actions
                Unit - Cause (Casting unit) to damage (Picked unit), dealing ((Real((Level of Thunder Strike (Thunder Bull) UNFINISHED for (Casting unit)))) x 50.00) damage of attack type Spells and damage type Lightning
        Special Effect - Create a special effect at ThunderTarget_Point using Abilities\Spells\Human\ThunderClap\ThunderClapCaster.mdl
        Set ThunderStrike_SFX2 = (Last created special effect)
        Special Effect - Create a special effect at ThunderTarget_Point using Abilities\Weapons\Bolt\BoltImpact.mdl
        Set ThunderStrike_SFX3 = (Last created special effect)
        Wait 2.00 seconds
        Unit - Unpause ThunderTarget_Unit
        Wait 6.00 seconds
        Special Effect - Destroy ThunderStrike_SFX1
        Special Effect - Destroy ThunderStrike_SFX2
        Special Effect - Destroy ThunderStrike_SFX3

I only changed the even from "finishes casting" and it worked like a charm.
Wierd for sure, but at least it works now :D
ty again for all the help!
 

Sim

Forum Administrator
Staff member
Reaction score
534
You might want to change it to "Starts the effect of an ability" to prevent the "save-mana and cooldown" abuse by cancelling the spell right away :D
 
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