|
|
@ -812,9 +812,10 @@ bool plClient::MsgReceive(plMessage* msg) |
|
|
|
//============================================================================
|
|
|
|
//============================================================================
|
|
|
|
if (plNetCommAuthMsg* authMsg = plNetCommAuthMsg::ConvertNoRef(msg)) { |
|
|
|
if (plNetCommAuthMsg* authMsg = plNetCommAuthMsg::ConvertNoRef(msg)) { |
|
|
|
plgDispatch::Dispatch()->UnRegisterForExactType(plNetCommAuthMsg::Index(), GetKey()); |
|
|
|
plgDispatch::Dispatch()->UnRegisterForExactType(plNetCommAuthMsg::Index(), GetKey()); |
|
|
|
if (IS_NET_SUCCESS(authMsg->result)) |
|
|
|
if (IS_NET_SUCCESS(authMsg->result)) { |
|
|
|
|
|
|
|
SetFlag(kFlagInitialAuthComplete); |
|
|
|
IPatchGlobalAgeFiles(); |
|
|
|
IPatchGlobalAgeFiles(); |
|
|
|
return true; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
return hsKeyedObject::MsgReceive(msg); |
|
|
|
return hsKeyedObject::MsgReceive(msg); |
|
|
@ -1476,24 +1477,21 @@ bool plClient::BeginGame() |
|
|
|
{ |
|
|
|
{ |
|
|
|
plNetClientMgr::GetInstance()->Init(); |
|
|
|
plNetClientMgr::GetInstance()->Init(); |
|
|
|
IPlayIntroMovie("avi/CyanWorlds.webm", 0.f, 0.f, 0.f, 1.f, 1.f, 0.75); |
|
|
|
IPlayIntroMovie("avi/CyanWorlds.webm", 0.f, 0.f, 0.f, 1.f, 1.f, 0.75); |
|
|
|
|
|
|
|
SetFlag(kFlagIntroComplete); |
|
|
|
if (GetDone()) return false; |
|
|
|
if (GetDone()) return false; |
|
|
|
if (NetCommGetStartupAge()->ageDatasetName.CompareI("StartUp") == 0) { |
|
|
|
IPatchGlobalAgeFiles(); |
|
|
|
// This is needed because there is no auth step in this case
|
|
|
|
|
|
|
|
plNetCommAuthMsg* msg = new plNetCommAuthMsg(); |
|
|
|
|
|
|
|
msg->result = kNetSuccess; |
|
|
|
|
|
|
|
msg->param = nullptr; |
|
|
|
|
|
|
|
msg->Send(); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
return true; |
|
|
|
return true; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
//============================================================================
|
|
|
|
//============================================================================
|
|
|
|
void plClient::IPatchGlobalAgeFiles( void ) |
|
|
|
void plClient::IPatchGlobalAgeFiles( void ) |
|
|
|
{ |
|
|
|
{ |
|
|
|
plgDispatch::Dispatch()->RegisterForExactType(plResPatcherMsg::Index(), GetKey()); |
|
|
|
if (HasFlag(kFlagIntroComplete) && HasFlag(kFlagInitialAuthComplete)) { |
|
|
|
|
|
|
|
plgDispatch::Dispatch()->RegisterForExactType(plResPatcherMsg::Index(), GetKey()); |
|
|
|
|
|
|
|
|
|
|
|
plResPatcher* patcher = plResPatcher::GetInstance(); |
|
|
|
plResPatcher* patcher = plResPatcher::GetInstance(); |
|
|
|
patcher->Update(plManifest::EssentialGameManifests()); |
|
|
|
patcher->Update(plManifest::EssentialGameManifests()); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
void plClient::InitDLLs() |
|
|
|
void plClient::InitDLLs() |
|
|
|