From 00c687b4d87c3eb986da8dd6a94cdb206348ebac Mon Sep 17 00:00:00 2001 From: Dokthar Date: Sat, 21 Nov 2015 13:06:30 +0100 Subject: [PATCH] fix #383 : in PhysicsRigidBody the old statement in read() (l.741) was always false --- .../main/java/com/jme3/bullet/objects/PhysicsRigidBody.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jme3-bullet/src/main/java/com/jme3/bullet/objects/PhysicsRigidBody.java b/jme3-bullet/src/main/java/com/jme3/bullet/objects/PhysicsRigidBody.java index 6f6eb4d76..0342f4c77 100644 --- a/jme3-bullet/src/main/java/com/jme3/bullet/objects/PhysicsRigidBody.java +++ b/jme3-bullet/src/main/java/com/jme3/bullet/objects/PhysicsRigidBody.java @@ -737,8 +737,8 @@ public class PhysicsRigidBody extends PhysicsCollisionObject { setKinematic(capsule.readBoolean("kinematic", false)); setRestitution(capsule.readFloat("restitution", 0)); - Vector3f angularFactor = (Vector3f) capsule.readSavable("angularFactor", Vector3f.NAN.clone()); - if(angularFactor == Vector3f.NAN) { + Vector3f angularFactor = (Vector3f) capsule.readSavable("angularFactor", null); + if(angularFactor == null) { setAngularFactor(capsule.readFloat("angularFactor", 1)); } else { setAngularFactor(angularFactor);