SendClientMessage Color bug
#1

When you do this

PHP код:
#define RED FF0000
#define COLOR_WHITE 0xFFFFFFFF
SendClientMessage(playerid,COLOR_WHITE,"blah{RED}blah"); 
it returns it like this in white text "blah{RED}blah" instead of changing colors it just displays it in the text. If you do you replace {RED} with {FF0000} it works fine though. It would be nice if we could define these colors, if I remember correctly you can do it with defined colors in dialogs.
Reply
#2

because the first is hexadezimal and the second is rrggbb so it can't work how you amde it....

That isn't in any way a bug.
Reply
#3

Quote:
Originally Posted by ulbi1990
Посмотреть сообщение
because the first is hexadezimal and the second is rrggbb so it can't work how you amde it....

That isn't in any way a bug.
if you can't understand what I meant here is a simpler way.

#define COL_RED FF0000
SendClientMessage(playerid,-1,"Blah{COL_RED}blah");

the above will not work it will say "Blah{COL_RED}blah"

SendClientMessage(playerid,-1,"Blah{FF0000} blah");

the above here will work, notice how the color code"FF0000" is the same as COL_RED is defined. Does that make more sense?
Reply
#4

pawn Код:
#define RED "{FF0000}"
#define COLOR_WHITE 0xFFFFFFFF
SendClientMessage(playerid,COLOR_WHITE,"blah"RED"blah");
This way it would work.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)