Hi,
I've been experimenting with adding interchangeable meshes (such as armour or weapons) to an existing character model. The way I've approached this thus far is to model the additional mesh within the same scene as the character model and constrain it to the appropriate joint so that it works with existing animations. I then export it, using the Panda DirectX exporter plugin, and load the mesh (now in my program) into an additional animated mesh scene node, meaning that I have to perform the same transformations that are performed on the character (when it moves) on the new mesh too. However, I've been scratching my head over the result for a couple of days now:
Test shoulder pads in 3ds Max
Test shoulder pads in-game
As you can see, for some reason, the right shoulder pad is in the correct position - and incidentally works perfectly with all the character's animations, whereas the left shoulder pad is in the wrong position.
If anybody can explain why this possibly might be happening, I would very much appreciate it. I would also very much appreciate it if anybody could suggest a better way of handling this entire process, preferably within a single scene node but still allow me to switch meshes on the fly. Thanks in advance.
DirectX file export from 3ds Max troubles
I'm having the same extremely anoying problems.
I'm trying basicly the same.
My system loads a .x file into a IAnimatedMeshSceneNode , using 3DsMax point helpers to define connection positions.
When I have the 'connector skeleton ' loaded, I'm hooking up IMeshSceneNodes to the connector positions. Works like a charm.
BUT.
The directx importer seems to be missing some functions:
In case of a IMeshSceneNode:
The model needs to be one mesh. Seperate objects will not be displayed.
You have to attach all objects in 3dsmax to one object and convert it to an editable mesh.
Plus: If you create one Sphere for example, and load it into a IMeshSceneNode, it works great.
But, if you scale the sphere in 3dsmax, the irrlicht importer seems to miss the transformation matrix and displays the sphere 'normally'.
If you convert the sphere to an editable mesh, then scale, it works.
The directx viewer provided with the DX SDK does what irrlicht does not...
I've tried several ways to get around the problem but it is simply anoying to keep the limitations in mind, all the time, when creating a model in smax, to find out later it still displays weird results when you're done.
Looks like we need a importer update for irrlicht. Or has anybody some solution ?
I'm still on irrlicht 1.4 ( Still have my original MS vC++ 6.0, wont compile 1.4.1 )
Besides this problem, I'm having so much fun with this engine. Thumbs up for the makers. Incredible that this superb engine has been created by guys who actually share their hard work.
I'm trying basicly the same.
My system loads a .x file into a IAnimatedMeshSceneNode , using 3DsMax point helpers to define connection positions.
When I have the 'connector skeleton ' loaded, I'm hooking up IMeshSceneNodes to the connector positions. Works like a charm.
BUT.
The directx importer seems to be missing some functions:
In case of a IMeshSceneNode:
The model needs to be one mesh. Seperate objects will not be displayed.
You have to attach all objects in 3dsmax to one object and convert it to an editable mesh.
Plus: If you create one Sphere for example, and load it into a IMeshSceneNode, it works great.
But, if you scale the sphere in 3dsmax, the irrlicht importer seems to miss the transformation matrix and displays the sphere 'normally'.
If you convert the sphere to an editable mesh, then scale, it works.
The directx viewer provided with the DX SDK does what irrlicht does not...
I've tried several ways to get around the problem but it is simply anoying to keep the limitations in mind, all the time, when creating a model in smax, to find out later it still displays weird results when you're done.
Looks like we need a importer update for irrlicht. Or has anybody some solution ?
I'm still on irrlicht 1.4 ( Still have my original MS vC++ 6.0, wont compile 1.4.1 )
Besides this problem, I'm having so much fun with this engine. Thumbs up for the makers. Incredible that this superb engine has been created by guys who actually share their hard work.
As a test, I made an entirely new mesh for the left shoulder pad. It works.
So, does anyone know if there's any hidden attributes carried over when you clone a mesh that could be causing the displacement?
EDIT: I think I might have found the problem.
Right shoulder pad:
Left shoulder pad:
The only trouble is, I don't know how to change the center point, seeing as selecting 'Create Center Point' doesn't seem to do anything at all.
So, does anyone know if there's any hidden attributes carried over when you clone a mesh that could be causing the displacement?
EDIT: I think I might have found the problem.
Right shoulder pad:
Left shoulder pad:
The only trouble is, I don't know how to change the center point, seeing as selecting 'Create Center Point' doesn't seem to do anything at all.
Finally I tried another model format, downloaded the plugins for B3d fromhttp://www.onigirl.com/pipeline/ and all the weird problems are solved. And it supports bones and helpers as well. No more .x files for me ! Give it a shot, it might suit your needs as well.
I patched it with the version 9 patch and then I get 'DLL <C:\Program Files\Autodesk\3ds Max 2009\PlugIns\b3dexp.dle> is not made for this version of the program.'
Is there a 2009 patch that I'm missing here?
EDIT: I installed 3ds Max 2008 so that I could at least try exporting to B3D. First I exported the character mesh itself, and that works absolutely fine. Then I tried to export the shoulders and the skeleton on their own, and even though the animations work in the B3D mesh viewer, they don't work in the Irrlicht engine.
Is there a 2009 patch that I'm missing here?
EDIT: I installed 3ds Max 2008 so that I could at least try exporting to B3D. First I exported the character mesh itself, and that works absolutely fine. Then I tried to export the shoulders and the skeleton on their own, and even though the animations work in the B3D mesh viewer, they don't work in the Irrlicht engine.
Problem solved.
mr.Zog to thank for: http://irrlicht.sourceforge.net/phpBB2/ ... b60b533bca
Goodbye .X
mr.Zog to thank for: http://irrlicht.sourceforge.net/phpBB2/ ... b60b533bca
Goodbye .X