Not inputting text? Dialogs
#1

I have this:
Quote:

if(dialogid == 16516)
{
if(response)
{
if(strlen(inputtext) >= 2 && strlen(inputtext) <= 64)
{
arrUpdates[iUpd][g_Update1] = strlen(inputtext);
format(string, sizeof(string), "You have change Update 1 to %s.", inputtext);
SendClientMessageEx(playerid, COLOR_LIGHTBLUE, string);
CreateDynamicUpdates(strlen(inputtext));
SaveDynamicUpdates();
}
else return ShowPlayerDialog(playerid, 16513, DIALOG_STYLE_LIST, "Update 1:", "Input text\nClear Update", "Select", "Cancel");
}
}

Its a post to create the text and put it in my Updates.ini file but instead it puts a '|', it even says you have changed the text to %s and then whatever inputted on the other dialog?

My CreateDynamicUpdates:
Код:
CreateDynamicUpdates(iUpd)
{
    new Filename[64], line[256];
    format(Filename, sizeof(Filename), "Updates.ini");
    new File:handle = fopen(Filename, io_write);

    format(line, sizeof(line), "Update 1=%s\r\n", arrUpdates[iUpd][g_Update1]); fwrite(handle, line);
    format(line, sizeof(line), "Update 2=%s\r\n", arrUpdates[iUpd][g_Update2]); fwrite(handle, line);
    format(line, sizeof(line), "Update 3=%s\r\n", arrUpdates[iUpd][g_Update3]); fwrite(handle, line);
    format(line, sizeof(line), "Update 4=%s\r\n", arrUpdates[iUpd][g_Update4]); fwrite(handle, line);
    format(line, sizeof(line), "Update 5=%s\r\n", arrUpdates[iUpd][g_Update5]); fwrite(handle, line);
    format(line, sizeof(line), "Update 6=%s\r\n", arrUpdates[iUpd][g_Update6]); fwrite(handle, line);
    format(line, sizeof(line), "Update 7=%s\r\n", arrUpdates[iUpd][g_Update7]); fwrite(handle, line);
    format(line, sizeof(line), "Update 8=%s\r\n", arrUpdates[iUpd][g_Update8]); fwrite(handle, line);
    format(line, sizeof(line), "Update 9=%s\r\n", arrUpdates[iUpd][g_Update9]); fwrite(handle, line);
    format(line, sizeof(line), "Update 10=%s\r\n", arrUpdates[iUpd][g_Update10]); fwrite(handle, line);
    format(line, sizeof(line), "Update 11=%s\r\n", arrUpdates[iUpd][g_Update11]); fwrite(handle, line);
    format(line, sizeof(line), "Update 12=%s\r\n", arrUpdates[iUpd][g_Update12]);
    fwrite(handle, line);
    fclose(handle);
}
my enum:
Quote:

enum eUpdateSystem {
g_Update1[64],
g_Update2[64],
g_Update3[64],
g_Update4[64],
g_Update5[64],
g_Update6[64],
g_Update7[64],
g_Update8[64],
g_Update9[64],
g_Update10[64],
g_Update11[64],
g_Update12[64],
g_Update13[64],
g_Update14[64],
g_Update15[64],
};

+rep to anyone that can even help
Reply


Messages In This Thread
Not inputting text? Dialogs - by RLGaming - 07.10.2012, 04:59
Respuesta: Not inputting text? Dialogs - by WCrimson - 07.10.2012, 05:10
Re: Not inputting text? Dialogs - by Dubya - 07.10.2012, 05:20
Re: Not inputting text? Dialogs - by RLGaming - 07.10.2012, 12:12
Re: Not inputting text? Dialogs - by RLGaming - 07.10.2012, 12:50
Re: Not inputting text? Dialogs - by RLGaming - 07.10.2012, 13:50
Re: Not inputting text? Dialogs - by Dubya - 07.10.2012, 15:04

Forum Jump:


Users browsing this thread: 1 Guest(s)