Can nxOgre give Y position of raycasting on my map surface?

ahmadi

17-08-2006 12:58:21

Hi
i have a map(level), its group of ogre meshs, now i can not raycast with ogre for giving Y position of raycasting on my map surface, its my code but it only can return baundingbox colision and no more about mesh:

float givey(float x,float z)
{
static Ray updateRay;
updateRay.setOrigin(Vector3(x,1000,z));
updateRay.setDirection(Vector3::NEGATIVE_UNIT_Y);
raySceneQuery->setRay(updateRay);
RaySceneQueryResult& qryResult = raySceneQuery->execute();
RaySceneQueryResult::iterator i = qryResult.begin();
if (i != qryResult.end() && i->worldFragment)
{
SceneQuery::WorldFragment* wf = i->worldFragment;
return (i->worldFragment->singleIntersection.y);
}
}

betajaen

17-08-2006 13:07:46

Yes, use the NxOgre raycaster.

ahmadi

21-08-2006 09:34:00

Yes, use the NxOgre raycaster.
i which demo can i see NxOgre raycaster?

betajaen

21-08-2006 09:41:47

Yes, use the NxOgre raycaster.
i which demo can i see NxOgre raycaster?


It would taken you 3 seconds to load up the NxTutorials.sln and find out that there is a tutorial number 305 labeled "Raycasting".

Jeez, use a little common sense here and there will you.

ahmadi

21-08-2006 09:56:31

Yes, use the NxOgre raycaster.
i which demo can i see NxOgre raycaster?


It would taken you 3 seconds to load up the NxTutorials.sln and find out that there is a tutorial number 305 labeled "Raycasting".

Jeez, use a little common sense here and there will you.

in my tutorials, i have not 305 !!
i have nxogre review 3 and last release of novodex

betajaen

21-08-2006 10:10:54

For gods sake man, look it up in the tutorials solution file then!

I cannot hold your hand through everything, you will have to search for this really simple thing yourself.

ahmadi

21-08-2006 11:20:58

For gods sake man, look it up in the tutorials solution file then!

I cannot hold your hand through everything, you will have to search for this really simple thing yourself.

its my tutorials solution , i can not see any 305:


also you must know, for now , i have ray casting code from your character source that is 311 not from 305!! :D

Thank you very much for you help, :P
i wish that God help you to make some more futures for nxogre such as
novodex cloth and ragdoll ,.... :shock: ohh sorry....