diff --git a/panda/src/linmath/lvector2.I b/panda/src/linmath/lvector2.I index d71eecece7..78be371947 100644 --- a/panda/src/linmath/lvector2.I +++ b/panda/src/linmath/lvector2.I @@ -199,7 +199,7 @@ template INLINE bool LVector2:: normalize() { NumType l2 = length_squared(); - if (l2 == 0.0) { + if (l2 == (NumType)0.0) { set(0.0, 0.0); return false; diff --git a/panda/src/linmath/lvector3.I b/panda/src/linmath/lvector3.I index 5e73b977b9..81aa9a66a2 100644 --- a/panda/src/linmath/lvector3.I +++ b/panda/src/linmath/lvector3.I @@ -211,7 +211,7 @@ template INLINE bool LVector3:: normalize() { NumType l2 = length_squared(); - if (l2 == 0.0) { + if (l2 == (NumType)0.0) { set(0.0, 0.0, 0.0); return false; diff --git a/panda/src/linmath/lvector4.I b/panda/src/linmath/lvector4.I index fab2837c93..841f0ee850 100644 --- a/panda/src/linmath/lvector4.I +++ b/panda/src/linmath/lvector4.I @@ -222,7 +222,7 @@ template INLINE bool LVector4:: normalize() { NumType l2 = length_squared(); - if (l2 == 0.0) { + if (l2 == (NumType)0.0) { set(0.0, 0.0, 0.0, 0.0); return false;