I search for solutions in this order: Past Code, Unreal Source, Wiki, BUF, groups.yahoo, google, screaming at monitor. – RegularX

Difference between revisions of "UE3:UIDataProvider OnlinePlayerStorage (UDK)"

From Unreal Wiki, The Unreal Engine Documentation Site
Jump to: navigation, search
(Talk)
m (1 revision: class descriptions for UDK January update (part 6))
 
(No difference)

Latest revision as of 06:50, 17 January 2010

UDK Object >> UIRoot >> UIDataProvider >> UIDataProvider_OnlinePlayerDataBase >> UIDataProvider_OnlinePlayerStorage
Package: 
Engine
Direct subclass:
UIDataProvider_OnlineProfileSettings

This class is responsible for mapping properties in an OnlineGameSettings object to something that the UI system can consume.

Properties[edit]

bWasErrorLastRead[edit]

Type: bool

If there was an error, it was possible the read was already in progress. This indicates to re-read upon a good completion

PlayerStorageArrayProviders[edit]

Type: array<PlayerStorageArrayProvider>

The list of mappings from settings id to their provider

Profile[edit]

Type: OnlinePlayerStorage

The storage settings that are used to load/save with the online subsystem

ProviderName[edit]

Type: name

Modifiers: const

For displaying in the provider tree

Default value: 'PlayerStorageData'

Default values[edit]

Property Value
WriteAccessType ACCESS_WriteAll

Structs[edit]

PlayerStorageArrayProvider[edit]

Modifiers: native

Keeps a list of providers for each storage settings id

int PlayerStorageId 
The storage settings id that this provider is for
name PlayerStorageName 
Cached to avoid extra look ups
UIDataProvider_OnlinePlayerStorageArray Provider 
The provider object to expose the data with

Functions[edit]

Events[edit]

OnRegister[edit]

event OnRegister (LocalPlayer InPlayer)

Overrides: UIDataProvider_OnlinePlayerDataBase.OnRegister

Binds the player to this provider. Starts the async friends list gathering

Parameters:

  • InPlayer - the player that we are retrieving friends for

OnUnregister[edit]

event OnUnregister ()

Overrides: UIDataProvider_OnlinePlayerDataBase.OnUnregister

Clears our delegate for getting login change notifications

SaveStorageData[edit]

event bool SaveStorageData ()

Writes the storage data to the online subsystem for this user

Other instance functions[edit]

AddReadCompleteDelegate[edit]

function AddReadCompleteDelegate (OnlinePlayerInterface PlayerInterface, byte LocalUserNum)

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

Parameters:

  • PlayerInterface - is the OnlinePlayerInterface used
  • LocalUserNum - which user to watch for read complete notifications

ArrayProviderPropertyChanged[edit]

function ArrayProviderPropertyChanged (UIDataProvider SourceProvider, optional name PropTag)

Called when a setting or property which is bound to one of our array providers is updated.

Parameters:

  • SourceProvider - the data provider that generated the notification
  • PropTag - the property that changed

ClearReadCompleteDelegate[edit]

function ClearReadCompleteDelegate (OnlinePlayerInterface PlayerInterface, byte LocalUserNum)

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

Parameters:

  • PlayerInterface - is the OnlinePlayerInterface used
  • LocalUserNum - which user to stop watching for read complete notifications

OnLoginChange[edit]

function OnLoginChange (byte LocalUserNum)

Executes a refetching of the storage data when the login for this player changes

Parameters:

  • LocalUserNum - the player that logged in/out

OnReadStorageComplete[edit]

function OnReadStorageComplete (byte LocalUserNum, bool bWasSuccessful)

Handles the notification that the async read of the storage data is done

Parameters:

  • bWasSuccessful - whether the call succeeded or not

OnSettingValueUpdated[edit]

function OnSettingValueUpdated (name SettingName)

Handler for the OnDataProviderPropertyChange delegate in our internal array providers. Determines which provider sent the update and propagates that update to this provider's own list of listeners.

Parameters:

  • SettingName - the name of the setting that was changed.

ReadData[edit]

function bool ReadData (OnlinePlayerInterface PlayerInterface, byte LocalUserNum, OnlinePlayerStorage PlayerStorage)

Reads the data

Parameters:

  • PlayerInterface - is the OnlinePlayerInterface used
  • LocalUserNum - the user that we are reading the data for
  • PlayerStorage - the object to copy the results to and contains the list of items to read

Returns:

true if the call succeeds, false otherwise

RefreshStorageData[edit]

function RefreshStorageData ()

Reads this user's storage data from the online subsystem.

WriteData[edit]

function bool WriteData (OnlinePlayerInterface PlayerInterface, byte LocalUserNum, OnlinePlayerStorage PlayerStorage)

Writes the online data for a given local user to the online data store

Parameters:

  • PlayerInterface - is the OnlinePlayerInterface used
  • LocalUserNum - the user that we are writing the data for
  • PlayerStorage - the object that contains the list of items to write

Returns:

true if the call succeeds, false otherwise