# Charge Regen Remaining For Unit Ability
Grammar — Charge regen time remaining of charge inCharge on ability inAbil on unit inUnit
Flags —Native
|Function
Returns the charge regen time remaining for the specified ability charge link.
# Arguments
unit
— Unitstring
<gamelink::Abil> — Abilitystring
<charge> — Charge
Returns — fixed
native fixed UnitAbilityGetChargeRegen(
unit inUnit,
string inAbil,
string inCharge,
);
# Related
Category: Unit / Charges And Cooldowns
- Add Charge Remaining Regen Time For Unit Behavior —
void
— UnitBehaviorAddChargeRegenRemaining - Add Charge Remaining Regen Time For Unit Ability —
void
— UnitAbilityAddChargeRegenRemaining - Add Charge Remaining Regen Time For Unit —
void
— UnitAddChargeRegenRemaining - Add Charge Full Regen Time For Unit Behavior —
void
— UnitBehaviorAddChargeRegenFull - Add Charge Full Regen Time For Unit Ability —
void
— UnitAbilityAddChargeRegenFull - Add Charge Full Regen Time For Unit —
void
— UnitAddChargeRegenFull - Add Charge Used For Unit Behavior —
void
— UnitBehaviorAddChargeUsed - Add Charge Used For Unit Ability —
void
— UnitAbilityAddChargeUsed - Add Charge Used For Unit —
void
— UnitAddChargeUsed - Remove Charge Used For Unit Behavior —
void
— libNtve_gf_UnitBehaviorRemoveChargeUsed - Remove Charge Used For Unit Ability —
void
— libNtve_gf_UnitAbilityRemoveChargeUsed - Remove Charge Used For Unit —
void
— libNtve_gf_UnitRemoveChargeUsed - Charge Regen Remaining For Unit Behavior —
fixed
— UnitBehaviorGetChargeRegen - Charge Regen Remaining For Unit Ability —
fixed
— UnitAbilityGetChargeRegen - Charge Regen Remaining For Unit —
fixed
— UnitGetChargeRegen - Charge Regen Full For Unit Behavior —
fixed
— UnitBehaviorGetChargeRegenFull - Charge Regen Full For Unit Ability —
fixed
— UnitAbilityGetChargeRegenFull - Charge Regen Full For Unit —
fixed
— UnitGetChargeRegenFull - Charge Used For Unit Behavior —
fixed
— UnitBehaviorGetChargeUsed - Charge Used For Unit Ability —
fixed
— UnitAbilityGetChargeUsed - Charge Used For Unit —
fixed
— UnitGetChargeUsed - Add Cooldown For Unit Behavior —
void
— UnitBehaviorAddCooldown - Add Cooldown For Unit Ability —
void
— UnitAbilityAddCooldown - Modify Cooldown For Unit —
void
— UnitModifyCooldown - Clear Cooldowns For Unit —
void
— UnitClearCooldowns - Remove Cooldown For Unit Behavior —
void
— libNtve_gf_UnitBehaviorRemoveCooldown - Remove Cooldown For Unit Ability —
void
— libNtve_gf_UnitAbilityRemoveCooldown - Remove Cooldown For Unit —
void
— libNtve_gf_UnitRemoveCooldown - Cooldown For Unit Behavior —
fixed
— UnitBehaviorGetCooldown - Cooldown For Unit Abilty —
fixed
— UnitAbilityGetCooldown - Cooldown For Unit —
fixed
— UnitGetCooldown - Activate Ability Cooldowns —
void
— UnitAbilitySpendExplicit - Reset Ability Cooldowns —
void
— UnitAbilityReset - Ability Charge Info For Unit —
fixed
— UnitAbilityChargeInfo
# Examples
mods/core.sc2mod — base.sc2data/TriggerLibs/NativeLib.galaxy:5825
// Automatic Variable Declarations
// Implementation
UnitAbilityAddChargeRegen(lp_inUnit, lp_inAbil, lp_inCharge, (-1.0 * UnitAbilityGetChargeRegen(lp_inUnit, lp_inAbil, lp_inCharge)));
}
mods/core.stormmod — base.stormdata/TriggerLibs/NativeLib.galaxy:4963
// Automatic Variable Declarations
// Implementation
UnitAbilityAddChargeRegen(lp_inUnit, lp_inAbil, lp_inCharge, (-1.0 * UnitAbilityGetChargeRegen(lp_inUnit, lp_inAbil, lp_inCharge)));
}
mods/starcoop/starcoop.sc2mod — base.sc2data/LibCOMI.galaxy:9840
// Implementation
while (true) {
while (!(((UnitAbilityGetCooldown(lp_unit, lp_ability, lp_cooldownLink) > 20.0) || ((UnitAbilityChargeInfo(lp_unit, AbilityCommand(lp_ability, 0), c_unitAbilChargeCountLeft) == 0.0) && (UnitAbilityGetChargeRegen(lp_unit, lp_ability, lp_cooldownLink) > 20.0))))) {
Wait(1.0, c_timeGame);
}
mods/starcoop/starcoop.sc2mod — base.sc2data/LibCOMI.galaxy:9843
Wait(1.0, c_timeGame);
}
while (!((UnitAbilityGetCooldown(lp_unit, lp_ability, lp_cooldownLink) <= 0.0) && ((UnitAbilityGetChargeRegen(lp_unit, lp_ability, lp_cooldownLink) <= 0.0) || (UnitAbilityChargeInfo(lp_unit, AbilityCommand(lp_ability, 0), c_unitAbilChargeCountLeft) > 0.0)))) {
Wait(1.0, c_timeGame);
}
mods/starcoop/starcoop.sc2mod — base.sc2data/LibCOMI.galaxy:10248
// Implementation
while (true) {
while (!((libCOMI_gv_cM_HornerVOFleetOffCooldown == false) && ((UnitAbilityGetCooldown(lp_unit, lp_ability, lp_cooldownLink) > 20.0) || ((UnitAbilityChargeInfo(lp_unit, AbilityCommand(lp_ability, 0), c_unitAbilChargeCountLeft) == 0.0) && (UnitAbilityGetChargeRegen(lp_unit, lp_ability, lp_cooldownLink) > 20.0))))) {
Wait(1.0, c_timeGame);
}
mods/starcoop/starcoop.sc2mod — base.sc2data/LibCOMI.galaxy:10251
Wait(1.0, c_timeGame);
}
while (!((UnitAbilityGetCooldown(lp_unit, lp_ability, lp_cooldownLink) <= 0.0) && ((UnitAbilityGetChargeRegen(lp_unit, lp_ability, lp_cooldownLink) <= 0.0) || (UnitAbilityChargeInfo(lp_unit, AbilityCommand(lp_ability, 0), c_unitAbilChargeCountLeft) > 0.0)))) {
Wait(1.0, c_timeGame);
}