Skip to main content

Query Multi Data

Queries the player's own data.

Call Information

public void MultiPlayerDataLoad (MultiLoadParam storageKeys, PlayNANOODelegate callback) {}

Call Information Details

ParameterDescriptionType
storageKeysPlayer data listMultiLoadParam
callbackCommunication resultPlayNANOODelegate

Source Code

using PlayNANOO;

public class PlayNANOOExample : MonoBehaviour
{
Plugin plugin;

void Awake()
{
plugin = Plugin.GetInstance();

PlayNANOO.Storage.MultiLoadParam multiLoadParam = new PlayNANOO.Storage.MultiLoadParam();
multiLoadParam.Items.Add(new PlayNANOO.Storage.MultiLoadParamValue { StorageKey = "STORAGE_KEY_1" });
multiLoadParam.Items.Add(new PlayNANOO.Storage.MultiLoadParamValue { StorageKey = "STORAGE_KEY_2" });

plugin.Storage.MultiLoad(multiLoadParam, (status, error, jsonString, values) => {
if (status.Equals(Configure.PN_API_STATE_SUCCESS))
{
foreach (Dictionary<string, object> value in (ArrayList)values["Items"])
{
Debug.Log(value["PlayerId"]);
Debug.Log(value["StorageKey"]);
Debug.Log(value["StorageValue"]);
}
}
else
{
Debug.Log("Fail");
}
});
}
}

Communication Result

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
{
"Items" : [
{
"PlayerId" : "String",
"StorageKey" : "String",
"StorageValue" : "String"
}
]
}

Result Information Details

Data KeyDescriptionType
Items.PlayerIdPlayer IDstring
Items.StorageKeyStorage data keystring
Items.StorageValueStorage data informationstring