Topic: create several instance of a material/bone animation

hi everyone, wink

I search a way in c++ to change the material of an entity without change those of the others entities using the same mesh (clones) ?
Same thing for the bones animation, how play an animation of an entity and play an other animation of an entity using the same mesh at the same time ?

regards

Re: create several instance of a material/bone animation

Hi,

meshs are instances, so if you want to heavily manipulate a mesh for a single entity, you can make a copy of the mesh and link it to the entity.

But for animation you don't have to do that, if you use entity->changeAnimation(animId) the mesh will be animated just before drawing, so even if multiple entity use the same mesh, they will play different animation.

You can even use material animation to change mesh materials without duplicating the mesh (you can animate all the colors and the uv offset).

Re: create several instance of a material/bone animation

I responded to a similar question before, with a piece a code to force load a mesh even if the mesh is already used :
http://forum.maratis3d.com/viewtopic.php?id=36

Re: create several instance of a material/bone animation

Ho, I am sorry, next time I will be more watchfull, thanks for your answer wink

Re: create several instance of a material/bone animation

welcome smile