I have a DarkRP server and i am trying to create a simple lua.
The thing that im trying to do is: when a hitman accepts the hit the hitman automaticly say “/ad Hit Accepted.”
But nothing happens when i execute the lua with “lua_openscript”
Here’s the code, what am i doing wrong?
function hitman( ply, text, team )
if onHitAccept then
ply:ConCommand("say /ad Hit Accepted.")
end
end
hook.Add("ConCommand" , "hitserverside" , hitman)
Thanks.