Page 1 of 1

BillboardSet and setUserObject

Posted: Thu Jun 30, 2005 12:14 am
by GangMan
Hi!

I'm currently working on a small space shooter application. To shoot I'm currently using a mesh-Entity for my laser beams. I then use the IntersectionSceneQuery to check for collisions of the laser with other objects.
This works quite fine.

Then I thought i could gain some performance by exchanging the mesh-based lasers with simple billboards, since this should be enough for my purpose. So that's what I did. Shooting works fine again and it also looks okay. The only problem is that I don't get any results from the IntersectionSceneQuery anymore, so Collisions don't work anymore.

I'm using the approach shown in Oogst's tutorial which means I subclass my own classes from UserDefinedObject. In my objects i use entity->setUserObject(this) or respectively billboardset->setUserObject(this). When I connect the UserObject with mesh, collisions work fine but when i connect it to the billboard set, nothing is detected anymore.

Does this happen on purpose (aren't billboards/billboardsets meant to collide) or is this some sort of bug? Since both Entity and BillboardSet are subclasses of MovableObject they should both produce a movables2movables result in the IntersectionSceneQuery. Am I wrong?

Thx for help and kind regards!

GangMan

Posted: Thu Jun 30, 2005 1:34 pm
by sinbad
Billboards are excluded from scene queries since their shape is not very representative (for one, they're 2D, and for two the AABB covers all of the items in the set). This has been made more configurable in Dagon due to the MovableObjectFactory changes though.