Making string of different colors.
#1

Код:
#define COLOR_GREEN 0x33AA33AA 
#define COLOR_RED 0xAA3333AA

new mainString[100];
new string1[10];
new string2[10];

format(mainString,128,"%s red   %s blue",COLOR_GREEN,COLOR_RED, string1, string2);
//Want string1 in green color and string 2 in red color
Please help
Reply
#2

https://sampwiki.blast.hk/wiki/Colour_Em...olor_embedding
Reply
#3

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
I can't get my answer
Reply
#4

Go to http://www.colorpicker.com/
Get a color and copy the code with 6 Characters Ex: FF0000 for red
make it between "{ }" you'll get {FF0000}, Go back to your string and put everywhere you want color to be red
FFFFFF is white so we will use {FFFFFF} to get white again
PHP код:
format(mainString,128,"{FF0000}Red {FFFFFF}White"); 
ect...
Reply
#5

Quote:
Originally Posted by Shinja
Посмотреть сообщение
Go to http://www.colorpicker.com/
Get a color and copy the code with 6 Characters Ex: FF0000 for red
make it between "{ }" you'll get {FF0000}, Go back to your string and put everywhere you want color to be red
FFFFFF is white so we will use {FFFFFF} to get white again
PHP код:
format(mainString,128,"{FF0000}Red {FFFFFF}White"); 
ect...
C++ is language i am using
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)