SteamMatchmaking

Swift
public struct SteamMatchmaking: Sendable

Steamworks ISteamMatchmaking

Access via matchmaking.


Topics

func addFavoriteGame(appID: AppID, ip: Int, connPort: UInt16, queryPort: UInt16, flags: FavoriteFlags, time32LastPlayedOnServer: RTime32) -> Int

Steamworks ISteamMatchmaking::AddFavoriteGame()

Declaration
Swift
public func addFavoriteGame(
    appID: AppID, ip: Int, connPort: UInt16, queryPort: UInt16,
    flags: FavoriteFlags, time32LastPlayedOnServer: RTime32
) -> Int

func addRequestLobbyListCompatibleMembersFilter(lobby: SteamID)

Steamworks ISteamMatchmaking::AddRequestLobbyListCompatibleMembersFilter()

Declaration
Swift
public func addRequestLobbyListCompatibleMembersFilter(lobby: SteamID)

func addRequestLobbyListDistanceFilter(lobbyDistanceFilter: LobbyDistanceFilter)

Steamworks ISteamMatchmaking::AddRequestLobbyListDistanceFilter()

Declaration
Swift
public func addRequestLobbyListDistanceFilter(
    lobbyDistanceFilter: LobbyDistanceFilter)

func addRequestLobbyListFilterSlotsAvailable(slotsAvailable: Int)

Steamworks ISteamMatchmaking::AddRequestLobbyListFilterSlotsAvailable()

Declaration
Swift
public func addRequestLobbyListFilterSlotsAvailable(slotsAvailable: Int)

func addRequestLobbyListNearValueFilter(keyToMatch: String, valueToBeCloseTo: Int)

Steamworks ISteamMatchmaking::AddRequestLobbyListNearValueFilter()

Declaration
Swift
public func addRequestLobbyListNearValueFilter(
    keyToMatch: String, valueToBeCloseTo: Int)

func addRequestLobbyListNumericalFilter(keyToMatch: String, valueToMatch: Int, comparisonType: LobbyComparison)

Steamworks ISteamMatchmaking::AddRequestLobbyListNumericalFilter()

Declaration
Swift
public func addRequestLobbyListNumericalFilter(
    keyToMatch: String, valueToMatch: Int, comparisonType: LobbyComparison)

func addRequestLobbyListResultCountFilter(maxResults: Int)

Steamworks ISteamMatchmaking::AddRequestLobbyListResultCountFilter()

Declaration
Swift
public func addRequestLobbyListResultCountFilter(maxResults: Int)

func addRequestLobbyListStringFilter(keyToMatch: String, valueToMatch: String, comparisonType: LobbyComparison)

Steamworks ISteamMatchmaking::AddRequestLobbyListStringFilter()

Declaration
Swift
public func addRequestLobbyListStringFilter(
    keyToMatch: String, valueToMatch: String, comparisonType: LobbyComparison)

func createLobby(lobbyType: LobbyType, maxMembers: Int, completion: (LobbyCreated?) -> Void)

Steamworks ISteamMatchmaking::CreateLobby(), callback

Declaration
Swift
public func createLobby(
    lobbyType: LobbyType, maxMembers: Int,
    completion: @escaping (LobbyCreated?) -> Void)

func createLobby(lobbyType: LobbyType, maxMembers: Int) async -> LobbyCreated?

Steamworks ISteamMatchmaking::CreateLobby(), async

Declaration
Swift
public func createLobby(lobbyType: LobbyType, maxMembers: Int) async
    -> LobbyCreated?

func deleteLobbyData(lobby: SteamID, key: String) -> Bool

Steamworks ISteamMatchmaking::DeleteLobbyData()

Declaration
Swift
@discardableResult
public func deleteLobbyData(lobby: SteamID, key: String) -> Bool

func getFavoriteGame(gameIndex: Int) -> (rc: Bool, appID: AppID, ip: Int, connPort: UInt16, queryPort: UInt16, flags: FavoriteFlags, rTime32LastPlayedOnServer: RTime32)

Steamworks ISteamMatchmaking::GetFavoriteGame()

Declaration
Swift
public func getFavoriteGame(gameIndex: Int) -> (
    rc: Bool, appID: AppID, ip: Int, connPort: UInt16, queryPort: UInt16,
    flags: FavoriteFlags, rTime32LastPlayedOnServer: RTime32
)

func getFavoriteGameCount() -> Int

Steamworks ISteamMatchmaking::GetFavoriteGameCount()

Declaration
Swift
public func getFavoriteGameCount() -> Int

func getLobbyByIndex(lobbyIndex: Int) -> SteamID

Steamworks ISteamMatchmaking::GetLobbyByIndex()

Declaration
Swift
public func getLobbyByIndex(lobbyIndex: Int) -> SteamID

func getLobbyChatEntry(lobby: SteamID, chatIDIndex: Int, data: UnsafeMutableRawPointer, dataSize: Int) -> (rc: Int, user: SteamID, chatEntryType: ChatEntryType)

Steamworks ISteamMatchmaking::GetLobbyChatEntry()

Declaration
Swift
public func getLobbyChatEntry(
    lobby: SteamID, chatIDIndex: Int, data: UnsafeMutableRawPointer,
    dataSize: Int
) -> (rc: Int, user: SteamID, chatEntryType: ChatEntryType)

func getLobbyData(lobby: SteamID, key: String) -> String

Steamworks ISteamMatchmaking::GetLobbyData()

Declaration
Swift
public func getLobbyData(lobby: SteamID, key: String) -> String

func getLobbyDataByIndex(lobby: SteamID, lobbyDataIndex: Int, keyBufferSize: Int, valueBufferSize: Int) -> (rc: Bool, key: String, value: String)

Steamworks ISteamMatchmaking::GetLobbyDataByIndex()

Declaration
Swift
public func getLobbyDataByIndex(
    lobby: SteamID, lobbyDataIndex: Int,
    keyBufferSize: Int = SteamConstants.maxLobbyKeyLength + 1,
    valueBufferSize: Int
) -> (rc: Bool, key: String, value: String)

func getLobbyDataCount(lobby: SteamID) -> Int

Steamworks ISteamMatchmaking::GetLobbyDataCount()

Declaration
Swift
public func getLobbyDataCount(lobby: SteamID) -> Int

func getLobbyGameServer(lobby: SteamID) -> (rc: Bool, gameServerIP: Int, gameServerPort: UInt16, gameServer: SteamID)

Steamworks ISteamMatchmaking::GetLobbyGameServer()

Declaration
Swift
public func getLobbyGameServer(lobby: SteamID) -> (
    rc: Bool, gameServerIP: Int, gameServerPort: UInt16, gameServer: SteamID
)

func getLobbyMemberByIndex(lobby: SteamID, memberIndex: Int) -> SteamID

Steamworks ISteamMatchmaking::GetLobbyMemberByIndex()

Declaration
Swift
public func getLobbyMemberByIndex(lobby: SteamID, memberIndex: Int) -> SteamID

func getLobbyMemberData(lobby: SteamID, user: SteamID, key: String) -> String?

Steamworks ISteamMatchmaking::GetLobbyMemberData()

Declaration
Swift
public func getLobbyMemberData(lobby: SteamID, user: SteamID, key: String)
    -> String?

func getLobbyMemberLimit(lobby: SteamID) -> Int

Steamworks ISteamMatchmaking::GetLobbyMemberLimit()

Declaration
Swift
public func getLobbyMemberLimit(lobby: SteamID) -> Int

func getLobbyOwner(lobby: SteamID) -> SteamID

Steamworks ISteamMatchmaking::GetLobbyOwner()

Declaration
Swift
public func getLobbyOwner(lobby: SteamID) -> SteamID

func getNumLobbyMembers(lobby: SteamID) -> Int

Steamworks ISteamMatchmaking::GetNumLobbyMembers()

Declaration
Swift
public func getNumLobbyMembers(lobby: SteamID) -> Int

func inviteUserToLobby(lobby: SteamID, invitee: SteamID) -> Bool

Steamworks ISteamMatchmaking::InviteUserToLobby()

Declaration
Swift
@discardableResult
public func inviteUserToLobby(lobby: SteamID, invitee: SteamID) -> Bool

func joinLobby(lobby: SteamID, completion: (LobbyEnter?) -> Void)

Steamworks ISteamMatchmaking::JoinLobby(), callback

Declaration
Swift
public func joinLobby(
    lobby: SteamID, completion: @escaping (LobbyEnter?) -> Void)

func joinLobby(lobby: SteamID) async -> LobbyEnter?

Steamworks ISteamMatchmaking::JoinLobby(), async

Declaration
Swift
public func joinLobby(lobby: SteamID) async -> LobbyEnter?

func leaveLobby(lobby: SteamID)

Steamworks ISteamMatchmaking::LeaveLobby()

Declaration
Swift
public func leaveLobby(lobby: SteamID)

func removeFavoriteGame(appID: AppID, ip: Int, connPort: UInt16, queryPort: UInt16, flags: FavoriteFlags) -> Bool

Steamworks ISteamMatchmaking::RemoveFavoriteGame()

Declaration
Swift
@discardableResult
public func removeFavoriteGame(
    appID: AppID, ip: Int, connPort: UInt16, queryPort: UInt16,
    flags: FavoriteFlags
) -> Bool

func requestLobbyData(lobby: SteamID) -> Bool

Steamworks ISteamMatchmaking::RequestLobbyData()

Declaration
Swift
@discardableResult
public func requestLobbyData(lobby: SteamID) -> Bool

func requestLobbyList(completion: (LobbyMatchList?) -> Void)

Steamworks ISteamMatchmaking::RequestLobbyList(), callback

Declaration
Swift
public func requestLobbyList(completion: @escaping (LobbyMatchList?) -> Void)

func requestLobbyList() async -> LobbyMatchList?

Steamworks ISteamMatchmaking::RequestLobbyList(), async

Declaration
Swift
public func requestLobbyList() async -> LobbyMatchList?

func sendLobbyChatMsg(lobby: SteamID, msgBody: UnsafeRawPointer, msgBodySize: Int) -> Bool

Steamworks ISteamMatchmaking::SendLobbyChatMsg()

Declaration
Swift
@discardableResult
public func sendLobbyChatMsg(
    lobby: SteamID, msgBody: UnsafeRawPointer, msgBodySize: Int
) -> Bool

func setLinkedLobby(lobby: SteamID, lobbyDependent: SteamID) -> Bool

Steamworks ISteamMatchmaking::SetLinkedLobby()

Declaration
Swift
public func setLinkedLobby(lobby: SteamID, lobbyDependent: SteamID) -> Bool

func setLobbyData(lobby: SteamID, key: String, value: String) -> Bool

Steamworks ISteamMatchmaking::SetLobbyData()

Declaration
Swift
public func setLobbyData(lobby: SteamID, key: String, value: String) -> Bool

func setLobbyGameServer(lobby: SteamID, gameServerIP: Int, gameServerPort: UInt16, gameServer: SteamID)

Steamworks ISteamMatchmaking::SetLobbyGameServer()

Declaration
Swift
public func setLobbyGameServer(
    lobby: SteamID, gameServerIP: Int, gameServerPort: UInt16,
    gameServer: SteamID)

func setLobbyJoinable(lobby: SteamID, lobbyJoinable: Bool) -> Bool

Steamworks ISteamMatchmaking::SetLobbyJoinable()

Declaration
Swift
@discardableResult
public func setLobbyJoinable(lobby: SteamID, lobbyJoinable: Bool) -> Bool

func setLobbyMemberData(lobby: SteamID, key: String, value: String)

Steamworks ISteamMatchmaking::SetLobbyMemberData()

Declaration
Swift
public func setLobbyMemberData(lobby: SteamID, key: String, value: String)

func setLobbyMemberLimit(lobby: SteamID, maxMembers: Int) -> Bool

Steamworks ISteamMatchmaking::SetLobbyMemberLimit()

Declaration
Swift
@discardableResult
public func setLobbyMemberLimit(lobby: SteamID, maxMembers: Int) -> Bool

func setLobbyOwner(lobby: SteamID, newOwner: SteamID) -> Bool

Steamworks ISteamMatchmaking::SetLobbyOwner()

Declaration
Swift
public func setLobbyOwner(lobby: SteamID, newOwner: SteamID) -> Bool

func setLobbyType(lobby: SteamID, lobbyType: LobbyType) -> Bool

Steamworks ISteamMatchmaking::SetLobbyType()

Declaration
Swift
@discardableResult
public func setLobbyType(lobby: SteamID, lobbyType: LobbyType) -> Bool

func getLobbyChatMsg(lobby: SteamID, chatIDIndex: Int) -> (rc: Int, user: SteamID, msg: String, chatEntryType: ChatEntryType)

Note

Provided by module SteamworksHelpers.

Steamworks ISteamMatchmaking::GetLobbyChatEntry() for strings

Declaration
Swift
public func getLobbyChatMsg(lobby: SteamID, chatIDIndex: Int) -> (
    rc: Int, user: SteamID, msg: String, chatEntryType: ChatEntryType
)

func sendLobbyChatMsg(lobby: SteamID, msg: String) -> Bool

Note

Provided by module SteamworksHelpers.

Steamworks ISteamMatchmaking::SendLobbyChatMsg() for strings

Declaration
Swift
@discardableResult
public func sendLobbyChatMsg(lobby: SteamID, msg: String) -> Bool