New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
level and multiplier is not set after ReloadUI() #16
Comments
PEW is unregistered after first use. I think the github version has a fix for this already, will test later today, I'm not sure if I have unpushed changes locally right now. |
It only needs to run on the first PEW so that is fine. It is only immediately after a reload that we need to force an update, because no other event is triggering an update. |
Which LAD version are you using? I can't reproduce this, neither with the current github version, nor with the released 1.2. |
I was using revision 18 from GitHub. Let me see if I can figure out some steps to reproduce it for you. |
Okay I did a new round of tests where I created a test addon which just embedded the necessary libraries to run LibArtifactData-1.0, and you are right, it works fine after a /reload. It must be an issue with how early I am trying to get data from it. Sorry for the confusion, you can close this. |
Just register the lib's ARTIFACT_KNOWLEDGE_CHANGED event. With revision 18 and above you don't have to handle the ARTIFACT_DATA_MISSING event for artifact knowledge anymore |
When doing a /reload the artifacts.knowledgeLevel and artifacts.knowledgeMultiplier fields are not being set. This can be fixed by adding a conditional ScanEquipped() to the PLAYER_ENTERING_WORLD event function.
This will ensure that lib.GetArtifactKnowledge() returns the proper values after a /reload.
The text was updated successfully, but these errors were encountered: