Interface IUserSavedData
ISavedData for the Player/User not related to any IEntity. This can be used to store all player preference in the future.
Inherited Members
Namespace: IdleKit.Framework
Assembly: cs.temp.dll.dll
Syntax
public interface IUserSavedData : ISavedData, IInjectable
Properties
contentInstanceId
The instanceId of the currently active IContent. This can be used to identify persistent data across the various IContent it appears in.
Declaration
string contentInstanceId { get; set; }
Property Value
Type | Description |
---|---|
String |
isNew
Returns true if this is a new player. useful for showing intros, tutorials and other similar content
Declaration
bool isNew { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
Methods
GetLastActivityTime()
Get the timestamp of the last user activity in the current IContent specified by contentInstanceId. Each IContent has its own last user activity timestamp.
Declaration
long GetLastActivityTime()
Returns
Type | Description |
---|---|
Int64 | Return the last activity timestamp, 0 if not found. |
SetLastActivityTime(Int64)
Set the timestamp of the last user activity in the current IContent specified by contentInstanceId. Each IContent has its own last user activity timestamp.
This function does not set any timestamp if contentInstanceId is null or empty.
Declaration
void SetLastActivityTime(long timestamp)
Parameters
Type | Name | Description |
---|---|---|
Int64 | timestamp |