PlayerTextDrawSetString string with a space at the end
#1

Some time ago I started creating this info box script, where I could use one function to display the text in an info box, and the text would be edited like so, that there would not be any cut words and there would be a limit to a one line length. At one time I gave up and did not know what was going on that the text would not show up in the info box (textdraws), but some would (the ones without a space at the end). I was debugging the whole script, tracking every move. The only lines that showed were the ones that did not have a space at the end. And the spaces were there, because the script was taking parts out of the whole text that was going to be used and putting them into separate lines. I would not have even imagined that a space at the end could cause this. So all in all:

Will work
Код:
PlayerTextDrawSetString(playerid, textdrawID, "I spent so much time on fixing this script!");
Will not work
Код:
PlayerTextDrawSetString(playerid, textdrawID, "I spent so much time on fixing this script! ");
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)