Server Exports
All server exports are available through the 17mov_Interface resource.
local interface = exports['17mov_Interface']showNotification(source, data)
Displays a notification for a player.
Arguments
sourcenumber- Player server ID.dataNotificationData | string- Uses the same notification data as the client export.
Example
interface:showNotification(source, {
type = 'success',
title = 'Payment received',
description = 'You received $500',
duration = 4000,
icon = 'banknote'
})startProgress(source, data)
Starts a non-blocking progress bar for a player.
Arguments
sourcenumber- Player server ID.dataProgressData- Uses the same progress data as the client export.
Example
stopProgress(source)
Stops the active progress bar for a player and marks it as completed.
Arguments
sourcenumber- Player server ID.
toggleDisplay(source, state)
Shows or hides the HUD for a player.
Arguments
sourcenumber- Player server ID.stateboolean-trueto show the HUD,falseto hide it.
addStress(source, amount)
Adds stress to a player.
Arguments
sourcenumber- Player server ID.amountnumber- Amount of stress to add.
removeStress(source, amount)
Removes stress from a player.
Arguments
sourcenumber- Player server ID.amountnumber- Amount of stress to remove.
getDefaultPositions()
Returns the default positions configured for HUD elements.
Returns
Example
setDefaultPositions(positions)
Updates the default HUD element positions and applies them to all players.
Arguments
positionstable- New default positions.
Returns
Example
getDefaultLayout()
Returns the default HUD layout saved by the admin editor.
Returns
Example
setDefaultLayout(code)
Sets or clears the default HUD layout and applies the change to all players.
Arguments
codestring | nil- Layout code. Passnilto clear the current default layout.
Returns
Example
To clear the current layout:
SoundFile
Represents a sound available in the sound library.
filestring- Sound file name.titlestring- Display name.typestring- Sound file type.
getSoundLibrary()
Returns all currently available sounds.
Returns
Example
refreshSoundLibrary()
Re-scans the sounds directory and returns the updated sound library.
Returns
Example
Last updated