BloodyMess : Convert ManualObjet to NxOgre

jamere

20-01-2009 15:22:35

Hi all,
I was wondering if there is something to convert quicky a manualObject to use it on NxOgre.
Maybe someone has the code somewhere?


ManualObject* manual = mSceneMgr->createManualObject("manual");
manual->begin("BaseWhiteNoLighting", RenderOperation::OT_LINE_STRIP);

manual->position(-100.0, -100.0, 0.0);
manual->position( 100.0, -100.0, 0.0);
manual->position( 100.0, 100.0, 0.0);
manual->position(-100.0, 100.0, 0.0);

manual->index(0);
manual->index(1);
manual->index(2);
manual->index(3);
manual->index(0);

manual->end();


And actually i would like to make a Breakout clone with NxOgre, and i would like to know if there is a way to make my Own body where when someone collide with my body it changes my color until it will be destroyed...
Maybe there is a state or a callback somewhere to tell my Body , it is colliding ?
Thanks, and sorry i'm new on NxOgre

betajaen

20-01-2009 16:39:21

Since that's more or less a cube, you can use a Cube. But for anything a little odd, then you can use the ManualMesh which is nearly identical in usage to the ManualObject in Ogre.

jamere

20-01-2009 16:54:33

ManualMesh, Ok thanks

And for a callback or a state for my new Body to inform it about a contact and change its Material?
Thanks

betajaen

20-01-2009 17:28:43

Yep, there is a callback system for that.

jamere

21-01-2009 08:34:19

Ok thanks, and sorry to bother you, but is there an example somewhere
Again thanks a lot

betajaen

21-01-2009 10:10:21

NxOgre.org wiki