mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-16 09:34:46 +00:00
Fix to setting animation names.
This commit is contained in:
1 parent
354c9808e4
commit
e65ba59b8e
2 files changed
+9
-2
No files matched your search
@@ -888,9 +888,10 @@ public class PacketHandlerServer{
|
||||
}
|
||||
else if (type == EnumPacketServer.AnimationSave) {
|
||||
String prevName = Server.readString(buffer);
|
||||
AnimationController.instance.animations.remove(prevName);
|
||||
Animation animation = new Animation();
|
||||
animation.readFromNBT(Server.readNBT(buffer));
|
||||
if (prevName != null && !prevName.equals(animation.getName()) && AnimationController.instance.has(animation.getName())) {
|
||||
if (AnimationController.instance.has(animation.getName())) {
|
||||
animation.name = prevName;
|
||||
}
|
||||
animation.save();
|
||||
|
||||
Reference in new issue
Block a user