2Hours to realize I can't cal an event inside another event in cloud code. I need to parse score from Unity to event_EndGame with GameSparks.Api and then parse the same variable into event_Placement . Is this right? And if so, why do I need this code in cloud scripting?
var request = new SparkRequests.LogEventRequest(); request.eventKey = "event_Placement"; request.score = score; request.Send();
I just don't understand what's the point :/ I don't trust the client to handle score, so i have to tweek the code and do some game logic in a module (since events doesnt run on events) is this right?
Flávio Correia
I've been trying to replicate this tutorial :
https://docs.gamesparks.com/tutorials/social-features/league-and-division-leaderboards.html
I don't know if this matters, I've named my
Global Leaderboard to ldr_Global (since tutorial doesn't give us a name) and
Divison Leaderboard to division.
Thing is, in my TestHarness I can register or authenticate players properly and get an Auth Token.
But when I run the event EndGame in Harness (with score properly set), I get a null response :
{"@class": ".LogEventResponse" }
It should at least go to event_placement and setScriptData("placementScore", score)
But no such data is created.
I don't create segments : league in RegistrationRequest(), like this on Player Connect
PS: I can see in my system.players collection that segments is properly set to league : "placement"