Problem with adding text on vehicle
#1

Hi there I have a problem when I try to add different color on vehicle as shown on the pictures bellow. The problem is, when If I put text to be white (0xFFFFFFFF), everything is working fine but when I want to make it blue (using navy blue 0x000080FF), it doesn't show at all, can someone help me?

Here the text is white and it's working:


Here the text is blue and it's NOT WORKING:


Here is the code from the script:
pawn Код:
if(strcmp( cmd, "/policecar", true ) == 0 )
{
    new Float:X, Float:Y, Float:Z;
    new col1[32];
    new col2[32];
    new policecar;
    col1 = strtok( cmdtext, idx );
    col2 = strtok( cmdtext, idx );

    GetPlayerPos( playerid, X, Y, Z );

    policecar = CreateVehicle( 560, X+2, Y+2, Z, 0, strval(col1), strval(col2), -1 );
        new Sign1, Sign2;
    Sign1 = CreateObject(19327, 0, 0, 0, 0, 0, 0);
    Sign2 = CreateObject(19327, 0, 0, 0, 0, 0, 0);
    AttachObjectToVehicle(Sign1, policecar, 1.064999, 0.000000, 0.000000, 0.000000, 0.000000, 89.444953);
    AttachObjectToVehicle(Sign2, policecar, -1.064999, 0.000000, 0.000000, 0.000000, 0.000000, -89.444953);
    SetObjectMaterialText(Sign1, "P O L I C E", 0, OBJECT_MATERIAL_SIZE_256x128,"Arial", 50, 1, 0x000080FF, 0, OBJECT_MATERIAL_TEXT_ALIGN_CENTER);
    SetObjectMaterialText(Sign2, "P O L I C E", 0, OBJECT_MATERIAL_SIZE_256x128,"Arial", 50, 1, 0x000080FF, 0, OBJECT_MATERIAL_TEXT_ALIGN_CENTER);
    new msg[256];
    format(msg,256,"Police car created | Colors: %d, %d", strval(col1), strval(col2));
    SendClientMessage(playerid,0xAAAAAAAA,msg);
       
    return 1;
}
Reply
#2

Should be
0xFF0080FF
or
0xFF000080

it's ARGB format so if you set 00 on start color is invisible
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)