1. The poll for our 11th Music Contest is up! Help us choose the most awesome cinematic tracks by casting a vote!
    Dismiss Notice
  2. Melee Mapping contest #3 - Poll is up! Vote for the best 4v4 melee maps!
    Dismiss Notice
  3. The 30th edition of the Modeling Contest is finally up! The Portable Buildings need your attention, so come along and have a blast!
    Dismiss Notice
  4. The Aftermath has been revealed for the 19th Terraining Contest! Be sure to check out the Results and see what came out of it.
    Dismiss Notice

[General] Is AddSpecialEffect broken?

Discussion in 'World Editor Help Zone' started by Robbepop, Feb 9, 2019.

  1. Robbepop

    Robbepop

    Joined:
    Mar 6, 2008
    Messages:
    870
    Resources:
    7
    Maps:
    6
    Spells:
    1
    Resources:
    7
    Hi,

    I am trying to use goo'old
    Code (vJASS):
    AddSpecialEffect(string modeName, real x, real y)
    native and cannot seem to get a special effect shown up for it if the special effect has no animations.

    This this has never made any problems to me in the past I suggest this might be related to a bug since recent versions of WarCraft III?

    Code (vJASS):
    AddSpecialEffectTarget
    works like a charm. But unfortunately I need AddSpecialEffect to work.

    Note that it seems to me that special effect having animations do NOT suffer from this problem.

    For example:

    Code (vJASS):

    AddSpecialEffect(
        "Abilities\\Spells\\Human\\MassTeleport\\MassTeleportTo.mdl",
        GetUnitY(builder),
        GetUnitX(builder)
    )
     


    works fine, while

    Code (vJASS):

    AddSpecialEffect(
        "Abilities\\Spells\\NightElf\\Blink\\BlinkCaster.mdl",
        GetUnitY(builder),
        GetUnitX(builder)
    )
     


    does not.
    And the only difference (as far as I can see) is that MassTeleportTo.mdl has animations and BlinkCaster.mdl does not.
     
    Last edited: Feb 10, 2019 at 11:54 AM
  2. BloodSoul

    BloodSoul

    Joined:
    May 10, 2009
    Messages:
    697
    Resources:
    2
    Spells:
    2
    Resources:
    2
    Weird. It actually works as intended for the latest patch version here. Maybe the reason for such behavior is happening because you swapped X and Y coordinates within the function call? (assuming you did the same thing in your actual code)
     
  3. Robbepop

    Robbepop

    Joined:
    Mar 6, 2008
    Messages:
    870
    Resources:
    7
    Maps:
    6
    Spells:
    1
    Resources:
    7
    Hey, good catch!
    However, I haven't swapped them in my real code.
    This Y/X swap was introduced as one of my many many many tests - didn't help either.
     
  4. ZiBitheWand3r3r

    ZiBitheWand3r3r

    Joined:
    Nov 21, 2012
    Messages:
    876
    Resources:
    14
    Maps:
    6
    Spells:
    8
    Resources:
    14
    Did you set decay time for effects in gameplay constants to zero maybe?
     
  5. Robbepop

    Robbepop

    Joined:
    Mar 6, 2008
    Messages:
    870
    Resources:
    7
    Maps:
    6
    Spells:
    1
    Resources:
    7
    I just looked that up.
    Decay time for effects was modified from 5.0 seconds to 2.0 seconds.
    It never was critical and always worked, until recently - couldn't even remember that I once changed it.
    Setting it back from 2.0 to 5.0 seconds fixed the issue ...

    Thanks!