2017-10-20 02:00:49 +00:00
|
|
|
class ExtHUD_SpectatorInfo extends KFGFxHUD_SpectatorInfo;
|
|
|
|
|
|
|
|
var class<Ext_PerkBase> ExtLastPerkClass;
|
|
|
|
var bool bUnsetInfo;
|
|
|
|
|
|
|
|
function LocalizeText()
|
|
|
|
{
|
|
|
|
local GFxObject TempObject;
|
|
|
|
TempObject = CreateObject("Object");
|
|
|
|
|
2020-11-28 19:53:57 +00:00
|
|
|
TempObject.SetString("prevPlayer", "FREE CAMERA");
|
|
|
|
TempObject.SetString("nextPlayer", PrevPlayerString);
|
|
|
|
TempObject.SetString("changeCamera", ChangeCameraString);
|
2017-10-20 02:00:49 +00:00
|
|
|
|
2020-11-28 19:53:57 +00:00
|
|
|
SetObject("localizedText", TempObject);
|
2017-10-20 02:00:49 +00:00
|
|
|
}
|
|
|
|
|
2020-11-28 20:04:55 +00:00
|
|
|
function UpdatePlayerInfo(optional bool bForceUpdate)
|
2017-10-20 02:00:49 +00:00
|
|
|
{
|
2017-10-21 16:20:49 +00:00
|
|
|
local GFxObject TempObject;
|
2017-10-20 02:00:49 +00:00
|
|
|
local ExtPlayerReplicationInfo E;
|
2023-05-14 02:49:12 +00:00
|
|
|
|
2020-11-28 20:12:58 +00:00
|
|
|
if (SpectatedKFPRI == None)
|
2017-10-21 16:20:49 +00:00
|
|
|
return;
|
2023-05-14 02:49:12 +00:00
|
|
|
|
2017-10-20 02:00:49 +00:00
|
|
|
E = ExtPlayerReplicationInfo(SpectatedKFPRI);
|
|
|
|
|
2020-11-28 20:12:58 +00:00
|
|
|
if (LastPerkLevel != E.ECurrentPerkLevel || LastPerkLevel != E.ECurrentPerkLevel || bForceUpdate)
|
2017-10-20 02:00:49 +00:00
|
|
|
{
|
2017-10-21 16:20:49 +00:00
|
|
|
LastPerkLevel = E.ECurrentPerkLevel;
|
|
|
|
ExtLastPerkClass = E.ECurrentPerk;
|
2020-11-28 20:04:55 +00:00
|
|
|
TempObject = CreateObject("Object");
|
|
|
|
TempObject.SetString("playerName", SpectatedKFPRI.GetHumanReadableName());
|
2020-11-28 20:12:58 +00:00
|
|
|
if (ExtLastPerkClass!=None && TempObject !=None)
|
2017-10-21 16:20:49 +00:00
|
|
|
{
|
2020-11-28 20:04:55 +00:00
|
|
|
TempObject.SetString("playerPerk", SpectatedKFPRI.CurrentPerkClass.default.LevelString @LastPerkLevel @ExtLastPerkClass.default.PerkName);
|
|
|
|
TempObject.SetString("iconPath", ExtLastPerkClass.Static.GetPerkIconPath(LastPerkLevel));
|
|
|
|
SetObject("playerData", TempObject);
|
2017-10-21 16:20:49 +00:00
|
|
|
}
|
2020-11-28 20:04:55 +00:00
|
|
|
else TempObject.SetString("playerPerk","No perk");
|
|
|
|
SetVisible(true);
|
2017-10-20 02:00:49 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
defaultproperties
|
|
|
|
{
|
2023-05-14 02:49:12 +00:00
|
|
|
|
2017-10-21 16:20:49 +00:00
|
|
|
}
|