How to prevent passive buff placers from working on certain units?

Hello! :)

I'm doing a slight variation of Abaddon's Curse of Avernus (abaddon_frostmourne), where he can apply several stacks of the curse. The skill is done (attached at the end of the post), but I couldn't prevent it from working on towers - this was problematic, as it became too strong this way (creeps on maximum speed attacking a super-slowed-down tower is pretty fun, but you quickly figure its broken).

I looked around and messed with the ability's targetting, but didn't manage to overcome this. I would like the passive to work on all regular units (enemy heroes + creeps, neutrals) but not on structures. Can anyone help find a way?

Thank you very much!

I'm copying the skill's current implementation below:


  • edited January 2015 Posts: 36

    Try adding something like this;

                    "Center" "TARGET"
                    "Radius" "%slow_radius"
                    "Teams" "DOTA_UNIT_TARGET_TEAM_ENEMY"

    Except with the Radius like 1 or something. Or maybe you can do it without the radius and that would work, not entirely sure, I can't test it right now.

    Ohgodohgodohgodohgodohgodohgodohgod wheredidalltheabilitiesgo ohgodohgodohgodohgodohgod whatdidido ohgodohgodohgod howdoicomputer

  • edited January 2015 Posts: 1,670

    ^ You can just remove the Radius line and it will default to 0.

    Edit: Method explained above works for any ApplyModifier block being applied on an enemy target. However, for the "Lifesteal" example, you still need to use lua because its a positive buff applied after attacking an enemy target.

    That being said, if you don't mind using a bit of lua, you can deny any "OnAttack" effect from landing on a particular unit, the method I'm currently using can be seen on Vampiric Aura, which I need to extend to the SpellLibrary...

    "Lifesteal" action works on buildings by default, to restrict this the trick would be to abuse the fact that "OnAttackLanded" happens before "OnDealDamage", so the actual effect is applied when the damage is dealt, while the Attack Landed just checks for the unit type in a lua script.

                "ScriptFile" "heroes/dread_lord/vampiric_aura.lua"
                "Function"   "VampiricAuraApply"
        "IsHidden"     "1"
                "Target"           "ATTACKER"
                "LifestealPercent" "%lifesteal"

    The lua script is very short and simple:

    -- Applies a Lifesteal modifier if the attacked target is not a building or mechanical unit 
    function VampiricAuraApply( event )
        -- Variables
        local attacker = event.attacker
        local target =
        local ability = event.ability
        if target.GetInvulnCount == nil and not target:IsMechanical() then
            ability:ApplyDataDrivenModifier(attacker, attacker, "modifier_vampiric_aura_lifesteal",                       {duration = 0.03} )

    target.GetInvulnCount is never nil for buildings (0 if they are attackable and >= 1 if they are invulnerable).

    The modifier_vampiric_aura_lifesteal is just added for 1 frame, which is enough for the attack to actually deal the damage and lifesteal from it.


    The concept of Modding Community doesn't go well together with Competitive Business
    My Project Page || My GitHub Profile ||

  • Posts: 19

    Confirmed that both versions work as intended (with and without the radius parameter)

    Thanks for the quick response! =]