Pular para o conteúdo principal

DeletePlayer3DTextLabel

descrição

Apaga um texto 3D criado com CreatePlayer3DTextLabel.

NomeDescrição
playeridID do jogador cujo texto 3D será apagado.
PlayerText3D:textidID do texto 3D do jogador a apagar.

retorno

true - A função executou com sucesso.

false - A função falhou, o que significa que o texto especificado não existe.

exemplo

new PlayerText3D:playerTextId[MAX_PLAYERS];

public OnPlayerSpawn(playerid)
{
new
name[MAX_PLAYER_NAME],
Float:x, Float:y, Float:z,
string[64];

GetPlayerName(playerid, name, sizeof(name));
GetPlayerPos(playerid, x, y, z);

format(string, sizeof(string), "Olá %s!\nEstou na tua posição", name);
playerTextId[playerid] = CreatePlayer3DTextLabel(playerid, string, 0x008080FF, x, y, z, 40.0);
return 1;
}

public OnPlayerDisconnect(playerid, reason)
{
DeletePlayer3DTextLabel(playerid, playerTextId[playerid]);
return 1;
}

funções relacionadas