[3.3.5] Core/Pet: Fix PetSpellMap <-> DB sync#20112
Conversation
|
I'm not intricately familiar with the relevant code paths. Could you outline the incorrect logic vs your correct fix? |
|
The idea - as far as I understood after analyzing the code - is that
There are currently two occurrences of I originally just noticed that the pet bar autocast issue only happens when there are entries for different ranks of the same spell in the But why did my previous patch seem to have fixed autocast settings? |
|
👍 great analysis and good catch |
|
Seems you integrated a slightly different fix. Guess that's alright. It reminds me to keep my work in a separate branch (3.3.5-my_work) to avoid merge conflicts when pulling "3.3.5" from upstream. :-) |
|
You can simply base your branches on |
PetSpellMapentries withstate == PETSPELL_REMOVEDmust not be erased before DB sync.characters.pet_spellscheckedThe previous patch was only a partial fix for the issue and didn't actually address the root cause, which is
PetSpellMapandcharacters.pet_spellare getting out of sync. The current fix only helps with (ranked non-talent) spells that are toggled on the pet action bar, because those are also written tocharacters.character_pet.Ranked non-talent spells that are not on the pet action bar, but put on auto via the pet spell book only are not correctly remembered without this second fix.