TomaszFurca Posted August 1, 2017 Share Posted August 1, 2017 Hi, after finish inventory GUI in my game - babylon.furcatomasz.pl I have small problem with mesh rotation after mount item to bone. For reproduce problem open my game, open inventory and click to any sword to change, then mounted item has wrong rotation. its my code to mount item: mesh.attachToBone(bone, meshCharacter); mesh.position = new BABYLON.Vector3(0, 0, 0); bone.getRotationToRef(BABYLON.Space.WORLD, meshCharacter, mesh.rotation); mesh.rotation = mesh.rotation.negate(); mesh.rotation.z = -mesh.rotation.z; Variable mesh is item to equip. Thanks for help, Tom. 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.