Skip to main content

Label::font

Shared

Update the font type of the selected label

Syntax​

Number label.font
  • fontID - Number (Font Types)

Examples​

Updates the font of the label through the command /labelfont

Server-Side

let startLabel = mp.labels.new("Use /labelfont to update the font of this label.", new mp.Vector3(-431.88, 1146.86, 327),
{
los: false,
font: 1,
drawDistance: 100,
});

mp.events.addCommand("labelfont", (player, _, fontID) => {
startLabel.font = parseInt(fontID);
player.outputChatBox(`You have updated the font of the label to Font ID: ${fontID}`);
});