Need some help with Color IDs!
#1

Hi right now I'm trying to make my own SendClientMessage with an own color.
I know I have to do #define colourname colorID
and then write it the colorname here-> ,colorname,"message"
but my problem is to make the color ID..
I have been searching around on the sa-mp wiki but can't find anything that is helping me.

By the way I tried this but it didn't work:

Define like this

#define lightgreen #1AFF00

and the SendClientMessage like this

SendClientMessage(playerid,lightgreen, "Welcome to Los Santos DeathMatch ~ by OleKristian95");
SendClientMessage(playerid,lightgreen, "To make an account type /register");
Reply
#2

well for a start #1AFF00 wont work like that as a define but here is the code for a light green
Код:
#define lightgreen 0x00FF00FF
and post the whole callback/function please in case you forgot brackets {} or smthn
Reply
#3

Use this:
pawn Код:
#define COLOR_LIGHTBLUE 0x33CCFFAA
#define COLOR_RED 0xAA3333AA
#define COLOR_GREY 0xAFAFAFAA
#define COLOR_YELLOW 0xFFFF00AA
#define COLOR_PINK 0xFF66FFAA
#define COLOR_BLUE 0x0000BBAA
#define COLOR_WHITE 0xFFFFFFAA
#define COLOR_DARKRED 0x660000AA
#define COLOR_ORANGE 0xFF9900AA
#define COLOR_BRIGHTRED 0xFF0000AA
#define COLOR_INDIGO 0x4B00B0AA
#define COLOR_VIOLET 0x9955DEEE
#define COLOR_LIGHTRED 0xFF99AADD
#define COLOR_SEAGREEN 0x00EEADDF
#define COLOR_GRAYWHITE 0xEEEEFFC4
#define COLOR_LIGHTNEUTRALBLUE 0xabcdef66
#define COLOR_GREENISHGOLD 0xCCFFDD56
#define COLOR_LIGHTBLUEGREEN 0x0FFDD349
#define COLOR_NEUTRALBLUE 0xABCDEF01
#define COLOR_LIGHTCYAN 0xAAFFCC33
#define COLOR_LEMON 0xDDDD2357
#define COLOR_MEDIUMBLUE 0x63AFF00A
#define COLOR_NEUTRAL 0xABCDEF97
#define COLOR_BLACK 0x00000000
#define COLOR_NEUTRALGREEN 0x81CFAB00
#define COLOR_DARKGREEN 0x12900BBF
#define COLOR_LIGHTGREEN 0x24FF0AB9
#define COLOR_DARKBLUE 0x300FFAAB
#define COLOR_BLUEGREEN 0x46BBAA00
#define COLOR_PINK 0xFF66FFAA
#define COLOR_LIGHTBLUE 0x33CCFFAA
#define COLOR_DARKRED 0x660000AA
#define COLOR_ORANGE 0xFF9900AA
#define COLOR_PURPLE 0x800080AA
#define COLOR_GRAD1 0xB4B5B7FF
#define COLOR_GRAD2 0xBFC0C2FF
#define COLOR_RED1 0xFF0000AA
#define COLOR_GREY 0xAFAFAFAA
#define COLOR_GREEN 0x33AA33AA
#define COLOR_RED 0xAA3333AA
#define COLOR_YELLOW 0xFFFF00AA
#define COLOR_WHITE 0xFFFFFFAA
#define COLOR_BROWN 0x993300AA
#define COLOR_CYAN 0x99FFFFAA
#define COLOR_TAN 0xFFFFCCAA
#define COLOR_PINK 0xFF66FFAA
#define COLOR_KHAKI 0x999900AA
#define COLOR_LIME 0x99FF00AA
#define COLOR_SYSTEM 0xEFEFF7AA
#define COLOR_GRAD2 0xBFC0C2FF
#define COLOR_GRAD4 0xD8D8D8FF
#define COLOR_GRAD6 0xF0F0F0FF
#define COLOR_GRAD2 0xBFC0C2FF
#define COLOR_GRAD3 0xCBCCCEFF
#define COLOR_GRAD5 0xE3E3E3FF
#define COLOR_GRAD1 0xB4B5B7FF
Reply
#4

ok i will show u how to do it

pawn Код:
//define it like this
#define WHITE 0x0000FFFF // This is what your looking for ;)
#define GREEN"{7FFF00}" //This is for the new Color Embedding

//Use it like this
SendClientMessage(playerid,WHITE, "To make an account type "GREEN"/register");
Reply
#5

Or Try it like this

Код:
#define lightgreen 0x00FF00FF
Код:
SendClientMessage(playerid,0x00FF00FF "Welcome to Los Santos DeathMatch ~ by OleKristian95");
SendClientMessage(playerid,0x00FF00FF, "To make an account type /register");
Reply
#6

Quote:
Originally Posted by Lookin
Посмотреть сообщение
well for a start #1AFF00 wont work like that as a define but here is the code for a light green
Код:
#define lightgreen 0x00FF00FF
and post the whole callback/function please in case you forgot brackets {} or smthn
Thanks alot Lookin now I see what I did wrong.

------------------------------------------------------------------------------------------------------------------

Thanks for all other answers too ^^
Reply
#7

no problem anytime mate
Reply
#8

Quote:
Originally Posted by HayZatic
Посмотреть сообщение
Or Try it like this

Код:
#define lightgreen 0x00FF00FF
Код:
SendClientMessage(playerid,0x00FF00FF "Welcome to Los Santos DeathMatch ~ by OleKristian95");
SendClientMessage(playerid,0x00FF00FF, "To make an account type /register");
Why would he define lightgreen
And then not use it ??

Becouse you defined it and then you done
pawn Код:
SendClientMessage(playerid,0x00FF00FF, "To make an account type /register");[/code][/QUOTE]
if he does it that way there is no point of defining it in first place
Reply
#9

Quote:
Originally Posted by park4bmx
Посмотреть сообщение
Why would he define lightgreen
And then not use it ??

Becouse you defined it and then you done
pawn Код:
SendClientMessage(playerid,0x00FF00FF, "To make an account type /register");[/code]
pawn Код:
 
if he does it that way there is no point of defining it in first place [/QUOTE]

He probably did a mistake
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)