Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,7 @@

*.ttf filter=lfs diff=lfs merge=lfs -text
*.ttc filter=lfs diff=lfs merge=lfs -text

# The vendored x86 GNS static archives exceed ordinary Git hosting file limits.
# Keep them as reproducible Git LFS payloads; wrapper sources and headers remain normal Git files.
/src/thirdparty/gamenetworkingsockets/lib/**/*.lib filter=lfs diff=lfs merge=lfs -text
10 changes: 10 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ reactivedrop/addonlist_workshop.txt
reactivedrop/bin/client.dll
reactivedrop/bin/missionchooser.dll
reactivedrop/bin/server.dll
reactivedrop/bin/asrd_gns_wrapper.*
reactivedrop/bin/Debug/
reactivedrop/bin/Profile/
reactivedrop/bin/Release/
reactivedrop/cfg/*.dat
reactivedrop/cfg/build_all_maps.cfg
reactivedrop/cfg/config.cfg
Expand All @@ -42,6 +46,9 @@ reactivedrop/tilegen_log.txt
reactivedrop/voice_ban.dt
src/game/client/Debug_swarm/
src/game/client/Release_swarm/
src/game/gns_wrapper/Debug/
src/game/gns_wrapper/Profile/
src/game/gns_wrapper/Release/
src/game/missionchooser/Debug/
src/game/missionchooser/Release/
src/game/server/Debug_swarm/
Expand All @@ -59,3 +66,6 @@ src/sourcelink.json
src/utils/*/Debug/
src/utils/*/Release/
/.vs

# Local temporary worker/check-out snapshots are not project submodules.
/TEMP/
35 changes: 35 additions & 0 deletions src/game/client/cdll_client_int.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@
#include "clientsideeffects.h"
#include "particlemgr.h"
#include "steam/steam_api.h"
#include "asrd_gns_runtime_hook.h"
#include "asrd_gns_client_lifecycle.h"
#include "asrd_gns_message_bridge.h"
#include "smoke_fog_overlay.h"
#include "view.h"
#include "ienginevgui.h"
Expand Down Expand Up @@ -349,6 +352,17 @@ CON_COMMAND( cl_dumpsplithacks, "Dump split screen workarounds." )
}
}

CON_COMMAND( asrd_gns_disconnect, "Close the active ASRD GNS connection and disconnect Source upper layers." )
{
ASRD_GNS_ClientRequestDisconnect();
}

CON_COMMAND( asrd_gns_disconnect_after, "Schedule an ASRD GNS disconnect after the connected state (seconds)." )
{
const float delaySeconds = args.ArgC() > 1 ? (float)atof( args[ 1 ] ) : 0.0f;
ASRD_GNS_ClientScheduleDisconnect( delaySeconds );
}

CHackForGetLocalPlayerAccessAllowedGuard::CHackForGetLocalPlayerAccessAllowedGuard( char const *pszContext, bool bOldState )
{
if ( bOldState )
Expand Down Expand Up @@ -1251,6 +1265,19 @@ int CHLClient::Init( CreateInterfaceFn appSystemFactory, CGlobalVarsBase *pGloba

// This is a fullscreen element, so only lives on slot 0!!!
m_pHudCloseCaption = GET_FULLSCREEN_HUDELEMENT( CHudCloseCaption );
if ( !ASRD_GNS_RuntimeHookRegisterClientConnectHandler(
&ASRD_GNS_ClientConnectIntent ) )
{
Warning( "[ASRD-GNS-CLIENT] connect callback registration failed\n" );
}
if ( !ASRD_GNS_EnsureRuntimeHookInstalled() )
{
Warning( "[ASRD-GNS-CLIENT] runtime hook installation failed\n" );
}
if ( !ASRD_GNS_SetClientRuntimeRole() )
{
Warning( "[ASRD-GNS-CLIENT] client runtime role rejected\n" );
}

COM_TimestampedLog( "ClientDLL Init - Finish" );
return true;
Expand All @@ -1271,6 +1298,10 @@ void CHLClient::PostInit()
//-----------------------------------------------------------------------------
void CHLClient::Shutdown( void )
{
ASRD_GNS_RuntimeHookUnregisterClientConnectHandler(
&ASRD_GNS_ClientConnectIntent );
ASRD_GNS_RuntimeHookShutdown();
ASRD_GNS_ClientShutdown();


ActivityList_Free();
Expand Down Expand Up @@ -2592,6 +2623,10 @@ void CHLClient::FrameStageNotify( ClientFrameStage_t curStage )
break;
case FRAME_START:
{
// Process GNS at the start of the client frame.
ASRD_GNS_ClientFrame();
ASRD_GNS_MessageBridgeFrame( false );

// Mark the frame as open for client fx additions
SetFXCreationAllowed( true );
SetBeamCreationAllowed( true );
Expand Down
30 changes: 22 additions & 8 deletions src/game/client/swarm_sdk_client.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@
<PlatformToolset>v145</PlatformToolset>
<CharacterSet>MultiByte</CharacterSet>
<WholeProgramOptimization>true</WholeProgramOptimization>
<VcpkgConfiguration>Release</VcpkgConfiguration>
<VCToolsVersion>
</VCToolsVersion>
</PropertyGroup>
Expand Down Expand Up @@ -140,7 +139,7 @@
<Culture>0x0409</Culture>
</ResourceCompile>
<Link>
<AdditionalDependencies>winmm.lib;ws2_32.lib;discord-rpc.lib;legacy_stdio_definitions.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalDependencies>asrd_gns_wrapper.lib;winmm.lib;ws2_32.lib;discord-rpc.lib;legacy_stdio_definitions.lib;%(AdditionalDependencies)</AdditionalDependencies>
<ShowProgress>NotSet</ShowProgress>
<OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
<SuppressStartupBanner>true</SuppressStartupBanner>
Expand Down Expand Up @@ -176,7 +175,7 @@
<Command>set "DEST_DIR=..\..\..\reactivedrop\bin"
mkdir "%25DEST_DIR%25" 2&gt;nul

robocopy "$(TargetDir)\" "%25DEST_DIR%25" "$(TargetFileName)" "$(TargetName).map" "$(TargetName).pdb" /IS /IT /COPY:DAT /R:1 /W:0 /NP
robocopy "$(TargetDir)\" "%25DEST_DIR%25" "$(TargetFileName)" /IS /IT /COPY:DAT /R:1 /W:0 /NP
if %errorlevel% GEQ 8 exit /b %errorlevel%
REM normalize robocopy success range (0–7) to MSBuild success (0)
cmd /c exit /b 0
Expand Down Expand Up @@ -246,7 +245,7 @@ exit /b 0
<Culture>0x0409</Culture>
</ResourceCompile>
<Link>
<AdditionalDependencies>winmm.lib;ws2_32.lib;discord-rpc.lib;legacy_stdio_definitions.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalDependencies>asrd_gns_wrapper.lib;winmm.lib;ws2_32.lib;discord-rpc.lib;legacy_stdio_definitions.lib;%(AdditionalDependencies)</AdditionalDependencies>
<ShowProgress>NotSet</ShowProgress>
<OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
<SuppressStartupBanner>true</SuppressStartupBanner>
Expand Down Expand Up @@ -288,7 +287,7 @@ exit /b 0
<Command>set "DEST_DIR=..\..\..\reactivedrop\bin"
mkdir "%25DEST_DIR%25" 2&gt;nul

robocopy "$(TargetDir)\" "%25DEST_DIR%25" "$(TargetFileName)" "$(TargetName).map" "$(TargetName).pdb" /IS /IT /COPY:DAT /R:1 /W:0 /NP
robocopy "$(TargetDir)\" "%25DEST_DIR%25" "$(TargetFileName)" /IS /IT /COPY:DAT /R:1 /W:0 /NP
if %errorlevel% GEQ 8 exit /b %errorlevel%
REM normalize robocopy success range (0–7) to MSBuild success (0)
cmd /c exit /b 0
Expand Down Expand Up @@ -358,7 +357,7 @@ exit /b 0
<Culture>0x0409</Culture>
</ResourceCompile>
<Link>
<AdditionalDependencies>winmm.lib;ws2_32.lib;discord-rpc.lib;legacy_stdio_definitions.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalDependencies>asrd_gns_wrapper.lib;winmm.lib;ws2_32.lib;discord-rpc.lib;legacy_stdio_definitions.lib;%(AdditionalDependencies)</AdditionalDependencies>
<ShowProgress>NotSet</ShowProgress>
<OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
<SuppressStartupBanner>true</SuppressStartupBanner>
Expand Down Expand Up @@ -399,7 +398,7 @@ exit /b 0
<Command>set "DEST_DIR=..\..\..\reactivedrop\bin"
mkdir "%25DEST_DIR%25" 2&gt;nul

robocopy "$(TargetDir)\" "%25DEST_DIR%25" "$(TargetFileName)" "$(TargetName).map" "$(TargetName).pdb" /IS /IT /COPY:DAT /R:1 /W:0 /NP
robocopy "$(TargetDir)\" "%25DEST_DIR%25" "$(TargetFileName)" /IS /IT /COPY:DAT /R:1 /W:0 /NP
if %errorlevel% GEQ 8 exit /b %errorlevel%
REM normalize robocopy success range (0–7) to MSBuild success (0)
cmd /c exit /b 0
Expand Down Expand Up @@ -3636,7 +3635,22 @@ exit /b 0
<Library Include="videoservices\lib\win32\vpx_mt.lib" />
<Library Include="videoservices\lib\win32\webm_mt.lib" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\shared\asrd_gns_runtime_hook.cpp" />
<ClInclude Include="..\shared\asrd_gns_runtime_hook.h" />
<ClCompile Include="..\shared\asrd_gns_client_lifecycle.cpp" />
<ClInclude Include="..\shared\asrd_gns_client_lifecycle.h" />
<ClCompile Include="..\shared\asrd_gns_message_registry.cpp" />
<ClInclude Include="..\shared\asrd_gns_message_registry.h" />
<ClCompile Include="..\shared\asrd_gns_message_bridge.cpp" />
<ClInclude Include="..\shared\asrd_gns_message_bridge.h" />
<ClCompile Include="..\shared\asrd_gns_move_compat.cpp" />
<ClInclude Include="..\shared\asrd_gns_move_compat.h" />
<ClCompile Include="..\shared\asrd_gns_server_lifecycle.cpp" />
<ClInclude Include="..\shared\asrd_gns_server_lifecycle.h" />
<ClInclude Include="..\..\public\asrd_gns_wrapper.h" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
</Project>
Loading
Loading