Burning Blossom damage spam with NoDami caused by setting entity on fire every tick
Kaleidio opened this issue ยท 4 comments
What's the issue you encountered?
public void entityInside(BlockState stateIn, World worldIn, BlockPos pos, Entity entityIn)
{
Block block = stateIn.getBlock();
if (entityIn instanceof LivingEntity)
{
if (block == BOPBlocks.burning_blossom)
{
(entityIn).setSecondsOnFire(1);
}
}
}
this code has a flaw as it assumes the entity is going to apply its own invincibility frames. entityInside
fires per tick, instead of acting as an event for when collision began. setting seconds on fire constantly will ignore any timers previously set which allows the NoDami mod to spam damage. this cannot be fixed on NoDami's side as it cannot assume all mods want the same burning behaviour
How can the issue be reproduced?
install NoDami
touch the BurningBlossom
Logs
n/a
Mod Version
any
Additional information
No response
I don't need the change in 1.19.3 as I was looking for 1.16.5, but I assume it would work as long as you haven't used setSecondsOnFire in a tick fashion (maybe an event or a simple state bool of some kind). that's the only way that could cause the issue. I assume 1.16.5 no longer has support then.