![]() |
GameDB
1.6.0
GameDB Pro is a plugin that provides an easy to use and powerful game and meta data editor
|
The base class all GameDBs inherit from. The GameDB provides methods for importing data. More...
Public Member Functions | |
Exception | Import (string jsonData, bool notify=true) |
Imports JSON representing the GameDB. More... | |
Exception | Import (string jsonData, string[] columImportList, bool notify=true) |
Imports JSON representing the GameDB. Allows specifying only certain fields to be imported. Useful for limiting the memory used of the loaded GameDB. More... | |
RequestUpdater | ImportFromServer (string serverHost, string downloadHost, string userID, string tag, string originalJSON, string cachePath, bool binary, string key, string salt, string[] columImportList=null, Action< Exception > onImport=null) |
(Pro Version only) Imports the GameDB from a server. Can be used in conjuction with the Golang server provided in the (Pro version) This allows over the air updating of GameDBs so new data can be pushed to clients without the need of releasing new versions of the clients. Downloaded GameDBs will be cached locally to avoid downloading again if they haven't changed. If they have change, only the diff between the original built-in GameDB and the uploaded GameDB will be downloaded. More... | |
Public Attributes | |
Action | OnDBLoaded = null |
OnDBLoaded allows callbacks to be added that are triggered if notify = true when importing or loading data. This allows code to deal with data potentially beind asynchronously loaded (when imported from a server) or hot reloaded via an Import or Reload from the GameDB Editor during run-time in editor. More... | |
string | Name => m_internal.Name |
Gets the name of the GameDB set when instantiating. More... | |
Properties | |
string | ScopeName = string.Empty [get] |
Gets the ScopeName of the GameDB set when creating it in the GameDB Editor. More... | |
Logger | Logger [get, set] |
Gets or sets the logger used for internal logs. More... | |
The base class all GameDBs inherit from. The GameDB provides methods for importing data.
Exception GameDBLibrary.GameDBBase.Import | ( | string | jsonData, |
bool | notify = true |
||
) |
Imports JSON representing the GameDB.
jsonData | A string representing the JSON format of the GameDB to import. |
notify | if set to true the OnDBLoaded callback will be triggered for the GameDB (defaults to true ). |
Exception GameDBLibrary.GameDBBase.Import | ( | string | jsonData, |
string [] | columImportList, | ||
bool | notify = true |
||
) |
Imports JSON representing the GameDB. Allows specifying only certain fields to be imported. Useful for limiting the memory used of the loaded GameDB.
jsonData | A string representing the JSON format of the GameDB to import. |
columImportList | An array of field names to import. |
notify | if set to true the OnDBLoaded callback will be triggered for the GameDB (defaults to true ). |
RequestUpdater GameDBLibrary.GameDBBase.ImportFromServer | ( | string | serverHost, |
string | downloadHost, | ||
string | userID, | ||
string | tag, | ||
string | originalJSON, | ||
string | cachePath, | ||
bool | binary, | ||
string | key, | ||
string | salt, | ||
string [] | columImportList = null , |
||
Action< Exception > | onImport = null |
||
) |
(Pro Version only)
Imports the GameDB from a server. Can be used in conjuction with the Golang server provided in the (Pro version) This allows over the air updating of GameDBs so new data can be pushed to clients without the need of releasing new versions of the clients. Downloaded GameDBs will be cached locally to avoid downloading again if they haven't changed. If they have change, only the diff between the original built-in GameDB and the uploaded GameDB will be downloaded.
serverHost | The server host base address of the GameDB server to communicate with. For example: https://mygamedbserver.com |
downloadHost | The download host base address of the GameDB to download. For example https://s3.aws.com/mygamedb |
userID | A unique identified used to represent the client downloading the GameDB. Can be used for A/B testing GameDB versions |
tag | The tag used to download the correct version of the GameDB |
originalJSON | The original json the update is based off. This will be imported if there are no cached version or anything to download from the server |
cachePath | The path to cache downloaded GameDBs too |
binary | if set to true the GameDB will be loaded as a binary source (defaults to false ) (key and salt required if loading binary) |
key | the key used to encrypt the database via the GameDBLibrary.BinaryGameDB utilities. Required if using binary = true |
salt | the salt used to encrypt the database via the GameDBLibrary.BinaryGameDB utilities. Required if using binary = true |
columImportList | An array of field names to import. |
onImport | A callback called when the data has be imported. |
string GameDBLibrary.GameDBBase.Name => m_internal.Name |
Gets the name of the GameDB set when instantiating.
The name of the GameDB.
Action GameDBLibrary.GameDBBase.OnDBLoaded = null |
OnDBLoaded allows callbacks to be added that are triggered if notify = true
when importing or loading data. This allows code to deal with data potentially beind asynchronously loaded (when imported from a server) or hot reloaded via an Import or Reload from the GameDB Editor during run-time in editor.
|
getset |
Gets or sets the logger used for internal logs.
The logger.
|
get |
Gets the ScopeName of the GameDB set when creating it in the GameDB Editor.
The ScopeName