# Set Player Skin
Grammar — Set Player player’s hero to skin.
Flags —Native
|Action
Sets the hero of the specified player.
# Arguments
int
— Playerstring
<gamelink::Skin> — Skin
Returns — void
native void PlayerSetSkin(int inPlayer, string inSkin);
# Related
Category: Player / Player Settings
- Modify Player Property (Integer) —
void
— PlayerModifyPropertyInt - Modify Player Property (Real) —
void
— PlayerModifyPropertyFixed - Player Property (Integer) —
int
— PlayerGetPropertyInt - Player Property (Real) —
fixed
— PlayerGetPropertyFixed - Modify Player Score (Integer) —
void
— PlayerScoreValueSetFromInt - Modify Player Score (Real) —
void
— PlayerScoreValueSetFromFixed - Player Score Value (Integer) —
int
— PlayerScoreValueGetAsInt - Player Score Value (Real) —
fixed
— PlayerScoreValueGetAsFixed - Turn Player Flag On/Off —
void
— PlayerSetState - Player Flag Check —
bool
— PlayerGetState - Player License Check —
bool
— PlayerHasLicense - Player Access Check —
bool
— PlayerHasAccessTo - Player Has Reward —
bool
— PlayerHasReward - Player Has Talent —
bool
— PlayerHasTalent - Name Of Player —
text
— PlayerName - Handle Of Player —
string
— PlayerHandle - Race Of Player —
string
<gamelink::Race> — PlayerRace - Hero Of Player —
string
<gamelink::Hero> — PlayerHero - Skin Of Player —
string
<gamelink::Skin> — PlayerSkin - Mount Of Player —
string
<gamelink::Mount> — PlayerMount - Spray Of Player —
string
<gamelink::Spray> — PlayerSpray - Artifact Of Player —
string
<gamelink::Artifact> — PlayerArtifact - Artifact Rank Of Player —
int
— PlayerArtifactRank - Commander Of Player —
string
<gamelink::Commander> — PlayerCommander - Commander Level Of Player —
int
— PlayerCommanderLevel - Commander Mastery Level Of Player —
int
— PlayerCommanderMasteryLevel - Commander Mastery Talent Rank Of Player —
int
— PlayerCommanderMasteryTalentRank - Commander Selected Prestige Of Player —
int
— PlayerCommanderSelectedPrestige - Brutal Plus Difficulty of Player —
int
— PlayerBrutalPlusDifficulty - Retry Mutation Index of Player —
int
— PlayerRetryMutation - Allied Commander Enemy Wave Type —
int
— PlayerACEnemyWaveType - Start Location Of Player —
point
— PlayerStartLocation - Controller Of Player —
int
<preset::PlayerController> — PlayerType - Status Of Player —
int
<preset::PlayerStatus> — PlayerStatus - Set Player Color —
void
— PlayerSetColorIndex - Set Player Race —
void
— PlayerSetRace - Set Player Hero —
void
— PlayerSetHero - Set Player Skin —
void
— PlayerSetSkin - Set Player Console Skin —
void
— PlayerSetConsoleSkin - Apply Player Skin —
void
— PlayerApplySkin - Apply Player Skin (Replacing Existing Unit) —
void
— libNtve_gf_PlayerApplySkinReplacingExistingUnit - Set Player Mount —
void
— PlayerSetMount - Set Player Spray —
void
— PlayerSetSpray - Set Player Commander —
void
— PlayerSetCommander - Set Player Commander Level —
void
— PlayerSetCommanderLevel - Set Player Commander Mastery Level —
void
— PlayerSetCommanderMasteryLevel - Set Player Death Timer —
void
— PlayerSetDeathTimer - Set Player Bounds —
void
— PlayerSetBounds - Add Player Talent —
void
— PlayerAddTalent - Remove Player Talent —
void
— PlayerRemoveTalent - Add Player Response —
void
— PlayerAddResponse - Remove Player Response —
void
— PlayerRemoveResponse - Clear Player Response —
void
— PlayerClearResponse - Player Color —
int
<playercolor> — PlayerGetColorIndex - Override Player Option —
void
— PlayerOptionOverride - Player Hotkey Profile —
string
— PlayerGetHotkeyProfile - Player Property Changed —
void
— TriggerAddEventPlayerPropChange - Player Joins Game —
void
— TriggerAddEventPlayerJoin - Player Leaves Game —
void
— TriggerAddEventPlayerLeft - Triggering Player —
int
— EventPlayer - Triggering Player Property —
int
<preset::Player_Property_Get> — EventPlayerProperty - Triggering Player Property Change (Integer) —
int
— EventPlayerPropertyChangeInt - Triggering Player Property Change (Real) —
fixed
— EventPlayerPropertyChangeFixed - Player Add Label —
void
— PlayerAddLabel - Player Remove Label —
void
— PlayerRemoveLabel - Player Remove All Labels —
void
— PlayerRemoveAllLabels - Player Has Label —
bool
— PlayerHasLabel - Player Add Reward —
void
— PlayerAddReward
# Examples
mods/heroesbrawlmods/brawlmapmods/coop/pvebrawlmod.stormmod — base.stormdata/LibPVEB.galaxy:552
lv_player = libPVEB_gv_pBNPCHeroes[lv_heroIndex].lv_player;
if ((libPVEB_gv_pBNPCHeroes[lv_heroIndex].lv_skin != null)) {
PlayerSetSkin(lv_player, libPVEB_gv_pBNPCHeroes[lv_heroIndex].lv_skin);
}
mods/heroesbrawlmods/brawlmapmods/coop/pvemod.stormmod — base.stormdata/LibPVEM.galaxy:759
libGame_gv_players[lv_player].lv_suppressKillLogwhenKilled = false;
if ((libPVEM_gv_pvENPCHeroes[lv_heroIndex].lv_skin != null)) {
PlayerSetSkin(lv_player, libPVEM_gv_pvENPCHeroes[lv_heroIndex].lv_skin);
}
mods/heroesbrawlmods/brawlmapmods/lunarfestival.stormmod — base.stormdata/LibLNYF.galaxy:287
if (auto19C27B59_val == 0) {
libGame_gv_players[lp_player].lv_heroIndex = libCore_gf_GetIndexFromHero("Chen");
PlayerSetSkin(lp_player, "ChenLunar");
}
else if (auto19C27B59_val == 1) {
mods/heroesbrawlmods/brawlmapmods/lunarfestival.stormmod — base.stormdata/LibLNYF.galaxy:291
else if (auto19C27B59_val == 1) {
libGame_gv_players[lp_player].lv_heroIndex = libCore_gf_GetIndexFromHero("LiLi");
PlayerSetSkin(lp_player, "LiLiLunarLiLi");
}
else if (auto19C27B59_val == 2) {
mods/heroesbrawlmods/brawlmapmods/lunarfestival.stormmod — base.stormdata/LibLNYF.galaxy:295
else if (auto19C27B59_val == 2) {
libGame_gv_players[lp_player].lv_heroIndex = libCore_gf_GetIndexFromHero("Illidan");
PlayerSetSkin(lp_player, "IllidanLunar");
}
else if (auto19C27B59_val == 3) {
mods/heroesbrawlmods/brawlmapmods/lunarfestival.stormmod — base.stormdata/LibLNYF.galaxy:299
else if (auto19C27B59_val == 3) {
libGame_gv_players[lp_player].lv_heroIndex = libCore_gf_GetIndexFromHero("Wizard");
PlayerSetSkin(lp_player, "WizardSkinLunar");
}
else if (auto19C27B59_val == 4) {
mods/heroesbrawlmods/brawlmapmods/lunarfestival.stormmod — base.stormdata/LibLNYF.galaxy:303
else if (auto19C27B59_val == 4) {
libGame_gv_players[lp_player].lv_heroIndex = libCore_gf_GetIndexFromHero("Jaina");
PlayerSetSkin(lp_player, "LunarJaina");
}
else if (auto19C27B59_val == 5) {
mods/heroesbrawlmods/brawlmapmods/lunarfestival.stormmod — base.stormdata/LibLNYF.galaxy:307
else if (auto19C27B59_val == 5) {
libGame_gv_players[lp_player].lv_heroIndex = libCore_gf_GetIndexFromHero("Samuro");
PlayerSetSkin(lp_player, "SamuroMonkey");
}
else if (auto19C27B59_val == 6) {
mods/heroesbrawlmods/brawlmapmods/lunarfestival.stormmod — base.stormdata/LibLNYF.galaxy:311
else if (auto19C27B59_val == 6) {
libGame_gv_players[lp_player].lv_heroIndex = libCore_gf_GetIndexFromHero("Sylvanas");
PlayerSetSkin(lp_player, "SylvanasLunar");
}
else if (auto19C27B59_val == 7) {
mods/heroesbrawlmods/brawlmapmods/lunarfestival.stormmod — base.stormdata/LibLNYF.galaxy:315
else if (auto19C27B59_val == 7) {
libGame_gv_players[lp_player].lv_heroIndex = libCore_gf_GetIndexFromHero("Amazon");
PlayerSetSkin(lp_player, "AmazonLunar");
}
else if (auto19C27B59_val == 8) {
mods/heroesbrawlmods/brawlmapmods/lunarfestival.stormmod — base.stormdata/LibLNYF.galaxy:319
else if (auto19C27B59_val == 8) {
libGame_gv_players[lp_player].lv_heroIndex = libCore_gf_GetIndexFromHero("Zuljin");
PlayerSetSkin(lp_player, "ZuljinLunar");
}
else if (auto19C27B59_val == 9) {
mods/heroesbrawlmods/brawlmapmods/lunarfestival.stormmod — base.stormdata/LibLNYF.galaxy:323
else if (auto19C27B59_val == 9) {
libGame_gv_players[lp_player].lv_heroIndex = libCore_gf_GetIndexFromHero("Kaelthas");
PlayerSetSkin(lp_player, "KaelthasLunar");
}
else {
mods/heroesbrawlmods/heroselectionmods/ingameheroselection.stormmod — base.stormdata/LibIGHS.galaxy:711
}
if ((lv_possibleSkinCount > 0)) {
PlayerSetSkin(lp_player, lv_possibleSkins[RandomInt(1, lv_possibleSkinCount)]);
}
mods/heroesdata.stormmod — base.stormdata/TriggerLibs/GameDataHelperLib.galaxy:5169
lv_multiplier = ((UnitLevel(libGame_gv_players[lv_abathurPlayer].lv_heroUnit) * 150.0) + 0.0);
lv_lifeofTarget = UnitGetPropertyFixed(lv_target, c_unitPropLifeMax, c_unitPropNormal);
PlayerSetSkin(lv_abathurPlayer, libGame_gv_players[UnitGetOwner(lv_target)].lv_skinData.lv_skinID);
if ((UnitGetOwner(lv_target) <= libCore_gv_bALMaxPlayers) && (libGame_gv_players[UnitGetOwner(lv_target)].lv_activeVehicle != null)) {
libNtve_gf_CreateUnitsWithDefaultFacing(1, lv_typeofCopiedUnit, 0, lv_abathurPlayer, UnitTypePlacementFromPoint(lv_typeofCopiedUnit, lv_abathurPlayer, UnitGetPosition(libGame_gv_players[lv_ownerofTarget].lv_activeVehicle), 35.0), lv_abathur);
mods/heroesdata.stormmod — base.stormdata/TriggerLibs/GameDataHelperLib.galaxy:5293
if (auto6824BDCC_var<0) { break; }
if ((UnitGetType(libGame_gv_players[auto6824BDCC_var].lv_heroUnit) == "HeroAbathur")) {
PlayerSetSkin(auto6824BDCC_var, libGame_gv_players[auto6824BDCC_var].lv_skinData.lv_skinID);
UnitSelect(lv_ultimateEvolutionUnit, auto6824BDCC_var, false);
UnitSelect(libGame_gv_players[auto6824BDCC_var].lv_heroUnit, auto6824BDCC_var, true);
mods/heroesdata.stormmod — base.stormdata/TriggerLibs/GameLib.galaxy:5535
libCore_gf_DataLoadSkinDataIntoIndex(libCore_gf_DataSkinsGetSkinLinkFromSkinCatalogIndex(libGame_gv_players[lp_choPlayerID].lv_selectedSkin), lp_choPlayerID);
libCore_gf_DataLoadSkinDataIntoIndex(libCore_gf_DataSkinsGetSkinLinkFromSkinCatalogIndex(libGame_gv_players[lv_gallPlayerID].lv_selectedSkin), lv_gallPlayerID);
PlayerSetSkin(lv_gallPlayerID, libGame_gv_players[lv_gallPlayerID].lv_skinData.lv_skinID);
libGame_gf_ChoGallMountandBannerSelection(lp_choPlayerID, lv_gallPlayerID);
return ;
mods/heroesdata.stormmod — base.stormdata/TriggerLibs/GameLib.galaxy:5558
libCore_gf_DataLoadSkinDataIntoIndex(libCore_gf_DataSkinsGetSkinLinkFromSkinCatalogIndex(libGame_gv_players[lp_choPlayerID].lv_selectedSkin), lp_choPlayerID);
libCore_gf_DataLoadSkinDataIntoIndex(libCore_gf_DataSkinsGetSkinLinkFromSkinCatalogIndex(libGame_gv_players[lv_gallPlayerID].lv_selectedSkin), lv_gallPlayerID);
PlayerSetSkin(lv_gallPlayerID, libGame_gv_players[lv_gallPlayerID].lv_skinData.lv_skinID);
libGame_gf_ChoGallMountandBannerSelection(lp_choPlayerID, lv_gallPlayerID);
return ;
mods/heroesdata.stormmod — base.stormdata/TriggerLibs/GameLib.galaxy:7847
libGame_gv_players[lp_choosingPlayer].lv_selectedSkin = libCore_gf_DataSkinsGetSkinIndexFromSkinLink(lv_skinLink);
libCore_gf_DataLoadSkinDataIntoIndex(lv_skinLink, lv_index);
PlayerSetSkin(lp_choosingPlayer, libGame_gv_players[lv_index].lv_skinData.lv_skinID);
}
mods/heroesdata.stormmod — base.stormdata/TriggerLibs/GameLib.galaxy:10587
lv_skinIndex = lp_player;
if ((libGame_gv_players[lv_skinIndex].lv_skinData.lv_skinID != null)) {
PlayerSetSkin(lp_player, libGame_gv_players[lv_skinIndex].lv_skinData.lv_skinID);
}
mods/heroesdata.stormmod — base.stormdata/TriggerLibs/UILib.galaxy:2934
if (auto288FD252_var<0) { break; }
if (((PlayerStatus(auto288FD252_var) != c_playerStatusUnused) && (PlayerSkin(auto288FD252_var) != libGame_gv_players[auto288FD252_var].lv_skinData.lv_skinID))) {
PlayerSetSkin(auto288FD252_var, libGame_gv_players[auto288FD252_var].lv_skinData.lv_skinID);
}
mods/heromods/dva.stormmod — base.stormdata/LibHDVA.galaxy:190
lv_skinIndex = lp_player;
if ((libGame_gv_players[lv_skinIndex].lv_skinData.lv_skinID != null)) {
PlayerSetSkin(lp_player, libGame_gv_players[lv_skinIndex].lv_skinData.lv_skinID);
}