Skip to content

Commit

Permalink
Starfish cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
MysticKoko committed Dec 22, 2024
1 parent 986bbd0 commit cfc6cba
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -145,10 +145,10 @@ class StarfishEntity(entityType: EntityType<out StarfishEntity>, world: World) :
return PlayState.CONTINUE
}

override fun damage(source: DamageSource?, amount: Float): Boolean {
override fun damage(source: DamageSource, amount: Float): Boolean {
if (super.damage(source, amount)) {

val attacker = source?.attacker
val attacker = source.attacker
if (this.variant?.variantName == "crown_of_thorns" && attacker is LivingEntity && attacker.mainHandStack.isEmpty) {
attacker.damage(this.damageSources.thorns(this), 2.0f)
attacker.addStatusEffect(StatusEffectInstance(StatusEffects.POISON, 200, 1))
Expand Down

0 comments on commit cfc6cba

Please sign in to comment.