Gurwinder
Gurwinder GPU SDE | AI & Graphics @ Intel, Loves to Work on AI, Games & AR/VR

Unity’s Floating Spaceships: Quick and Effortless Creation for Stunning Visuals

Unity’s Floating Spaceships: Quick and Effortless Creation for Stunning Visuals

One of the easiest ways of making a game object float in Unity is to use Sine function.

Step 1: Download any free spaceship obj from Turbosquid.

walking

Step 2: Import it in Unity and add game component ‘Rigidbody’ and disable gravity.

Step 3: Add a script move on the Game Object and write down the given code snippet.

walking

Step 4: Add Rigid body in inspector to game object and put these respective values:

Speed= 1f-2f

Amplitude= .1f-1.0f

or you can do it accordingly.

walking

You have your floating spaceship in unity.

comments powered by Disqus