# Catalog Reference Get

Grammar — Value of reference for player player
FlagsNative | Function

Returns the value of a field for an entry. Use catalog lookup functions to retrieve a data value or other information from the game data. To find the name of a field path, open the data editor and turn on View Raw Data. For example, if you wanted to get the unit for the first index of a train ability, your field path string would be “InfoArray[0].Unit”.

# Arguments

  • string [ reference ] — Reference
  • int — Player

Returns — string

native string CatalogReferenceGet(
	string reference,
	int player,
);

Category: Catalog / Lookup

# Examples

# campaigns/swarmstory.sc2campaign

SwarmCampaignLib.galaxy

// L7398
CatalogReferenceGet("Character,EvolutionMaster,Name[0]", c_playerAny)

# campaigns/voidstory.sc2campaign

VoidCampaignUILib.galaxy

// L2853
CatalogReferenceGet("Unit,SoACaster,Food", 0)

# mods/core.sc2mod

NativeLib.galaxy

// L1739
CatalogReferenceGet(lv_ref, lp_player)

# mods/heroesdata.stormmod

GameDataHelperLib.galaxy

// L18534
CatalogReferenceGet("Abil,RehgarChainHeal,Cost[0].Cooldown.Link", UnitGetOwner(lv_rehgarUnit))

# mods/starcoop/starcoop.sc2mod

LibCOMI.galaxy

// L29591
CatalogReferenceGet("Behavior,SOASuperShield,Duration", c_playerAny)