AttributeFix

AttributeFix

114M Downloads

[1.19.2] max attribute not working

itsdinkd opened this issue ยท 3 comments

commented

image

As shown in config, the max value is 10k however in game they cap at 1024.

image

this didn't happen before i ported my modpack to 1.19.2

commented

Thanks for opening the issue report, based on your screenshot it appears the mod is working correctly? The max health is displayed as 2550 and that is the value that would be clamped to 1024 without the mod. The current health of mobs is not affected by this mod and is related to how the mob is spawned, and how custom attribute modifiers are being applied. Here is a command for a spawn egg that should spawn a zombie with 10,000 for both values.

/give @p zombie_spawn_egg{EntityTag:{id:zombie,Health:10000,Attributes:[{Name:"generic.max_health",Base:10000f}]},display:{Name:'[{"text":"10k Health Egg","italic":false}]'}} 1

commented

Hmm I see what you're saying. So I most likely have a confliction somewhere preventing the mob to have max health. It used to spawn with full hp, at least until I ported to 1.19.2

commented

It could be a number of things and really depends on how you are spawning the mobs. For example health is loaded before the max health when using NBT. This is why my example command above sets the base health and the max health.