Fix Animation IDs

This commit is contained in:
Kam committed 2023-11-06 20:53:21 -05:00
1 parent f1c153bdfe
commit 0e13c28939
1 file changed
+7 -1
@@ -172,7 +172,13 @@ public class Animation implements IAnimation {
}
public void readFromNBT(NBTTagCompound compound){
id = compound.getInteger("ID");
if(compound.hasKey("ID")){
id = compound.getInteger("ID");
}
else {
id = AnimationController.Instance.getUnusedId();
}
name = compound.getString("Name");
speed = compound.getFloat("Speed");
smooth = compound.getByte("Smooth");