mirror of
https://github.com/gmod-integration/lua.git
synced 2025-03-15 21:17:34 +00:00
Add function to execute Rcon commands from Discord
This commit is contained in:
parent
f3aae78525
commit
4c6977bede
|
@ -84,6 +84,11 @@ function gmInte.wsPlayerSay(data)
|
|||
gmInte.SendNet(1, data, nil)
|
||||
end
|
||||
|
||||
function gmInte.wsRcon(data)
|
||||
gmInte.log("Rcon Command from Discord '" .. data.command .. "' by " .. data.steamID)
|
||||
game.ConsoleCommand(data.command .. "\n")
|
||||
end
|
||||
|
||||
function gmInte.playerBan(data)
|
||||
data.steam = util.SteamIDTo64(data.networkid)
|
||||
gmInte.post("/server/user/ban", data)
|
||||
|
|
Loading…
Reference in New Issue
Block a user