Build yourself a small filter that ignores non-lockables, maybe add a static method to CollisionFilter that creates a filter from a lambda, and pass it to the query. Off goes the loop and everything. ;)