SA-MP Forums Archive
Why do colors not work on a dialog? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Why do colors not work on a dialog? (/showthread.php?tid=456024)



Why do colors not work on a dialog? - thimo - 04.08.2013

Okay im trying to use colors on a dialog but it just shows the normal color. My code:
pawn Код:
new string[2048], HouseID;
            HouseID = APlayerData[playerid][CurrentHouse];
            format(string, sizeof(string), "%sSome house info you may find helpfull:\n", string);
            format(string, sizeof(string), "%sYour house id: {DB881A}%i{FFFFFF}\n", string, HouseID);
            format(string, sizeof(string), "%sYour house X: {DB881A}%f{FFFFFF}, Y:{DB881A}%f{FFFFFF}, Z:{DB881A}%f{FFFFFF}\n", string, AHouseData[HouseID][HouseX], AHouseData[HouseID][HouseY], AHouseData[HouseID][HouseZ]);
            format(string, sizeof(string), "%sYour house buy price: %i, Your house selling price: %i", string, AHouseData[HouseID][price], AHouseData[HouseID][price]*0.75);
            format(string, sizeof(string), "%sFor any old European Trucking players that think that you can still buy cars here, you cant.\n", string);
            format(string, sizeof(string), "%sYou need to buy your vehicles at the dealers.", string);
           
            ShowPlayerDialog(playerid, DialogHouseInfo, DIALOG_STYLE_MSGBOX, "House info", string, "Ok", "");



Re: Why do colors not work on a dialog? - Necip - 04.08.2013

Can you show a SS?


Re: Why do colors not work on a dialog? - arjanforgames - 04.08.2013

As far as I know you need to use hexadecimal color codes.
Although I see you are using them they are supposed to work.


Re: Why do colors not work on a dialog? - Zex Tan - 04.08.2013

Hmmmm... Thats strange.

You could use "strcat" and also

pawn Код:
#define       color     "{hexadecimal}"

Later you could just

pawn Код:
"Hello "color" world!"