mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-17 12:15:11 +00:00
Fixed animations being stuck. Animations should now properly continue where they left off when a player rejoins a server/ singleplayer world.
This commit is contained in:
1 parent
fd4a6d0a2c
commit
266a6515e5
7 files changed
+171
-65
No files matched your search
@@ -375,8 +375,14 @@ public class PacketHandlerClient extends PacketHandlerServer{
|
||||
}
|
||||
|
||||
animationData.setAnimation(ClientCacheHandler.animationCache.get(animationId));
|
||||
animationData.readFromNBT(compound);
|
||||
Client.sendData(EnumPacketServer.CacheAnimation, animationId);
|
||||
animationData.viewReadFromNBT(compound);
|
||||
|
||||
if (compound.hasKey("Frame")) {
|
||||
animationData.animation.readFromNBT(compound.getCompoundTag("Animation"));
|
||||
animationData.animation.jumpToFrameAtTime(compound.getInteger("Frame"), compound.getInteger("Time"));
|
||||
} else if (compound.hasKey("Animation")) {
|
||||
Client.sendData(EnumPacketServer.CacheAnimation, animationId);
|
||||
}
|
||||
}
|
||||
}
|
||||
else if(type == EnumPacketClient.DISABLE_MOUSE_INPUT) {
|
||||
|
||||
Reference in new issue
Block a user