ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Client functions
  3. guiCreateLabel

Function

guiCreateLabel

Creates a text label.

Syntax

gui-label guiCreateLabel(float x, float y, float width, float height, string text, bool relative [, element parent = nil])

Arguments

xfloat
X position.
yfloat
Y position.
widthfloat
Width.
heightfloat
Height.
textstring
The text.
relativebool
Relative values.Optional in MTA:SA: bool relative = false
parentelement, optional = nil
Parent.

Differences from MTA:SA

  • Arguments in a different colour differ from MTA:SA.

In MTA:SA

guiCreateLabel(float x, float y, float width, float height, string text, bool relative = false, gui-element parent = nil)

Returns

The label.

Example

local label = guiCreateLabel(20, 20, 300, 24, "Witaj na serwerze!", false)
guiLabelSetColor(label, 255, 200, 0)
guiSetFont(label, "default-bold")

See also