kevzettler Posted October 30, 2016 Share Posted October 30, 2016 I have an imported, animated, rigged character mesh. I want to move its z position on keyboard input. I'm not seeing a position attribute on the Skeleton or on the Bones. I'm not seeing an obvious way to do this. playground at: http://playground.babylonjs.com/#2F6AQS#2 Quote Link to comment Share on other sites More sharing options...
gryff Posted October 30, 2016 Share Posted October 30, 2016 @kevzettler : Hi kev There are a number of examples of moving an animated rigged character with mouse clicks - maybe they will give you a starting point 1. Point and Click Box 2. Point and click movement of a rigged character by ProfessorF 3. And @Dad72 had an example of a character walking over a terrain - but I have lost the link Hope that is a start. cheers, gryff Quote Link to comment Share on other sites More sharing options...
kevzettler Posted October 30, 2016 Author Share Posted October 30, 2016 Thanks for the leads @gryff I should expand on my initial post. My issue is that I have multiple meshes attached to the skeleton. ProfessorF's example is helpful. However it appears there is only 1 mesh in that example which is explicitly updated. I've tried creating a Parent root mesh that I change the position on and iterating over the bones children to assign them as children of the root mesh. but that dosen't seem to work Quote Link to comment Share on other sites More sharing options...
gryff Posted October 31, 2016 Share Posted October 31, 2016 2 hours ago, kevzettler said: However it appears there is only 1 mesh in that example which is explicitly updated. @kevzettler : actually kev, the "dude" has multiple meshes - see image below of the "dude" playing in the Sandbox. Meshes by name: /0 : head /1 : upper body armour /2 : legs /3 : upper body (arms and chest) /4 : eyes /5 : some kind of "empty" ( a root mesh to control translation/rotation by the code) cheers, gryff Quote Link to comment Share on other sites More sharing options...
kevzettler Posted October 31, 2016 Author Share Posted October 31, 2016 thanks @gryff I updated the playground http://playground.babylonjs.com/#2F6AQS#3 I now attach all rigged imported meshes to a Root mesh. I added some WASD key controls to move it. There's only one problem I can see at the moment. The SkeletonViewer seems to be moving at a different velocity than the meshes. I think this might actually be a bug. Would appreciate another looks Quote Link to comment Share on other sites More sharing options...
gryff Posted October 31, 2016 Share Posted October 31, 2016 2 hours ago, kevzettler said: The SkeletonViewer seems to be moving at a different velocity than the meshes. I think this might actually be a bug. Would appreciate another looks @kevzettler;: I recognize the figure - explains why I have a subdirectory on my HD for "kevzettler" I think @adam is the guy who should look at issues with the "SkeletonViewer" cheers, gryff Quote Link to comment Share on other sites More sharing options...
adam Posted October 31, 2016 Share Posted October 31, 2016 Move the mesh instead of the root bone of the skeleton. Nabroski 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.