GetDKP for EQdkp-Plus

GetDKP for EQdkp-Plus

50k Downloads

Sending Data and Asking for Data doesnt work

taker2one opened this issue ยท 5 comments

commented

Hello,

I noticed that sending and asking for data (buttons in config window) doesnt work atm in WoW-Classic.

The problem seems to be that it is not possible anymore to get arguments for events if they are set in the xml file and will therefore be nil inside of the handler.
I debugged the GetDKP_Config_OnEvent eventhandler and found out that the arguments are always nil.
I remembered that i heard about that problem, tried the fix and it worked like a charm.

How did i fix this:
GetDKPConfig.xml
Remove Line 109-111
<!--<OnEvent> GetDKP_Config_OnEvent(self, event); </OnEvent>-->

Register eventhandler in GetDKPConfig.lua
this:SetScript("OnEvent", GetDKP_Config_OnEvent);

We will be using this addon the first time tomorrow while raiding and i dont know if there is maybe any similar problem where event arguments are needed but not set because of the same problem in an other file.

commented

Not sure, there is no official documentation regarding such a change. Do you have any source for this?

Nevertheless, most pages uses this method. not sure if there is a negative impact. I added your fix to the source, please check If I implemented it correctly.

commented

I have no real source for that, i just googled the problem that the arguments are always nil and some guys said they heard about such a change and so i just trie it and it worked.

But I'm sorry cause I forgot to mention that it is also neccessary to change the parameter of the onevent function itself.

function GetDKP_Config_OnEvent(self, event, ... ) local arg1, arg2, arg3, arg4 = ...;

I spent so much time today to analyse the not working sync that i did not remeber every change.

commented

then please send me your file to [email protected]. I will then check. I cannot test it as I am not in a raid.

commented

I created a pull request with the file version that works for me, i thought that would be easier for you :)

commented

thanks a lot

#2