Skip to main content

πŸ’» Hud

Usefull hud exports​

Lua Script Exports for sky_hud​

notify Export​

Parameters​

title: Title Message (string)

  • title: Title Message (string)
  • message: Subtitle Message (string)
  • sort: Notify Sort Type ("info", "success", "warn", "error") (string)
  • time: Showing time in milliseconds (1000 = 1 second) (number)

Usage​

exports['sky_hud']:notify(title, message, sort, time)

announce Export​

Parameters​

  • title: Announce Title (string)
  • message: Subtitle Message (string)
  • time: Showing time in milliseconds (1000 = 1 second) (number)

Usage​

exports['sky_hud']:announce(title, message, time)

This export allows you to display an announcement with a specified title and message. The announcement will be visible for the specified time duration.

pressE Export​

Parameters​

  • title: Press-E Title (string)
  • letter: Press-E Letter (string)
note

The maximum wait time for this export is approximately 200 milliseconds.

Usage​

exports['sky_hud']:pressE(title, letter)

Use this export to trigger a "Press E" prompt with a specified title and letter. This prompt will be visible for a short duration, allowing the player to interact with it.

openRequest Export​

Parameters​

  • title: Request Title (string)
  • message: Request Message (string)
  • time: Wait time until the request automatically closes in milliseconds (1000 = 1 second) (number)
  • callback: Callback function (function)
note

If the player accepts the request, the callback function will be called with true; otherwise, it will be called with false.

Usage​

exports['sky_hud']:openRequest('Hud-Showcase', 'Do you want to test something?', 5000, function(accepted)
print('Accepted: ', accepted)
end)

This export allows you to open a request prompt with a specified title and message. The prompt will wait for the player's response for the given time duration. If the player accepts the request, the provided callback function will be invoked with true; otherwise, it will be invoked with false.

showVoiceChat Export​

Parameters​

  • show: Show or hide the voice chat connected screen (boolean)

Usage​

exports['sky_hud']:showVoiceChat(show)

Use this export to show or hide the voice chat connected screen based on the show parameter. Set show to true to display the screen, and false to hide it.