summaryrefslogtreecommitdiffstats
path: root/nms-patches/EntityTurtle.patch
blob: 0a4df9659a0bcccc34e9463891737d46b9190237 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
--- a/net/minecraft/server/EntityTurtle.java
+++ b/net/minecraft/server/EntityTurtle.java
@@ -231,7 +231,9 @@
 
     protected void l() {
         super.l();
+        this.forceDrops = true; // CraftBukkit
         this.a((IMaterial) Items.SCUTE, 1);
+        this.forceDrops = false; // CraftBukkit
     }
 
     public void a(float f, float f1, float f2) {
@@ -260,7 +262,9 @@
     }
 
     public void onLightningStrike(EntityLightning entitylightning) {
+        org.bukkit.craftbukkit.event.CraftEventFactory.entityDamage = entitylightning; // CraftBukkit
         this.damageEntity(DamageSource.LIGHTNING, Float.MAX_VALUE);
+        org.bukkit.craftbukkit.event.CraftEventFactory.entityDamage = null; // CraftBukkit
     }
 
     public void die(DamageSource damagesource) {