Skip to content

Commit

Permalink
Remove SteamGameServer_Init completely, swapping to SteamInternal_Gam…
Browse files Browse the repository at this point in the history
…eServer_Init. Fixes #407
  • Loading branch information
rlabrecque committed Apr 10, 2021
1 parent 8ef3d2a commit 7519c2f
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 5 deletions.
2 changes: 1 addition & 1 deletion Plugins/Steamworks.NET/Steam.cs
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ public static bool Init(uint unIP, ushort usGamePort, ushort usQueryPort, EServe

bool ret;
using (var pchVersionString2 = new InteropHelp.UTF8StringHandle(pchVersionString)) {
ret = NativeMethods.SteamGameServer_Init(unIP, usGamePort, usQueryPort, eServerMode, pchVersionString2);
ret = NativeMethods.SteamInternal_GameServer_Init(unIP, 0, usGamePort, usQueryPort, eServerMode, pchVersionString2);
}

// Steamworks.NET specific: We initialize the SteamAPI Context like this for now, but we need to do it
Expand Down
4 changes: 0 additions & 4 deletions Plugins/Steamworks.NET/autogen/NativeMethods.cs
Original file line number Diff line number Diff line change
Expand Up @@ -135,10 +135,6 @@ internal static class NativeMethods {
public static extern bool SteamAPI_ManualDispatch_GetAPICallResult(HSteamPipe hSteamPipe, SteamAPICall_t hSteamAPICall, IntPtr pCallback, int cubCallback, int iCallbackExpected, out bool pbFailed);
#endregion
#region steam_gameserver.h
[DllImport(NativeLibraryName, EntryPoint = "SteamGameServer_Init", CallingConvention = CallingConvention.Cdecl)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool SteamGameServer_Init(uint unIP, ushort usGamePort, ushort usQueryPort, EServerMode eServerMode, InteropHelp.UTF8StringHandle pchVersionString);

[DllImport(NativeLibraryName, EntryPoint = "SteamGameServer_Shutdown", CallingConvention = CallingConvention.Cdecl)]
public static extern void SteamGameServer_Shutdown();

Expand Down

0 comments on commit 7519c2f

Please # to comment.