"dini_FloatSet" - decimal place from inputtext.
#1

When I enter value 2.3 in inputtext, it saves it as 2.30000 in the file, if I enter 1.1, then the value in the file is 1.09999, how can I change it? That the value should be saved with a maximum of 1 decimal place?


Code:
new Float:value;

if(sscanf(inputtext, "f", value)){
	ShowDialog(playerid, 32, DIALOG_STYLE_INPUT, "Admin", "You must write this value!", "Next", "Prev");
	return true;
}

dini_FloatSet(FILE_CONF, "gmk", value);
ShowPlayerDialog(playerid, 0, DIALOG_STYLE_MSGBOX, "Lorem", "Changed!", "Close", "");
return true;
Reply


Messages In This Thread
"dini_FloatSet" - decimal place from inputtext. - by CherryMond - 01.04.2018, 21:03
Re: "dini_FloatSet" - decimal place from inputtext. - by NaS - 02.04.2018, 08:33

Forum Jump:


Users browsing this thread: 1 Guest(s)