autodoc_server_functions
JO Functions > jo.notif.left()
Notification on the left with title, icon, color and sound <br>
JO Functions > jo.notif.left() > Syntax
jo.notif.left(source, title, text, dict, icon, color, duration, soundset_ref, soundset_name)
JO Functions > jo.notif.left() > Parameters
source : integer
The source ID of the player
title : string
The title of the notification
text : string
The text of the notification
dict : string
The dictionnary of the icon
icon : string
The name of the icon
color : string <BadgeOptional />
The color of the text <br> default : "COLOR_WHITE"
duration : integer <BadgeOptional />
The duration of the notification in ms <br> default: 3000
soundset_ref : string <BadgeOptional />
The dictionnary of the soundset <br> default : "Transaction_Feed_Sounds"
soundset_name : string <BadgeOptional />
The name of the soundset <br> default : "Transaction_Positive"
JO Functions > jo.notif.left() > Example
local source = 1
local title = "Title"
local text = "The text"
local dict = "hud_textures"
local icon = "check"
local color = "COLOR_GREEN"
local duration = 5000
jo.notif.left(source, title, text, dict, icon, color, duration)
:::details Preview <img src="/images/notifLeft.jpg" /> :::
JO Functions > jo.notif.print()
A function to print in the client console from the server side <br>
JO Functions > jo.notif.print() > Syntax
jo.notif.print(source, ...)
JO Functions > jo.notif.print() > Parameters
source : integer
The source ID of the player
... : any
The data you want to print
JO Functions > jo.notif.print() > Example
local source = 1
local data = {
foo = "bar",
bar = "foo"
}
jo.notif.print(source, json.encode(data))
JO Functions > jo.notif.right()
Notification on the right with icon, color and sound <br>
JO Functions > jo.notif.right() > Syntax
jo.notif.right(source, text, dict, icon, color, duration, soundset_ref, soundset_name)
JO Functions > jo.notif.right() > Parameters
source : integer
(The source ID of the player)
text : string
The text of the notification
dict : string
The dictionnary of the icon
icon : string
The name of the icon
color : string <BadgeOptional />
The color of the text <br> default : "COLOR_WHITE"
duration : integer <BadgeOptional />
The duration of the notification in ms <br> default: 3000
soundset_ref : string <BadgeOptional />
The dictionnary of the soundset <br> default : "Transaction_Feed_Sounds"
soundset_name : string <BadgeOptional />
The name of the soundset <br> default : "Transaction_Positive"
JO Functions > jo.notif.right() > Example
local source = 1
local text = "Success notification"
local dict = "hud_textures"
local icon = "check"
local color = "COLOR_GREEN"
local duration = 5000
jo.notif.right(source, text, dict, icon, color, duration)
:::details Preview <img src="/images/notifRight.jpg" /> :::
JO Functions > jo.notif.rightError()
A function to display an error notification <br>
JO Functions > jo.notif.rightError() > Syntax
jo.notif.rightError(source, text)
JO Functions > jo.notif.rightError() > Parameters
source : integer
The source ID of the player
text : string
The text of the notification
JO Functions > jo.notif.rightError() > Return Value
Type : boolean
Always return
false
JO Functions > jo.notif.rightError() > Example
local source = 1
jo.notif.rightError(source, "Error !")
:::details Preview <img src="/images/notifError.jpg" /> :::
JO Functions > jo.notif.rightSuccess()
A function to display a successful notification <br>
JO Functions > jo.notif.rightSuccess() > Syntax
jo.notif.rightSuccess(source, text)
JO Functions > jo.notif.rightSuccess() > Parameters
source : integer
The source ID of the player
text : string
The text of the notification
JO Functions > jo.notif.rightSuccess() > Return Value
Type : boolean
Always return
true
JO Functions > jo.notif.rightSuccess() > Example
local source = 1
jo.notif.rightSuccess(source, "Success notification")
:::details Preview <img src="/images/notifRight.jpg" /> :::
JO Functions > jo.notif.simpleTop()
Notification on the top with big title and subtitle (native mission start/end) <br>
JO Functions > jo.notif.simpleTop() > Syntax
jo.notif.simpleTop(source, title, subtitle, duration)
JO Functions > jo.notif.simpleTop() > Parameters
source : integer
The source ID of the player
title : string
The title of the notification
subtitle : string
The text of the notification
duration : integer <BadgeOptional />
The duration of the notification in ms <br> default : 3000
JO Functions > jo.notif.simpleTop() > Example
local title = "Mission Started"
local subtitle = "You just start a great mission !"
local duration = 5000
local source = 1
jo.notif.simpleTop(source, title, subtitle, duration)
:::details Preview <img src="/images/notifSimpleTop.gif" /> :::
JO Functions > jo.notif.right() > Parameters
source : integer
(The source ID of the player)
text : string
The text of the notification
dict : string <BadgeOptional />
The dictionnary of the icon
icon : string <BadgeOptional />
The name of the icon
color : string <BadgeOptional />
The color of the text <br> default : "COLOR_WHITE"
duration : integer <BadgeOptional />
The duration of the notification in ms <br> default: 3000
soundset_ref : string <BadgeOptional />
The dictionnary of the soundset <br> default : "Transaction_Feed_Sounds"
soundset_name : string <BadgeOptional />
The name of the soundset <br> default : "Transaction_Positive"