diff options
author | Jack <66967891+ASpoonPlaysGames@users.noreply.github.com> | 2023-12-14 12:00:26 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-12-14 13:00:26 +0100 |
commit | 0976a3500e6774258322ab2bc80ebd515c175e77 (patch) | |
tree | 8573693b05b741c9a988265bc137820f908c922e /NorthstarDLL/masterserver/masterserver.cpp | |
parent | 8a4107191b782d087a94511e9fb6f85fcb7c43d9 (diff) | |
download | NorthstarLauncher-0976a3500e6774258322ab2bc80ebd515c175e77.tar.gz NorthstarLauncher-0976a3500e6774258322ab2bc80ebd515c175e77.zip |
Rework `-vanilla` to be a vanilla compatibility mode (#601)
Old `-vanilla` behaviour is now handled by `-nonorthstardll`.
New squirrel constant called `VANILLA`. Set to true when in vanilla compatibility mode.
Differences when in vanilla compatibility mode:
- Doesn't restrict server commands (same as `-norestrictservercommands`)
- Doesn't block FairFight screenshot functions
- Doesn't do Atlas-related stuff (except for mainmenupromos)
Diffstat (limited to 'NorthstarDLL/masterserver/masterserver.cpp')
-rw-r--r-- | NorthstarDLL/masterserver/masterserver.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/NorthstarDLL/masterserver/masterserver.cpp b/NorthstarDLL/masterserver/masterserver.cpp index 21b76f73..53a5fa9a 100644 --- a/NorthstarDLL/masterserver/masterserver.cpp +++ b/NorthstarDLL/masterserver/masterserver.cpp @@ -3,6 +3,7 @@ #include "shared/playlist.h" #include "server/auth/serverauthentication.h" #include "core/tier0.h" +#include "core/vanilla.h" #include "engine/r2engine.h" #include "mods/modmanager.h" #include "shared/misccommands.h" @@ -88,7 +89,7 @@ size_t CurlWriteToStringBufferCallback(char* contents, size_t size, size_t nmemb void MasterServerManager::AuthenticateOriginWithMasterServer(const char* uid, const char* originToken) { - if (m_bOriginAuthWithMasterServerInProgress) + if (m_bOriginAuthWithMasterServerInProgress || g_pVanillaCompatibility->GetVanillaCompatibility()) return; // do this here so it's instantly set @@ -466,7 +467,7 @@ void MasterServerManager::RequestMainMenuPromos() void MasterServerManager::AuthenticateWithOwnServer(const char* uid, const char* playerToken) { // dont wait, just stop if we're trying to do 2 auth requests at once - if (m_bAuthenticatingWithGameServer) + if (m_bAuthenticatingWithGameServer || g_pVanillaCompatibility->GetVanillaCompatibility()) return; m_bAuthenticatingWithGameServer = true; @@ -601,7 +602,7 @@ void MasterServerManager::AuthenticateWithOwnServer(const char* uid, const char* void MasterServerManager::AuthenticateWithServer(const char* uid, const char* playerToken, RemoteServerInfo server, const char* password) { // dont wait, just stop if we're trying to do 2 auth requests at once - if (m_bAuthenticatingWithGameServer) + if (m_bAuthenticatingWithGameServer || g_pVanillaCompatibility->GetVanillaCompatibility()) return; m_bAuthenticatingWithGameServer = true; |