diff --git a/cocos2d/core/physics/CCPhysicsManager.js b/cocos2d/core/physics/CCPhysicsManager.js index 92816b61b0..335d974e5f 100644 --- a/cocos2d/core/physics/CCPhysicsManager.js +++ b/cocos2d/core/physics/CCPhysicsManager.js @@ -135,7 +135,7 @@ var PhysicsManager = cc.Class({ }, rayCast: function (p1, p2, type) { - if (p1.sub(p2).magSqr() === 0) { + if (p1.equals(p2)) { return []; }