This is a dev resource, you are supposed to add the functionality yourself, but here is an example:
add this to server.lua:
local characters = {}
RegisterCommand("setid", function(source, args, rawCommand)
if (source > 0) then
local data = {
FirstName = args[1] or (characters[source] and characters[source].FirstName) or "John",
LastName = args[2] or (characters[source] and characters[source].LastName) or "Doe",
DOB = args[3] or (characters[source] and characters[source].DOB) or "2/22/1999",
Issue = os.date("%x"),
CitizenID = "-",
Sex = "-",
Hair = "-",
Height = "-",
Eyes = "-",
Image = "images/placeholder.png",
Format = "id"
}
characters[source] = data
TriggerClientEvent('chat:addMessage', source, { args = { 'ID: ', "You succesfully set your id to: "..data.FirstName.." "..data.LastName..", "..data.DOB } })
else
print("setid command was executed by the server console, RCON client, or a resource, this should not happen.")
end
end, false)
RegisterCommand("showid", function(source, args, rawCommand)
if (source > 0) then
if characters[source] then
TriggerClientEvent('licenses:showToClosest', source, characters[source])
else
TriggerClientEvent('chat:addMessage', source, { args = { 'ID: ', "You haven't set your id, use /setid first!" } })
end
else
print("showid command was executed by the server console, RCON client, or a resource, this should not happen.")
end
end, false)
and this to client.lua if you wish to give them some help:
TriggerEvent('chat:addSuggestion', '/setid', "sets your id", {
{ name="Firstname", help="The first name of your character", },
{ name="Lastname", help="The last name of your character", },
{ name="DOB", help="Date of Birth", }
})
TriggerEvent('chat:addSuggestion', '/showid', "Shows your id to the closest person, use /setid to set your id.")
Remember to disable the example.lua file if you haven’t as it contains a showid command their aswell. I hope this helped, you can add more arguments if you wish.