mirror of
https://github.com/Facepunch/Facepunch.Steamworks.git
synced 2024-12-27 07:05:50 +03:00
Merge pull request #269 from laurirasanen/master
Install SteamNetworkingSockets events when initializing SteamServer
This commit is contained in:
commit
d64ef909c6
@ -81,9 +81,9 @@ internal static void Shutdown()
|
||||
ConnectionInterfaces = null;
|
||||
}
|
||||
|
||||
internal static void InstallEvents()
|
||||
internal static void InstallEvents( bool server = false )
|
||||
{
|
||||
SteamNetConnectionStatusChangedCallback_t.Install( x => ConnectionStatusChanged( x ) );
|
||||
SteamNetConnectionStatusChangedCallback_t.Install( x => ConnectionStatusChanged( x ), server );
|
||||
}
|
||||
|
||||
private static void ConnectionStatusChanged( SteamNetConnectionStatusChangedCallback_t data )
|
||||
|
@ -37,8 +37,9 @@ internal static ISteamGameServer Internal
|
||||
internal static void InstallEvents()
|
||||
{
|
||||
SteamInventory.InstallEvents();
|
||||
SteamNetworkingSockets.InstallEvents(true);
|
||||
|
||||
ValidateAuthTicketResponse_t.Install( x => OnValidateAuthTicketResponse?.Invoke( x.SteamID, x.OwnerSteamID, x.AuthSessionResponse ), true );
|
||||
ValidateAuthTicketResponse_t.Install( x => OnValidateAuthTicketResponse?.Invoke( x.SteamID, x.OwnerSteamID, x.AuthSessionResponse ), true );
|
||||
SteamServersConnected_t.Install( x => OnSteamServersConnected?.Invoke(), true );
|
||||
SteamServerConnectFailure_t.Install( x => OnSteamServerConnectFailure?.Invoke( x.Result, x.StillRetrying ), true );
|
||||
SteamServersDisconnected_t.Install( x => OnSteamServersDisconnected?.Invoke( x.Result ), true );
|
||||
|
Loading…
Reference in New Issue
Block a user