mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-03 23:07:40 +01:00
SPIGOT-401: Add async catcher for mob effects.
This commit is contained in:
parent
4cd535b41d
commit
4988864512
@ -25,6 +25,18 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
|
||||
public int a(Random random) {
|
||||
return 1;
|
||||
diff --git a/src/main/java/net/minecraft/server/EntityLiving.java b/src/main/java/net/minecraft/server/EntityLiving.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/net/minecraft/server/EntityLiving.java
|
||||
+++ b/src/main/java/net/minecraft/server/EntityLiving.java
|
||||
@@ -0,0 +0,0 @@ public abstract class EntityLiving extends Entity {
|
||||
}
|
||||
|
||||
public void addEffect(MobEffect mobeffect) {
|
||||
+ org.spigotmc.AsyncCatcher.catchOp( "effect add"); // Spigot
|
||||
if (this.d(mobeffect)) {
|
||||
if (this.effects.containsKey(Integer.valueOf(mobeffect.getEffectId()))) {
|
||||
((MobEffect) this.effects.get(Integer.valueOf(mobeffect.getEffectId()))).a(mobeffect);
|
||||
diff --git a/src/main/java/net/minecraft/server/EntityTracker.java b/src/main/java/net/minecraft/server/EntityTracker.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/net/minecraft/server/EntityTracker.java
|
||||
|
Loading…
Reference in New Issue
Block a user