Phone mails

Welcome to Phone mails

You can completely modify the command from config_commands.lua.

Administrators can send Mails to all players using the command sendmail as in the example that we will give here.

/sendmail Subject Message

Here is a brief example

/sendmail "Important" "Players please disconnect from the server for brief maintenance."

Basic integration

With this system, you can also add Mails in other scripts, such as when making a drug sale or when buying an item.

Basic integration only for Clientside

TriggerServerEvent('qs-smartphone:server:sendNewMail', {
        sender = 'Robby Williams',
        subject = 'Hey bro, how are you?',
        message = 'Soon we will launch more versions and this will be more complete, what are you waiting for to get this great phone brother?',
        button = {}
    })

Advanced integration

This event is already more advanced, since it will work with online and offline players. It will serve for projects that require more information.

RegisterCommand("emailexample", function(source, args)
    local identifier = args[1]
    local data = {}
    data.sender = args[2] -- Sender
    data.subject = args[3] --  Subject
    data.message = args[4] -- Message
    data.button = args[5] -- Button, not neccesary
    TriggerServerEvent('qs-smartphone:server:sendNewMailToOffline', identifier, data)
end, false)

Last updated