setcallhook

LUA

setcallhook

setcallhook (HOOK)

Sets the function HOOK as the call hook, and returns the old hook. The only argument to the call hook is the event name (“call” or “return”.) Use getinfo with level 2 to get more information about the function being called or returning (level 0 is getinfo, level 1 is the hook.)Without arguments, call hooks are turned off.