Hello!
I'm kinda new to lua, have experience from VB since before.
I can't get around to understand how hooks work.
Is it possible to use hooks in an function? Or do they need to be outside an function?
If it is, is it also possible to recall that function with a hook in the function? (to make it automatic, will use hook.remove in another function)
Example;
function ulx.XXX()
hook.add("TTTBeginRound","startmodeTG",startatgmode)
hook.add("TTTEndRound","resetinvTG",synligatrait)
hook.add("TTTPrepareRound","callnextroundTG",ulx.XXX) --Is this possible?
end
Are my hooks rightly done?
Edit:
Am I on the right track here thinking that hooks disappear after use? Or are they still active to the next time?
Thanks!
/Oggy