# For Each Learnable Ability On Unit
Grammar — For each learnable ability abil in unit do (Actions)
Flags —SubFunctions
|Action
Runs the contained actions once for each learnable ability on the specified unit.
# Arguments
anyvariable
— Abilityunit
— Unit
Returns — void
#AUTOVAR(unit, unit) = #PARAM(unit);
#AUTOVAR(i) = 1;
for ( ; #AUTOVAR(i) <= UnitAbilityCount(#AUTOVAR(unit)) ; #AUTOVAR(i) += 1 ) {
#PARAM(abil) = UnitAbilityGet(#AUTOVAR(unit), #AUTOVAR(i));
#SUBFUNCS(actions)
}
# Related
Category: Ability / Loops
- For Each Ability On Unit — macro
- For Each Learnable Ability On Unit — macro
# Examples
— None found —