Logging all XP gains
Hi all,
I am making a small addon for Classic that logs all XP gains to a SavedVariables file that I can then parse later for analysis. I am struggling a bit with the SavedVariables piece. Hoping someone can help. XPlogger.toc Lua Code:
main.lua Lua Code:
However, I am not seeing the SavedVariables file being written and the XPLogger.TotalXP is reset on /reload. Any help would be appreciated. |
You need to wait until ADDON_LOADED until your savedvariables are available
https://wow.gamepedia.com/Saving_var..._game_sessions Something like this Lua Code:
|
Quote:
i.e. Lua Code:
|
Yes. It is generally preferred that you know what your saved variables are before you try to use them. :)
|
Quote:
Your last script works fine for me. Check if you have any errors by getting BugSack |
Quote:
|
Quote:
The last piece I think is now logging each XP gain in a table. Edit: All sorted. Sharing below for those interested. Lua Code:
Will now write a parser. |
Quote:
|
Quote:
Use at your own risk, I take no responsibility. Code:
private void Button_ParseFile(object sender, RoutedEventArgs e) |
Quote:
|
To continue with this thread, is there a way to catch XP awarded through exploring a new zone? Those don't seem to get captured by CHAT_MSG_COMBAT_XP_GAIN.
Thanks |
All times are GMT -6. The time now is 03:29 PM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI