Manually resize bounding box

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
WishFish
Posts: 8
Joined: Thu Feb 07, 2008 10:08 am

Manually resize bounding box

Post by WishFish »

Hi,

I have two nodes where i want to manually resize their bounding boxes.

Bounding box of the first node in question is too wide, so getSceneNodeFromScreenCoordinatesBB returns the node even if the player clicks beside the node.

The second node is a small animal and even that the animal is very weak, the player can die before he succeds in picking the animal node!
I want to enlarge bounding box of that node so that picking becomes easier.

Is there an easy&intuitive way to do that?
radiant
Posts: 112
Joined: Fri Feb 22, 2008 8:04 pm
Location: Mexico

Post by radiant »

well.... u can resize the bounding box using:

irr::scene::IMesh::setBoundingBox (const core::aabbox3df);

on your Imesh object before adding your scene node and then create your scene node.

Hope it helps
WishFish
Posts: 8
Joined: Thu Feb 07, 2008 10:08 am

Post by WishFish »

radiant wrote:well.... u can resize the bounding box using:

irr::scene::IMesh::setBoundingBox (const core::aabbox3df);

on your Imesh object before adding your scene node and then create your scene node.

Hope it helps
I got the impression that it is not possible to change boundingbox.

But this simply works.

Thanks alot!
Post Reply