πCreate Task
The basics of how to create a new task.
RegisterNetEvent('--:client:CreateTask')
AddEventHandler('--:client:CreateTask', function()
local TaskTitle = 'Task Title'
local taskDescription = 'Task Description'
local taskIcon = 'fas fa-check'
local taskStatusComplete = false
TriggerServerEvent('--:server:AddGroupTask', GroupID, TaskTitle, taskDescription, taskIcon, taskStatusComplete)
end)-- #ADD GROUP TASK# --
RegisterServerEvent('--:server:AddGroupTask')
AddEventHandler('--:server:AddGroupTask', function(groupID, taskTitle, taskDescription, taskIcon, taskStatusComplete)
local src = source
exports["nelo-tablet"]:NeloAddGroupTask(groupID, taskTitle, taskDescription, taskIcon, taskStatusComplete)
end)
TriggerServerEvent('--:server:ShowTaskGroup', GroupID) -- #SHOW TASK GROUP# --
RegisterServerEvent('--:server:ShowTaskGroup')
AddEventHandler('--:server:ShowTaskGroup', function(groupID)
local src = source
exports["nelo-tablet"]:NeloNotifyGroup(groupID, src)
end)true = completed
false = not completed
When the task is completed, it is automatically removed from the .json file and taken off the screen.
Last updated