I’m trying to use physics.queryAABB with the category filters mentioned in the reference. I can’t get it to work - any call to queryAABB with more than 2 arguments returns nil.
I circumvented the problem, but I’m curious - did I do something wrong? Sample code below:
@Fktor Getting rid of the categories, this returns 3 entries, but two are duplicates. Why 3, I don’t know. Supposedly using the categories ignores physics.objects.
for a,b in pairs(query) do
Looking through the code it seems like the category filtering isn’t working at the moment because it doesn’t exist. So the documentation is wrong in that sense.
As for duplicates, this is a bug due to the way non-convex polygons are decomposed into a series of convex polygons, meaning you can get the same “body” twice. I’m planning to fix these issues along with the problems with raycast in the next update.
Okey, thanks for the answer