String not being set
#1

Hello all,

So I am trying to store three different values into a two-dimensional array, the strings are taken from the database and then stored in the array so that the user is then able to see them in a dialog.
Код:
new Temp[4][];
Код:
public OnPlayerCharacterSelection(playerid) {
	MySQL::getData(rows, fields);
	for(new i = 0; i < rows; i++) {
		MySQL::storeString(i, 0, Temp[i][0]);
		if(strfind(Temp[i][0], "null", true) != -1) strcat((Temp[i][0] = EOS, Temp[i]), "Create Character", 17);
	}
	format(str, sizeof(str), "%s\n%s\n%s", Temp[0], Temp[1], Temp[2]);
	ShowPlayerDialog(playerid, DIALOG_ACCOUNT, DIALOG_STYLE_LIST, ""SVR_NAME" - Account", str, DIALOG_BUTTON_SELECT, DIALOG_BUTTON_EXIT);
}
What actually happens is when the data is taken from the database, it tries to store in the array but fails.. and it only displays one value out of two but value is displays is "Create Character".

I'm not really sure what is happening here so if you can see, please let us know.
Reply


Messages In This Thread
String not being set - by MotherDucker - 21.06.2016, 03:09
Re: String not being set - by DRIFT_HUNTER - 21.06.2016, 03:23
Re: String not being set - by MotherDucker - 21.06.2016, 03:27
Re: String not being set - by Lynn - 21.06.2016, 03:29
Re: String not being set - by MotherDucker - 21.06.2016, 03:39
Re: String not being set - by DRIFT_HUNTER - 21.06.2016, 03:55
Re: String not being set - by MotherDucker - 21.06.2016, 04:09

Forum Jump:


Users browsing this thread: 1 Guest(s)