use steam transport in qsb

This commit is contained in:
JohnCorby 2025-02-24 23:50:30 -08:00
parent 94d59de38d
commit ce7d4d75a1
3 changed files with 8 additions and 6 deletions

View File

@ -74,7 +74,7 @@
<PackageReference Include="OuterWildsGameLibs" Version="1.1.15.1018" IncludeAssets="compile" />
<PackageReference Include="OWML" Version="2.15.1" IncludeAssets="compile" />
<Reference Include="..\Lib\*.dll" />
<ProjectReference Include="..\FizzySteamworks\FizzySteamworks.csproj" />
<!-- <ProjectReference Include="..\FizzySteamworks\FizzySteamworks.csproj" />-->
<ProjectReference Include="..\SteamTransport\SteamTransport.csproj" />
<ProjectReference Include="..\SteamRerouter\SteamRerouter.csproj" />
<ProjectReference Include="..\QSBPatcher\QSBPatcher.csproj" />

View File

@ -1,6 +1,4 @@
using Epic.OnlineServices.Logging;
using Mirror;
using Mirror.FizzySteam;
using Mirror;
using OWML.Common;
using OWML.Utils;
using QSB.Anglerfish.TransformSync;
@ -70,7 +68,7 @@ public class QSBNetworkManager : NetworkManager, IAddComponentOnStart
private static LatencySimulation _latencyTransport;
private static kcp2k.KcpTransport _kcpTransport;
private static FizzySteamworks _steamTransport;
private static SteamTransport.SteamTransport _steamTransport;
public override void Awake()
{
@ -84,7 +82,7 @@ public class QSBNetworkManager : NetworkManager, IAddComponentOnStart
}
{
_steamTransport = gameObject.AddComponent<FizzySteamworks>();
_steamTransport = gameObject.AddComponent<SteamTransport.SteamTransport>();
// Steam uses seconds
_steamTransport.Timeout = QSBCore.Timeout;
}

View File

@ -23,6 +23,10 @@ public class SteamTransport : Transport
public string TestIpAddress;
// TODO: configurable timeout
/// <summary>
/// timeout in seconds when connecting, and timeout before detecting a loss in connection
/// </summary>
public int Timeout;
public override bool Available() => true;