Dreamlo

Good morning,

I was making some tests withDreamlo Corona Plug In and found 2 issues.

1- When I ask for the score for only one name I receive “empty” always for the score as you can see in the example.

dreamlo.getScores({name=“gatico”}, handleBestScore)

08:32:08.715  table: 0A54CEE0 {

08:32:08.715    [seconds] => “0”

08:32:08.715    [name] => “gatico”

08:32:08.715    [date] => “11/19/2017 4:06:35 PM”

08:32:08.715    [text] => “”

08:32:08.715    [score] => “”

08:32:08.715  }

When I ask for more scores it works OK.

09:13:57.228    [6] => table: 0A54D0C0 {

09:13:57.228             [seconds] => “0”

09:13:57.228             [name] => “gatico”

09:13:57.228             [date] => “11/19/2017 4:06:35 PM”

09:13:57.228             [text] => “”

09:13:57.228             [score] => “15”

09:13:57.228           }

09:13:57.228    [7] => table: 0A54D0C0 {

09:13:57.228             [seconds] => “0”

09:13:57.228             [name] => “sapito”

09:13:57.228             [date] => “11/19/2017 4:08:22 PM”

09:13:57.228             [text] => “”

09:13:57.228             [score] => “15”

2- If I ask for only one name the Corona Plugin does not give the “Position” field. So if I want to know the position I have to get all the Scores List. Are there a way to get the position foronly one name ?

This should be fixed

Hello Scott,

I checked, but I think that there are now another problem, let me explain what I see.

In the program I invoke the following code:

dreamlo.getScores({name=“gatico”}, handleScore)

and I check and now I receive one table that has a “name” field but a value with a lot of information and not only one field.

In the console  I see:

http://www.dreamlo.com/lb/5a0e0b106b2b65b0a068ffc8/json-get/gatico

table: 0A3D0620 {

15:10:10.871    [name] => “{“dreamlo”:{“leaderboard”:{“entry”:[{“name”:“javier”,“score”:“180”,“seconds”:“0”,“text”:”",“date”:“11/21/2017 12:41:43 AM”},{“name”:“JaviX”,“score”:“157”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 1:54:51 AM”},{“name”:“MATI”,“score”:“131”,“seconds”:“0”,“text”:"",“date”:“11/21/2017 12:58:27 AM”},{“name”:“Jerm”,“score”:“35”,“seconds”:“0”,“text”:"",“date”:“11/20/2017 9:11:44 PM”},{“name”:“Javier”,“score”:“34”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 10:10:16 PM”},{“name”:“javiHow”,“score”:“33”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 10:14:45 PM”},{“name”:“Javi+Hoy”,“score”:“28”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 3:58:34 PM”},{“name”:“parensejito”,“score”:“17”,“seconds”:“0”,“text”:"",“date”:“11/20/2017 11:53:12 PM”},{“name”:“gatico”,“score”:“15”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 4:06:35 PM”},{“name”:“sapito”,“score”:“15”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 4:08:22 PM”},{“name”:“cabezon”,“score”:“15”,“seconds”:“0”,“text”:"",“date”:“11/21/2017 12:23:29 AM”},{“name”:“Simo”,“score”:“14”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 3:46:55 PM”},{“name”:“cupido”,“score”:“14”,“seconds”:“0”,“text”:"",“date”:“11/21/2017 12:25:10 AM”},{“name”:“Mati”,“score”:“14”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 4:11:15 PM”},{“name”:“yo”,“score”:“13”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 4:02:59 PM”},{“name”:“JaviXXX”,“score”:“13”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 3:44:53 PM”},{“name”:“perensejito”,“score”:“12”,“seconds”:“0”,“text”:"",“date”:“11/20/2017 11:00:57 PM”},{“name”:“Javiy”,“score”:“12”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 1:08:20 AM”},{“name”:“Pedrito”,“score”:“11”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 4:07:44 PM”},{“name”:“luchito”,“score”:“11”,“seconds”:“0”,“text”:"",“date”:“11/20/2017 10:53:12 PM”},{“name”:“hice+diez”,“score”:“10”,“seconds”:“0”,“text”:"",“date”:“11/19/2017 4:13:05 PM”}]}}}"

so the problem now is different, could be a pointer that is pointing to another structure.

thanks for your answer.

Javier

Try now

Good morning Scott,

Yes, I checked and now is working OK. for the command:  dreamlo.getScores({name=“gatico”}, handleScore)

I receive:

08:45:45.308  table: 0CF46220 {

08:45:45.308    [seconds] => “0”

08:45:45.308    [name] => “gatico”

08:45:45.308    [date] => “11/19/2017 4:06:35 PM”

08:45:45.308    [text] => “”

08:45:45.308    [score] => “15”

08:45:45.308  }

Thanks.

Javier.

Hello Scott!

I’m also trying to use Dreamlo in my game but having troubles with duplicate entries. When a player named “Bob” submits his score and then another player named “Bob” (from a different device) submits his, the first score gets overwritten.

Is there a way to use the “text” field and pass on a player ID instead so that I can check the IDs and allow duplicate names in my Leaderboard?

This is a limit of using Dreamlo. There is a name parameter and it’s unique. You can only have one Bob. However, you can set any number of values as part of storing your data. I don’t know if Scott’s plugin supports it, but the Dreamlo API does, for instance:

[http://dreamlo.com/lb/(your](http://dreamlo.com/lb/(your) super secret very long code)/add/Carmine/1000/90/Awesome

You could do /add/youruniqueid/score/name and then when you fetch the scores to show, you could choose to not show the uniqueID.  See:

http://dreamlo.com/developer

However, be aware that sending any unique ID could qualify as Personally Identifiable Information (this includes device ID’s, IP addresses, etc.) and this would have GDPR exposure with regards to the European Union’s new enforcement of their privacy rules. You would have to ask your users for permission to collect this data.

Rob

Dreamlo index with name,  so I check in my game if this name already exist. I warning the user to change to new one.

I hope that this help you.

I see. Thank you for the response Rob!

@javierenrique: Yeah I thought of that too but that will only work if the player is online. I was thinking of a workaround to accommodate both offline and online players. Thanks!

Just wanted to update the thread and mention that I found a solution to my problem.

  1. Created a unique ID for every user (i.e. xxxx-xxxx-xxxx)

  2. Appended this unique ID to the player name before submitting to Dreamlo.

  3. Whenever I retrieve the scores, I parse the player’s name and the unique ID

This allows me to post duplicate player names on Dreamlo w/out having to check if the player name already exists.

Question about the plugin: If I upgrade my Dreamlo to SSL and use https://, will Scott’s plugin still work?

Sorry for late response, my plugin supports it

dreamlo.int( publicCode(string), privateCode(string), alerts(boolean) ,https(boolean) )

Fantastic! Thanks Scott!

How do you handle GDPR with Dreamlo and how can you be sure that it’s GDPR compliant? That’s the only thing bothering me with Dreamlo.

Dreamlo doesn’t by itself collect any private data (from what I can tell). You make send a “Player name” as the primary key, but that value doesn’t have to be bound to anything bindable to private data unless you send data that could be mapped to personal data. 

But like anything, if you use an ID that could be mapped to personal data, you should ask for consent and only use the service if the user opt-in’s to it. If they later change their mind, it’s easy enough to tell Dreamlo to delete the record for the user.

Rob

@Scott: Is it possible to have 2 dreamlo leaderboards in one Corona project?

i.e.

dreamlo_chart1 = require( “plugin.dreamlo” )

dreamlo_chart2 = require( “plugin.dreamlo” )

dreamlo_chart1.int( “xxxxxxxxxxxxxx”, “xxxxxxxxxxxxxx”, true, true )

dreamlo_chart2.int( “xxxxxxxxxxxxxx”, “xxxxxxxxxxxxxx”, true, true )

I tried it but for some reason my charts are getting messed up. The entries I added onto chart1 are being submitted to chart2 and vice versa.

I don’t need to two sperate module just use int to switch the leaderboards

dreamlo_chart1.int( “xxxxxxxxxxxxxx”, “xxxxxxxxxxxxxx”, true, true )

–do something on leaderboard one

dreamlo_chart1.int( “xxxxxxxxxxxxxx”, “xxxxxxxxxxxxxx”, true, true )

–do something on leaderboard two

Hi,

Did this solution work for you?

Kind regards
Alex

If your game aims to be played by many users, don’t use dreamlo.
I made a game a few months ago, and it was in the top 20 in the United States.
Of course, the number of users has increased rapidly.
The dreamlo admin shuts down the leaderboard without any notice.