The formula you've used to check which level a custom Animal Companion advances relies on checking the size it advances to. However certain Animal Companions, such as the Wolfdog and Yak introduced in Ultimate Wilderness, do not increase in size upon advancement.
However filling in the same size as pre-advancement breaks stat calculation, as the table for stat modifiers for size changes lacks entires for Large/Large, etc., and stat advancement calculation does not check whether a lookup is necessary.
Proposed solution: Determine custom Animal Companion advancement based on entry in any advancement field, rather than just size.
Anonymous
Thanks for the report!
Yeah, that shouldn't be like that. I need to completely redo companions at some point.
I've put in your suggested changes for 9.04