2016-01-04 14:58:00 -05:00
|
|
|
#include "STDInclude.hpp"
|
2015-12-23 08:45:53 -05:00
|
|
|
|
|
|
|
namespace Steam
|
|
|
|
{
|
|
|
|
int User::GetHSteamUser()
|
|
|
|
{
|
|
|
|
return NULL;
|
|
|
|
}
|
|
|
|
|
|
|
|
bool User::LoggedOn()
|
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
|
|
|
SteamID User::GetSteamID()
|
|
|
|
{
|
2016-01-12 08:42:04 -05:00
|
|
|
static unsigned int subId = 0;
|
2015-12-24 13:21:10 -05:00
|
|
|
|
2015-12-25 15:42:35 -05:00
|
|
|
SteamID id;
|
2015-12-24 13:21:10 -05:00
|
|
|
|
2015-12-25 15:42:35 -05:00
|
|
|
if (!subId)
|
|
|
|
{
|
2016-02-27 08:46:18 -05:00
|
|
|
if (Components::Dedicated::IsDedicated() || Components::ZoneBuilder::IsEnabled()) // Dedi guid
|
2015-12-27 14:05:43 -05:00
|
|
|
{
|
2016-01-12 08:42:04 -05:00
|
|
|
subId = ~0xDED1CA7E;
|
2015-12-27 14:05:43 -05:00
|
|
|
}
|
2016-02-22 17:35:53 -05:00
|
|
|
else if (Components::Singleton::IsFirstInstance()) // ECDSA guid
|
2015-12-27 14:05:43 -05:00
|
|
|
{
|
2016-02-22 17:35:53 -05:00
|
|
|
subId = Components::Auth::GetKeyHash();
|
2015-12-27 14:05:43 -05:00
|
|
|
}
|
2015-12-27 14:16:01 -05:00
|
|
|
else // Random guid
|
2015-12-27 14:05:43 -05:00
|
|
|
{
|
|
|
|
subId = (Game::Com_Milliseconds() + timeGetTime());
|
|
|
|
}
|
2016-01-12 08:38:33 -05:00
|
|
|
|
|
|
|
subId &= ~0x80000000; // Ensure it's positive
|
2015-12-25 15:42:35 -05:00
|
|
|
}
|
2015-12-24 13:21:10 -05:00
|
|
|
|
2015-12-27 08:05:08 -05:00
|
|
|
id.Bits = 0x110000100000000 | subId;
|
2015-12-23 08:45:53 -05:00
|
|
|
return id;
|
|
|
|
}
|
|
|
|
|
|
|
|
int User::InitiateGameConnection(void *pAuthBlob, int cbMaxAuthBlob, SteamID steamIDGameServer, unsigned int unIPServer, unsigned short usPortServer, bool bSecure)
|
|
|
|
{
|
2016-02-21 13:57:56 -05:00
|
|
|
Components::Logger::Print("%s\n", __FUNCTION__);
|
2015-12-23 08:45:53 -05:00
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
void User::TerminateGameConnection(unsigned int unIPServer, unsigned short usPortServer)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
void User::TrackAppUsageEvent(SteamID gameID, int eAppUsageEvent, const char *pchExtraInfo)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
bool User::GetUserDataFolder(char *pchBuffer, int cubBuffer)
|
|
|
|
{
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
void User::StartVoiceRecording()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
void User::StopVoiceRecording()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
int User::GetCompressedVoice(void *pDestBuffer, unsigned int cbDestBufferSize, unsigned int *nBytesWritten)
|
|
|
|
{
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
int User::DecompressVoice(void *pCompressed, unsigned int cbCompressed, void *pDestBuffer, unsigned int cbDestBufferSize, unsigned int *nBytesWritten)
|
|
|
|
{
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
unsigned int User::GetAuthSessionTicket(void *pTicket, int cbMaxTicket, unsigned int *pcbTicket)
|
|
|
|
{
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
int User::BeginAuthSession(const void *pAuthTicket, int cbAuthTicket, SteamID steamID)
|
|
|
|
{
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
void User::EndAuthSession(SteamID steamID)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
void User::CancelAuthTicket(unsigned int hAuthTicket)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
unsigned int User::UserHasLicenseForApp(SteamID steamID, unsigned int appID)
|
|
|
|
{
|
|
|
|
return 1;
|
|
|
|
}
|
|
|
|
}
|