🌟Ability
Table to work with CAbility
.
CAbility
.CAbility
extends CEntity
Returns the ability owner.
IsPassive(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the ability is passive.
IsBasic(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the ability is basic.
IsUltimate(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the ability is an ultimate.
IsAttributes(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the ability is an attribute or a talent.
GetType(ability: CAbility
): Enum.AbilityTypes
CAbility
): Enum.AbilityTypes
Returns the ability type.
GetBehavior(ability: CAbility
): Enum.AbilityBehavior
CAbility
): Enum.AbilityBehavior
Returns the ability type.
GetTargetTeam(ability: CAbility
): Enum.TargetTeam
CAbility
): Enum.TargetTeam
Returns the target team of this Ability.
GetTargetType(ability: CAbility
): Enum.TargetType
CAbility
): Enum.TargetType
Returns the target type of this Ability.
GetTargetFlags(ability: CAbility
): Enum.TargetFlags
CAbility
): Enum.TargetFlags
Returns the target flags of this Ability.
GetDamageType(ability: CAbility
): Enum.DamageTypes
CAbility
): Enum.DamageTypes
Returns the damage type of this Ability.
GetImmunityType(ability: CAbility
): Enum.ImmunityTypes
CAbility
): Enum.ImmunityTypes
Returns the immunity type of this Ability.
GetDispellableType(ability: CAbility
): Enum.DispellableTypes
CAbility
): Enum.DispellableTypes
Returns the dispel type of this Ability.
name
string
Special value name. Can be found in the ability KV file. (assets/data/npc_abilities.json
)
lvl [?]
integer
Ability level, if -1 will automatically get lvl. (default: -1)
WRONG API FIX ME IT MUST BE GetSpecialValueFor.
IsReady(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the ability is ready to use.
SecondsSinceLastUse(ability: CAbility
): number
CAbility
): number
Returns the number of seconds passed from the last usage of the ability. Will return -1 if the ability is not on the cooldown.
GetDamage(ability: CAbility
): number
CAbility
): number
Returns the ability damage from assets/data/npc_abilities.json field. Will return 0.0 if the ability doesn't contain this field.
GetLevel(ability: CAbility
): integer
CAbility
): integer
Returns the current ability level.
include_modifiers [?]
boolean
(default: true)
Gets the cast delay of this Ability.
GetCastPointModifier(ability: CAbility
): number
CAbility
): number
Gets the cast delay modifier of this Ability.
mana [?]
number
(default: 0.0)
Returns true
if the ability is currently castable. Checks for mana cost, cooldown, level,
and slot for items.
IsChannelling(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the ability is in channeling state. Example: teleport, rearm, powershot
etc.
GetName(ability: CAbility
): string
CAbility
): string
Returns the ability name or empty string.
GetBaseName(ability: CAbility
): string
CAbility
): string
Returns the ability base name or empty string.
IsInnate(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the ability is innate.
IsInnatePassive(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the ability is passive innate.
GetMaxLevel(ability: CAbility
): integer
CAbility
): integer
Returns ability's max level.
IsGrantedByFacet(ability: CAbility
): boolean
CAbility
): boolean
Returns true
when abiliti is granted by facet.
CanBeExecuted(ability: CAbility
): Enum.AbilityCastResult
CAbility
): Enum.AbilityCastResult
Returns -1
if ability can be executed.
IsOwnersManaEnough(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if enough mana for cast.
CastNoTarget(ability: CAbility
, queue [?]
: boolean
, push [?]
: boolean
, execute_fast [?]
: boolean
, identifier [?]
: string
): nil
CAbility
, queue [?]
: boolean
, push [?]
: boolean
, execute_fast [?]
: boolean
, identifier [?]
: string
): nil
queue [?]
boolean
Will add order to the cast queue. (default: false)
push [?]
boolean
Will push order to the OnPrepareUnitOrders callback. (default: false)
execute_fast [?]
boolean
Will push order to start of the order's list. (default: false)
identifier [?]
string
The identifier which will be passed to OnPrepareUnitOrders
callback. (default: nil)
Casts the ability that doesn't require a target or position.
queue [?]
boolean
Will add order to the cast queue. (default: false)
push [?]
boolean
Will push order to the OnPrepareUnitOrders callback. (default: false)
execute_fast [?]
boolean
Will push order to start of the order's list. (default: false)
identifier [?]
string
The identifier which will be passed to OnPrepareUnitOrders
callback. (default: nil)
Casts the ability at a specified position.
queue [?]
boolean
Will add order to the cast queue. (default: false)
push [?]
boolean
Will push order to the OnPrepareUnitOrders callback. (default: false)
execute_fast [?]
boolean
Will push order to start of the order's list. (default: false)
identifier [?]
string
The identifier which will be passed to OnPrepareUnitOrders
callback. (default: nil)
Casts the ability on a specified target.
Toggle(ability: CAbility
, queue [?]
: boolean
, push [?]
: boolean
, execute_fast [?]
: boolean
, identifier [?]
: string
): nil
CAbility
, queue [?]
: boolean
, push [?]
: boolean
, execute_fast [?]
: boolean
, identifier [?]
: string
): nil
queue [?]
boolean
Will add order to the cast queue. (default: false)
push [?]
boolean
Will push order to the OnPrepareUnitOrders callback. (default: false)
execute_fast [?]
boolean
Will push order to start of the order's list. (default: false)
identifier [?]
string
The identifier which will be passed to OnPrepareUnitOrders
callback. (default: nil)
Toggles the ability. Example: Armlet.
ToggleMod(ability: CAbility
, queue [?]
: boolean
, push [?]
: boolean
, execute_fast [?]
: boolean
, identifier [?]
: string
): nil
CAbility
, queue [?]
: boolean
, push [?]
: boolean
, execute_fast [?]
: boolean
, identifier [?]
: string
): nil
queue [?]
boolean
Will add order to the cast queue. (default: false)
push [?]
boolean
Will push order to the OnPrepareUnitOrders callback. (default: false)
execute_fast [?]
boolean
Will push order to start of the order's list. (default: false)
identifier [?]
string
The identifier which will be passed to OnPrepareUnitOrders
callback. (default: nil)
Toggles the ability modifier. Example: Frost Arrows, Medusa's Shield.
Returns if the ability is upgradable with a specific reason.
GetIndex(ability: CAbility
): integer
CAbility
): integer
Returns the index of the ability in the ability owner's list. The index can be used in NPC.GetAbilityByIndex later.
GetCastRange(ability: CAbility
): number
CAbility
): number
Returns the cast range of the ability.
IsHidden(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if ability is hidden. Example: Zeus's Nimbus before purchasing agh.
IsActivated(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the ability is in an activated state.
GetDirtyButtons(ability: CAbility
): integer
CAbility
): integer
Returns we don't know what :).
GetToggleState(ability: CAbility
): boolean
CAbility
): boolean
Returns if the ability is toggled. Example: Medusa's Shield.
IsInAbilityPhase(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the ability is in the cast state. Examples: Nature's Prophet's Teleport,
Meepo's Poof.
GetCooldown(ability: CAbility
): number
CAbility
): number
Returns the amount of time before the ability can be cast.
GetCooldownLength(ability: CAbility
): number
CAbility
): number
Returns the amount of time the ability couldn't be cast after being used.
GetManaCost(ability: CAbility
): number
CAbility
): number
Returns the ability mana cost.
GetAutoCastState(ability: CAbility
): boolean
CAbility
): boolean
Returns the autocast state of the ability.
GetAltCastState(ability: CAbility
): boolean
CAbility
): boolean
Returns the alt cast state of the ability. Example: Doom's Devour.
GetChannelStartTime(ability: CAbility
): number
CAbility
): number
Returns the gametime the channeling of the ability will start. Requires the ability to be in the cast state when called.
GetCastStartTime(ability: CAbility
): number
CAbility
): number
Returns the gametime the ability will be casted. Requires the ability to be in the cast state when called.
IsInIndefinateCooldown(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the cooldown of the ability is indefinite.
IsInIndefinateCooldown(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the cooldown of the ability is frozen.
GetOverrideCastPoint(ability: CAbility
): number
CAbility
): number
Returns the overridden cast point. Example: Arcane Blink.
IsStolen(ability: CAbility
): boolean
CAbility
): boolean
Returns true
if the ability is stolen.
GetCurrentCharges(ability: CAbility
): integer
CAbility
): integer
Returns the number of charges available.
ChargeRestoreTimeRemaining(ability: CAbility
): integer
CAbility
): integer
Returns the remaining time for the next charge to restore.
GetKeybind(ability: Ability
): string
Ability
): string
ability
Ability
Returns the keybind of the ability.
Last updated