lua/lua/gmod_integration/client/cl_hook.lua
2024-02-16 14:26:27 +01:00

19 lines
401 B
Lua

//
// Hook
//
// Player Finish Init
hook.Add("InitPostEntity", "gmInte:Ply:Ready", function()
gmInte.SendNet("ready")
end)
hook.Add("OnPlayerChat", "gmInte:OnPlayerChat:AdminCmd", function(ply, strText, bTeamOnly, bPlayerIsDead)
if (ply != LocalPlayer()) then return end
strText = string.lower(strText)
if (strText == "/gmi") then
gmInte.openAdminConfig()
return true
end
end)