Skip to main content
Version: 5.7.0

GetParentCurrency

Gets the parent player's currency for the given currency type or all currency types if null passed in.

ServiceOperation
virtualCurrencyGET_PARENT_VC

Method Parameters

ParameterDescription
vcIdThe currency type to retrieve or null if all currency types are being requested.
levelNameName of the parent level.

Usage

http://localhost:3000
string vcId = "coins";
string levelName = "master";
SuccessCallback successCallback = (response, cbObject) =>
{
Debug.Log(string.Format("Success | {0}", response));
};
FailureCallback failureCallback = (status, code, error, cbObject) =>
{
Debug.Log(string.Format("Failed | {0} {1} {2}", status, code, error));
};

_bc.VirtualCurrencyService.GetParentCurrency(vcId, levelName, successCallback, failureCallback);
JSON Response
{
"status":200,
"data":{
"currencyMap":{
"credits":{
"consumed":20,
"balance":180,
"purchased":0,
"awarded":200,
"revoked": 0
}
}
}
}