• Removes the ability from target unit.

    Returns:

    • true if the removal was successful (hero did have this ability before)
    • false otherwise (hero does not have this ability)

    Parameters

    • whichUnit: Unit<UnitEventMap>

      Target unit.

    • abilityId: number

      Abilities' raw code identifier.

    Returns boolean

    Bug

    Removing non-interrupt abilities like divine shile while they're being cast (at the EVENT_PLAYER_UNIT_SPELL_EFFECT point), and while the caster is moving, will cause the caster to become unresponsive to new commands until they reach their ordered move point.

Generated using TypeDoc