Custom Maps & Logic
  • Custom Map Tutorial
    • Custom Map Introduction
    • Your first map
    • Map Navigation
    • Object Selection
    • Object Positioning
    • Object Attributes
    • Shortcuts and Macros
    • Editor Settings
    • Built-in Components Common Errors
    • Map Performance
    • Custom Assets
      • Your first Asset Bundle
      • Asset Bundles in Map Editor
      • Asset Bundles in Game
      • Adding to Asset Bundles
      • Asset Bundle naming
  • Custom Logic Tutorial
    • Custom Logic Introduction
    • Your first script
    • Variables
    • Types
    • Variable Inspector
    • Expressions
    • Conditionals
    • Loops
    • Functions
    • Coroutines
    • Classes
    • Static Classes
    • Components
    • Extensions
    • Cutscenes
    • Static Objects
    • Networking
    • Commenting
  • Reference
    • Static Classes
      • Game
      • Network
      • Map
      • UI
      • Time
      • Convert
      • String
      • Input
      • Math
      • Random
      • Cutscene
      • Camera
      • RoomData
      • PersistentData
      • Json
      • Physics
    • Objects
      • Component
      • Object
      • Character
      • Human
      • Titan
      • Shifter
      • MapObject
      • Transform
      • Player
      • NetworkView
      • Color
      • Vector3
      • Quaternion
      • Dict
      • List
      • Range
      • LineCastHitResult
      • MapTargetable
      • Random
    • Callbacks
      • Main
      • Components
  • Examples
    • Gamemodes
      • Survive
      • Waves
      • Endless
      • Racing
      • Blade PVP
      • Thunderspear PVP
      • Titan Explode
      • Cranked
      • More Examples
    • Components
      • SupplyStation
      • Daylight
      • PointLight
      • Rigidbody
      • NavMeshObstacle
      • Cannon
      • Dummy
      • Wagon
      • Tag
      • KillRegion
      • DamageRegion
      • MovePingPong
      • RacingCheckpointRegion
      • RacingFinishRegion
      • TeleportRegion
      • Animal
      • SignalMover
      • SignalSender
      • More Examples
Powered by GitBook
On this page
  1. Reference
  2. Static Classes

UI

UI label functions.

Functions

Function
Returns
Description

SetLabel(type: string, label: string)

null

Sets the label at a certain location. Valid types: "TopCenter", "TopLeft", "TopRight", "MiddleCenter", "MiddleLeft", "MiddleRight", "BottomLeft", "BottomRight", "BottomCenter".

SetLabelForTime(type: string, label: string, time: float)

null

Sets the label for a certain time, after which it will be cleared.

SetLabelAll(type: string, label: string)

null

Sets the label for all players. Master client only. Be careful not to call this often.

SetLabelForTimeAll(type: string, label: string, time: float)

null

Sets the label for all players for a certain time. Master client only.

CreatePopup(name: string, title: string, width: int, height: int)

null

Creates a new popup. This popup is hidden until shown.

ShowPopup(name: string)

null

Shows the popup with given name.

HidePopup(name: string)

null

Hides the popup with given name.

ClearPopup(name: string)

null

Clears all elements in popup with given name.

IsPopupActive(name: string)

bool

Is the popup active.

GetPopups()

List(string)

Returns a list of all created popup names.

AddPopupLabel(name: string, label: string)

null

Adds a text row to the popup with label as content.

AddPopupButton(popupName: string, buttonName: string, buttonText: string)

null

Adds a button row to the popup with given button name and display text. When button is pressed, OnButtonClick is called in Main with buttonName parameter.

AddPopupButtons(popupName: string, buttonNames: List, buttonTitles: List)

null

Adds a list of buttons in a row to the popup.

AddPopupBottomButton(popupName: string, buttonName: string, buttonText: string)

null

Adds a button to the bottom bar of the popup.

WrapStyleTag(text: string, style: string, args: string)

string

Returns a wrapped string given style and args.

GetLocale(category: string, subcategory: string, key: string)

string

Gets translated locale from the current Language.json file with given category, subcategory, and key pattern.

GetLanguage()

string

Returns the current language (ie "English).

ShowChangeCharacterMenu()

null

Shows the change character menu if main character is Human.

SetScoreboardHeader(header: string)

null

Sets the display of the scoreboard header (default "Kills / Deaths...")

SetScoreboardProperty(property: string)

null

Sets which Player custom property to read from to display on the scoreboard. If set to empty string, will use the default "Kills / Deaths..." display.

GetThemeColor(panel : string, category : string, item : string)

Color

Gets the color of the specified item. See theme json for reference.

PreviousMapNextTime

Last updated 3 months ago