From 5b69c12a88b5d87f99db79bce0928bc87af1a74b Mon Sep 17 00:00:00 2001 From: Dave Schuyler Date: Fri, 25 Jul 2003 23:25:58 +0000 Subject: [PATCH] calling apply_linear_force if node is a PandaNode --- panda/src/collide/collisionHandlerPusher.cxx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/panda/src/collide/collisionHandlerPusher.cxx b/panda/src/collide/collisionHandlerPusher.cxx index 9e551c296e..9d2ec5da3e 100644 --- a/panda/src/collide/collisionHandlerPusher.cxx +++ b/panda/src/collide/collisionHandlerPusher.cxx @@ -170,7 +170,6 @@ handle_entries() { for (sj = shoves.begin(); sj != si; ++sj) { ShoveData &sd2 = (*sj); if (sd2._valid) { - float d = sd._vector.dot(sd2._vector); if (collide_cat.is_debug()) { collide_cat.debug() @@ -185,7 +184,6 @@ handle_entries() { } else { sd._valid = false; } - } else { // These two shoves are not in the same direction. // If they are both from polygons that are a child @@ -259,6 +257,8 @@ handle_entries() { LVecBase3f pos = trans->get_pos(); pos += net_shove * trans->get_mat(); def._node->set_transform(trans->set_pos(pos)); + + apply_linear_force(def, force_normal); } else { // Otherwise, go ahead and do the matrix math to do things // the old and clumsy way. @@ -266,7 +266,6 @@ handle_entries() { def.get_mat(mat); def.set_mat(LMatrix4f::translate_mat(net_shove) * mat); } - apply_linear_force(def, force_normal); } } }