Events & Commands
Phone notifications
The JPR Phone System contains a wide variety of notifications, all original notifications are processed by itself, nothing needs to be done, but if you want to send a custom notification, you can do so by following the example below.
TriggerEvent("jpr-phonesystem:client:customnotification", {
app = "Custom", -- dont change
title = "Custom Notification",
img = "imagem.png",
text = "Im a custom notification",
time = 2600,
})
Phone wallet logs
The JPR Phone System contains a wallet app where you can see all your transactions made. This is our trigger to add a new log on wallet app:
TriggerServerEvent("jpr-phonesystem:server:createNewWalletLog", AMOUNT, TYPE, NOTIFICATION)
AMOUNT = Amount of the transaction made TYPE = Should be 0 or 1 ( 0 = Deposit, 1 = Withdraw ) NOTIFICATION = true or false ( true = Player receive notification on phone, false = No notification)
Phone mails
TriggerServerEvent('jpr-phonesystem:server:sendEmail', {
subject = "Phone System", -- Subject
message = "Hello, nice phone sir!", -- Content
sender = "jpresources.client.fivem@gmail.com", -- Submitted by
event = {type = "client", event = "jpr-phonesystem:example", buttonData = {}}, -- Optional
})
If you don't want the email to trigger some kind of event, leave it like this
TriggerServerEvent('jpr-phonesystem:server:sendEmail', {
subject = "Phone System", -- Subject
message = "Hello, nice phone sir!", -- Content
sender = "jpresources.client.fivem@gmail.com", -- Submitted by
event = {}, -- Optional
})
Verified Share It ( Instagram ) command
The JPR Phone System allows you to add verified to some player's share it profile, you can edit the name of the command in the config.lua
.
Its syntax should be as follows:
/(name of command) (account id) (true or false)
True - Add verified
False - Remove verified
In-Game example:
/verifiedInstagram 65qHj7UZ408UfCU true
Where can i find Account ID?
You can find Account ID in the discord webhook channel or in SQL Table: jpr_phonesystem_instagram_accounts
Account ID is NOT Game ID
Verified Catiter ( Twitter ) command
The JPR Phone System allows you to add verified to some player's catiter profile, you can edit the name of the command in the config.lua
.
Its syntax should be as follows:
/(name of command) (account id) (true or false)
True - Add verified
False - Remove verified
In-Game example:
/verifiedTwitter 65qHj7UZ408UfCU true
Where can i find Account ID?
You can find Account ID in the discord webhook channel or in SQL Table: jpr_phonesystem_tweet_accounts
Account ID is NOT Game ID
Verified TikTrend ( Tiktok ) command
The JPR Phone System allows you to add verified to some player's tiktrend profile, you can edit the name of the command in the config.lua
.
Its syntax should be as follows:
/(name of command) (account id) (true or false)
True - Add verified
False - Remove verified
In-Game example:
/verifiedTiktok 65qHj7UZ408UfCU true
Where can i find Account ID?
You can find Account ID in the discord webhook channel or in SQL Table: jpr_phonesystem_tiktok_accounts
Account ID is NOT Game ID
Billing command
You can change command name going to config.lua
in Config.BillingCommand
Example:
/sendbill ID Amount
/sendbill 1 500
NPC events
To repair battery:
TriggerEvent('jpr-phonesystem:client:fixPhone')
To hack phones:
TriggerEvent('jpr-phonesystem:client:hackPhone')
Exports List
Is Phone Open
Will return true of false, depending of opening state of phone.
exports['jpr-phonesystem']:isPhoneOpen() --- return true or false
Close Phone
Will give you the hability to close Phone System via code.
exports['jpr-phonesystem']:closePhone() --- return true or false
Open Phone
Will give you the hability to open Phone System via code.
exports['jpr-phonesystem']:openPhone()
Is Camara Open
Will return true of false, depending of opening state of camera.
exports['jpr-phonesystem']:isCamaraOpen() --- return true or false
Get Phone Number
Will return the current player phone number.
exports['jpr-phonesystem']:getPhoneNumber() --- 96847392
Send Whatsapp
Will send a message to the selected player to whatsapp.
Template:
exports['jpr-phonesystem']:sendWhatsapp(Receiver Number, Sender Number (Can be a name), Message, Type)
Receiver should be the number of player you want to contact; Sender Number can be anything, even a name; Message is what you want to send to player;
Type is the type of message: - "message" - Will send a normal text message; - "gps" - Will send a GPS message (on Message field you need to send the coords); - "image" - Will send a image message (on Message field you need to send a link);
Example:
exports['jpr-phonesystem']:sendWhatsapp("7142903207", "export testing", "export test", "message")
Send iMessage
Will send a message to the selected player to iMessage.
Template:
exports['jpr-phonesystem']:sendiMessage(Receiver Number, Sender Number (Can be a name), Message, Type)
Receiver should be the number of player you want to contact; Sender Number can be anything, even a name; Message is what you want to send to player;
Type is the type of message: - "message" - Will send a normal text message; - "gps" - Will send a GPS message (on Message field you need to send the coords); - "image" - Will send a image message (on Message field you need to send a link);
Example:
exports['jpr-phonesystem']:sendiMessage("7142903207", "export testing", "export test", "message")
All this exports are CLIENT SIDED
Distress Signal
To send a distress signal, use this trigger:
"ambulance" - Means your ambulance job tag "Distress Signal received, please help the citizen!" - Is the message that player will receive
TriggerServerEvent("jpr-phonesystem:server:sendDistressSignal", "ambulance", "Distress Signal received, please help the citizen!")
Last updated