22.08.2012, 10:44
Quote:
I see the problem, you'll have to set a \ before all the " that you are using in your text becuse otherwise the function think your string ends there. Like this:
format(str, sizeof(str), "\"#COL_RED\"[ADMIN-ANN]\"#COl_WHITE\"%s: %s", sendername, str); |
pawn Код:
new szStr[ 128 ]; // this is the default value of the chat message..
and for GameTextForPlayer/GameTextForAll, if you want to change the colour (or want a next line) of it then you have to use
pawn Код:
// colors ..
~n~ New line
~r~ Red
~g~ Green
~b~ Blue
~w~ White
~y~ Yellow
~p~ Purple
~l~ Black
~h~ Turn text colour lighter (used too much will make your text white, doesnt work on black)
// special text
~u~ up arrow (grey)
~d~ down arrow (grey)
~<~ left arrow (grey)
~>~ right arrow (grey)
] displays a * symbol (Only in text styles 3, 4 and 5)
~k~ keyboard key mapping (eg ~k~~VEHICLE_TURRETLEFT~ and ~k~~PED_FIREWEAPON~). Look here for a list of keys