Macbeth Posted May 21, 2015 Share Posted May 21, 2015 Hello everyone! This might be a noob question, I don't know, I'm very new to game development. What I'm trying to do is hooking 1 or more models into surtain places in a skeleton (I think). What I have is a base player model (skeleton) with a lot of points on it, for example head and body.I am trying to make a head and a body model to display at those two exact points. Here's a screenshot of the player model: And here's the head model I want to be displayed on the head of the player model: Is this possible to do with Babylon JS? What I want to achieve is to have a character model, and I can switch parts, of the model to look different in game, just like an inventory to switch items for the character. Sorry if this question is so "noobly" asked, but I'm really new at this. I have not created these models myself. Regards,Daniel Quote Link to comment Share on other sites More sharing options...
Macbeth Posted May 25, 2015 Author Share Posted May 25, 2015 Does anyone know if this is possible? Quote Link to comment Share on other sites More sharing options...
Wingnut Posted May 25, 2015 Share Posted May 25, 2015 Hi MacBeth... welcome to the forum! Good to have you with us. If I understand what you are asking, YES, it is quite possible, and maybe VERY easy. Your skeleton is created with many 'bone' segments, correct? Could you parent a mesh... to one of those bones? (in the BJS scene... AFTER the .babylon import) That would seem to be an easy method to attach a separate head mesh, and other body parts. You might see some "z-fighting" and mesh tearing whenever the parented-to-a-bone mesh... overlaps with another body mesh. But still, you will have an interesting "change your character" system, here. Keep in mind that I am not a pro... but I wanted to comment just the same. I want to see the results... because... this is cooooool! I once did a little experimenting with 'linked' mesh using our Oimo and Cannon physics engine plugins. The two demos can be seen at... http://www.html5gamedevs.com/topic/2571-the-wingnut-chronicles/page-22#entry65034 (and the next comment too) You are building ragdolls that can have their body parts fall-off, eh? hehe. COOL! I want to see it happen! Pulling the heads off-of dolls... is a thing we guys are KNOWN-FOR! Quote Link to comment Share on other sites More sharing options...
dbawel Posted May 26, 2015 Share Posted May 26, 2015 The only issue is that parenting doesn't pass deformations. If you want to do this, the only way currently is to parent multiple objects (and you can deform multiple meshes to bones as well) and apply an alpha channel to thier texture or material to make them visible and unvisible. This can also be a gradient value so that the change isn't abrupt. Quote Link to comment Share on other sites More sharing options...
Macbeth Posted May 30, 2015 Author Share Posted May 30, 2015 The only issue is that parenting doesn't pass deformations. If you want to do this, the only way currently is to parent multiple objects (and you can deform multiple meshes to bones as well) and apply an alpha channel to thier texture or material to make them visible and unvisible. This can also be a gradient value so that the change isn't abrupt. How do I do this? 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.