Always snap to grid

UE3:OnlinePlayerInterface functions (UT3)

From Unreal Wiki, The Unreal Engine Documentation Site
Revision as of 09:11, 17 May 2008 by Wormbo (Talk | contribs) (Auto-generated page)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
UT3 OnlinePlayerInterface (functions)

Contents

OnlinePlayerInterface functions in other games:
UDK

Functions[edit]

Instance functions[edit]

AcceptFriendInvite[edit]

function bool AcceptFriendInvite (byte LocalUserNum, OnlineSubsystem.UniqueNetId RequestingPlayer)

Used to accept a friend invite sent to this player

Parameters:

  • LocalUserNum - the user the invite is for
  • RequestingPlayer - the player the invite is from
  • true - if successful, false otherwise

AddAddFriendByNameCompleteDelegate[edit]

function AddAddFriendByNameCompleteDelegate (byte LocalUserNum, delegate<OnAddFriendByNameCompleteFriendDelegate)

Adds the delegate used to notify the gameplay code that the user has received a friend invite

Parameters:

  • LocalUserNum - the user associated with the notification
  • FriendDelegate - the delegate to use for notifications

AddFriend[edit]

function bool AddFriend (byte LocalUserNum, OnlineSubsystem.UniqueNetId NewFriend, optional string Message)

Sends a friend invite to the specified player

Parameters:

  • LocalUserNum - the user that is sending the invite
  • NewFriend - the player to send the friend request to
  • Message - the message to display to the recipient

Returns:

true if successful, false otherwise

AddFriendByName[edit]

function bool AddFriendByName (byte LocalUserNum, string FriendName, optional string Message)

Sends a friend invite to the specified player nick

Parameters:

  • LocalUserNum - the user that is sending the invite
  • FriendName - the name of the player to send the invite to
  • Message - the message to display to the recipient

Returns:

true if successful, false otherwise

AddFriendInviteReceivedDelegate[edit]

function AddFriendInviteReceivedDelegate (byte LocalUserNum, delegate<OnFriendInviteReceivedInviteDelegate)

Adds the delegate used to notify the gameplay code that the user has received a friend invite

Parameters:

  • LocalUserNum - the user associated with the notification
  • InviteDelegate - the delegate to use for notifications

AddFriendMessageReceivedDelegate[edit]

function AddFriendMessageReceivedDelegate (byte LocalUserNum, delegate<OnFriendMessageReceivedMessageDelegate)

Adds the delegate used to notify the gameplay code that the user has received a friend invite

Parameters:

  • LocalUserNum - the user associated with the notification
  • MessageDelegate - the delegate to use for notifications

AddFriendsChangeDelegate[edit]

function AddFriendsChangeDelegate (byte LocalUserNum, delegate<OnFriendsChangeFriendsDelegate)

Sets the delegate used to notify the gameplay code that a friends list changed

Parameters:

  • LocalUserNum - the user to read the friends list of
  • FriendsDelegate - the delegate to use for notifications

AddJoinFriendGameCompleteDelegate[edit]

function AddJoinFriendGameCompleteDelegate (delegate<OnJoinFriendGameCompleteJoinFriendGameCompleteDelegate)

Sets the delegate used to notify when the join friend is complete

Parameters:

  • JoinFriendGameCompleteDelegate - the delegate to use for notifications

AddKeyboardInputDoneDelegate[edit]

function AddKeyboardInputDoneDelegate (delegate<OnKeyboardInputCompleteInputDelegate)

Adds the delegate used to notify the gameplay code that the user has completed their keyboard input

Parameters:

  • InputDelegate - the delegate to use for notifications

AddLoginCancelledDelegate[edit]

function AddLoginCancelledDelegate (delegate<OnLoginCancelledCancelledDelegate)

Adds a delegate to the list of delegates that are fired when a login is cancelled

Parameters:

  • CancelledDelegate - the delegate to add to the list

AddLoginChangeDelegate[edit]

function AddLoginChangeDelegate (delegate<OnLoginChangeLoginDelegate, optional byte LocalUserNum)

Sets the delegate used to notify the gameplay code that a login changed

Parameters:

  • LoginDelegate - the delegate to use for notifications
  • LocalUserNum - whether to watch for changes on a specific slot or all slots

AddLoginFailedDelegate[edit]

function AddLoginFailedDelegate (byte LocalUserNum, delegate<OnLoginFailedLoginDelegate)

Sets the delegate used to notify the gameplay code that a login failed

Parameters:

  • LocalUserNum - the controller number of the associated user
  • LoginDelegate - the delegate to use for notifications

AddLogoutCompletedDelegate[edit]

function AddLogoutCompletedDelegate (byte LocalUserNum, delegate<OnLogoutCompletedLogoutDelegate)

Sets the delegate used to notify the gameplay code that a logout completed

Parameters:

  • LocalUserNum - the controller number of the associated user
  • LogoutDelegate - the delegate to use for notifications

AddMutingChangeDelegate[edit]

function AddMutingChangeDelegate (delegate<OnMutingChangeMutingDelegate)

Sets the delegate used to notify the gameplay code that a muting list changed

Parameters:

  • MutingDelegate - the delegate to use for notifications

AddReadFriendsCompleteDelegate[edit]

function AddReadFriendsCompleteDelegate (byte LocalUserNum, delegate<OnReadFriendsCompleteReadFriendsCompleteDelegate)

Sets the delegate used to notify the gameplay code that the friends read request has completed

Parameters:

  • LocalUserNum - the user to read the friends list of
  • ReadFriendsCompleteDelegate - the delegate to use for notifications

AddReadProfileSettingsCompleteDelegate[edit]

function AddReadProfileSettingsCompleteDelegate (byte LocalUserNum, delegate<OnReadProfileSettingsCompleteReadProfileSettingsCompleteDelegate)

Sets the delegate used to notify the gameplay code that the last read request has completed

Parameters:

  • LocalUserNum - which user to watch for read complete notifications
  • ReadProfileSettingsCompleteDelegate - the delegate to use for notifications

AddReceivedGameInviteDelegate[edit]

function AddReceivedGameInviteDelegate (byte LocalUserNum, delegate<OnReceivedGameInviteReceivedGameInviteDelegate)

Adds the delegate used to notify the gameplay code that the user has received a game invite

Parameters:

  • LocalUserNum - the user associated with the notification
  • ReceivedGameInviteDelegate - the delegate to use for notifications

AddWriteProfileSettingsCompleteDelegate[edit]

function AddWriteProfileSettingsCompleteDelegate (byte LocalUserNum, delegate<OnWriteProfileSettingsCompleteWriteProfileSettingsCompleteDelegate)

Sets the delegate used to notify the gameplay code that the last write request has completed

Parameters:

  • LocalUserNum - which user to watch for write complete notifications
  • WriteProfileSettingsCompleteDelegate - the delegate to use for notifications

AreAnyFriends[edit]

function bool AreAnyFriends (byte LocalUserNum, out array<OnlineSubsystem.FriendsQueryQuery)

Checks that whether a group of player ids are among the specified player's friends

Parameters:

  • LocalUserNum - the controller number of the associated user
  • Query - an array of players to check for being included on the friends list

Returns:

TRUE if the call succeeded, FALSE otherwise

AutoLogin[edit]

function bool AutoLogin ()

Logs the player into the online service using parameters passed on the command line. Expects -Login=<UserName> -Password=<password>. If either are missing, the function returns false and doesn't start the login process

Returns:

true if the async call started ok, false otherwise

CanCommunicate[edit]

function OnlineSubsystem.EFeaturePrivilegeLevel CanCommunicate (byte LocalUserNum)

Determines whether the player is allowed to use voice or text chat online

Parameters:

  • LocalUserNum - the controller number of the associated user

Returns:

the Privilege level that is enabled

CanDownloadUserContent[edit]

function OnlineSubsystem.EFeaturePrivilegeLevel CanDownloadUserContent (byte LocalUserNum)

Determines whether the player is allowed to download user created content

Parameters:

  • LocalUserNum - the controller number of the associated user

Returns:

the Privilege level that is enabled

CanPlayOnline[edit]

function OnlineSubsystem.EFeaturePrivilegeLevel CanPlayOnline (byte LocalUserNum)

Determines whether the player is allowed to play online

Parameters:

  • LocalUserNum - the controller number of the associated user

Returns:

the Privilege level that is enabled

CanPurchaseContent[edit]

function OnlineSubsystem.EFeaturePrivilegeLevel CanPurchaseContent (byte LocalUserNum)

Determines whether the player is allowed to buy content online

Parameters:

  • LocalUserNum - the controller number of the associated user

Returns:

the Privilege level that is enabled

CanShowPresenceInformation[edit]

function OnlineSubsystem.EFeaturePrivilegeLevel CanShowPresenceInformation (byte LocalUserNum)

Determines whether the player is allowed to have their online presence information shown to remote clients

Parameters:

  • LocalUserNum - the controller number of the associated user

Returns:

the Privilege level that is enabled

CanViewPlayerProfiles[edit]

function OnlineSubsystem.EFeaturePrivilegeLevel CanViewPlayerProfiles (byte LocalUserNum)

Determines whether the player is allowed to view other people's player profile

Parameters:

  • LocalUserNum - the controller number of the associated user

Returns:

the Privilege level that is enabled

ClearAddFriendByNameCompleteDelegate[edit]

function ClearAddFriendByNameCompleteDelegate (byte LocalUserNum, delegate<OnAddFriendByNameCompleteFriendDelegate)

Removes the delegate specified from the list

Parameters:

  • LocalUserNum - the user associated with the notification
  • FriendDelegate - the delegate to use for notifications

ClearFriendInviteReceivedDelegate[edit]

function ClearFriendInviteReceivedDelegate (byte LocalUserNum, delegate<OnFriendInviteReceivedInviteDelegate)

Removes the delegate specified from the list

Parameters:

  • LocalUserNum - the user associated with the notification
  • InviteDelegate - the delegate to use for notifications

ClearFriendMessageReceivedDelegate[edit]

function ClearFriendMessageReceivedDelegate (byte LocalUserNum, delegate<OnFriendMessageReceivedMessageDelegate)

Removes the delegate specified from the list

Parameters:

  • LocalUserNum - the user associated with the notification
  • MessageDelegate - the delegate to use for notifications

ClearFriendsChangeDelegate[edit]

function ClearFriendsChangeDelegate (byte LocalUserNum, delegate<OnFriendsChangeFriendsDelegate)

Sets the delegate used to notify the gameplay code that a friends list changed

Parameters:

  • LocalUserNum - the user to read the friends list of
  • FriendsDelegate - the delegate to use for notifications

ClearJoinFriendGameCompleteDelegate[edit]

function ClearJoinFriendGameCompleteDelegate (delegate<OnJoinFriendGameCompleteJoinFriendGameCompleteDelegate)

Removes the delegate from the list of notifications

Parameters:

  • JoinFriendGameCompleteDelegate - the delegate to use for notifications

ClearKeyboardInputDoneDelegate[edit]

function ClearKeyboardInputDoneDelegate (delegate<OnKeyboardInputCompleteInputDelegate)

Clears the delegate used to notify the gameplay code that the user has completed their keyboard input

Parameters:

  • InputDelegate - the delegate to use for notifications

ClearLoginCancelledDelegate[edit]

function ClearLoginCancelledDelegate (delegate<OnLoginCancelledCancelledDelegate)

Removes the specified delegate from the notification list

Parameters:

  • CancelledDelegate - the delegate to remove fromt he list

ClearLoginChangeDelegate[edit]

function ClearLoginChangeDelegate (delegate<OnLoginChangeLoginDelegate, optional byte LocalUserNum)

Removes the specified delegate from the notification list

Parameters:

  • LoginDelegate - the delegate to use for notifications
  • LocalUserNum - whether to watch for changes on a specific slot or all slots

ClearLoginFailedDelegate[edit]

function ClearLoginFailedDelegate (byte LocalUserNum, delegate<OnLoginFailedLoginDelegate)

Removes the specified delegate from the notification list

Parameters:

  • LocalUserNum - the controller number of the associated user
  • LoginDelegate - the delegate to use for notifications

ClearLogoutCompletedDelegate[edit]

function ClearLogoutCompletedDelegate (byte LocalUserNum, delegate<OnLogoutCompletedLogoutDelegate)

Removes the specified delegate from the notification list

Parameters:

  • LocalUserNum - the controller number of the associated user
  • LogoutDelegate - the delegate to use for notifications

ClearMutingChangeDelegate[edit]

function ClearMutingChangeDelegate (delegate<OnMutingChangeMutingDelegate)

Clears the delegate used to notify the gameplay code that a muting list changed

Parameters:

  • MutingDelegate - the delegate to use for notifications

ClearReadFriendsCompleteDelegate[edit]

function ClearReadFriendsCompleteDelegate (byte LocalUserNum, delegate<OnReadFriendsCompleteReadFriendsCompleteDelegate)

Clears the delegate used to notify the gameplay code that the friends read request has completed

Parameters:

  • LocalUserNum - the user to read the friends list of
  • ReadFriendsCompleteDelegate - the delegate to use for notifications

ClearReadProfileSettingsCompleteDelegate[edit]

function ClearReadProfileSettingsCompleteDelegate (byte LocalUserNum, delegate<OnReadProfileSettingsCompleteReadProfileSettingsCompleteDelegate)

Searches the existing set of delegates for the one specified and removes it from the list

Parameters:

  • LocalUserNum - which user to watch for read complete notifications
  • ReadProfileSettingsCompleteDelegate - the delegate to find and clear

ClearReceivedGameInviteDelegate[edit]

function ClearReceivedGameInviteDelegate (byte LocalUserNum, delegate<OnReceivedGameInviteReceivedGameInviteDelegate)

Removes the delegate specified from the list

Parameters:

  • LocalUserNum - the user associated with the notification
  • ReceivedGameInviteDelegate - the delegate to use for notifications

ClearWriteProfileSettingsCompleteDelegate[edit]

function ClearWriteProfileSettingsCompleteDelegate (byte LocalUserNum, delegate<OnWriteProfileSettingsCompleteWriteProfileSettingsCompleteDelegate)

Clears the delegate used to notify the gameplay code that the last write request has completed

Parameters:

  • LocalUserNum - which user to watch for write complete notifications
  • WriteProfileSettingsCompleteDelegate - the delegate to use for notifications

DeleteMessage[edit]

function bool DeleteMessage (byte LocalUserNum, int MessageIndex)

Deletes a message from the list of messages

Parameters:

  • LocalUserNum - the user that is deleting the message
  • MessageIndex - the index of the message to delete

Returns:

true if the message was deleted, false otherwise

DenyFriendInvite[edit]

function bool DenyFriendInvite (byte LocalUserNum, OnlineSubsystem.UniqueNetId RequestingPlayer)

Used to deny a friend request sent to this player

Parameters:

  • LocalUserNum - the user the invite is for
  • RequestingPlayer - the player the invite is from
  • true - if successful, false otherwise

GetFriendMessages[edit]

function GetFriendMessages (byte LocalUserNum, out array<OnlineSubsystem.OnlineFriendMessageFriendMessages)

Returns the list of messages for the specified player

Parameters:

  • LocalUserNum - the local player wanting to join
  • FriendMessages - the set of messages cached locally for the player

GetFriendsList[edit]

function OnlineSubsystem.EOnlineEnumerationReadState GetFriendsList (byte LocalUserNum, out array<OnlineSubsystem.OnlineFriendFriends, optional int Count, optional int StartingAt)

Copies the list of friends for the player previously retrieved from the online service. The list can be retrieved in whole or in part.

Parameters:

  • LocalUserNum - the user to read the friends list of
  • Friends - the out array that receives the copied data
  • Count - the number of friends to read or zero for all
  • StartingAt - the index of the friends list to start at (for pulling partial lists)

Returns:

OERS_Done if the read has completed, otherwise one of the other states

GetKeyboardInputResults[edit]

function string GetKeyboardInputResults (out byte bWasCanceled)

Fetches the results of the input

Parameters:

  • bWasCanceled - whether the user cancelled the input or not

Returns:

the string entered by the user. Note the string will be empty if it fails validation

GetLoginStatus[edit]

function OnlineSubsystem.ELoginStatus GetLoginStatus (byte LocalUserNum)

Fetches the login status for a given player

Parameters:

  • LocalUserNum - the controller number of the associated user

Returns:

the enum value of their status

GetPlayerNickname[edit]

function string GetPlayerNickname (byte LocalUserNum)

Reads the player's nick name from the online service

Parameters:

  • LocalUserNum - the controller number of the associated user

Returns:

a string containing the players nick name

GetProfileSettings[edit]

function OnlineProfileSettings GetProfileSettings (byte LocalUserNum)

Returns the online profile settings for a given user

Parameters:

  • LocalUserNum - the user that we are reading the data for

Returns:

the profile settings object

GetUniquePlayerId[edit]

function bool GetUniquePlayerId (byte LocalUserNum, out OnlineSubsystem.UniqueNetId PlayerId)

Gets the platform specific unique id for the specified player

Parameters:

  • LocalUserNum - the controller number of the associated user
  • PlayerId - the byte array that will receive the id

Returns:

TRUE if the call succeeded, FALSE otherwise

IsFriend[edit]

function bool IsFriend (byte LocalUserNum, OnlineSubsystem.UniqueNetId PlayerId)

Checks that a unique player id is part of the specified user's friends list

Parameters:

  • LocalUserNum - the controller number of the associated user
  • PlayerId - the id of the player being checked

Returns:

TRUE if a member of their friends list, FALSE otherwise

IsMuted[edit]

function bool IsMuted (byte LocalUserNum, OnlineSubsystem.UniqueNetId PlayerId)

Checks that a unique player id is on the specified user's mute list

Parameters:

  • LocalUserNum - the controller number of the associated user
  • PlayerId - the id of the player being checked

Returns:

TRUE if the player should be muted, FALSE otherwise

JoinFriendGame[edit]

function bool JoinFriendGame (byte LocalUserNum, OnlineSubsystem.UniqueNetId Friend)

Allows the local player to follow a friend into a game

Parameters:

  • LocalUserNum - the local player wanting to join
  • Friend - the player that is being followed

Returns:

true if the async call worked, false otherwise

Login[edit]

function bool Login (byte LocalUserNum, string LoginName, string Password, optional bool bWantsLocalOnly)

Logs the player into the online service. If this fails, it generates a OnLoginFailed notification

Parameters:

  • LocalUserNum - the controller number of the associated user
  • LoginName - the unique identifier for the player
  • Password - the password for this account
  • bWantsLocalOnly - whether the player wants to sign in locally only or not

Returns:

true if the async call started ok, false otherwise

Logout[edit]

function bool Logout (byte LocalUserNum)

Signs the player out of the online service

Parameters:

  • LocalUserNum - the controller number of the associated user

Returns:

TRUE if the call succeeded, FALSE otherwise

ReadFriendsList[edit]

function bool ReadFriendsList (byte LocalUserNum, optional int Count, optional int StartingAt)

Starts an async task that retrieves the list of friends for the player from the online service. The list can be retrieved in whole or in part.

Parameters:

  • LocalUserNum - the user to read the friends list of
  • Count - the number of friends to read or zero for all
  • StartingAt - the index of the friends list to start at (for pulling partial lists)

Returns:

true if the read request was issued successfully, false otherwise

ReadProfileSettings[edit]

function bool ReadProfileSettings (byte LocalUserNum, OnlineProfileSettings ProfileSettings)

Reads the online profile settings for a given user

Parameters:

  • LocalUserNum - the user that we are reading the data for
  • ProfileSettings - the object to copy the results to and contains the list of items to read

Returns:

true if the call succeeds, false otherwise

RemoveFriend[edit]

function bool RemoveFriend (byte LocalUserNum, OnlineSubsystem.UniqueNetId FormerFriend)

Removes a friend from the player's friend list

Parameters:

  • LocalUserNum - the user that is removing the friend
  • FormerFriend - the player to remove from the friend list

Returns:

true if successful, false otherwise

SendGameInviteToFriend[edit]

function bool SendGameInviteToFriend (byte LocalUserNum, OnlineSubsystem.UniqueNetId Friend, optional string Text)

Sends an invitation to play in the player's current session

Parameters:

  • LocalUserNum - the user that is sending the invite
  • Friend - the player to send the invite to
  • Text - the text of the message for the invite

Returns:

true if successful, false otherwise

SendGameInviteToFriends[edit]

function bool SendGameInviteToFriends (byte LocalUserNum, array<OnlineSubsystem.UniqueNetIdFriends, optional string Text)

Sends invitations to play in the player's current session

Parameters:

  • LocalUserNum - the user that is sending the invite
  • Friends - the player to send the invite to
  • Text - the text of the message for the invite

Returns:

true if successful, false otherwise

SendMessageToFriend[edit]

function bool SendMessageToFriend (byte LocalUserNum, OnlineSubsystem.UniqueNetId Friend, string Message)

Sends a message to a friend

Parameters:

  • LocalUserNum - the user that is sending the message
  • Friend - the player to send the message to
  • Message - the message to display to the recipient

Returns:

true if successful, false otherwise

SetOnlineStatus[edit]

function SetOnlineStatus (byte LocalUserNum, int StatusId, const out array<Settings.LocalizedStringSettingLocalizedStringSettings, const out array<Settings.SettingsPropertyProperties)

Sets the online status information to use for the specified player. Used to tell other players what the player is doing (playing, menus, away, etc.)

Parameters:

  • LocalUserNum - the controller number of the associated user
  • StatusId - the status id to use (maps to strings where possible)
  • LocalizedStringSettings - the list of localized string settings to set
  • Properties - the list of properties to set

ShowFriendsUI[edit]

function bool ShowFriendsUI (byte LocalUserNum)

Displays the UI that shows a user's list of friends

Parameters:

  • LocalUserNum - the controller number of the associated user

Returns:

TRUE if it was able to show the UI, FALSE if it failed

ShowKeyboardUI[edit]

function bool ShowKeyboardUI (byte LocalUserNum, string TitleText, string DescriptionText, optional bool bIsPassword, optional bool bShouldValidate, optional string DefaultText, optional int MaxResultLength)

Displays the UI that shows the keyboard for inputing text

Parameters:

  • LocalUserNum - the controller number of the associated user
  • TitleText - the title to display to the user
  • DescriptionText - the text telling the user what to input
  • bIsPassword - whether the item being entered is a password or not
  • bShouldValidate - whether to apply the string validation API after input or not
  • DefaultText - the default string to display
  • MaxResultLength - the maximum length string expected to be filled in

Returns:

TRUE if it was able to show the UI, FALSE if it failed

ShowLoginUI[edit]

function bool ShowLoginUI (optional bool bShowOnlineOnly)

Displays the UI that prompts the user for their login credentials. Each platform handles the authentication of the user's data.

Parameters:

  • bShowOnlineOnly - whether to only display online enabled profiles or not

Returns:

TRUE if it was able to show the UI, FALSE if it failed

WriteProfileSettings[edit]

function bool WriteProfileSettings (byte LocalUserNum, OnlineProfileSettings ProfileSettings)

Writes the online profile settings for a given user to the online data store

Parameters:

  • LocalUserNum - the user that we are writing the data for
  • ProfileSettings - the list of settings to write out

Returns:

true if the call succeeds, false otherwise