Callback
Use to easily communicate between both client and server
lib.callback.await
Call and await for a response of a server callback
Parameter
Type
Required
Description
event
String
Server defined event name
playerId
Number
Server Only - source to send request to
cb
Function
Callback function, there must be at least one defined
lib.callback.register
Register a client callback, this can be used to easily request data from a client from the server
Parameter
Type
Required
Description
event
String
Event name to be called from the server
cb
Function
Callback function, should return values for the callback
Last updated