@Override public void read(JmeImporter im) throws IOException { InputCapsule input = im.getCapsule(this); Savable[] jointRootsAsSavable = input.readSavableArray("rootJoints", null); rootJoints = new Joint[jointRootsAsSavable.length]; System.arraycopy(jointRootsAsSavable, 0, rootJoints, 0, jointRootsAsSavable.length); Savable[] jointListAsSavable = input.readSavableArray("jointList", null); jointList = new Joint[jointListAsSavable.length]; System.arraycopy(jointListAsSavable, 0, jointList, 0, jointListAsSavable.length); String className = input.readString("modelTransformClass", MatrixJointModelTransform.class.getCanonicalName()); try { modelTransformClass = (Class<? extends JointModelTransform>) Class.forName(className); } catch (ClassNotFoundException e) { throw new AssetLoadException("Cannnot find class for name " + className); } int i = 0; for (Joint joint : jointList) { joint.setId(i++); instanciateJointModelTransform(joint); } createSkinningMatrices(); for (Joint rootJoint : rootJoints) { rootJoint.update(); } applyInitialPose(); }