Wolves with owners revert to vanilla attributes
Summary
Setting the owner of a custom Wolf mob seems to revert the wolf's attributes to those of a vanilla wolf - 20 HP and 3-6 damage depending on difficulty. This even occurs when setting the Wolf's owner on spawn, or through the 'summon' mechanic.
Upon further investigation, I found MC-193202 on the Minecraft bug tracker - a bug still in the game which causes the NBT data of tamed wolves to unintentionally reset, likely due to wolves having different attributes once tamed. It's likely this bug is related, as I can't think of any reason why MythicMobs itself would reset these values.
Through my testing, the wolf's initial custom stats are set as intended, but are then immediately overwritten with the vanilla attributes.
Testing
I tested the following Wolf mob which is part of a project of mine.
BestFriendWolf:
Type: WOLF
Display: '&2Wolf Companion &6[&c<caster.hp>&6/&c<caster.mhp>&6]'
Health: 16
Damage: 6
LevelModifiers:
Health: 6
Damage: 1
Faction: Allies
Options:
AlwaysShowName: true
Despawn: chunk
PreventOtherDrops: true
AIGoalSelectors:
- clear
- meleeattack
- gotoowner 6
- lookatplayers
AITargetSelectors:
- ownertarget
- ownerattacker
- attacker
Skills:
- remove{delay=600} @self ~onSpawn
First of all, you'll notice the mob's HP display isn't set to update - this is to test and affirm that the HP is in fact set on spawn. The mob's name ingame shows an HP of 16 (or the appropriate value, when spawned at a higher level).
However, when I spawn the mob and punch it in order to gauge it's HP, it in fact has 20 HP, not 16. On top of this, when the mob attacks others, it only deals 4 damage instead of 6 (which is the vanilla amount of damage, as my server is running on Normal difficulty.).
This occurs when spawning the mob through a summon mechanic with summonerIsOwner set to true, or when adding a new skill that sets the Wolf's owner.
However, if the mob is spawned without an owner, it functions as intended - hence why I believe the wolf owner mechanic in Minecraft to be the problem.
Conclusion
As this is a vanilla issue, I don't expect any kind of miracle fix to completely squash out the issue. It's entirely possible to work around this bug using your own onSpawn mechanics with a delay of a few ticks.
However, I wanted to report the issue, as other unsolved issues on this tracker seem to point to the same problem.
On top of that, I'm sure a workaround could be implemented by cancelling or overriding the event which resets the mob's attribute values, or by setting the values again after the wolf's owner is defined, but I haven't touched Spigot code in a long time so that isn't for me to say.