---@param data table
RegisterNetEvent('drx_mdt:client:setWaypoint', function(data)
if type(data) ~= 'table' or type(data.x) ~= 'number' or type(data.y) ~= 'number' then
prints.error('Invalid waypoint data received')
return
end
if IsWaypointActive() then
DeleteWaypoint()
end
SetNewWaypoint(data.x, data.y)
end)