#Vanilla bug, knockback cause creature disappear.

9 messages · Page 1 of 1 (latest)

frank bear
#

vanilla method "knockback" in "EntityLivingBase" class has a bug, when both xRatio == 0 && zRatio == 0, will cause creatures be attacked disappear, this issue happened in dragon weapon knockback.
How to reproduce?
use a fireblood saber and use /summon commnad summon a husk(or any other creatures), and hit it with that weapon instantly, the creature will disappear instead of being knockbacked!

jaunty cypress
#

instantly means tick perfect hit?

#

doesnt happen to me otherwise

#

you could also send the log when it happens

sweet flint
#

Yea will prob create a crashlog even though it doesnt crash. But if this is command only then who cares

frank bear
#

when player and creatures collision box's x and z overlaped, the will be happened 🙂

sweet flint
#
events.onLivingKnockBack(function(event as crafttweaker.event.LivingKnockBackEvent){
if(event.ratioX == 0 && event.ratioZ == 0)
  event.ratioX = 1;
});
#

this puts kb dir in +x now, you could ofc also randomise it