15.12.2014, 11:48
Hey, I want to create a tag system but I have a problem with colors
Here is the code, can someone tell me what's wrong with this pawn code ? Thanks.
pawn Код:
new string[256];
new tag[60];
new tagcouleur;
format(tag, sizeof(tag), "%s", inputtext);
if(TagCouleur[playerid] == 1) tagcouleur = HexToInt("FF0000FF"); //rouge
if(TagCouleur[playerid] == 2) tagcouleur = HexToInt("0000FFFF"); //bleu
if(TagCouleur[playerid] == 3) tagcouleur = HexToInt("00FF00FF"); //vert
if(TagCouleur[playerid] == 4) tagcouleur = HexToInt("840000FF"); //rouge foncй
if(TagCouleur[playerid] == 5) tagcouleur = HexToInt("843A00FF"); //marron
TagID[playerid] = CreateObject(19482, PosTag[playerid][0], PosTag[playerid][1], PosTag[playerid][2], 0.0, 0.0, 90.0);
SetObjectMaterialText(TagID[playerid], tag, 0, OBJECT_MATERIAL_SIZE_256x128, "Arial", Tag[playerid], 0, tagcouleur, 0x00000000, OBJECT_MATERIAL_TEXT_ALIGN_CENTER);
EditObject(playerid, TagID[playerid]);
return true;