Doloro GDK 22 .1.0 Beta
by Tauri Interactive
Doloro.InvetorySystem.Storage Class Reference

Detailed Description

Implements conception of the in-game storage.

Inheritance diagram for Doloro.InvetorySystem.Storage:
Collaboration diagram for Doloro.InvetorySystem.Storage:

Public Member Functions

delegate void StorageDelegate (Storage storage)
 Delegate using in storage related events. More...
 
bool SaveItemState (string bundle, string key)
 Saves item session data to the storage container. More...
 
void SaveFeatureState (AStorageFeature source)
 Saves feature's cross-session data to the database. More...
 
void LoadFeatureState (AStorageFeature destination)
 Loads feature's cross-session data from the database. More...
 
void Dispose ()
 Releases entire on-scene temporal resources.
 

Protected Member Functions

virtual void Awake ()
 Occurs when instance created in the world.
 
virtual void OnDestroy ()
 Release instance from external events.
 
virtual void OnDestory ()
 Overs the rent.
 
virtual void OnRentOver ()
 Occurs each time when source changed for entity that had been renting.
 
virtual void OnRentStarted ()
 Occurs each time when source changed for entity that has been renting.
 
virtual void Dispose (bool disposing)
 

Properties

StoragesDatabase.StorageContainer source [get, set]
 Source database entry binded to the storage.
 
IEnumerable< FeatureType > features [get]
 Collection of features applied to the resource instance.
 

Events

static StorageDelegate NewStorage
 Occurs when new storage instantiate at the world.
 
StorageDelegate RentStarted
 Occurs after OnRentStarted execution.
 
StorageDelegate RentOver
 Occurs after OnRentOver execution.
 

Member Function Documentation

◆ LoadFeatureState()

void Doloro.InvetorySystem.Storage.LoadFeatureState ( AStorageFeature  destination)

Loads feature's cross-session data from the database.

Parameters
destinationDestination feature instance to data restore.

◆ SaveFeatureState()

void Doloro.InvetorySystem.Storage.SaveFeatureState ( AStorageFeature  source)

Saves feature's cross-session data to the database.

Parameters
sourceProperty to save.

◆ SaveItemState()

bool Doloro.InvetorySystem.Storage.SaveItemState ( string  bundle,
string  key 
)

Saves item session data to the storage container.

Parameters
bundleTarget item resource bundle to search.
keyTarget item resource key in the bundler to search.
Returns
Is the container related to the resource has been found in the storage.

◆ StorageDelegate()

delegate void Doloro.InvetorySystem.Storage.StorageDelegate ( Storage  storage)

Delegate using in storage related events.

Parameters
storageTarget storage instance.

The documentation for this class was generated from the following file: