mirror of
https://github.com/gmod-integration/lua.git
synced 2025-03-16 06:37:34 +00:00
move hooks cl_hook
This commit is contained in:
parent
f5a707eea4
commit
7a3f3d3c9e
8
lua/gmod_integration/client/cl_hook.lua
Normal file
8
lua/gmod_integration/client/cl_hook.lua
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
//
|
||||||
|
// Hook
|
||||||
|
//
|
||||||
|
|
||||||
|
// Player Finish Init
|
||||||
|
hook.Add("InitPostEntity", "gmInte:Ply:Ready", function()
|
||||||
|
gmInte.SendNet(0)
|
||||||
|
end)
|
|
@ -1,19 +0,0 @@
|
||||||
// Networking
|
|
||||||
|
|
||||||
/*
|
|
||||||
Upload
|
|
||||||
0 - Say I'm ready
|
|
||||||
Receive
|
|
||||||
*/
|
|
||||||
|
|
||||||
// net function
|
|
||||||
function gmInte.SendNet(id, args)
|
|
||||||
net.Start("gmIntegration")
|
|
||||||
net.WriteUInt(id, 8)
|
|
||||||
net.WriteString(util.TableToJSON(args || {}))
|
|
||||||
net.SendToServer()
|
|
||||||
end
|
|
||||||
|
|
||||||
hook.Add("InitPostEntity", "gmInte:Ply:Ready", function()
|
|
||||||
gmInte.SendNet(0)
|
|
||||||
end)
|
|
Loading…
Reference in New Issue
Block a user