Unit.GetNameKey (Civ5 API)

From Civilization Modding Wiki
Revision as of 13:00, 20 September 2012 by DonQuich (talk | contribs) (Bot update)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

This page is a part of the Lua and UI Reference (Civ5).


Function.png This function is a member of Unit.

This is an instance method, invoke it with a colon.


Usage

string Unit:GetNameKey()


Returned Value

No description available.


Source code samples

Redundant occurences have been removed.

ConfirmGiftPopup.lua

UI/InGame/PopupsGeneric/ConfirmGiftPopup.lua
0026
local unitNameKey = pUnit:GetNameKey();


MilitaryOverview.lua

UI/InGame/Popups/MilitaryOverview.lua
0161
sortEntry.name = unit:GetNameKey();


PlotMouseoverInclude.lua

UI/InGame/PlotMouseoverInclude.lua
0272
strUnitText = strUnitText .. Locale.ConvertTextKey("TXT_KEY_MULTIPLAYER_UNIT_TT", pPlayer:GetNickName(), pPlayer:GetCivilizationAdjectiveKey(), unit:GetNameKey());
0276
local desc = Locale.ConvertTextKey("TXT_KEY_PLOTROLL_UNIT_DESCRIPTION_CIV", pPlayer:GetCivilizationAdjectiveKey(), unit:GetNameKey());
0279
strUnitText = strUnitText .. Locale.ConvertTextKey("TXT_KEY_PLOTROLL_UNIT_DESCRIPTION_CIV", pPlayer:GetCivilizationAdjectiveKey(), unit:GetNameKey());


ReturnCivilianPopup.lua

UI/InGame/PopupsGeneric/ReturnCivilianPopup.lua
0026
local strOldUnitKey = pUnit:GetNameKey();


SetUnitName.lua

UI/InGame/Popups/SetUnitName.lua
0120
local unitName = pUnit:GetNameKey();


UnitFlagManager.lua

UI/InGame/UnitFlagManager.lua
0170
local desc = Locale.ConvertTextKey("TXT_KEY_PLOTROLL_UNIT_DESCRIPTION_CIV",  o.m_Player:GetCivilizationAdjectiveKey(), pUnit:GetNameKey());
0173
unitNameString = Locale.ConvertTextKey("TXT_KEY_PLOTROLL_UNIT_DESCRIPTION_CIV",  o.m_Player:GetCivilizationAdjectiveKey(), pUnit:GetNameKey());
0195
local string = Locale.ConvertTextKey("TXT_KEY_MULTIPLAYER_UNIT_TT", o.m_Player:GetNickName(), o.m_Player:GetCivilizationAdjectiveKey(), pUnit:GetNameKey() );
0217
o.m_Instance.UnitIcon:SetToolTipString(Locale.ConvertTextKey("TXT_KEY_MULTIPLAYER_UNIT_TT", o.m_Player:GetNickName(), o.m_Player:GetCivilizationAdjectiveKey(), pUnit:GetNameKey()));
1582
toolTipString = Locale.ConvertTextKey("TXT_KEY_MULTIPLAYER_UNIT_TT", pPlayer:GetNickName(), pPlayer:GetCivilizationAdjectiveKey(), pUnit:GetNameKey());
1585
local desc = Locale.ConvertTextKey("TXT_KEY_PLOTROLL_UNIT_DESCRIPTION_CIV",  pPlayer:GetCivilizationAdjectiveKey(), pUnit:GetNameKey());
1588
toolTipString = Locale.ConvertTextKey("TXT_KEY_PLOTROLL_UNIT_DESCRIPTION_CIV",  pPlayer:GetCivilizationAdjectiveKey(), pUnit:GetNameKey());


UnitFlagManager.lua (G&K)

DLC/Expansion/UI/InGame/UnitFlagManager.lua
0195
string = Locale.ConvertTextKey("TXT_KEY_MULTIPLAYER_UNIT_TT", o.m_Player:GetNickName(), o.m_Player:GetCivilizationAdjectiveKey(), pUnit:GetNameKey() );


UnitList.lua

UI/InGame/UnitList.lua
0131
sortEntry.name = Locale.ConvertTextKey( unit:GetNameKey() );


UnitPanel.lua

UI/InGame/WorldView/UnitPanel.lua
0723
local searchString = Locale.ConvertTextKey( unit:GetNameKey() );
0736
local name = unit and unit:GetNameKey() or "unit is nil";



The initial version of this page was created by the Civ5 API Bot, see the Civ5 API Reference FAQ. Some of the texts come from the 2kgames' wiki and most of code samples are copyrighted to Firaxis.
Functions' signatures were either copied from the 2kgames' wiki, or infered from the Lua source files and the binaries. Errors are possible.
Contributors may find help in the Contributors guide to the Civ5 API.