mirror of
https://github.com/Facepunch/Facepunch.Steamworks.git
synced 2025-01-12 22:58:01 +03:00
New accessor system
This commit is contained in:
parent
ea60c03b95
commit
171d563f56
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamAppList : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamAppList();
|
||||
|
||||
|
||||
internal ISteamAppList()
|
||||
internal ISteamAppList( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamAppList_v001")]
|
||||
internal static extern IntPtr SteamAPI_SteamAppList_v001();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamAppList_v001();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamAppList_GetNumInstalledApps")]
|
||||
private static extern uint _GetNumInstalledApps( IntPtr self );
|
||||
|
@ -9,14 +9,20 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamApps : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamApps();
|
||||
|
||||
|
||||
internal ISteamApps()
|
||||
internal ISteamApps( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamApps_v008")]
|
||||
internal static extern IntPtr SteamAPI_SteamApps_v008();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamApps_v008();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamGameServerApps_v008")]
|
||||
internal static extern IntPtr SteamAPI_SteamGameServerApps_v008();
|
||||
public override IntPtr GetServerInterfacePointer() => SteamAPI_SteamGameServerApps_v008();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamApps_BIsSubscribed")]
|
||||
[return: MarshalAs( UnmanagedType.I1 )]
|
||||
|
@ -9,12 +9,10 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamClient : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamClient();
|
||||
|
||||
|
||||
internal ISteamClient()
|
||||
internal ISteamClient( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
#region FunctionMeta
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamController : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamController();
|
||||
|
||||
|
||||
internal ISteamController()
|
||||
internal ISteamController( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamController_v007")]
|
||||
internal static extern IntPtr SteamAPI_SteamController_v007();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamController_v007();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamController_Init")]
|
||||
[return: MarshalAs( UnmanagedType.I1 )]
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamFriends : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamFriends();
|
||||
|
||||
|
||||
internal ISteamFriends()
|
||||
internal ISteamFriends( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamFriends_v017")]
|
||||
internal static extern IntPtr SteamAPI_SteamFriends_v017();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamFriends_v017();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamFriends_GetPersonaName")]
|
||||
private static extern Utf8StringPointer _GetPersonaName( IntPtr self );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamGameSearch : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamGameSearch();
|
||||
|
||||
|
||||
internal ISteamGameSearch()
|
||||
internal ISteamGameSearch( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamGameSearch_v001")]
|
||||
internal static extern IntPtr SteamAPI_SteamGameSearch_v001();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamGameSearch_v001();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamGameSearch_AddGameSearchParams")]
|
||||
private static extern GameSearchErrorCode_t _AddGameSearchParams( IntPtr self, [MarshalAs( UnmanagedType.CustomMarshaler, MarshalTypeRef = typeof( Utf8StringToNative ) )] string pchKeyToFind, [MarshalAs( UnmanagedType.CustomMarshaler, MarshalTypeRef = typeof( Utf8StringToNative ) )] string pchValuesToFind );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamGameServer : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamGameServer();
|
||||
|
||||
|
||||
internal ISteamGameServer()
|
||||
internal ISteamGameServer( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamGameServer_v013")]
|
||||
internal static extern IntPtr SteamAPI_SteamGameServer_v013();
|
||||
public override IntPtr GetServerInterfacePointer() => SteamAPI_SteamGameServer_v013();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamGameServer_SetProduct")]
|
||||
private static extern void _SetProduct( IntPtr self, [MarshalAs( UnmanagedType.CustomMarshaler, MarshalTypeRef = typeof( Utf8StringToNative ) )] string pszProduct );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamGameServerStats : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamGameServerStats();
|
||||
|
||||
|
||||
internal ISteamGameServerStats()
|
||||
internal ISteamGameServerStats( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamGameServerStats_v001")]
|
||||
internal static extern IntPtr SteamAPI_SteamGameServerStats_v001();
|
||||
public override IntPtr GetServerInterfacePointer() => SteamAPI_SteamGameServerStats_v001();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamGameServerStats_RequestUserStats")]
|
||||
private static extern SteamAPICall_t _RequestUserStats( IntPtr self, SteamId steamIDUser );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamHTMLSurface : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamHTMLSurface();
|
||||
|
||||
|
||||
internal ISteamHTMLSurface()
|
||||
internal ISteamHTMLSurface( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamHTMLSurface_v005")]
|
||||
internal static extern IntPtr SteamAPI_SteamHTMLSurface_v005();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamHTMLSurface_v005();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamHTMLSurface_Init")]
|
||||
[return: MarshalAs( UnmanagedType.I1 )]
|
||||
|
@ -9,14 +9,20 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamHTTP : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamHTTP();
|
||||
|
||||
|
||||
internal ISteamHTTP()
|
||||
internal ISteamHTTP( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamHTTP_v003")]
|
||||
internal static extern IntPtr SteamAPI_SteamHTTP_v003();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamHTTP_v003();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamGameServerHTTP_v003")]
|
||||
internal static extern IntPtr SteamAPI_SteamGameServerHTTP_v003();
|
||||
public override IntPtr GetServerInterfacePointer() => SteamAPI_SteamGameServerHTTP_v003();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamHTTP_CreateHTTPRequest")]
|
||||
private static extern HTTPRequestHandle _CreateHTTPRequest( IntPtr self, HTTPMethod eHTTPRequestMethod, [MarshalAs( UnmanagedType.CustomMarshaler, MarshalTypeRef = typeof( Utf8StringToNative ) )] string pchAbsoluteURL );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamInput : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamInput();
|
||||
|
||||
|
||||
internal ISteamInput()
|
||||
internal ISteamInput( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamInput_v001")]
|
||||
internal static extern IntPtr SteamAPI_SteamInput_v001();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamInput_v001();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamInput_Init")]
|
||||
[return: MarshalAs( UnmanagedType.I1 )]
|
||||
|
@ -9,14 +9,20 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamInventory : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamInventory();
|
||||
|
||||
|
||||
internal ISteamInventory()
|
||||
internal ISteamInventory( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamInventory_v003")]
|
||||
internal static extern IntPtr SteamAPI_SteamInventory_v003();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamInventory_v003();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamGameServerInventory_v003")]
|
||||
internal static extern IntPtr SteamAPI_SteamGameServerInventory_v003();
|
||||
public override IntPtr GetServerInterfacePointer() => SteamAPI_SteamGameServerInventory_v003();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamInventory_GetResultStatus")]
|
||||
private static extern Result _GetResultStatus( IntPtr self, SteamInventoryResult_t resultHandle );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamMatchmaking : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamMatchmaking();
|
||||
|
||||
|
||||
internal ISteamMatchmaking()
|
||||
internal ISteamMatchmaking( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamMatchmaking_v009")]
|
||||
internal static extern IntPtr SteamAPI_SteamMatchmaking_v009();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamMatchmaking_v009();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamMatchmaking_GetFavoriteGameCount")]
|
||||
private static extern int _GetFavoriteGameCount( IntPtr self );
|
||||
|
@ -9,12 +9,10 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamMatchmakingPingResponse : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamMatchmakingPingResponse();
|
||||
|
||||
|
||||
internal ISteamMatchmakingPingResponse()
|
||||
internal ISteamMatchmakingPingResponse( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
#region FunctionMeta
|
||||
|
@ -9,12 +9,10 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamMatchmakingPlayersResponse : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamMatchmakingPlayersResponse();
|
||||
|
||||
|
||||
internal ISteamMatchmakingPlayersResponse()
|
||||
internal ISteamMatchmakingPlayersResponse( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
#region FunctionMeta
|
||||
|
@ -9,12 +9,10 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamMatchmakingRulesResponse : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamMatchmakingRulesResponse();
|
||||
|
||||
|
||||
internal ISteamMatchmakingRulesResponse()
|
||||
internal ISteamMatchmakingRulesResponse( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
#region FunctionMeta
|
||||
|
@ -9,12 +9,10 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamMatchmakingServerListResponse : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamMatchmakingServerListResponse();
|
||||
|
||||
|
||||
internal ISteamMatchmakingServerListResponse()
|
||||
internal ISteamMatchmakingServerListResponse( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
#region FunctionMeta
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamMatchmakingServers : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamMatchmakingServers();
|
||||
|
||||
|
||||
internal ISteamMatchmakingServers()
|
||||
internal ISteamMatchmakingServers( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamMatchmakingServers_v002")]
|
||||
internal static extern IntPtr SteamAPI_SteamMatchmakingServers_v002();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamMatchmakingServers_v002();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamMatchmakingServers_RequestInternetServerList")]
|
||||
private static extern HServerListRequest _RequestInternetServerList( IntPtr self, AppId iApp, [In,Out] ref MatchMakingKeyValuePair[] ppchFilters, uint nFilters, IntPtr pRequestServersResponse );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamMusic : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamMusic();
|
||||
|
||||
|
||||
internal ISteamMusic()
|
||||
internal ISteamMusic( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamMusic_v001")]
|
||||
internal static extern IntPtr SteamAPI_SteamMusic_v001();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamMusic_v001();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamMusic_BIsEnabled")]
|
||||
[return: MarshalAs( UnmanagedType.I1 )]
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamMusicRemote : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamMusicRemote();
|
||||
|
||||
|
||||
internal ISteamMusicRemote()
|
||||
internal ISteamMusicRemote( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamMusicRemote_v001")]
|
||||
internal static extern IntPtr SteamAPI_SteamMusicRemote_v001();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamMusicRemote_v001();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamMusicRemote_RegisterSteamMusicRemote")]
|
||||
[return: MarshalAs( UnmanagedType.I1 )]
|
||||
|
@ -9,14 +9,20 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamNetworking : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamNetworking();
|
||||
|
||||
|
||||
internal ISteamNetworking()
|
||||
internal ISteamNetworking( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamNetworking_v006")]
|
||||
internal static extern IntPtr SteamAPI_SteamNetworking_v006();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamNetworking_v006();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamGameServerNetworking_v006")]
|
||||
internal static extern IntPtr SteamAPI_SteamGameServerNetworking_v006();
|
||||
public override IntPtr GetServerInterfacePointer() => SteamAPI_SteamGameServerNetworking_v006();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamNetworking_SendP2PPacket")]
|
||||
[return: MarshalAs( UnmanagedType.I1 )]
|
||||
|
@ -9,12 +9,10 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamNetworkingConnectionCustomSignaling : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamNetworkingConnectionCustomSignaling();
|
||||
|
||||
|
||||
internal ISteamNetworkingConnectionCustomSignaling()
|
||||
internal ISteamNetworkingConnectionCustomSignaling( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
#region FunctionMeta
|
||||
|
@ -9,12 +9,10 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamNetworkingCustomSignalingRecvContext : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamNetworkingCustomSignalingRecvContext();
|
||||
|
||||
|
||||
internal ISteamNetworkingCustomSignalingRecvContext()
|
||||
internal ISteamNetworkingCustomSignalingRecvContext( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
#region FunctionMeta
|
||||
|
@ -9,14 +9,20 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamNetworkingSockets : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamNetworkingSockets();
|
||||
|
||||
|
||||
internal ISteamNetworkingSockets()
|
||||
internal ISteamNetworkingSockets( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamNetworkingSockets_v008")]
|
||||
internal static extern IntPtr SteamAPI_SteamNetworkingSockets_v008();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamNetworkingSockets_v008();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamGameServerNetworkingSockets_v008")]
|
||||
internal static extern IntPtr SteamAPI_SteamGameServerNetworkingSockets_v008();
|
||||
public override IntPtr GetServerInterfacePointer() => SteamAPI_SteamGameServerNetworkingSockets_v008();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamNetworkingSockets_CreateListenSocketIP")]
|
||||
private static extern Socket _CreateListenSocketIP( IntPtr self, ref NetAddress localAddress, int nOptions, [In,Out] NetKeyValue[] pOptions );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamNetworkingUtils : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamNetworkingUtils();
|
||||
|
||||
|
||||
internal ISteamNetworkingUtils()
|
||||
internal ISteamNetworkingUtils( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamNetworkingUtils_v003")]
|
||||
internal static extern IntPtr SteamAPI_SteamNetworkingUtils_v003();
|
||||
public override IntPtr GetGlobalInterfacePointer() => SteamAPI_SteamNetworkingUtils_v003();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamNetworkingUtils_AllocateMessage")]
|
||||
private static extern IntPtr _AllocateMessage( IntPtr self, int cbAllocateBuffer );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamParentalSettings : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamParentalSettings();
|
||||
|
||||
|
||||
internal ISteamParentalSettings()
|
||||
internal ISteamParentalSettings( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamParentalSettings_v001")]
|
||||
internal static extern IntPtr SteamAPI_SteamParentalSettings_v001();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamParentalSettings_v001();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamParentalSettings_BIsParentalLockEnabled")]
|
||||
[return: MarshalAs( UnmanagedType.I1 )]
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamParties : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamParties();
|
||||
|
||||
|
||||
internal ISteamParties()
|
||||
internal ISteamParties( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamParties_v002")]
|
||||
internal static extern IntPtr SteamAPI_SteamParties_v002();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamParties_v002();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamParties_GetNumActiveBeacons")]
|
||||
private static extern uint _GetNumActiveBeacons( IntPtr self );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamRemotePlay : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamRemotePlay();
|
||||
|
||||
|
||||
internal ISteamRemotePlay()
|
||||
internal ISteamRemotePlay( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamRemotePlay_v001")]
|
||||
internal static extern IntPtr SteamAPI_SteamRemotePlay_v001();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamRemotePlay_v001();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamRemotePlay_GetSessionCount")]
|
||||
private static extern uint _GetSessionCount( IntPtr self );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamRemoteStorage : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamRemoteStorage();
|
||||
|
||||
|
||||
internal ISteamRemoteStorage()
|
||||
internal ISteamRemoteStorage( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamRemoteStorage_v014")]
|
||||
internal static extern IntPtr SteamAPI_SteamRemoteStorage_v014();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamRemoteStorage_v014();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamRemoteStorage_FileWrite")]
|
||||
[return: MarshalAs( UnmanagedType.I1 )]
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamScreenshots : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamScreenshots();
|
||||
|
||||
|
||||
internal ISteamScreenshots()
|
||||
internal ISteamScreenshots( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamScreenshots_v003")]
|
||||
internal static extern IntPtr SteamAPI_SteamScreenshots_v003();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamScreenshots_v003();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamScreenshots_WriteScreenshot")]
|
||||
private static extern ScreenshotHandle _WriteScreenshot( IntPtr self, IntPtr pubRGB, uint cubRGB, int nWidth, int nHeight );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamTV : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamTV();
|
||||
|
||||
|
||||
internal ISteamTV()
|
||||
internal ISteamTV( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamTV_v001")]
|
||||
internal static extern IntPtr SteamAPI_SteamTV_v001();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamTV_v001();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamTV_IsBroadcasting")]
|
||||
[return: MarshalAs( UnmanagedType.I1 )]
|
||||
|
@ -9,14 +9,20 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamUGC : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamUGC();
|
||||
|
||||
|
||||
internal ISteamUGC()
|
||||
internal ISteamUGC( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamUGC_v014")]
|
||||
internal static extern IntPtr SteamAPI_SteamUGC_v014();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamUGC_v014();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamGameServerUGC_v014")]
|
||||
internal static extern IntPtr SteamAPI_SteamGameServerUGC_v014();
|
||||
public override IntPtr GetServerInterfacePointer() => SteamAPI_SteamGameServerUGC_v014();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamUGC_CreateQueryUserUGCRequest")]
|
||||
private static extern UGCQueryHandle_t _CreateQueryUserUGCRequest( IntPtr self, AccountID_t unAccountID, UserUGCList eListType, UgcType eMatchingUGCType, UserUGCListSortOrder eSortOrder, AppId nCreatorAppID, AppId nConsumerAppID, uint unPage );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamUser : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamUser();
|
||||
|
||||
|
||||
internal ISteamUser()
|
||||
internal ISteamUser( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamUser_v020")]
|
||||
internal static extern IntPtr SteamAPI_SteamUser_v020();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamUser_v020();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamUser_GetHSteamUser")]
|
||||
private static extern HSteamUser _GetHSteamUser( IntPtr self );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamUserStats : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamUserStats();
|
||||
|
||||
|
||||
internal ISteamUserStats()
|
||||
internal ISteamUserStats( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamUserStats_v011")]
|
||||
internal static extern IntPtr SteamAPI_SteamUserStats_v011();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamUserStats_v011();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamUserStats_RequestCurrentStats")]
|
||||
[return: MarshalAs( UnmanagedType.I1 )]
|
||||
|
@ -9,14 +9,20 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamUtils : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamUtils();
|
||||
|
||||
|
||||
internal ISteamUtils()
|
||||
internal ISteamUtils( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamUtils_v009")]
|
||||
internal static extern IntPtr SteamAPI_SteamUtils_v009();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamUtils_v009();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamGameServerUtils_v009")]
|
||||
internal static extern IntPtr SteamAPI_SteamGameServerUtils_v009();
|
||||
public override IntPtr GetServerInterfacePointer() => SteamAPI_SteamGameServerUtils_v009();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamUtils_GetSecondsSinceAppActive")]
|
||||
private static extern uint _GetSecondsSinceAppActive( IntPtr self );
|
||||
|
@ -9,14 +9,17 @@ namespace Steamworks
|
||||
{
|
||||
internal class ISteamVideo : SteamInterface
|
||||
{
|
||||
public override IntPtr GetInterfacePointer() => GetApi.SteamVideo();
|
||||
|
||||
|
||||
internal ISteamVideo()
|
||||
internal ISteamVideo( bool IsGameServer )
|
||||
{
|
||||
SetupInterface();
|
||||
SetupInterface( IsGameServer );
|
||||
}
|
||||
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_SteamVideo_v002")]
|
||||
internal static extern IntPtr SteamAPI_SteamVideo_v002();
|
||||
public override IntPtr GetUserInterfacePointer() => SteamAPI_SteamVideo_v002();
|
||||
|
||||
|
||||
#region FunctionMeta
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAPI_ISteamVideo_GetVideoURL")]
|
||||
private static extern void _GetVideoURL( IntPtr self, AppId unVideoAppID );
|
||||
|
@ -16,9 +16,9 @@ namespace Steamworks
|
||||
internal static ISteamApps Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamApps();
|
||||
Internal = new ISteamApps( server );
|
||||
}
|
||||
|
||||
|
||||
|
@ -58,7 +58,7 @@ namespace Steamworks
|
||||
internal static void AddInterface<T>() where T : SteamClass, new()
|
||||
{
|
||||
var t = new T();
|
||||
t.InitializeInterface();
|
||||
t.InitializeInterface( false );
|
||||
openInterfaces.Add( t );
|
||||
}
|
||||
|
||||
|
@ -15,9 +15,9 @@ namespace Steamworks
|
||||
internal static ISteamFriends Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamFriends();
|
||||
Internal = new ISteamFriends( server );
|
||||
|
||||
richPresence = new Dictionary<string, string>();
|
||||
}
|
||||
|
@ -8,9 +8,9 @@ namespace Steamworks
|
||||
internal static ISteamInput Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamInput();
|
||||
Internal = new ISteamInput( server );
|
||||
}
|
||||
|
||||
internal const int STEAM_CONTROLLER_MAX_COUNT = 16;
|
||||
|
@ -17,9 +17,9 @@ namespace Steamworks
|
||||
internal static ISteamInventory Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamInventory();
|
||||
Internal = new ISteamInventory( server );
|
||||
|
||||
InstallEvents();
|
||||
}
|
||||
|
@ -15,9 +15,9 @@ namespace Steamworks
|
||||
internal static ISteamMatchmaking Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamMatchmaking();
|
||||
Internal = new ISteamMatchmaking( server );
|
||||
|
||||
InstallEvents();
|
||||
}
|
||||
|
@ -15,9 +15,9 @@ namespace Steamworks
|
||||
internal static ISteamMatchmakingServers Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamMatchmakingServers();
|
||||
Internal = new ISteamMatchmakingServers( server );
|
||||
}
|
||||
}
|
||||
}
|
@ -18,9 +18,9 @@ namespace Steamworks
|
||||
internal static ISteamMusic Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamMusic();
|
||||
Internal = new ISteamMusic( server );
|
||||
|
||||
InstallEvents();
|
||||
}
|
||||
|
@ -13,9 +13,9 @@ namespace Steamworks
|
||||
internal static ISteamNetworking Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamNetworking();
|
||||
Internal = new ISteamNetworking( server );
|
||||
|
||||
InstallEvents();
|
||||
}
|
||||
|
@ -13,9 +13,9 @@ namespace Steamworks
|
||||
internal static ISteamNetworkingSockets Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamNetworkingSockets();
|
||||
Internal = new ISteamNetworkingSockets( server );
|
||||
|
||||
SocketInterfaces = new Dictionary<uint, SocketInterface>();
|
||||
ConnectionInterfaces = new Dictionary<uint, ConnectionInterface>();
|
||||
|
@ -15,9 +15,9 @@ namespace Steamworks
|
||||
internal static ISteamNetworkingUtils Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamNetworkingUtils();
|
||||
Internal = new ISteamNetworkingUtils( server );
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -15,9 +15,9 @@ namespace Steamworks
|
||||
internal static ISteamParentalSettings Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamParentalSettings();
|
||||
Internal = new ISteamParentalSettings( server );
|
||||
InstallEvents();
|
||||
}
|
||||
|
||||
|
@ -12,9 +12,9 @@ namespace Steamworks
|
||||
internal static ISteamParties Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamParties();
|
||||
Internal = new ISteamParties( server );
|
||||
InstallEvents();
|
||||
}
|
||||
|
||||
|
@ -15,9 +15,9 @@ namespace Steamworks
|
||||
internal static ISteamRemoteStorage Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamRemoteStorage();
|
||||
Internal = new ISteamRemoteStorage( server );
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -15,9 +15,9 @@ namespace Steamworks
|
||||
internal static ISteamScreenshots Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamScreenshots();
|
||||
Internal = new ISteamScreenshots( server );
|
||||
InstallEvents();
|
||||
}
|
||||
|
||||
|
@ -15,9 +15,9 @@ namespace Steamworks
|
||||
internal static ISteamGameServer Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamGameServer();
|
||||
Internal = new ISteamGameServer( server );
|
||||
InstallEvents();
|
||||
}
|
||||
|
||||
@ -110,7 +110,7 @@ namespace Steamworks
|
||||
internal static void AddInterface<T>() where T : SteamClass, new()
|
||||
{
|
||||
var t = new T();
|
||||
t.InitializeInterface();
|
||||
t.InitializeInterface( true );
|
||||
openInterfaces.Add( t );
|
||||
}
|
||||
|
||||
|
@ -12,9 +12,9 @@ namespace Steamworks
|
||||
internal static ISteamGameServerStats Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamGameServerStats();
|
||||
Internal = new ISteamGameServerStats( server );
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -17,9 +17,9 @@ namespace Steamworks
|
||||
internal static ISteamUGC Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamUGC();
|
||||
Internal = new ISteamUGC( server );
|
||||
InstallEvents();
|
||||
}
|
||||
|
||||
|
@ -18,9 +18,9 @@ namespace Steamworks
|
||||
internal static ISteamUser Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamUser();
|
||||
Internal = new ISteamUser( server );
|
||||
InstallEvents();
|
||||
|
||||
richPresence = new Dictionary<string, string>();
|
||||
|
@ -12,9 +12,9 @@ namespace Steamworks
|
||||
internal static ISteamUserStats Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamUserStats();
|
||||
Internal = new ISteamUserStats( server );
|
||||
|
||||
InstallEvents();
|
||||
RequestCurrentStats();
|
||||
|
@ -15,9 +15,9 @@ namespace Steamworks
|
||||
internal static ISteamUtils Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamUtils();
|
||||
Internal = new ISteamUtils( server );
|
||||
|
||||
InstallEvents();
|
||||
}
|
||||
|
@ -15,9 +15,9 @@ namespace Steamworks
|
||||
internal static ISteamVideo Internal;
|
||||
internal override SteamInterface Interface => Internal;
|
||||
|
||||
internal override void InitializeInterface()
|
||||
internal override void InitializeInterface( bool server )
|
||||
{
|
||||
Internal = new ISteamVideo();
|
||||
Internal = new ISteamVideo( server );
|
||||
|
||||
InstallEvents();
|
||||
}
|
||||
|
@ -1,83 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Net;
|
||||
using System.Net.Sockets;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
|
||||
namespace Steamworks
|
||||
{
|
||||
internal static class GetApi
|
||||
{
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamClient" )]
|
||||
internal static extern IntPtr SteamClient();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamUser" )]
|
||||
internal static extern IntPtr SteamUser();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamFriends" )]
|
||||
internal static extern IntPtr SteamFriends();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamUtils" )]
|
||||
internal static extern IntPtr SteamUtils();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamMatchmaking" )]
|
||||
internal static extern IntPtr SteamMatchmaking();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamMatchmakingServerListResponse" )]
|
||||
internal static extern IntPtr SteamMatchmakingServerListResponse();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamMatchmakingPingResponse" )]
|
||||
internal static extern IntPtr SteamMatchmakingPingResponse();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamMatchmakingPlayersResponse" )]
|
||||
internal static extern IntPtr SteamMatchmakingPlayersResponse();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamMatchmakingRulesResponse" )]
|
||||
internal static extern IntPtr SteamMatchmakingRulesResponse();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamMatchmakingServers" )]
|
||||
internal static extern IntPtr SteamMatchmakingServers();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamGameSearch" )]
|
||||
internal static extern IntPtr SteamGameSearch();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamParties" )]
|
||||
internal static extern IntPtr SteamParties();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamRemoteStorage" )]
|
||||
internal static extern IntPtr SteamRemoteStorage();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamUserStats" )]
|
||||
internal static extern IntPtr SteamUserStats();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamApps" )]
|
||||
internal static extern IntPtr SteamApps();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamNetworking" )]
|
||||
internal static extern IntPtr SteamNetworking();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamScreenshots" )]
|
||||
internal static extern IntPtr SteamScreenshots();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamMusic" )]
|
||||
internal static extern IntPtr SteamMusic();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamMusicRemote" )]
|
||||
internal static extern IntPtr SteamMusicRemote();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamHTTP" )]
|
||||
internal static extern IntPtr SteamHTTP();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamInput" )]
|
||||
internal static extern IntPtr SteamInput();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamController" )]
|
||||
internal static extern IntPtr SteamController();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamUGC" )]
|
||||
internal static extern IntPtr SteamUGC();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamAppList" )]
|
||||
internal static extern IntPtr SteamAppList();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamHTMLSurface" )]
|
||||
internal static extern IntPtr SteamHTMLSurface();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamInventory" )]
|
||||
internal static extern IntPtr SteamInventory();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamVideo" )]
|
||||
internal static extern IntPtr SteamVideo();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamParentalSettings" )]
|
||||
internal static extern IntPtr SteamParentalSettings();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamGameServer" )]
|
||||
internal static extern IntPtr SteamGameServer();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamGameServerStats" )]
|
||||
internal static extern IntPtr SteamGameServerStats();
|
||||
|
||||
//
|
||||
// NOTE: Stubs - these don't exist
|
||||
//
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamNetworkingSockets" )]
|
||||
internal static extern IntPtr SteamNetworkingSockets();
|
||||
[DllImport( Platform.LibraryName, EntryPoint = "SteamNetworkingUtils" )]
|
||||
internal static extern IntPtr SteamNetworkingUtils();
|
||||
}
|
||||
}
|
@ -11,15 +11,25 @@ namespace Steamworks
|
||||
{
|
||||
internal abstract class SteamInterface
|
||||
{
|
||||
public abstract IntPtr GetInterfacePointer();
|
||||
public virtual IntPtr GetUserInterfacePointer() => IntPtr.Zero;
|
||||
public virtual IntPtr GetServerInterfacePointer() => IntPtr.Zero;
|
||||
public virtual IntPtr GetGlobalInterfacePointer() => IntPtr.Zero;
|
||||
|
||||
public IntPtr Self;
|
||||
|
||||
public bool IsValid => Self != IntPtr.Zero;
|
||||
|
||||
internal void SetupInterface()
|
||||
internal void SetupInterface( bool gameServer )
|
||||
{
|
||||
Self = GetInterfacePointer();
|
||||
Self = GetGlobalInterfacePointer();
|
||||
|
||||
if ( Self != IntPtr.Zero )
|
||||
return;
|
||||
|
||||
if ( gameServer )
|
||||
Self = GetServerInterfacePointer();
|
||||
else
|
||||
Self = GetUserInterfacePointer();
|
||||
}
|
||||
|
||||
internal void ShutdownInterface()
|
||||
@ -30,7 +40,7 @@ namespace Steamworks
|
||||
|
||||
public abstract class SteamClass
|
||||
{
|
||||
internal abstract void InitializeInterface();
|
||||
internal abstract void InitializeInterface( bool server );
|
||||
internal virtual void DestroyInterface()
|
||||
{
|
||||
Interface.ShutdownInterface();
|
||||
|
@ -25,16 +25,43 @@ namespace Generator
|
||||
{
|
||||
StartBlock( $"internal class {iface.Name} : SteamInterface" );
|
||||
{
|
||||
WriteLine( $"public override IntPtr GetInterfacePointer() => GetApi.{iface.Name.Substring( 1 )}();" );
|
||||
WriteLine();
|
||||
WriteLine();
|
||||
StartBlock( $"internal {iface.Name}()" );
|
||||
StartBlock( $"internal {iface.Name}( bool IsGameServer )" );
|
||||
{
|
||||
WriteLine( $"SetupInterface();" );
|
||||
WriteLine( $"SetupInterface( IsGameServer );" );
|
||||
}
|
||||
EndBlock();
|
||||
WriteLine();
|
||||
|
||||
if ( iface.Accessors != null )
|
||||
{
|
||||
foreach ( var func in iface.Accessors )
|
||||
{
|
||||
WriteLine( $"[DllImport( Platform.LibraryName, EntryPoint = \"{func.Name_Flat}\")]" );
|
||||
WriteLine( $"internal static extern IntPtr {func.Name_Flat}();" );
|
||||
|
||||
if ( func.Kind == "user" )
|
||||
{
|
||||
WriteLine( $"public override IntPtr GetUserInterfacePointer() => {func.Name_Flat}();" );
|
||||
}
|
||||
else if ( func.Kind == "gameserver" )
|
||||
{
|
||||
WriteLine( $"public override IntPtr GetServerInterfacePointer() => {func.Name_Flat}();" );
|
||||
}
|
||||
else if ( func.Kind == "global" )
|
||||
{
|
||||
WriteLine( $"public override IntPtr GetGlobalInterfacePointer() => {func.Name_Flat}();" );
|
||||
}
|
||||
else
|
||||
{
|
||||
throw new Exception( $"unknown Kind {func.Kind}" );
|
||||
}
|
||||
}
|
||||
|
||||
WriteLine();
|
||||
WriteLine();
|
||||
}
|
||||
|
||||
foreach ( var func in iface.Methods )
|
||||
{
|
||||
if ( Cleanup.IsDeprecated( $"{iface.Name}.{func.Name}" ) )
|
||||
|
@ -38,6 +38,16 @@ namespace Generator
|
||||
|
||||
public Method[] Methods { get; set; }
|
||||
|
||||
|
||||
public class Accessor
|
||||
{
|
||||
public string Kind { get; set; }
|
||||
public string Name { get; set; }
|
||||
public string Name_Flat { get; set; }
|
||||
}
|
||||
|
||||
public Accessor[] Accessors { get; set; }
|
||||
|
||||
}
|
||||
|
||||
public Interface[] Interfaces { get; set; }
|
||||
|
Loading…
x
Reference in New Issue
Block a user