03.01.2019, 08:40
If it's ever not conveniently formatted to use with sscanf, you could always do something like:
That would be inside your iteration. How do you use it?
Inside your OnDialogResponse. Delete it after.
We're using the listitem the player would be at in OnDialogResponse and setting their ID through the PVar.
listitems start at 0 and as does your countPlayers variable.
It's pretty simple and self explanatory but if you don't understand, let me know and I'll explain further.
pawn Code:
new tmpstr[80];
format(tmpstr, sizeof(tmpstr), "PLIST_%i_USERID", countPlayers);
SetPVarInt(playerid, tmpstr, get_players_id);
pawn Code:
new tmpstr[80], get_player_id;
format(tmpstr, sizeof(tmpstr), "PLIST_%i_USERID", listitem);
get_player_id = GetPVarInt(playerid, tmpstr);
We're using the listitem the player would be at in OnDialogResponse and setting their ID through the PVar.
listitems start at 0 and as does your countPlayers variable.
It's pretty simple and self explanatory but if you don't understand, let me know and I'll explain further.

