Client::OPMemorizeSpell
Hello all,
first i'am not sure where to post this under wich dev section. So feel free to move to the correct section. :) I'am working on some code and have find a strange bug and not sure where this comes from. I have add some code to the Client::OPMemorizeSpell function. Code:
// Custom - Used for disabling scribes more than given number The code works so far when a user tries to scribe a spell and reached the maximum scribe number he gets this message and the spells will not be scribed. So far so good. :) But on the client something strange happend. The user get the info from server spell is not scribed but the gui is not responding anymore. I can't click on npc's or door's. Keys also don't work anymore so i cant open any windows like inventory. I can open dialogs like inventory only over the menu. Buttons stills works but it seems the gui is not responding anymore to hotkeys. If i open one of the dialogs like inventory over the menu it shows up but it takes no input from mouse. This happend to any menu i call over the menu. I can click into the chat input window and still can type some commands. So when i use the #zone command to leave the zone the gui seems to work like it should. It only happend when i try to use the custom code i posted above. Some more infos: I compile under windows with visual studion 2013 in X64 mode. The client iam testing at the moment is underfoot(steam). Thanks in advance!!! (Going to work now. Maybe i can respond later from work.) |
Total guess, but the client probably assumes scribing will succeed under normal circumstances and gets stuck in scribe-mode waiting for a packet.
I would try: Code:
UnscribeSpell(memspell->slot, true); Alternatively: Code:
MemorizeSpell(memspell->slot, 0xFFFFFFFF, memSpellScribing); I am moderately confident that the first one might work. |
Quote:
i will check this later at home when iam back from work. :) |
Hello,
it works now. But you need to answer with the MemorizeSpell(memspell->slot, 0xFFFFFFFF, memSpellScribing). I think it has to do with the fact that when the client wants to write a valid spell to the spellbook it send the packet for scribing a spell. So you need to answer with the correct packet i think. Code:
// Custom - Used for disabling scribes more than given number The only side effect is that you see the answer unknown spell written etc... But thats ok since i can send the information to the client whats the real problem. :) Thank you very much for the nice hint Zaela_S. |
All times are GMT -4. The time now is 07:24 AM. |
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.