irrEdit , getSceneNodeFromName & AnimatedMeshSceneNode

Post your questions, suggestions and experiences regarding game design, integration of external libraries here. For irrEdit, irrXML and irrKlang, see the
ambiera forums
Post Reply
Kaki
Posts: 41
Joined: Thu Oct 12, 2006 12:19 pm
Location: France

irrEdit , getSceneNodeFromName & AnimatedMeshSceneNode

Post by Kaki »

Hello

As I understood, irrEdit give us only SceneNode and not an AnimatedMeshSceneNode. Or I want to make a scene with AnimatedMesh.

getSceneNodeFromName("myModel") not work if it is an AnimatedSceneNode.

How can I do ? I would be obliged to define another AnimatedMeshScene Node.

Thanks in advance
JP
Posts: 4526
Joined: Tue Sep 13, 2005 2:56 pm
Location: UK
Contact:

Post by JP »

Have you tried casting the ISceneNode as an IAnimatedMeshSceneNode? I guess that would probably work if you know it's going to be an IAnimatedMeshSceneNode.
Image Image Image
Kaki
Posts: 41
Joined: Thu Oct 12, 2006 12:19 pm
Location: France

Post by Kaki »

Well I'm french and I'm not a specialist of English.

but when I do :
IAnimatedMeshSceneNode* node2 = smgr->getSceneNodeFromName("Adibou");

I have an error : cannot convert from 'irr::scene::ISceneNode *' to 'irr::scene::IAnimatedMeshSceneNode *'

I don't know what I do
JP
Posts: 4526
Joined: Tue Sep 13, 2005 2:56 pm
Location: UK
Contact:

Post by JP »

You have to actually cast it as an IAnimatedMeshSceneNode. I'm not too sure about whether it would work but try this:

IAnimatedMeshSceneNode* aNode = (IAnimatedMeshSceneNode*)smgr->getSceneNodeFromName("Adibou");
Image Image Image
Kaki
Posts: 41
Joined: Thu Oct 12, 2006 12:19 pm
Location: France

Post by Kaki »

You're right man. Thanks a lot :lol:
Post Reply