Floating Feather With Wind in Unity
by kmeng90251 in Design > Animation
9 Views, 0 Favorites, 0 Comments
Floating Feather With Wind in Unity
I made a floating feather Make it Float contest.
A few months ago, I had a school project where I learned Unity for 2 months trying to make various games. I blogged my process if you'd like to see (https://kmeng90251.wixsite.com/geniusprojectunity). For this project, I thought why not use my new skills in Unity to make a feather float down the screen?
Supplies
3D modeling software
Unity
Create Feather
I used Blender to create a rough feather.
I don't have much experience using Blender, so I just created a plane, sub divided it two times, and then shifted the edge vertices up and down a bit to simulate a rough feather. If you are better at designing, you may make your own feather here and export as .fbx, or you can download my feather. (https://drive.google.com/file/d/1t6gopYyt7JJyB4eTMdjq-JOSXz187SLW/view?usp=sharing)
Float in Unity
Create a Universal 3d project.
Once the project opens, there should be a project tab at the bottom of the window. In the tab, right click in the assets folder and select "Show in Explorer". Copy your exported .fbx file into this folder.
Next, right click in the assets folder again and hover over Create -> Scripting -> MonoBehavior Script. Name the script "FeatherFloat".
Then, open the script by double clicking the file. Replace all the code in the file with the following:
Save the script and go back to Unity.
In the assets folder at the bottom of your screen, you should see your feather model. Drag the model into the left side of the screen in the tab labeled "Hierarchy". Click on the new element in the hierarchy with the name of your model. On the right hand side in the "Inspector", click "Add Component" and add a "Rigidbody" (not a "Rigidbody 2D"). Set the Mass to 0.02, Linear damping to 5, Angular damping to 0, and ensure "Use Gravity" is checked.
Then, drag the script you made from the Assets folder at the bottom of the screen into the "Inspector" tab. The feather should now have a "Rigidbody" and your script as components of itself.
Finally, orient the feather so that it is in front of the Main Camera, then switch over to the Game tab at the top of the view port, and press the play button at the top center.
Done!
Congratulations! You just made a floating feather with wind in Unity!