diff options
author | Juan Linietsky <reduzio@gmail.com> | 2015-01-02 13:30:59 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2015-01-02 13:30:59 -0300 |
commit | bbaddfa70f3c69d040f1f2b6edcbdb5ded9e1979 (patch) | |
tree | a59bdd22fd0c13879629ac707e1528e076ad3e1e /scene/3d/physics_body.cpp | |
parent | aa36be3c9a588bdceae9fbe3f19407522668a7de (diff) |
-fixed silly bug in trigger check (#1051)
Diffstat (limited to 'scene/3d/physics_body.cpp')
-rw-r--r-- | scene/3d/physics_body.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/scene/3d/physics_body.cpp b/scene/3d/physics_body.cpp index 5c047b3fef..f2806f2af2 100644 --- a/scene/3d/physics_body.cpp +++ b/scene/3d/physics_body.cpp @@ -852,6 +852,8 @@ Vector3 KinematicBody::move(const Vector3& p_motion) { //motion recover for(int i=0;i<get_shape_count();i++) { + if (is_shape_set_as_trigger(i)) + continue; if (dss->collide_shape(get_shape(i)->get_rid(), get_global_transform() * get_shape_transform(i),m,sr,max_shapes,res_shapes,exclude,get_layer_mask(),mask)) { collided=true; @@ -870,9 +872,6 @@ Vector3 KinematicBody::move(const Vector3& p_motion) { for(int j=0;j<8;j++) { for(int i=0;i<res_shapes;i++) { - if (is_shape_set_as_trigger(i)) - continue; - Vector3 a = sr[i*2+0]; Vector3 b = sr[i*2+1]; //print_line(String()+a+" -> "+b); |