Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
Simple: What's the most efficient way to hook OnPlayerUpdate? People have always said CallLocalFunction and/or CallRemoteFunction are slow.
Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
What about hooking a public function for a timer? Same method?
Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
Ah okay, this is very helpful, thanks. Just a bit annoying to have to 'define' the hooks though - not as easy as just 'Hook:' with y_hooks :/
Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
Hook: doesn't work with non-native callbacks though (such as a timer function), right? I tried that and it didn't work.
What about hooking it multiple times? In 3 different files?
Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
So if I wanted to 'chain' multiple callbacks, I'd add the ALS stuff at the bottom of the already-hooked one? But that'll be hard to maintain if I include a file between the two hooked ones?
Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
If they're called like this:
OnPlayerUpdate > MY_x > Your_x
If you remove MY_x, doesn't that mean Your_x will never be called? Because it's not being 're-directed' or whatever there? What if I have 100+ hooks and need to remove one in the middle?
Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
I see. ALS is pretty clever. Thanks.
Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
Yeah, I just did some testing now to see what exactly what would happen.