Merge pull request #1609 from TheoXD/_fix_crash_in_viewport_picking

Fixed crash in viewport object picking.
This commit is contained in:
Juan Linietsky 2015-04-07 20:12:19 -03:00
commit 49ca7b5f12
1 changed files with 1 additions and 1 deletions

View File

@ -406,7 +406,7 @@ void Viewport::_notification(int p_what) {
int rc = ss2d->intersect_point(point,res,64,Set<RID>(),0xFFFFFFFF,0xFFFFFFFF);
for(int i=0;i<rc;i++) {
if (res[i].collider) {
if (res[i].collider_id && res[i].collider) {
CollisionObject2D *co=res[i].collider->cast_to<CollisionObject2D>();
if (co) {