SPIGOT-6560: Crash when falling stalactite hits player

By: md_5 <git@md-5.net>
This commit is contained in:
CraftBukkit/Spigot 2021-06-15 08:01:07 +10:00
parent 46666cb5a8
commit 752618d75f

View file

@ -876,7 +876,7 @@ public class CraftEventFactory {
} else if (blockDamage != null) {
DamageCause cause = null;
Block damager = blockDamage;
if (source == DamageSource.CACTUS || source == DamageSource.SWEET_BERRY_BUSH || source == DamageSource.STALAGMITE || source == DamageSource.ANVIL) {
if (source == DamageSource.CACTUS || source == DamageSource.SWEET_BERRY_BUSH || source == DamageSource.STALAGMITE || source == DamageSource.FALLING_STALACTITE || source == DamageSource.ANVIL) {
cause = DamageCause.CONTACT;
} else if (source == DamageSource.HOT_FLOOR) {
cause = DamageCause.HOT_FLOOR;