diff options
author | tahg <tahgtahv@gmail.com> | 2011-03-02 11:00:16 -0800 |
---|---|---|
committer | tahg <tahgtahv@gmail.com> | 2011-03-02 11:00:16 -0800 |
commit | 34458efd83fe1119448c660924296347ef03c6d6 (patch) | |
tree | 45ac28c4bf10d3b1e58c846f985be65c82a8cafd /src/main/java/net/minecraft/server/EntityTracker.java | |
parent | 9a264ed666902c1790287d7659b1f4a0e47f696e (diff) | |
download | craftbukkit-34458efd83fe1119448c660924296347ef03c6d6.tar craftbukkit-34458efd83fe1119448c660924296347ef03c6d6.tar.gz craftbukkit-34458efd83fe1119448c660924296347ef03c6d6.tar.lz craftbukkit-34458efd83fe1119448c660924296347ef03c6d6.tar.xz craftbukkit-34458efd83fe1119448c660924296347ef03c6d6.zip |
Synchronized EntityTracking
Diffstat (limited to 'src/main/java/net/minecraft/server/EntityTracker.java')
-rw-r--r-- | src/main/java/net/minecraft/server/EntityTracker.java | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/main/java/net/minecraft/server/EntityTracker.java b/src/main/java/net/minecraft/server/EntityTracker.java index 4776bc3b..fbb6f6ee 100644 --- a/src/main/java/net/minecraft/server/EntityTracker.java +++ b/src/main/java/net/minecraft/server/EntityTracker.java @@ -17,7 +17,7 @@ public class EntityTracker { this.d = minecraftserver.f.a(); } - public void a(Entity entity) { + public synchronized void a(Entity entity) { if (entity instanceof EntityPlayer) { this.a(entity, 512, 2); EntityPlayer entityplayer = (EntityPlayer) entity; @@ -61,7 +61,7 @@ public class EntityTracker { this.a(entity, i, j, false); } - public void a(Entity entity, int i, int j, boolean flag) { + public synchronized void a(Entity entity, int i, int j, boolean flag) { if (i > this.d) { i = this.d; } @@ -78,7 +78,7 @@ public class EntityTracker { } } - public void b(Entity entity) { + public synchronized void b(Entity entity) { if (entity instanceof EntityPlayer) { EntityPlayer entityplayer = (EntityPlayer) entity; Iterator iterator = this.a.iterator(); @@ -98,7 +98,7 @@ public class EntityTracker { } } - public void a() { + public synchronized void a() { ArrayList arraylist = new ArrayList(); Iterator iterator = this.a.iterator(); @@ -126,7 +126,7 @@ public class EntityTracker { } } - public void a(Entity entity, Packet packet) { + public synchronized void a(Entity entity, Packet packet) { EntityTrackerEntry entitytrackerentry = (EntityTrackerEntry) this.b.a(entity.id); if (entitytrackerentry != null) { @@ -134,7 +134,7 @@ public class EntityTracker { } } - public void b(Entity entity, Packet packet) { + public synchronized void b(Entity entity, Packet packet) { EntityTrackerEntry entitytrackerentry = (EntityTrackerEntry) this.b.a(entity.id); if (entitytrackerentry != null) { @@ -142,7 +142,7 @@ public class EntityTracker { } } - public void a(EntityPlayer entityplayer) { + public synchronized void a(EntityPlayer entityplayer) { Iterator iterator = this.a.iterator(); while (iterator.hasNext()) { |