Destroy Special Effect Delay

Status
Not open for further replies.
Level 9
Joined
Dec 31, 2016
Messages
320
When I use Destroy Special Effect action the special effect is not instantly removed but stays in place for a couple of seconds. Any way to remove it instantly? I tried to set it's alpha to 0 and remove all sub animation but neither works.
 
I don't believe it is possible to immediately remove an effect, but you could change it's height to -1000 to get it out of sight.

Perhaps something like increasing the effect speed to x1000 of the regular speed could work as well, to get it out of the way immediately.
 
Set the Special Effects height to something you can't see/hear like -5000, then destroy it.

Edit: Oh, whoops, I just repeated what pr114 said...

Also, I attached a map with some GUI triggers for controlling Special Effects.
 

Attachments

Last edited:
I have the same issue even in your example. I think the problem is that my special effect is attached to a unit and so it cannot be moved. But using a simple destroy action doesn't destroy it immediatelly.
Any solution to this? Or maybe can I somehow create it at point but make it so that it moves with the unit it should be attached to?
 
Oh, yeah, attached special effects are limited. There's nothing stopping you from moving a Point-based special effect though.

Store the unit/sfx in Variables then have a short interval Timer that runs this:
  • Custom script: call BlzSetSpecialEffectPosition(udg_YourSfx, GetUnitX(udg_YourUnit), GetUnitY(udg_YourUnit), BlzGetUnitZ(udg_YourUnit))
 
ah, now another problem arose. When I set the scale to 0 and destroy the special effect, then after a moment I create another special effect attached to the same unit, this new effect has also the scale of 0.
It only seems to work after I create effects on a few other units and some time passes. Strange behaviour. Any help on this?
 
Have done some testing, and I can see you can also immediately remove a unit effect if you do 'Set Effect Time' to 10.
And this has no consequence for the next spell effect.
I don't how exactly you did it that it works. This doesn't work for me, there's still a huge delay.
  • Untitled Trigger 001
    • Events
      • Player - Player 1 (Red) Selects a unit
    • Conditions
    • Actions
      • Special Effect - Create a special effect attached to the origin of (Triggering unit) using UI\Feedback\SelectionCircle\SelectionCircle.mdl
      • Special Effect - Set Time of (Last created special effect) to 10.00
      • Special Effect - Destroy (Last created special effect)
 
I think it doesn't work because this model has no animation.
In that case Uncle's solution is the best one, where you set the Special Effect scale to 1 again.

Interestingly using 'Set Effect Scale' also changes the size of new effects of the same type on the same unit, for ~5 seconds (after which the second effect will automatically resize in the midst of the animation).


  • Special Effect - Create a special effect attached to the overhead of Paladin 0000 <gen> using Abilities\Spells\Undead\AnimateDead\AnimateDeadTarget.mdl
  • Special Effect - Set Scale of (Last created special effect) to 2.00
  • Special Effect - Destroy (Last created special effect)
  • Wait 4.00 seconds
  • Special Effect - Create a special effect attached to the overhead of Peasant 0002 <gen> using Abilities\Spells\Undead\AnimateDead\AnimateDeadTarget.mdl [B]> small[/B]
  • Special Effect - Create a special effect attached to the overhead of Paladin 0000 <gen> using Abilities\Spells\Undead\AnimateDead\AnimateDeadTarget.mdl [B]> big for 1 second[/B]
 
Status
Not open for further replies.
Back
Top