[Need Help] Darknet chat whitelisted

Hellooo,

i scripted a little simple “darknet chat” script an i want to add something like a “whitelist” that only people who are written in with Steam license can write in the Darknet

here is the code :

server.lua

RegisterCommand("drknt", function(source, args, rawCommand)
    local message = table.concat(args, " ")

    TriggerClientEvent("chatMessage", -1, "[" .. source .. "] " .. "DarkNetChat", {173,32,32},  message)
end)


function stringsplit(inputstr, sep)
    if sep == nil then
        sep = "%s"
    end
    local t={} ; i=1
    for str in string.gmatch(inputstr, "([^"..sep.."]+)") do
        t[i] = str
        i = i + 1
    end
    return t
end

sorry for bad englisch :slight_smile: