mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-12 02:37:27 +00:00
Remove more threading
This commit is contained in:
1 parent
49fab85291
commit
f77a2ff101
3 files changed
+10
-15
No files matched your search
@@ -51,17 +51,15 @@ public class Server {
|
||||
}
|
||||
|
||||
public static void sendAssociatedData(final Entity entity, final EnumPacketClient enu, final Object... obs) {
|
||||
CustomNPCsThreader.runTack(() -> {
|
||||
ByteBuf buffer = Unpooled.buffer();
|
||||
try {
|
||||
if(!fillBuffer(buffer, enu, obs))
|
||||
return;
|
||||
TargetPoint point = new TargetPoint(entity.dimension, entity.posX, entity.posY, entity.posZ, 60);
|
||||
CustomNpcs.Channel.sendToAllAround(new FMLProxyPacket(buffer,"CustomNPCs"), point);
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
});
|
||||
ByteBuf buffer = Unpooled.buffer();
|
||||
try {
|
||||
if(!fillBuffer(buffer, enu, obs))
|
||||
return;
|
||||
TargetPoint point = new TargetPoint(entity.dimension, entity.posX, entity.posY, entity.posZ, 60);
|
||||
CustomNpcs.Channel.sendToAllAround(new FMLProxyPacket(buffer,"CustomNPCs"), point);
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
public static void sendToAll(EnumPacketClient enu, Object... obs) {
|
||||
ByteBuf buffer = Unpooled.buffer();
|
||||
|
||||
Reference in new issue
Block a user