API Clients
Topics
Clients
class SteamBaseAPI
class SteamBaseAPI
Behavior common to both the user and game server APIs.
You can’t create this directly; instead use a SteamAPI
or SteamGameServerAPI
.
In Steamworks, a callback is a broadcast notification. In C++ you discover what notifications
are available from the docs and use the STEAM_CALLBACK()
macro to connect your method.
In this Swift version you register using a run-time call to one of the registration methods
such as onSteamServersConnected(_:)
. If you register after creating your API instance
and before making your first call to runCallbacks()
then your code is equivalent to the C++
version.
Declaration
public class SteamBaseAPI: @unchecked Sendable
class SteamAPI
class SteamAPI
An instance of the Steamworks user API
Create and retain one of these to access and use the Steamworks APIs.
Steamworks ref: steam_api.h
Declaration
public final class SteamAPI: SteamBaseAPI, Sendable
class SteamGameServerAPI
class SteamGameServerAPI
An instance of the Steamworks game server API
Create and retain one of these to access and use the Steamworks game server APIs.
Steamworks ref: steam_gameserver.h
Declaration
public final class SteamGameServerAPI: SteamBaseAPI, Sendable
struct SteamEncryptedAppTicket
struct SteamEncryptedAppTicket
Wrap up the SteamEncryptedAppTicket
functions.
Declaration
public struct SteamEncryptedAppTicket: Sendable