mirror of
https://github.com/Facepunch/Facepunch.Steamworks.git
synced 2025-04-13 21:10:06 +03:00
OnP2PConnectionFailed passes error enum
This commit is contained in:
parent
7c50db6997
commit
ef071d3d71
@ -933,7 +933,7 @@ namespace Steamworks
|
|||||||
//
|
//
|
||||||
// EP2PSessionError
|
// EP2PSessionError
|
||||||
//
|
//
|
||||||
internal enum P2PSessionError : int
|
public enum P2PSessionError : int
|
||||||
{
|
{
|
||||||
None = 0,
|
None = 0,
|
||||||
NotRunningApp = 1,
|
NotRunningApp = 1,
|
||||||
|
@ -33,7 +33,7 @@ namespace Steamworks
|
|||||||
internal static void InstallEvents()
|
internal static void InstallEvents()
|
||||||
{
|
{
|
||||||
P2PSessionRequest_t.Install( x => OnP2PSessionRequest?.Invoke( x.SteamIDRemote ) );
|
P2PSessionRequest_t.Install( x => OnP2PSessionRequest?.Invoke( x.SteamIDRemote ) );
|
||||||
P2PSessionConnectFail_t.Install( x => OnP2PConnectionFailed?.Invoke( x.SteamIDRemote ) );
|
P2PSessionConnectFail_t.Install( x => OnP2PConnectionFailed?.Invoke( x.SteamIDRemote, (P2PSessionError) x.P2PSessionError ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -47,7 +47,7 @@ namespace Steamworks
|
|||||||
/// All queued packets unsent at this point will be dropped, further attempts
|
/// All queued packets unsent at this point will be dropped, further attempts
|
||||||
/// to send will retry making the connection (but will be dropped if we fail again).
|
/// to send will retry making the connection (but will be dropped if we fail again).
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public static Action<SteamId> OnP2PConnectionFailed;
|
public static Action<SteamId, P2PSessionError> OnP2PConnectionFailed;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This should be called in response to a OnP2PSessionRequest
|
/// This should be called in response to a OnP2PSessionRequest
|
||||||
|
@ -74,6 +74,7 @@ public static class Cleanup
|
|||||||
if ( name == "InventoryDefId" ) return "public";
|
if ( name == "InventoryDefId" ) return "public";
|
||||||
if ( name == "P2PSend" ) return "public";
|
if ( name == "P2PSend" ) return "public";
|
||||||
if ( name == "RoomEnter" ) return "public";
|
if ( name == "RoomEnter" ) return "public";
|
||||||
|
if ( name == "P2PSessionError" ) return "public";
|
||||||
|
|
||||||
return "internal";
|
return "internal";
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user