Stretchy bones used to squash this chubby low-poly frog named Arnold from our free android game JuJu Frog made in Unity |
In this quick tutorial I will show you how to set up 3ds max stretchy bones (with squash and stretch) and properly export them to Unity game editor.
Setting up stretchy bones in 3ds max:
- Start by making a simple bone and a nub bone chain
- Create two point helpers and align their position to each bone (alt + a keyboard shortcut)
- Open Animation > "Bone tools" dialogue and scroll down to the bottom. Select the main bone and turn off "Freeze Length", turn on "Squash" and press the "Reset Stretch" button
- Position constrain the main bone to the first point helper. Animation > Constraints > Position Constraint and click the first point helper
- Add "Look At" constraint to the main bone. With the main bone still selected go to Animation > Constraints > LookAt Constraint and click the second point helper.
- Position constrain the nub bone to the second point helper. Select the nub bone and go to Animation > Constraints > Position Constraint and click the second point helper
Preparing bones for Unity
- Create another bone (let's call it bone_unity) and align it to the main bone. Position and orientation constrain the bone_unity to the main bone. I gave it red color so it is more visible.
- With the bone_unity still selected, go to Motion Panel, and assign "Scale Script" controller.
- The Script Controller window will pop up. In it, create a new variable boneMax and click Assign Node. Navigate to the main bone and select it.
- Now paste this into the Expression text field:
That's it. Close the Script Controller window and you have your bone_unity matching the squash and stretch of the main bone. It is ready for export! Just export the unity_bone and your mesh, no need to export the main bone and the nub. Also, make sure you select "Bake animation" in FBX export dialogue.
Hope you liked this tutorial. If you have some questions, please share in the comments or contact me directly via e-mail.
Hi, I seem to be having an issue and wanted to know to which of the bones should I skin the geometry, to the main bone or the unity bone?
ReplyDeleteNever mind, decided to try both ways and its the unity bone you should skin to. Thanks for this, it was driving me crazy that I could make strechy bones work on unity. Keep up the good work! :)
ReplyDeleteHey man, thanks, I'm glad the tutorial was helpful! :)
Deletethanks, Alonso if I don´t read your answer I wouldn´t think in that posibility of skin the bone_unity to my mesh :D, creo que hablas español así que, muchas gracias.
DeleteThis comment has been removed by a blog administrator.
ReplyDeleteThis comment has been removed by a blog administrator.
ReplyDeleteThanks very much Ivan I was looking for squash and stretch in unity.
ReplyDeleteis this gonna work with multiple bones that are connected?
ReplyDeleteYes it works, just do the setup for each bone and you're ready to go.
DeleteHi! I found your tutorial suuper helpful! I tried with one bone and it worked completely fine, but I'm having issues with a chain of, let's say, three bones. If I do the chain of three independent bones only attached to each other by constraint, they don't stretch; and if I do a chain with them in hierarchy, I cannot use the script for the unitybones because it doesn't get the scale of a bone that is child of another bone. Am I just absolutely clueless? Or did I miss something?
ReplyDeleteThank you for your time! :)
Aj hum ko Online Istikhara service ma Khush amdid karta hain. Ap har kisam k ma masla ko humse share kijiya or mann ki murad paya inshallah tamam bigrey huway kam darust ho jain ga. 1 phone call kar +923244544864, +6281315996474 apni taman pershani ka hall paya.
ReplyDeleteRohani Zaicha
Istikhara
Horoscope
Astrology
Istikhara for Marriage
ROhaniilaj
ROhani Wazaif
Amil Online
Amliyat
Black Magic ka tor
Marriage problem
Husband Wife Problem
Hey, thanks for the tutorial. I was too lazy to do it by hand, so i wrote a handy max script that does it automatically. On top of that it automatically re-skins the mesh to those new bones, keeping all the weights consistant. Here it is:
ReplyDeletehttps://www.scriptspot.com/3ds-max/scripts/stretchy-bones-converter
Can you post this link somewhere in the article please? I think it would be handy for all the people coming here.
Hello, can you come to a video tutorial?
ReplyDeleteDude you are a life saver thanks so much.
ReplyDeleteThis blog is very powerful. Its helps me a lot about this topic. very nice and the very
ReplyDeletehelpful blog commenting Sites List that you have posted. I like it very much please keep
doing this amazing work. Have a very nice day sir.: Hati Yang Dikhianati
Samsun
ReplyDeleteUrfa
Erzincan
Mersin
Kayseri
TİP3R
ağrı
ReplyDeleteelazığ
siirt
ankara
van
1BGL
whatsapp goruntulu show
ReplyDeleteshow
TMO
Maraş Lojistik
ReplyDeleteHatay Lojistik
Tokat Lojistik
Elazığ Lojistik
Aksaray Lojistik
RLEAF
9973D
ReplyDeleteBatman Evden Eve Nakliyat
Erzincan Evden Eve Nakliyat
Isparta Evden Eve Nakliyat
Kayseri Lojistik
Iğdır Evden Eve Nakliyat
CFFFD
ReplyDeleteMaraş Evden Eve Nakliyat
Konya Evden Eve Nakliyat
Erzincan Evden Eve Nakliyat
Muş Evden Eve Nakliyat
Kocaeli Evden Eve Nakliyat
6A6B7
ReplyDeleteSiirt Lojistik
Kars Şehir İçi Nakliyat
Siirt Şehir İçi Nakliyat
Osmaniye Şehirler Arası Nakliyat
Çerkezköy Cam Balkon
Ardahan Şehirler Arası Nakliyat
Muş Evden Eve Nakliyat
Giresun Lojistik
Karaman Şehirler Arası Nakliyat
03343
ReplyDeleteKilis Lojistik
Mercatox Güvenilir mi
Maraş Parça Eşya Taşıma
Denizli Şehir İçi Nakliyat
İzmir Parça Eşya Taşıma
Niğde Lojistik
Çorum Şehirler Arası Nakliyat
Bibox Güvenilir mi
Ünye Kurtarıcı
C2137
ReplyDeleteErzurum Şehirler Arası Nakliyat
Mardin Parça Eşya Taşıma
Qlc Coin Hangi Borsada
Bilecik Parça Eşya Taşıma
Bursa Şehirler Arası Nakliyat
Rize Parça Eşya Taşıma
Antep Lojistik
Kalıcı Makyaj
Amasya Şehir İçi Nakliyat
07650
ReplyDeleteKayseri Lojistik
Ünye Koltuk Kaplama
Çanakkale Evden Eve Nakliyat
Muğla Şehir İçi Nakliyat
Çerkezköy Sineklik
Antalya Parça Eşya Taşıma
Edirne Parça Eşya Taşıma
Kars Şehirler Arası Nakliyat
Bartın Şehir İçi Nakliyat
350A0
ReplyDeletekocaeli muhabbet sohbet
rastgele görüntülü sohbet ücretsiz
kilis rastgele görüntülü sohbet ücretsiz
yalova kızlarla canlı sohbet
rastgele sohbet odaları
telefonda kızlarla sohbet
rastgele görüntülü sohbet
nevşehir canlı sohbet ücretsiz
sesli sohbet mobil
203B9
ReplyDeleteardahan rastgele canlı sohbet
muş ücretsiz sohbet siteleri
kadınlarla sohbet
konya en iyi görüntülü sohbet uygulamaları
sakarya parasız sohbet
trabzon nanytoo sohbet
antep sohbet siteleri
van canlı sohbet ücretsiz
burdur canli goruntulu sohbet siteleri
21194
ReplyDeleteyabancı sohbet
Kastamonu Muhabbet Sohbet
kırşehir sohbet odaları
mobil sohbet et
karaman canlı görüntülü sohbet uygulamaları
Trabzon Canlı Sohbet
Niğde Sesli Sohbet Odası
Kırşehir Kadınlarla Ücretsiz Sohbet
muğla canlı sohbet odaları
A7712
ReplyDeletetrezor suite
quickswap
dappradar
uwulend finance
zkswap
shapeshift
yearn finance
defillama
pinksale
fdhgbfhbnfghtyhuy
ReplyDeleteشركة مكافحة الحمام بالاحساء
TGHTYHNJYH
ReplyDeleteتسليك مجاري بالاحساء
Thank You and that i have a super proposal: How Much Home Renovation Cost average remodel cost
ReplyDeleteشركة صيانة خزانات بعنيزة CwRRt2eA6S
ReplyDeleteشركة كشف تسربات المياه بالجبيل dYF6hNA2s3
ReplyDeleteشركة تنظيف مجالس بالدمام YR7aVsBkCl
ReplyDeleteشركة تنظيف خزانات VEGUyLVhN2
ReplyDeleteشركة مكافحة حشرات بخميس مشيط WK5R5H3zhB
ReplyDelete