add chat sync to discord

This commit is contained in:
Linventif 2023-09-20 17:23:20 +02:00
parent c290e31465
commit a06ece834e

View File

@ -1,26 +1,36 @@
//
// Hooks
// Server
//
// Server
hook.Add("ShutDown", "gmInte:Server:ShutDown", function()
gmInte.serverShutDown(ply)
gmInte.serverShutDown()
end)
// set convar sv_hibernate_think to 1
hook.Add("Initialize", "gmInte.sendStatus", function()
timer.Simple(1, function()
gmInte.serverStart()
gmInte.sendStatus()
end)
end)
//
// Player
//
gameevent.Listen("player_connect")
hook.Add("player_connect", "gmInte:Player:Connect", function(data)
gmInte.playerConnect(data)
end)
hook.Add("PlayerDisconnected", "gmInte:Player:Disconnect", function(ply)
gmInte.playerDisconnected(ply)
end)
hook.Add("onPlayerChangedName", "gmInte:PlayerChangeName", function(ply, old, new)
gmInte.playerChangeName(ply, old, new)
end)
hook.Add("PlayerSay", "gmInte:PlayerSay", function(ply, text, team)
gmInte.playerSay(ply, text, team)
end)