Text is not showing -
MrakBuster - 30.09.2018
Hi.
I created a value showing in dialog. It looks like this:
Код:
CMD:budget(playerid, params[])
{
new string[64], str[2048];
format(string, sizeof(string), "Budget amount: %d\n", Budget);
strcat(str, string);
strcat(str, "\n");
strcat(str, "text");
ShowPlayerDialog(playerid, DIALOG_BUDGET, DIALOG_STYLE_MSGBOX, "Budget info", string, "OK", "");
return 1;
}
The problem is, that the
text is not showing. Not even the new line.
When i type /budget, only thing, that shows up is one line, that says the amount budget, nothing else.
Where is the
"fatal error" that will cure this?
For any help, I will be much more, then just thankful.
Re: Text is not showing -
Undef1ned - 30.09.2018
PHP код:
CMD:budget(playerid, params[])
{
new str[90], dialog[145];
format(str, sizeof(str), "Budget amount: %d\n\n", Budget); strcat(dialog, str);
strcat(dialog, "text");
ShowPlayerDialog(playerid, DIALOG_BUDGET, DIALOG_STYLE_MSGBOX, "Budget info", dialog, "OK", "");
return 1;
}
Re: Text is not showing -
MrakBuster - 30.09.2018
still the same issue
instead of pasting code, if somebody could please point out, where the mistake is, so i can learn on it....
i am not the type of guy, that just wants to copy and paste
Re: Text is not showing -
Undef1ned - 30.09.2018
What does not work or where is the error?
sa-mp-250.jpg
Re: Text is not showing -
MrakBuster - 30.09.2018
Nowhere. I just wanna see, that where was the mistake IN MY CODE, so i can correct it myself and learn on it. I dont want to use other codes, I want to maintain my variables and coding style.
Re: Text is not showing -
UFF - 30.09.2018
Код:
CMD:budget(playerid, params[])
{
new string[500], str[500];
format(string, sizeof(string), "Budget amount: %d\n", Budget);
strcat(str, string);
strcat(str, "\n");
strcat(str, "text");
ShowPlayerDialog(playerid, DIALOG_BUDGET, DIALOG_STYLE_MSGBOX, "Budget info", str, "OK", "");
return 1;
}
You have to use str instead of string in ShowPlayerDialog.