Long messages with ShowPlayerDialog
#1

ok i want to make a dialog that shows stats. is there a way to format the text in the showplayerdialog for showing money etc?. if i use new s[...] and format it, i need way lots of memory like s[512] so is there a way to save this memory and format it inside ShowPlayerDialog itself?
Reply
#2

i think no ... or i dont understand what you say
Reply
#3

pawn Код:
new string[1024]; // <= That's the string's size (1024).
format(string, sizeof(string), "Money: $%d\r\nMore stats....", GetPlayerMoney(playerid)); // \r\n makes a new line.
ShowPlayerDialog(playerid, 1234, DIALOG_STYLE_MSGBOX, "Your Stats", string, "Close", "Close");
That's what you were talking about?
Reply
#4

1024 ok to use? ****** said 128 is beeter then 256 so i thought there was a limit
Reply
#5

128 is how many cells. So 1024 is alot of cells say if you only display one stat. But since your doing a full /stat command in dialog you will need around 512 to 1024 or even less. Be sure to make the size of everything fit and try not to waste cells. Read some of ******'s scripting topics about cells and optimization stuff.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)