ricardo1996
Member
Hi. Im trying to save the inital googleplay player id to prevent duplicate scores to multiple accounts. S i thought il just save the id of the inital login into global.playerid and save it along side the rest of saved data. then another variable tempplayerid whih i use to log the current playerid. i then use the tempplayer var and compare it to the global.playerid if they are the same id then il uplad scres to leaderboard.
bu im having issues in the async social event. data structure index does not exist. helpplease this is a must needed implementation.
bu im having issues in the async social event. data structure index does not exist. helpplease this is a must needed implementation.
Code:
if(ds_exists(async_load, ds_type_map)){
if(ds_map_find_value(async_load, "id") == achievement_our_info){
tempplayerid = ds_map_find_value(async_load, "playerid");
if(global.playerid == -1) {
global.playerid = tempplayerid;
safe_ini_open(Fn,Pw);
safe_ini_write_real("player", "info", global.playerid);
safe_ini_close();
}
}
}