hooking the same packet twice.
Moderator: POL Developer
hooking the same packet twice.
I accidentally hooked the same packet twice. whenever I logged into the server it would crash without generating a dump. just wanted to let you know. odd that pol didn't report this somehow when it was initializing the hooks. not really a big thing, but would have saved me a few hours time if it had complained about it (yeah, it was totally my fault to begin with)
Re: hooking the same packet twice.
Just reading the code, it seems to already care for multiply defined packets, logging them. Would you mind posting the crash dump?
Re: hooking the same packet twice.
as i said, there was no dump generated. the console said it was generating one, but it just created an empty file.
Re: hooking the same packet twice.
Ouch :/
Sorry, didn't read the "without". Weird, very weird.
Sorry, didn't read the "without". Weird, very weird.
Re: hooking the same packet twice.
Nando, where you need to look is the definition of incoming/outgoing script references for it. You can define the same packet in multiple locations for separate packages handling subcommands (iirc). So it's the definition of main packet that needs to be worried about also.
If you still have trouble, I can try getting time through the week to look at it after work or something, if the wife doesn't decide to do a lot of shopping this week, lol.
If you still have trouble, I can try getting time through the week to look at it after work or something, if the wife doesn't decide to do a lot of shopping this week, lol.
Re: hooking the same packet twice.
Core reports the error, but, goes on and let's it load. Check start.log to see if it was listed in there when initializing the packethooks. Should say something:
Code: Select all
Packet hook receive function multiply defined for packet <your packet ID here>