# Unit Resources
Grammar — u (current|Current/Default) resource amount
Flags —Function
Returns the amount of resources a unit has.
# Arguments
unit
— Unitbool
[ preset::CurrentDefaultOption ] — Current
Returns — int
int libNtve_gf_UnitGetPropertyResources(
unit lp_u,
bool lp_current,
);
# Related
Category: Unit / Properties
- [F] —
string
[ gamelink::Unit ] — Unit Type Of Unit — ( UnitGetType ) - [F] —
int
— Unit Tag — ( UnitGetTag ) - [F] —
int
— Unit Seed — ( UnitGetSeed ) - [F] —
void
— Unit Property Changes — ( TriggerAddEventUnitProperty ) - [F] —
int
[ preset::Unit_Property ] — Triggering Unit Property — ( EventUnitProperty ) - [F] —
int
— Triggering Unit Property Change (Integer) — ( EventUnitPropertyChangeInt ) - [F] —
fixed
— Triggering Unit Property Change (Real) — ( EventUnitPropertyChangeFixed ) - [F] —
void
— Set Unit Property — ( UnitSetPropertyFixed ) - [F] —
void
— Set Unit State — ( UnitSetState ) - [F] —
void
— Set Unit Seed — ( UnitSetSeed ) - [F] —
void
— Reset Unit Seed — ( UnitResetSeed ) - [F] —
void
— Make Unit Invulnerable — ( libNtve_gf_MakeUnitInvulnerable ) - [F] —
void
— Make Unit Uncommandable — ( libNtve_gf_MakeUnitUncommandable ) - [F] —
fixed
— Unit Property — ( UnitGetPropertyFixed ) - [F] —
int
— Unit Property (Int) — ( UnitGetPropertyInt ) - [F] —
fixed
— Unit Type Property — ( UnitTypeGetProperty ) - [F] —
bool
— Unit Classification Check — ( UnitTestState ) - [F] —
bool
— Unit Type Classification Check — ( UnitTypeTestFlag ) - [F] —
bool
— Unit Type Attribute Check — ( UnitTypeTestAttribute ) - [F] —
bool
— Unit Targetable Check — ( UnitTestPlane ) - [F] —
bool
— Unit Is Invulnerable — ( libNtve_gf_UnitIsInvulnerable ) - [F] —
int
— Unit Kills — ( libNtve_gf_UnitGetPropertyKills ) - [F] —
int
— Unit Resources — ( libNtve_gf_UnitGetPropertyResources ) - [F] —
point
— Unit Attachment Point — ( UnitGetAttachmentPoint ) - [F] —
text
— Name Of Unit Type — ( UnitTypeGetName ) - [F] —
string
— Gender Code Of Unit Type — ( UnitTypeGetGenderCode ) - [F] —
int
— Unit Type Cost — ( UnitTypeGetCost ) - [F] —
bool
— Unit Type Is Affected By Upgrade — ( UnitTypeIsAffectedByUpgrade ) - [F] —
void
— Reset Movement Speed — ( UnitResetSpeed ) - [F] —
bool
— Unit Uses Mover — ( UnitMoverExists ) - [F] —
bool
— Unit Type Uses Mover — ( libNtve_gf_UnitMoverExists ) - [F] —
string
[ gamelink::Unit ] — Unit Type From String — ( UnitTypeFromString ) - [F] —
void
— Set Unit Color — ( UnitSetTeamColorIndex ) - [F] —
void
— Set Unit Info Button - Ability Tooltip — ( libNtve_gf_SetUnitInfoButtonAbilityTooltip ) - [F] —
void
— Set Unit Info Button - Button Tooltip — ( libNtve_gf_SetUnitInfoButtonButtonTooltip ) - [F] —
void
— Set Unit Info Button - Item Tooltip — ( libNtve_gf_SetUnitInfoButtonItemTooltip ) - [F] —
void
— Reset Unit Info Button - Ability Tooltip — ( libNtve_gf_ResetUnitInfoButtonAbilityTooltip ) - [F] —
void
— Reset Unit Info Button - Button Tooltip — ( libNtve_gf_ResetUnitInfoButtonButtonTooltip ) - [F] —
void
— Reset Unit Info Button - Item Tooltip — ( libNtve_gf_ResetUnitInfoButtonItemTooltip ) - [F] —
void
— Set Unit Command Button Tooltip — ( UnitSetInfoButtonTooltip ) - [F] —
void
— Reset Unit Command Button Tooltip — ( UnitClearInfoButtonTooltip ) - [F] —
void
— Set Unit Highlight Cursor — ( UnitSetCursor ) - [F] —
void
— Set Unit Ping Cursor — ( UnitSetPingCursor ) - [F] —
void
— Set Unit Info — ( UnitSetInfoText ) - [F] —
void
— Set Unit Info Text — ( UnitSetInfoText2 ) - [F] —
void
— Set Unit Info Tip — ( UnitSetInfoTip ) - [F] —
void
— Set Unit Info SubTip — ( UnitSetInfoSubTip ) - [F] —
void
— Clear Unit Info — ( UnitClearInfoText ) - [F] —
void
— Set Unit Status Bar State (Deprecated) — ( UnitForceStatusBar ) - [F] —
void
— Show Unit Status Bar — ( UnitStatusBarOverride ) - [F] —
void
— Hide Unit Status Bar — ( UnitStatusBarClearOverride ) - [F] —
void
— Set Unit Scale — ( UnitSetScale ) - [F] —
void
— Set Unit Model Variation — ( libNtve_gf_UnitSetVariation ) - [F] —
void
— Change Unit Height — ( UnitSetHeight ) - [F] —
fixed
— Height Of Unit — ( UnitGetHeight ) - [F] —
void
— Change Unit Damage — ( libNtve_gf_ChangeUnitDamage ) - [F] —
unit
— Add On Child — ( UnitAddOnChild ) - [F] —
unit
— Add On Parent — ( UnitAddOnParent )
# Examples
# campaigns/liberty.sc2campaign
// L2881
libNtve_gf_UnitGetPropertyResources(autoBC161B9B_var, c_unitPropCurrent)
// L2881
libNtve_gf_UnitGetPropertyResources(autoBC161B9B_var, c_unitPropCurrent)
// L5637
libNtve_gf_UnitGetPropertyResources(UnitFromId(10), c_unitPropCurrent)
// L5638
libNtve_gf_UnitGetPropertyResources(UnitFromId(9), c_unitPropCurrent)
// L5639
libNtve_gf_UnitGetPropertyResources(UnitFromId(8), c_unitPropCurrent)
// L5640
libNtve_gf_UnitGetPropertyResources(UnitFromId(7), c_unitPropCurrent)
// L5641
libNtve_gf_UnitGetPropertyResources(UnitFromId(6), c_unitPropCurrent)
// L5642
libNtve_gf_UnitGetPropertyResources(UnitFromId(5), c_unitPropCurrent)
// L5643
libNtve_gf_UnitGetPropertyResources(UnitFromId(4), c_unitPropCurrent)
// L5644
libNtve_gf_UnitGetPropertyResources(UnitFromId(3), c_unitPropCurrent)
// L5647
libNtve_gf_UnitGetPropertyResources(UnitFromId(13), c_unitPropCurrent)
// L8355
libNtve_gf_UnitGetPropertyResources(auto04D6847B_var, c_unitPropCurrent)
// L8355
libNtve_gf_UnitGetPropertyResources(auto04D6847B_var, c_unitPropCurrent)
// L5637
libNtve_gf_UnitGetPropertyResources(UnitFromId(10), c_unitPropCurrent)
// L5638
libNtve_gf_UnitGetPropertyResources(UnitFromId(9), c_unitPropCurrent)
// L5639
libNtve_gf_UnitGetPropertyResources(UnitFromId(8), c_unitPropCurrent)
// L5640
libNtve_gf_UnitGetPropertyResources(UnitFromId(7), c_unitPropCurrent)
// L5641
libNtve_gf_UnitGetPropertyResources(UnitFromId(6), c_unitPropCurrent)
// L5642
libNtve_gf_UnitGetPropertyResources(UnitFromId(5), c_unitPropCurrent)
// L5643
libNtve_gf_UnitGetPropertyResources(UnitFromId(4), c_unitPropCurrent)
// L5644
libNtve_gf_UnitGetPropertyResources(UnitFromId(3), c_unitPropCurrent)
// L5647
libNtve_gf_UnitGetPropertyResources(UnitFromId(13), c_unitPropCurrent)
// L1720
libNtve_gf_UnitGetPropertyResources(auto27D91F20_var, c_unitPropCurrent)
// L1732
libNtve_gf_UnitGetPropertyResources(auto51A0BC80_var, c_unitPropCurrent)
// L4891
libNtve_gf_UnitGetPropertyResources(UnitFromId(4), c_unitPropCurrent)
// L4892
libNtve_gf_UnitGetPropertyResources(UnitFromId(6), c_unitPropCurrent)
// L4893
libNtve_gf_UnitGetPropertyResources(UnitFromId(7), c_unitPropCurrent)
// L4894
libNtve_gf_UnitGetPropertyResources(UnitFromId(5), c_unitPropCurrent)
// L4895
libNtve_gf_UnitGetPropertyResources(UnitFromId(2), c_unitPropCurrent)
// L4896
libNtve_gf_UnitGetPropertyResources(UnitFromId(9), c_unitPropCurrent)
// L4897
libNtve_gf_UnitGetPropertyResources(UnitFromId(3), c_unitPropCurrent)
// L4898
libNtve_gf_UnitGetPropertyResources(UnitFromId(8), c_unitPropCurrent)
// L4900
libNtve_gf_UnitGetPropertyResources(UnitFromId(459), c_unitPropCurrent)
// L1720
libNtve_gf_UnitGetPropertyResources(auto27D91F20_var, c_unitPropCurrent)
// L1732
libNtve_gf_UnitGetPropertyResources(auto51A0BC80_var, c_unitPropCurrent)
// L4891
libNtve_gf_UnitGetPropertyResources(UnitFromId(4), c_unitPropCurrent)
// L4892
libNtve_gf_UnitGetPropertyResources(UnitFromId(6), c_unitPropCurrent)
// L4893
libNtve_gf_UnitGetPropertyResources(UnitFromId(7), c_unitPropCurrent)
// L4894
libNtve_gf_UnitGetPropertyResources(UnitFromId(5), c_unitPropCurrent)
// L4895
libNtve_gf_UnitGetPropertyResources(UnitFromId(2), c_unitPropCurrent)
// L4896
libNtve_gf_UnitGetPropertyResources(UnitFromId(9), c_unitPropCurrent)
// L4897
libNtve_gf_UnitGetPropertyResources(UnitFromId(3), c_unitPropCurrent)
// L4898
libNtve_gf_UnitGetPropertyResources(UnitFromId(8), c_unitPropCurrent)
// L4900
libNtve_gf_UnitGetPropertyResources(UnitFromId(459), c_unitPropCurrent)
// L5323
libNtve_gf_UnitGetPropertyResources(UnitFromId(65), c_unitPropCurrent)
// L5324
libNtve_gf_UnitGetPropertyResources(UnitFromId(68), c_unitPropCurrent)
// L5325
libNtve_gf_UnitGetPropertyResources(UnitFromId(67), c_unitPropCurrent)
// L5326
libNtve_gf_UnitGetPropertyResources(UnitFromId(66), c_unitPropCurrent)
// L5327
libNtve_gf_UnitGetPropertyResources(UnitFromId(292), c_unitPropCurrent)
// L9149
libNtve_gf_UnitGetPropertyResources(UnitFromId(17), c_unitPropCurrent)
// L9150
libNtve_gf_UnitGetPropertyResources(UnitFromId(286), c_unitPropCurrent)
// L9151
libNtve_gf_UnitGetPropertyResources(UnitFromId(246), c_unitPropCurrent)
// L9152
libNtve_gf_UnitGetPropertyResources(UnitFromId(378), c_unitPropCurrent)
// L9153
libNtve_gf_UnitGetPropertyResources(UnitFromId(382), c_unitPropCurrent)
// L9154
libNtve_gf_UnitGetPropertyResources(UnitFromId(287), c_unitPropCurrent)
// L9155
libNtve_gf_UnitGetPropertyResources(UnitFromId(383), c_unitPropCurrent)
// L9157
libNtve_gf_UnitGetPropertyResources(UnitFromId(379), c_unitPropCurrent)
// L9944
libNtve_gf_UnitGetPropertyResources(UnitFromId(8), c_unitPropCurrent)
// L9945
libNtve_gf_UnitGetPropertyResources(UnitFromId(7), c_unitPropCurrent)
// L9946
libNtve_gf_UnitGetPropertyResources(UnitFromId(6), c_unitPropCurrent)
// L9947
libNtve_gf_UnitGetPropertyResources(UnitFromId(5), c_unitPropCurrent)
// L9948
libNtve_gf_UnitGetPropertyResources(UnitFromId(4), c_unitPropCurrent)
// L9949
libNtve_gf_UnitGetPropertyResources(UnitFromId(3), c_unitPropCurrent)
// L9950
libNtve_gf_UnitGetPropertyResources(UnitFromId(2), c_unitPropCurrent)
// L9951
libNtve_gf_UnitGetPropertyResources(UnitFromId(1), c_unitPropCurrent)
// L9953
libNtve_gf_UnitGetPropertyResources(UnitFromId(9), c_unitPropCurrent)
// L5323
libNtve_gf_UnitGetPropertyResources(UnitFromId(65), c_unitPropCurrent)
// L5324
libNtve_gf_UnitGetPropertyResources(UnitFromId(68), c_unitPropCurrent)
// L5325
libNtve_gf_UnitGetPropertyResources(UnitFromId(67), c_unitPropCurrent)
// L5326
libNtve_gf_UnitGetPropertyResources(UnitFromId(66), c_unitPropCurrent)
// L5327
libNtve_gf_UnitGetPropertyResources(UnitFromId(292), c_unitPropCurrent)
// L9149
libNtve_gf_UnitGetPropertyResources(UnitFromId(17), c_unitPropCurrent)
// L9150
libNtve_gf_UnitGetPropertyResources(UnitFromId(286), c_unitPropCurrent)
// L9151
libNtve_gf_UnitGetPropertyResources(UnitFromId(246), c_unitPropCurrent)
// L9152
libNtve_gf_UnitGetPropertyResources(UnitFromId(378), c_unitPropCurrent)
// L9153
libNtve_gf_UnitGetPropertyResources(UnitFromId(382), c_unitPropCurrent)
// L9154
libNtve_gf_UnitGetPropertyResources(UnitFromId(287), c_unitPropCurrent)
// L9155
libNtve_gf_UnitGetPropertyResources(UnitFromId(383), c_unitPropCurrent)
// L9157
libNtve_gf_UnitGetPropertyResources(UnitFromId(379), c_unitPropCurrent)
// L9944
libNtve_gf_UnitGetPropertyResources(UnitFromId(8), c_unitPropCurrent)
// L9945
libNtve_gf_UnitGetPropertyResources(UnitFromId(7), c_unitPropCurrent)
// L9946
libNtve_gf_UnitGetPropertyResources(UnitFromId(6), c_unitPropCurrent)
// L9947
libNtve_gf_UnitGetPropertyResources(UnitFromId(5), c_unitPropCurrent)
// L9948
libNtve_gf_UnitGetPropertyResources(UnitFromId(4), c_unitPropCurrent)
// L9949
libNtve_gf_UnitGetPropertyResources(UnitFromId(3), c_unitPropCurrent)
// L9950
libNtve_gf_UnitGetPropertyResources(UnitFromId(2), c_unitPropCurrent)
// L9951
libNtve_gf_UnitGetPropertyResources(UnitFromId(1), c_unitPropCurrent)
// L9953
libNtve_gf_UnitGetPropertyResources(UnitFromId(9), c_unitPropCurrent)
# mods/starcoop/starcoop.sc2mod
// L6642
libNtve_gf_UnitGetPropertyResources(lv_indexResource, c_unitPropCurrent)
// L6669
libNtve_gf_UnitGetPropertyResources(lv_indexResource, c_unitPropCurrent)
// L9031
libNtve_gf_UnitGetPropertyResources(lv_indexResource, c_unitPropCurrent)
// L9039
libNtve_gf_UnitGetPropertyResources(lv_indexResource, c_unitPropCurrent)