docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class SteamFriends

    Purpose: interface to accessing information about individual users, that can be a friend, in a group, on a game server or in a lobby with the local user

    Inheritance
    object
    SteamFriends
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Unity.Steamworks.Interop
    Assembly: Unity.Steamworks.Interop.dll
    Syntax
    public static class SteamFriends

    Methods

    ActivateGameOverlay(string)

    activates the game overlay, with an optional dialog to open valid options include "Friends", "Community", "Players", "Settings", "OfficialGameGroup", "Stats", "Achievements", "chatroomgroup/nnnn"

    Declaration
    public static void ActivateGameOverlay(string pchDialog)
    Parameters
    Type Name Description
    string pchDialog

    Passed through to ISteamFriends::ActivateGameOverlay.

    ActivateGameOverlayInviteDialog(CSteamID)

    activates game overlay to open the invite dialog. Invitations will be sent for the provided lobby.

    Declaration
    public static void ActivateGameOverlayInviteDialog(CSteamID steamIDLobby)
    Parameters
    Type Name Description
    CSteamID steamIDLobby

    Passed through to ISteamFriends::ActivateGameOverlayInviteDialog.

    ActivateGameOverlayInviteDialogConnectString(string)

    Activates the game overlay to open an invite dialog that will send the provided Rich Presence connect string to selected friends

    Declaration
    public static void ActivateGameOverlayInviteDialogConnectString(string pchConnectString)
    Parameters
    Type Name Description
    string pchConnectString

    Passed through to ISteamFriends::ActivateGameOverlayInviteDialogConnectString.

    ActivateGameOverlayRemotePlayTogetherInviteDialog(CSteamID)

    activates game overlay to open the remote play together invite dialog. Invitations will be sent for remote play together

    Declaration
    public static void ActivateGameOverlayRemotePlayTogetherInviteDialog(CSteamID steamIDLobby)
    Parameters
    Type Name Description
    CSteamID steamIDLobby

    Passed through to ISteamFriends::ActivateGameOverlayRemotePlayTogetherInviteDialog.

    ActivateGameOverlayToStore(AppId_t, EOverlayToStoreFlag)

    activates game overlay to store page for app

    Declaration
    public static void ActivateGameOverlayToStore(AppId_t nAppID, EOverlayToStoreFlag eFlag)
    Parameters
    Type Name Description
    AppId_t nAppID

    Passed through to ISteamFriends::ActivateGameOverlayToStore.

    EOverlayToStoreFlag eFlag

    Passed through to ISteamFriends::ActivateGameOverlayToStore.

    ActivateGameOverlayToUser(string, CSteamID)

    activates game overlay to a specific place valid options are "steamid" - opens the overlay web browser to the specified user or groups profile "chat" - opens a chat window to the specified user, or joins the group chat "jointrade" - opens a window to a Steam Trading session that was started with the ISteamEconomy/StartTrade Web API "stats" - opens the overlay web browser to the specified user's stats "achievements" - opens the overlay web browser to the specified user's achievements "friendadd" - opens the overlay in minimal mode prompting the user to add the target user as a friend "friendremove" - opens the overlay in minimal mode prompting the user to remove the target friend "friendrequestaccept" - opens the overlay in minimal mode prompting the user to accept an incoming friend invite "friendrequestignore" - opens the overlay in minimal mode prompting the user to ignore an incoming friend invite

    Declaration
    public static void ActivateGameOverlayToUser(string pchDialog, CSteamID steamID)
    Parameters
    Type Name Description
    string pchDialog

    Passed through to ISteamFriends::ActivateGameOverlayToUser.

    CSteamID steamID

    Passed through to ISteamFriends::ActivateGameOverlayToUser.

    ActivateGameOverlayToWebPage(string, EActivateGameOverlayToWebPageMode)

    activates game overlay web browser directly to the specified URL full address with protocol type is required, e.g. http://www.steamgames.com/

    Declaration
    public static void ActivateGameOverlayToWebPage(string pchURL, EActivateGameOverlayToWebPageMode eMode = EActivateGameOverlayToWebPageMode.k_EActivateGameOverlayToWebPageMode_Default)
    Parameters
    Type Name Description
    string pchURL

    Passed through to ISteamFriends::ActivateGameOverlayToWebPage.

    EActivateGameOverlayToWebPageMode eMode

    Passed through to ISteamFriends::ActivateGameOverlayToWebPage.

    BHasEquippedProfileItem(CSteamID, ECommunityProfileItemType)

    Calls the Steamworks ISteamFriends::BHasEquippedProfileItem method.

    Declaration
    public static bool BHasEquippedProfileItem(CSteamID steamID, ECommunityProfileItemType itemType)
    Parameters
    Type Name Description
    CSteamID steamID

    Passed through to ISteamFriends::BHasEquippedProfileItem.

    ECommunityProfileItemType itemType

    Passed through to ISteamFriends::BHasEquippedProfileItem.

    Returns
    Type Description
    bool

    The value ISteamFriends::BHasEquippedProfileItem returns.

    ClearRichPresence()

    Calls the Steamworks ISteamFriends::ClearRichPresence method.

    Declaration
    public static void ClearRichPresence()

    CloseClanChatWindowInSteam(CSteamID)

    Calls the Steamworks ISteamFriends::CloseClanChatWindowInSteam method.

    Declaration
    public static bool CloseClanChatWindowInSteam(CSteamID steamIDClanChat)
    Parameters
    Type Name Description
    CSteamID steamIDClanChat

    Passed through to ISteamFriends::CloseClanChatWindowInSteam.

    Returns
    Type Description
    bool

    The value ISteamFriends::CloseClanChatWindowInSteam returns.

    DownloadClanActivityCounts(CSteamID[], int)

    for clans a user is a member of, they will have reasonably up-to-date information, but for others you'll have to download the info to have the latest

    Declaration
    public static SteamAPICall_t DownloadClanActivityCounts(CSteamID[] psteamIDClans, int cClansToRequest)
    Parameters
    Type Name Description
    CSteamID[] psteamIDClans

    Passed through to ISteamFriends::DownloadClanActivityCounts.

    int cClansToRequest

    Passed through to ISteamFriends::DownloadClanActivityCounts.

    Returns
    Type Description
    SteamAPICall_t

    The value ISteamFriends::DownloadClanActivityCounts returns.

    DownloadClanActivityCountsAsync(CSteamID[], int)

    Async version of DownloadClanActivityCounts(CSteamID[], int).

    Declaration
    public static Task<DownloadClanActivityCountsResult_t> DownloadClanActivityCountsAsync(CSteamID[] psteamIDClans, int cClansToRequest)
    Parameters
    Type Name Description
    CSteamID[] psteamIDClans

    Passed through to ISteamFriends::DownloadClanActivityCounts.

    int cClansToRequest

    Passed through to ISteamFriends::DownloadClanActivityCounts.

    Returns
    Type Description
    Task<DownloadClanActivityCountsResult_t>

    The DownloadClanActivityCountsResult_t Steam reports once the call completes.

    EnumerateFollowingList(uint)

    Calls the Steamworks ISteamFriends::EnumerateFollowingList method.

    Declaration
    public static SteamAPICall_t EnumerateFollowingList(uint unStartIndex)
    Parameters
    Type Name Description
    uint unStartIndex

    Passed through to ISteamFriends::EnumerateFollowingList.

    Returns
    Type Description
    SteamAPICall_t

    The value ISteamFriends::EnumerateFollowingList returns.

    EnumerateFollowingListAsync(uint)

    Async version of EnumerateFollowingList(uint).

    Declaration
    public static Task<FriendsEnumerateFollowingList_t> EnumerateFollowingListAsync(uint unStartIndex)
    Parameters
    Type Name Description
    uint unStartIndex

    Passed through to ISteamFriends::EnumerateFollowingList.

    Returns
    Type Description
    Task<FriendsEnumerateFollowingList_t>

    The FriendsEnumerateFollowingList_t Steam reports once the call completes.

    GetChatMemberByIndex(CSteamID, int)

    Calls the Steamworks ISteamFriends::GetChatMemberByIndex method.

    Declaration
    public static CSteamID GetChatMemberByIndex(CSteamID steamIDClan, int iUser)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::GetChatMemberByIndex.

    int iUser

    Passed through to ISteamFriends::GetChatMemberByIndex.

    Returns
    Type Description
    CSteamID

    The value ISteamFriends::GetChatMemberByIndex returns.

    GetClanActivityCounts(CSteamID, out int, out int, out int)

    returns the most recent information we have about what's happening in a clan

    Declaration
    public static bool GetClanActivityCounts(CSteamID steamIDClan, out int pnOnline, out int pnInGame, out int pnChatting)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::GetClanActivityCounts.

    int pnOnline

    Passed through to ISteamFriends::GetClanActivityCounts.

    int pnInGame

    Passed through to ISteamFriends::GetClanActivityCounts.

    int pnChatting

    Passed through to ISteamFriends::GetClanActivityCounts.

    Returns
    Type Description
    bool

    The value ISteamFriends::GetClanActivityCounts returns.

    GetClanByIndex(int)

    Calls the Steamworks ISteamFriends::GetClanByIndex method.

    Declaration
    public static CSteamID GetClanByIndex(int iClan)
    Parameters
    Type Name Description
    int iClan

    Passed through to ISteamFriends::GetClanByIndex.

    Returns
    Type Description
    CSteamID

    The value ISteamFriends::GetClanByIndex returns.

    GetClanChatMemberCount(CSteamID)

    Calls the Steamworks ISteamFriends::GetClanChatMemberCount method.

    Declaration
    public static int GetClanChatMemberCount(CSteamID steamIDClan)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::GetClanChatMemberCount.

    Returns
    Type Description
    int

    The value ISteamFriends::GetClanChatMemberCount returns.

    GetClanChatMessage(CSteamID, int, out string, int, out EChatEntryType, out CSteamID)

    Calls the Steamworks ISteamFriends::GetClanChatMessage method.

    Declaration
    public static int GetClanChatMessage(CSteamID steamIDClanChat, int iMessage, out string prgchText, int cchTextMax, out EChatEntryType peChatEntryType, out CSteamID psteamidChatter)
    Parameters
    Type Name Description
    CSteamID steamIDClanChat

    Passed through to ISteamFriends::GetClanChatMessage.

    int iMessage

    Passed through to ISteamFriends::GetClanChatMessage.

    string prgchText

    Receives the string ISteamFriends::GetClanChatMessage writes.

    int cchTextMax

    Passed through to ISteamFriends::GetClanChatMessage.

    EChatEntryType peChatEntryType

    Passed through to ISteamFriends::GetClanChatMessage.

    CSteamID psteamidChatter

    Passed through to ISteamFriends::GetClanChatMessage.

    Returns
    Type Description
    int

    The value ISteamFriends::GetClanChatMessage returns.

    GetClanCount()

    clan (group) iteration and access functions

    Declaration
    public static int GetClanCount()
    Returns
    Type Description
    int

    The value ISteamFriends::GetClanCount returns.

    GetClanName(CSteamID)

    Calls the Steamworks ISteamFriends::GetClanName method.

    Declaration
    public static string GetClanName(CSteamID steamIDClan)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::GetClanName.

    Returns
    Type Description
    string

    The value ISteamFriends::GetClanName returns.

    GetClanOfficerByIndex(CSteamID, int)

    returns the steamID of a clan officer, by index, of range [0,GetClanOfficerCount)

    Declaration
    public static CSteamID GetClanOfficerByIndex(CSteamID steamIDClan, int iOfficer)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::GetClanOfficerByIndex.

    int iOfficer

    Passed through to ISteamFriends::GetClanOfficerByIndex.

    Returns
    Type Description
    CSteamID

    The value ISteamFriends::GetClanOfficerByIndex returns.

    GetClanOfficerCount(CSteamID)

    returns the number of officers in a clan (including the owner)

    Declaration
    public static int GetClanOfficerCount(CSteamID steamIDClan)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::GetClanOfficerCount.

    Returns
    Type Description
    int

    The value ISteamFriends::GetClanOfficerCount returns.

    GetClanOwner(CSteamID)

    iteration of clan officers - can only be done when a RequestClanOfficerList() call has completed returns the steamID of the clan owner

    Declaration
    public static CSteamID GetClanOwner(CSteamID steamIDClan)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::GetClanOwner.

    Returns
    Type Description
    CSteamID

    The value ISteamFriends::GetClanOwner returns.

    GetClanTag(CSteamID)

    Calls the Steamworks ISteamFriends::GetClanTag method.

    Declaration
    public static string GetClanTag(CSteamID steamIDClan)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::GetClanTag.

    Returns
    Type Description
    string

    The value ISteamFriends::GetClanTag returns.

    GetCoplayFriend(int)

    Calls the Steamworks ISteamFriends::GetCoplayFriend method.

    Declaration
    public static CSteamID GetCoplayFriend(int iCoplayFriend)
    Parameters
    Type Name Description
    int iCoplayFriend

    Passed through to ISteamFriends::GetCoplayFriend.

    Returns
    Type Description
    CSteamID

    The value ISteamFriends::GetCoplayFriend returns.

    GetCoplayFriendCount()

    recently-played-with friends iteration this iterates the entire list of users recently played with, across games GetFriendCoplayTime() returns as a unix time

    Declaration
    public static int GetCoplayFriendCount()
    Returns
    Type Description
    int

    The value ISteamFriends::GetCoplayFriendCount returns.

    GetFollowerCount(CSteamID)

    following apis

    Declaration
    public static SteamAPICall_t GetFollowerCount(CSteamID steamID)
    Parameters
    Type Name Description
    CSteamID steamID

    Passed through to ISteamFriends::GetFollowerCount.

    Returns
    Type Description
    SteamAPICall_t

    The value ISteamFriends::GetFollowerCount returns.

    GetFollowerCountAsync(CSteamID)

    Async version of GetFollowerCount(CSteamID).

    Declaration
    public static Task<FriendsGetFollowerCount_t> GetFollowerCountAsync(CSteamID steamID)
    Parameters
    Type Name Description
    CSteamID steamID

    Passed through to ISteamFriends::GetFollowerCount.

    Returns
    Type Description
    Task<FriendsGetFollowerCount_t>

    The FriendsGetFollowerCount_t Steam reports once the call completes.

    GetFriendByIndex(int, EFriendFlags)

    returns the steamID of a user iFriend is a index of range [0, GetFriendCount()) iFriendsFlags must be the same value as used in GetFriendCount() the returned CSteamID can then be used by all the functions below to access details about the user

    Declaration
    public static CSteamID GetFriendByIndex(int iFriend, EFriendFlags iFriendFlags)
    Parameters
    Type Name Description
    int iFriend

    Passed through to ISteamFriends::GetFriendByIndex.

    EFriendFlags iFriendFlags

    Passed through to ISteamFriends::GetFriendByIndex.

    Returns
    Type Description
    CSteamID

    The value ISteamFriends::GetFriendByIndex returns.

    GetFriendCoplayGame(CSteamID)

    Calls the Steamworks ISteamFriends::GetFriendCoplayGame method.

    Declaration
    public static AppId_t GetFriendCoplayGame(CSteamID steamIDFriend)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetFriendCoplayGame.

    Returns
    Type Description
    AppId_t

    The value ISteamFriends::GetFriendCoplayGame returns.

    GetFriendCoplayTime(CSteamID)

    Calls the Steamworks ISteamFriends::GetFriendCoplayTime method.

    Declaration
    public static int GetFriendCoplayTime(CSteamID steamIDFriend)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetFriendCoplayTime.

    Returns
    Type Description
    int

    The value ISteamFriends::GetFriendCoplayTime returns.

    GetFriendCount(EFriendFlags)

    friend iteration takes a set of k_EFriendFlags, and returns the number of users the client knows about who meet that criteria then GetFriendByIndex() can then be used to return the id's of each of those users

    Declaration
    public static int GetFriendCount(EFriendFlags iFriendFlags)
    Parameters
    Type Name Description
    EFriendFlags iFriendFlags

    Passed through to ISteamFriends::GetFriendCount.

    Returns
    Type Description
    int

    The value ISteamFriends::GetFriendCount returns.

    GetFriendCountFromSource(CSteamID)

    iterators for getting users in a chat room, lobby, game server or clan note that large clans that cannot be iterated by the local user note that the current user must be in a lobby to retrieve CSteamIDs of other users in that lobby steamIDSource can be the steamID of a group, game server, lobby or chat room

    Declaration
    public static int GetFriendCountFromSource(CSteamID steamIDSource)
    Parameters
    Type Name Description
    CSteamID steamIDSource

    Passed through to ISteamFriends::GetFriendCountFromSource.

    Returns
    Type Description
    int

    The value ISteamFriends::GetFriendCountFromSource returns.

    GetFriendFromSourceByIndex(CSteamID, int)

    Calls the Steamworks ISteamFriends::GetFriendFromSourceByIndex method.

    Declaration
    public static CSteamID GetFriendFromSourceByIndex(CSteamID steamIDSource, int iFriend)
    Parameters
    Type Name Description
    CSteamID steamIDSource

    Passed through to ISteamFriends::GetFriendFromSourceByIndex.

    int iFriend

    Passed through to ISteamFriends::GetFriendFromSourceByIndex.

    Returns
    Type Description
    CSteamID

    The value ISteamFriends::GetFriendFromSourceByIndex returns.

    GetFriendGamePlayed(CSteamID, out FriendGameInfo_t)

    returns true if the friend is actually in a game, and fills in pFriendGameInfo with an extra details

    Declaration
    public static bool GetFriendGamePlayed(CSteamID steamIDFriend, out FriendGameInfo_t pFriendGameInfo)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetFriendGamePlayed.

    FriendGameInfo_t pFriendGameInfo

    Passed through to ISteamFriends::GetFriendGamePlayed.

    Returns
    Type Description
    bool

    The value ISteamFriends::GetFriendGamePlayed returns.

    GetFriendMessage(CSteamID, int, out string, int, out EChatEntryType)

    Calls the Steamworks ISteamFriends::GetFriendMessage method.

    Declaration
    public static int GetFriendMessage(CSteamID steamIDFriend, int iMessageID, out string pvData, int cubData, out EChatEntryType peChatEntryType)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetFriendMessage.

    int iMessageID

    Passed through to ISteamFriends::GetFriendMessage.

    string pvData

    Receives the string ISteamFriends::GetFriendMessage writes.

    int cubData

    Passed through to ISteamFriends::GetFriendMessage.

    EChatEntryType peChatEntryType

    Passed through to ISteamFriends::GetFriendMessage.

    Returns
    Type Description
    int

    The value ISteamFriends::GetFriendMessage returns.

    GetFriendPersonaName(CSteamID)

    returns the name another user - guaranteed to not be NULL. same rules as GetFriendPersonaState() apply as to whether or not the user knowns the name of the other user note that on first joining a lobby, chat room or game server the local user will not known the name of the other users automatically; that information will arrive asyncronously

    Declaration
    public static string GetFriendPersonaName(CSteamID steamIDFriend)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetFriendPersonaName.

    Returns
    Type Description
    string

    The value ISteamFriends::GetFriendPersonaName returns.

    GetFriendPersonaNameHistory(CSteamID, int)

    accesses old friends names - returns an empty string when their are no more items in the history

    Declaration
    public static string GetFriendPersonaNameHistory(CSteamID steamIDFriend, int iPersonaName)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetFriendPersonaNameHistory.

    int iPersonaName

    Passed through to ISteamFriends::GetFriendPersonaNameHistory.

    Returns
    Type Description
    string

    The value ISteamFriends::GetFriendPersonaNameHistory returns.

    GetFriendPersonaState(CSteamID)

    returns the current status of the specified user this will only be known by the local user if steamIDFriend is in their friends list; on the same game server; in a chat room or lobby; or in a small group with the local user

    Declaration
    public static EPersonaState GetFriendPersonaState(CSteamID steamIDFriend)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetFriendPersonaState.

    Returns
    Type Description
    EPersonaState

    The value ISteamFriends::GetFriendPersonaState returns.

    GetFriendRelationship(CSteamID)

    returns a relationship to a user

    Declaration
    public static EFriendRelationship GetFriendRelationship(CSteamID steamIDFriend)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetFriendRelationship.

    Returns
    Type Description
    EFriendRelationship

    The value ISteamFriends::GetFriendRelationship returns.

    GetFriendRichPresence(CSteamID, string)

    Calls the Steamworks ISteamFriends::GetFriendRichPresence method.

    Declaration
    public static string GetFriendRichPresence(CSteamID steamIDFriend, string pchKey)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetFriendRichPresence.

    string pchKey

    Passed through to ISteamFriends::GetFriendRichPresence.

    Returns
    Type Description
    string

    The value ISteamFriends::GetFriendRichPresence returns.

    GetFriendRichPresenceKeyByIndex(CSteamID, int)

    Calls the Steamworks ISteamFriends::GetFriendRichPresenceKeyByIndex method.

    Declaration
    public static string GetFriendRichPresenceKeyByIndex(CSteamID steamIDFriend, int iKey)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetFriendRichPresenceKeyByIndex.

    int iKey

    Passed through to ISteamFriends::GetFriendRichPresenceKeyByIndex.

    Returns
    Type Description
    string

    The value ISteamFriends::GetFriendRichPresenceKeyByIndex returns.

    GetFriendRichPresenceKeyCount(CSteamID)

    Calls the Steamworks ISteamFriends::GetFriendRichPresenceKeyCount method.

    Declaration
    public static int GetFriendRichPresenceKeyCount(CSteamID steamIDFriend)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetFriendRichPresenceKeyCount.

    Returns
    Type Description
    int

    The value ISteamFriends::GetFriendRichPresenceKeyCount returns.

    GetFriendSteamLevel(CSteamID)

    friends steam level

    Declaration
    public static int GetFriendSteamLevel(CSteamID steamIDFriend)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetFriendSteamLevel.

    Returns
    Type Description
    int

    The value ISteamFriends::GetFriendSteamLevel returns.

    GetFriendsGroupCount()

    friend grouping (tag) apis returns the number of friends groups

    Declaration
    public static int GetFriendsGroupCount()
    Returns
    Type Description
    int

    The value ISteamFriends::GetFriendsGroupCount returns.

    GetFriendsGroupIDByIndex(int)

    returns the friends group ID for the given index (invalid indices return k_FriendsGroupID_Invalid)

    Declaration
    public static FriendsGroupID_t GetFriendsGroupIDByIndex(int iFG)
    Parameters
    Type Name Description
    int iFG

    Passed through to ISteamFriends::GetFriendsGroupIDByIndex.

    Returns
    Type Description
    FriendsGroupID_t

    The value ISteamFriends::GetFriendsGroupIDByIndex returns.

    GetFriendsGroupMembersCount(FriendsGroupID_t)

    returns the number of members in a given friends group

    Declaration
    public static int GetFriendsGroupMembersCount(FriendsGroupID_t friendsGroupID)
    Parameters
    Type Name Description
    FriendsGroupID_t friendsGroupID

    Passed through to ISteamFriends::GetFriendsGroupMembersCount.

    Returns
    Type Description
    int

    The value ISteamFriends::GetFriendsGroupMembersCount returns.

    GetFriendsGroupMembersList(FriendsGroupID_t, CSteamID[], int)

    gets up to nMembersCount members of the given friends group, if fewer exist than requested those positions' SteamIDs will be invalid

    Declaration
    public static void GetFriendsGroupMembersList(FriendsGroupID_t friendsGroupID, CSteamID[] pOutSteamIDMembers, int nMembersCount)
    Parameters
    Type Name Description
    FriendsGroupID_t friendsGroupID

    Passed through to ISteamFriends::GetFriendsGroupMembersList.

    CSteamID[] pOutSteamIDMembers

    Passed through to ISteamFriends::GetFriendsGroupMembersList.

    int nMembersCount

    Passed through to ISteamFriends::GetFriendsGroupMembersList.

    GetFriendsGroupName(FriendsGroupID_t)

    returns the name for the given friends group (NULL in the case of invalid friends group IDs)

    Declaration
    public static string GetFriendsGroupName(FriendsGroupID_t friendsGroupID)
    Parameters
    Type Name Description
    FriendsGroupID_t friendsGroupID

    Passed through to ISteamFriends::GetFriendsGroupName.

    Returns
    Type Description
    string

    The value ISteamFriends::GetFriendsGroupName returns.

    GetLargeFriendAvatar(CSteamID)

    gets the large (184x184) avatar of the current user, which is a handle to be used in IClientUtils::GetImageRGBA(), or 0 if none set returns -1 if this image has yet to be loaded, in this case wait for a AvatarImageLoaded_t callback and then call this again

    Declaration
    public static int GetLargeFriendAvatar(CSteamID steamIDFriend)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetLargeFriendAvatar.

    Returns
    Type Description
    int

    The value ISteamFriends::GetLargeFriendAvatar returns.

    GetMediumFriendAvatar(CSteamID)

    gets the medium (64x64) avatar of the current user, which is a handle to be used in IClientUtils::GetImageRGBA(), or 0 if none set

    Declaration
    public static int GetMediumFriendAvatar(CSteamID steamIDFriend)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetMediumFriendAvatar.

    Returns
    Type Description
    int

    The value ISteamFriends::GetMediumFriendAvatar returns.

    GetNumChatsWithUnreadPriorityMessages()

    Return the number of chats (friends or chat rooms) with unread messages. A "priority" message is one that would generate some sort of toast or notification, and depends on user settings. You can register for UnreadChatMessagesChanged_t callbacks to know when this has potentially changed.

    Declaration
    public static int GetNumChatsWithUnreadPriorityMessages()
    Returns
    Type Description
    int

    The value ISteamFriends::GetNumChatsWithUnreadPriorityMessages returns.

    GetPersonaName()

    returns the local players name - guaranteed to not be NULL. this is the same name as on the users community profile page this is stored in UTF-8 format like all the other interface functions that return a char *, it's important that this pointer is not saved off; it will eventually be free'd or re-allocated

    Declaration
    public static string GetPersonaName()
    Returns
    Type Description
    string

    The value ISteamFriends::GetPersonaName returns.

    GetPersonaState()

    gets the status of the current user

    Declaration
    public static EPersonaState GetPersonaState()
    Returns
    Type Description
    EPersonaState

    The value ISteamFriends::GetPersonaState returns.

    GetPlayerNickname(CSteamID)

    Returns nickname the current user has set for the specified player. Returns NULL if the no nickname has been set for that player. DEPRECATED: GetPersonaName follows the Steam nickname preferences, so apps shouldn't need to care about nicknames explicitly.

    Declaration
    public static string GetPlayerNickname(CSteamID steamIDPlayer)
    Parameters
    Type Name Description
    CSteamID steamIDPlayer

    Passed through to ISteamFriends::GetPlayerNickname.

    Returns
    Type Description
    string

    The value ISteamFriends::GetPlayerNickname returns.

    GetProfileItemPropertyString(CSteamID, ECommunityProfileItemType, ECommunityProfileItemProperty)

    Calls the Steamworks ISteamFriends::GetProfileItemPropertyString method.

    Declaration
    public static string GetProfileItemPropertyString(CSteamID steamID, ECommunityProfileItemType itemType, ECommunityProfileItemProperty prop)
    Parameters
    Type Name Description
    CSteamID steamID

    Passed through to ISteamFriends::GetProfileItemPropertyString.

    ECommunityProfileItemType itemType

    Passed through to ISteamFriends::GetProfileItemPropertyString.

    ECommunityProfileItemProperty prop

    Passed through to ISteamFriends::GetProfileItemPropertyString.

    Returns
    Type Description
    string

    The value ISteamFriends::GetProfileItemPropertyString returns.

    GetProfileItemPropertyUint(CSteamID, ECommunityProfileItemType, ECommunityProfileItemProperty)

    Calls the Steamworks ISteamFriends::GetProfileItemPropertyUint method.

    Declaration
    public static uint GetProfileItemPropertyUint(CSteamID steamID, ECommunityProfileItemType itemType, ECommunityProfileItemProperty prop)
    Parameters
    Type Name Description
    CSteamID steamID

    Passed through to ISteamFriends::GetProfileItemPropertyUint.

    ECommunityProfileItemType itemType

    Passed through to ISteamFriends::GetProfileItemPropertyUint.

    ECommunityProfileItemProperty prop

    Passed through to ISteamFriends::GetProfileItemPropertyUint.

    Returns
    Type Description
    uint

    The value ISteamFriends::GetProfileItemPropertyUint returns.

    GetSmallFriendAvatar(CSteamID)

    gets the small (32x32) avatar of the current user, which is a handle to be used in IClientUtils::GetImageRGBA(), or 0 if none set

    Declaration
    public static int GetSmallFriendAvatar(CSteamID steamIDFriend)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::GetSmallFriendAvatar.

    Returns
    Type Description
    int

    The value ISteamFriends::GetSmallFriendAvatar returns.

    HasFriend(CSteamID, EFriendFlags)

    returns true if the specified user meets any of the criteria specified in iFriendFlags iFriendFlags can be the union (binary or, |) of one or more k_EFriendFlags values

    Declaration
    public static bool HasFriend(CSteamID steamIDFriend, EFriendFlags iFriendFlags)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::HasFriend.

    EFriendFlags iFriendFlags

    Passed through to ISteamFriends::HasFriend.

    Returns
    Type Description
    bool

    The value ISteamFriends::HasFriend returns.

    InviteUserToGame(CSteamID, string)

    Rich invite support. If the target accepts the invite, a GameRichPresenceJoinRequested_t callback is posted containing the connect string. (Or you can configure your game so that it is passed on the command line instead. This is a deprecated path; ask us if you really need this.)

    Declaration
    public static bool InviteUserToGame(CSteamID steamIDFriend, string pchConnectString)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::InviteUserToGame.

    string pchConnectString

    Passed through to ISteamFriends::InviteUserToGame.

    Returns
    Type Description
    bool

    The value ISteamFriends::InviteUserToGame returns.

    IsClanChatAdmin(CSteamID, CSteamID)

    Calls the Steamworks ISteamFriends::IsClanChatAdmin method.

    Declaration
    public static bool IsClanChatAdmin(CSteamID steamIDClanChat, CSteamID steamIDUser)
    Parameters
    Type Name Description
    CSteamID steamIDClanChat

    Passed through to ISteamFriends::IsClanChatAdmin.

    CSteamID steamIDUser

    Passed through to ISteamFriends::IsClanChatAdmin.

    Returns
    Type Description
    bool

    The value ISteamFriends::IsClanChatAdmin returns.

    IsClanChatWindowOpenInSteam(CSteamID)

    interact with the Steam (game overlay / desktop)

    Declaration
    public static bool IsClanChatWindowOpenInSteam(CSteamID steamIDClanChat)
    Parameters
    Type Name Description
    CSteamID steamIDClanChat

    Passed through to ISteamFriends::IsClanChatWindowOpenInSteam.

    Returns
    Type Description
    bool

    The value ISteamFriends::IsClanChatWindowOpenInSteam returns.

    IsClanOfficialGameGroup(CSteamID)

    Calls the Steamworks ISteamFriends::IsClanOfficialGameGroup method.

    Declaration
    public static bool IsClanOfficialGameGroup(CSteamID steamIDClan)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::IsClanOfficialGameGroup.

    Returns
    Type Description
    bool

    The value ISteamFriends::IsClanOfficialGameGroup returns.

    IsClanPublic(CSteamID)

    Calls the Steamworks ISteamFriends::IsClanPublic method.

    Declaration
    public static bool IsClanPublic(CSteamID steamIDClan)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::IsClanPublic.

    Returns
    Type Description
    bool

    The value ISteamFriends::IsClanPublic returns.

    IsFollowing(CSteamID)

    Calls the Steamworks ISteamFriends::IsFollowing method.

    Declaration
    public static SteamAPICall_t IsFollowing(CSteamID steamID)
    Parameters
    Type Name Description
    CSteamID steamID

    Passed through to ISteamFriends::IsFollowing.

    Returns
    Type Description
    SteamAPICall_t

    The value ISteamFriends::IsFollowing returns.

    IsFollowingAsync(CSteamID)

    Async version of IsFollowing(CSteamID).

    Declaration
    public static Task<FriendsIsFollowing_t> IsFollowingAsync(CSteamID steamID)
    Parameters
    Type Name Description
    CSteamID steamID

    Passed through to ISteamFriends::IsFollowing.

    Returns
    Type Description
    Task<FriendsIsFollowing_t>

    The FriendsIsFollowing_t Steam reports once the call completes.

    IsUserInSource(CSteamID, CSteamID)

    returns true if the local user can see that steamIDUser is a member or in steamIDSource

    Declaration
    public static bool IsUserInSource(CSteamID steamIDUser, CSteamID steamIDSource)
    Parameters
    Type Name Description
    CSteamID steamIDUser

    Passed through to ISteamFriends::IsUserInSource.

    CSteamID steamIDSource

    Passed through to ISteamFriends::IsUserInSource.

    Returns
    Type Description
    bool

    The value ISteamFriends::IsUserInSource returns.

    JoinClanChatRoom(CSteamID)

    chat interface for games this allows in-game access to group (clan) chats from in the game the behavior is somewhat sophisticated, because the user may or may not be already in the group chat from outside the game or in the overlay use ActivateGameOverlayToUser( "chat", steamIDClan ) to open the in-game overlay version of the chat

    Declaration
    public static SteamAPICall_t JoinClanChatRoom(CSteamID steamIDClan)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::JoinClanChatRoom.

    Returns
    Type Description
    SteamAPICall_t

    The value ISteamFriends::JoinClanChatRoom returns.

    JoinClanChatRoomAsync(CSteamID)

    Async version of JoinClanChatRoom(CSteamID).

    Declaration
    public static Task<JoinClanChatRoomCompletionResult_t> JoinClanChatRoomAsync(CSteamID steamIDClan)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::JoinClanChatRoom.

    Returns
    Type Description
    Task<JoinClanChatRoomCompletionResult_t>

    The JoinClanChatRoomCompletionResult_t Steam reports once the call completes.

    LeaveClanChatRoom(CSteamID)

    Calls the Steamworks ISteamFriends::LeaveClanChatRoom method.

    Declaration
    public static bool LeaveClanChatRoom(CSteamID steamIDClan)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::LeaveClanChatRoom.

    Returns
    Type Description
    bool

    The value ISteamFriends::LeaveClanChatRoom returns.

    OpenClanChatWindowInSteam(CSteamID)

    Calls the Steamworks ISteamFriends::OpenClanChatWindowInSteam method.

    Declaration
    public static bool OpenClanChatWindowInSteam(CSteamID steamIDClanChat)
    Parameters
    Type Name Description
    CSteamID steamIDClanChat

    Passed through to ISteamFriends::OpenClanChatWindowInSteam.

    Returns
    Type Description
    bool

    The value ISteamFriends::OpenClanChatWindowInSteam returns.

    RegisterProtocolInOverlayBrowser(string)

    Call this before calling ActivateGameOverlayToWebPage() to have the Steam Overlay Browser block navigations to your specified protocol (scheme) uris and instead dispatch a OverlayBrowserProtocolNavigation_t callback to your game. ActivateGameOverlayToWebPage() must have been called with k_EActivateGameOverlayToWebPageMode_Modal

    Declaration
    public static bool RegisterProtocolInOverlayBrowser(string pchProtocol)
    Parameters
    Type Name Description
    string pchProtocol

    Passed through to ISteamFriends::RegisterProtocolInOverlayBrowser.

    Returns
    Type Description
    bool

    The value ISteamFriends::RegisterProtocolInOverlayBrowser returns.

    ReplyToFriendMessage(CSteamID, string)

    Calls the Steamworks ISteamFriends::ReplyToFriendMessage method.

    Declaration
    public static bool ReplyToFriendMessage(CSteamID steamIDFriend, string pchMsgToSend)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::ReplyToFriendMessage.

    string pchMsgToSend

    Passed through to ISteamFriends::ReplyToFriendMessage.

    Returns
    Type Description
    bool

    The value ISteamFriends::ReplyToFriendMessage returns.

    RequestClanOfficerList(CSteamID)

    requests information about a clan officer list when complete, data is returned in ClanOfficerListResponse_t call result this makes available the calls below you can only ask about clans that a user is a member of note that this won't download avatars automatically; if you get an officer, and no avatar image is available, call RequestUserInformation( steamID, false ) to download the avatar

    Declaration
    public static SteamAPICall_t RequestClanOfficerList(CSteamID steamIDClan)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::RequestClanOfficerList.

    Returns
    Type Description
    SteamAPICall_t

    The value ISteamFriends::RequestClanOfficerList returns.

    RequestClanOfficerListAsync(CSteamID)

    Async version of RequestClanOfficerList(CSteamID).

    Declaration
    public static Task<ClanOfficerListResponse_t> RequestClanOfficerListAsync(CSteamID steamIDClan)
    Parameters
    Type Name Description
    CSteamID steamIDClan

    Passed through to ISteamFriends::RequestClanOfficerList.

    Returns
    Type Description
    Task<ClanOfficerListResponse_t>

    The ClanOfficerListResponse_t Steam reports once the call completes.

    RequestEquippedProfileItems(CSteamID)

    Steam Community items equipped by a user on their profile You can register for EquippedProfileItemsChanged_t to know when a friend has changed their equipped profile items

    Declaration
    public static SteamAPICall_t RequestEquippedProfileItems(CSteamID steamID)
    Parameters
    Type Name Description
    CSteamID steamID

    Passed through to ISteamFriends::RequestEquippedProfileItems.

    Returns
    Type Description
    SteamAPICall_t

    The value ISteamFriends::RequestEquippedProfileItems returns.

    RequestEquippedProfileItemsAsync(CSteamID)

    Async version of RequestEquippedProfileItems(CSteamID).

    Declaration
    public static Task<EquippedProfileItems_t> RequestEquippedProfileItemsAsync(CSteamID steamID)
    Parameters
    Type Name Description
    CSteamID steamID

    Passed through to ISteamFriends::RequestEquippedProfileItems.

    Returns
    Type Description
    Task<EquippedProfileItems_t>

    The EquippedProfileItems_t Steam reports once the call completes.

    RequestFriendRichPresence(CSteamID)

    Requests rich presence for a specific user.

    Declaration
    public static void RequestFriendRichPresence(CSteamID steamIDFriend)
    Parameters
    Type Name Description
    CSteamID steamIDFriend

    Passed through to ISteamFriends::RequestFriendRichPresence.

    RequestUserInformation(CSteamID, bool)

    requests information about a user - persona name & avatar if bRequireNameOnly is set, then the avatar of a user isn't downloaded

    • it's a lot slower to download avatars and churns the local cache, so if you don't need avatars, don't request them if returns true, it means that data is being requested, and a PersonaStateChange_t callback will be posted when it's retrieved if returns false, it means that we already have all the details about that user, and functions can be called immediately
    Declaration
    public static bool RequestUserInformation(CSteamID steamIDUser, bool bRequireNameOnly)
    Parameters
    Type Name Description
    CSteamID steamIDUser

    Passed through to ISteamFriends::RequestUserInformation.

    bool bRequireNameOnly

    Passed through to ISteamFriends::RequestUserInformation.

    Returns
    Type Description
    bool

    The value ISteamFriends::RequestUserInformation returns.

    SendClanChatMessage(CSteamID, string)

    Calls the Steamworks ISteamFriends::SendClanChatMessage method.

    Declaration
    public static bool SendClanChatMessage(CSteamID steamIDClanChat, string pchText)
    Parameters
    Type Name Description
    CSteamID steamIDClanChat

    Passed through to ISteamFriends::SendClanChatMessage.

    string pchText

    Passed through to ISteamFriends::SendClanChatMessage.

    Returns
    Type Description
    bool

    The value ISteamFriends::SendClanChatMessage returns.

    SetInGameVoiceSpeaking(CSteamID, bool)

    User is in a game pressing the talk button (will suppress the microphone for all voice comms from the Steam friends UI)

    Declaration
    public static void SetInGameVoiceSpeaking(CSteamID steamIDUser, bool bSpeaking)
    Parameters
    Type Name Description
    CSteamID steamIDUser

    Passed through to ISteamFriends::SetInGameVoiceSpeaking.

    bool bSpeaking

    Passed through to ISteamFriends::SetInGameVoiceSpeaking.

    SetListenForFriendsMessages(bool)

    peer-to-peer chat interception this is so you can show P2P chats inline in the game

    Declaration
    public static bool SetListenForFriendsMessages(bool bInterceptEnabled)
    Parameters
    Type Name Description
    bool bInterceptEnabled

    Passed through to ISteamFriends::SetListenForFriendsMessages.

    Returns
    Type Description
    bool

    The value ISteamFriends::SetListenForFriendsMessages returns.

    SetPlayedWith(CSteamID)

    Mark a target user as 'played with'. This is a client-side only feature that requires that the calling user is in game

    Declaration
    public static void SetPlayedWith(CSteamID steamIDUserPlayedWith)
    Parameters
    Type Name Description
    CSteamID steamIDUserPlayedWith

    Passed through to ISteamFriends::SetPlayedWith.

    SetRichPresence(string, string)

    Rich Presence data is automatically shared between friends who are in the same game Each user has a set of Key/Value pairs Note the following limits: k_cchMaxRichPresenceKeys, k_cchMaxRichPresenceKeyLength, k_cchMaxRichPresenceValueLength There are five magic keys: "status" - a UTF-8 string that will show up in the 'view game info' dialog in the Steam friends list "connect" - a UTF-8 string that contains the command-line for how a friend can connect to a game "steam_display" - Names a rich presence localization token that will be displayed in the viewing user's selected language in the Steam client UI. For more info: https://partner.steamgames.com/doc/api/ISteamFriends#richpresencelocalization "steam_player_group" - When set, indicates to the Steam client that the player is a member of a particular group. Players in the same group may be organized together in various places in the Steam UI. "steam_player_group_size" - When set, indicates the total number of players in the steam_player_group. The Steam client may use this number to display additional information about a group when all of the members are not part of a user's friends list. GetFriendRichPresence() returns an empty string "" if no value is set SetRichPresence() to a NULL or an empty string deletes the key You can iterate the current set of keys for a friend with GetFriendRichPresenceKeyCount() and GetFriendRichPresenceKeyByIndex() (typically only used for debugging)

    Declaration
    public static bool SetRichPresence(string pchKey, string pchValue)
    Parameters
    Type Name Description
    string pchKey

    Passed through to ISteamFriends::SetRichPresence.

    string pchValue

    Passed through to ISteamFriends::SetRichPresence.

    Returns
    Type Description
    bool

    The value ISteamFriends::SetRichPresence returns.

    In This Article
    Back to top
    Copyright © 2026 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)