SendClientMessage And SendClientMessgaeToaLL Argument mismatch ?
#1

I used both Send Client Message And Send Client Message To All Both giving errors HERE
Код:
error 035: argument type mismatch (argument 2)
Код:
SendClientMessage(playerid, COL_GREEN, "Server has saved all logged in accounts ");
Reply
#2

Show us your color define.
Reply
#3

Код:
#define COL_WHITE "{FFFFFF}"
#define COL_RED "{F81414}"
#define COL_GREEN "{00FF22}"
#define COL_LIGHTBLUE "{00CED1}"
HERE
Reply
#4

That's the problem, you can't use the { } in SendClientMessage, if you want to use those colors you can do:


pawn Код:
SendClientMessage(playerid, -1, "{00FF22}Message");
Otherwise, if you want to use it the way you do, you'll need the HEX code as of 0xcodes.
Reply
#5

Oh thanks a lot
Reply
#6

i think "COL_GREEN" is in hex Color, SendClientMessage and SendClientMesaageToAll doesn't allow this.



Put this on top of scripts under includes.
pawn Код:
#define COLOR_GREEN 0x33AA33AA
And replace "COL_GREEN" with "COLOR_GREEN".

Hope it helped.
Reply
#7

I have Defined COLORs With HEX code Now but how do i use it like this SendClientMessage(playerid,WHITE,"Hi[OTHERCOLORHERE] How are you ? ");

It sHould result :- HIHow Are You
Reply
#8

Quote:
Originally Posted by rockhopper
Посмотреть сообщение
I have Defined COLORs With HEX code Now but how do i use it like this SendClientMessage(playerid,WHITE,"Hi[OTHERCOLORHERE] How are you ? ");

It sHould result :- HIHow Are You
Just used the {color} after the Hi.
Reply
#9

Thanks
Reply
#10

Not working LOL Very funny :- Hii {COLOR_GREEN} How are you ? This is coming LOL
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)