I need to know what functions are called after PostLogin, I made a VIP system that sets certain things when the player joins but I need GetPlayerIDHash() to return the players SteamID and not his CD-Key hash and this seems to only happen after PostLogin is called. I currently have the function call in Tick on the PRI but it has rpoven unreliable as it seems to skip players and sometimes doesn't work
Here is the code if you could improve it in anyway
PRI
PlayerController
Here is the code if you could improve it in anyway
PRI
Code:
function Tick(float DT)
{
Super.Tick(DT);
if( !bGotVIPValues )
{
bGotVIPValues = true;
if( FMXPlayerController(Owner) != none )
FMXPlayerController(Owner).InitVIPInfo();
}
}
PlayerController
Code:
function InitVIPInfo()
{
local int i;
local ForrestPRI FPlayerRepInfo;
local string SteamID;
local FMXScrnMut FScrnMut;
FPlayerRepInfo = ForrestPRI(PlayerReplicationInfo);
if( FPlayerRepInfo == none )
return;
SteamID = GetPlayerIDHash();
FScrnMut = FMXScrnMut(Mut);
for(i=0;i<FScrnMut.SteamIDs.Length;i++)
{
if( FScrnMut.SteamIDs[i].ID == SteamID )
{
FPlayerRepInfo.IsVIP = true;
FPlayerRepInfo.bSuperVIP = True;
FPlayerRepInfo.MedalMaterial = Material(DynamicLoadObject(FScrnMut.SteamIDs[i].MedalMaterial, class'Material', true));
FPlayerRepInfo.PlayerNameColor = FScrnMut.SteamIDs[i].VIPColor;
BecomeVIP();
}
}
}