Jump to content

Babylon.js armature can't move properly


vendoc
 Share

Recommended Posts

Hello every one, i have an issue about loading a armatured babylon file.
I have a blender file with skeleton, then i export it to babylon. when i load it in babylon my file can move but the move is so strange. it doesn't move like in blender.
 
here is my code

function loadGajah() {    BABYLON.SceneLoader.ImportMesh("", "assets/", "gajahGerak5.babylon", scene, function (newMeshes, particleSystems, skeletons) {               newMeshes[0].checkCollisions = true;               //newMeshes[0].position =  new BABYLON.Vector3(-80, -13, -50);               newMeshes[0].position =  new BABYLON.Vector3(10, -13, -10);               newMeshes[0].scaling = new BABYLON.Vector3(0.0055, 0.0055, 0.0055);               newMeshes[0].diffuseTexture = new BABYLON.Texture("gajah1_2.MainEleH_NORMALS.jpg", scene);                scene.beginAnimation(skeletons[0], 1, 40, true, 1.0);                          });}

thanks

Link to comment
Share on other sites

Hi vendoc, welcome to the forum :)

 

my file can move but the move is so strange

 

 

Unfortunately, that does not tell us very much. Is it a humanoid character - or something else? Can you provide a .blend file ? And what is the origin of the animation?

 

Is this the kind of "strange" behaviour you are talking about?

 

Weird Animation

 

cheers, gryff :)

Link to comment
Share on other sites

  • 2 weeks later...

Morning vendoc :)

 

Thanks for posting the .blend file - unfortunately it does not contain an armature. It is just a simple model of an animal.

 

Here is my log for export :

 

========= Conversion from Blender to Babylon.js =========
    Python World class constructor completed
    WARNING: No active camera has been assigned, or is not in a currently selected Blender layer
    processing begun of mesh:  Cylinder
        WARNING:  No materials have been assigned:
        num positions      :  942
        num normals        :  942
        num uvs            :  0
        num uvs2           :  0
        num colors         :  0
        num indices        :  5502
========= Writing of scene file started =========
========= Writing of scene file completed =========
========= end of processing =========

 

 

 

Apart from warnings about no camera in scene and the mesh that is processed has no material - nothing about an armature.

 

I think maybe you posted the wrong file

 

cheers, gryff :)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...