Hi,
So I have a cloud script with this function:
handlers.SelectEvent=function SelectEvent(args, context)
{ var message = "2" + currentPlayerId + "!";
log.info(message); var inputValue = null; if (args && args.inputValue) inputValue = args.inputValue;
log.debug("helloWorld:", { input: args.inputValue }); return { messageValue: message };
}
and in Unity C# I have:
public void startCloudScript () { PlayFabClientAPI.ExecuteCloudScript (new PlayFab.ClientModels.ExecuteCloudScriptRequest () { FunctionName = "helloWorld", FunctionParameter = null, GeneratePlayStreamEvent = false }, OncloudEvent, Error) ; }
for starting the function execution and:
void OncloudEvent (PlayFab.ClientModels.ExecuteCloudScriptResult res)
{
Debug.Log (res.FunctionName);
Debug.Log( PlayFab.Json.PlayFabSimpleJson.SerializeObject (res.FunctionResult));
}
for getting the result.
The issue I have is that even though I can get the function name from the first Debug statement in OnCloudEvent(), the second statement always returns null.
I want to be able to see the message that I have sent from the CloudScript.
How would I go about this?