Ugrás a fő tartalomhoz

TextDrawBoxColor

Description

Adjusts the text box colour (only used if TextDrawUseBox 'use' parameter is 'true').

NameDescription
Text:textidThe TextDraw to change
boxColourThe colour. Opacity is set by the alpha intensity of colour (eg. color 0x000000FF has a solid black box opacity, whereas 0x000000AA has a semi-transparent black box opacity).

Returns

This function does not return any specific values.

Examples

new Text:gMyTextdraw;

public OnGameModeInit()
{
gMyTextdraw = TextDrawCreate(123.0, 123.0, "Example");
TextDrawUseBox(gMyTextdraw, true);
TextDrawBoxColor(gMyTextdraw, 0xFFFFFFFF);
return 1;
}

Notes

tanács

If you want to change the boxcolour of a textdraw that is already shown, you don't have to recreate it. Simply use TextDrawShowForPlayer/TextDrawShowForAll after modifying the textdraw and the change will be visible.