GameDev : how import assets in Unity (format file .blend and .FBX)
The current state of our game is not bad! We set up some good mechanics and tested it.
But to improve our game, we need to implement good graphics, right?
It makes everything better!
I have opened a new empty project and now let’s see how to import ASSETS into Unity.
I am not an artist, but when we create games we need assets to replace our “cubes” with good graphics!
Obviously, if you know how to use programs like Maya, ZBrush or others you can create your own templates.
There are some sites where we can find a lot of free assets.
This is the link to one of the site :
Here is a summary of upcoming OGA events that are taking place this year and when, So get these in your calendar! :) Be…
Now, I create a simple example to understand how import from site to Unity
First, choose a random assest, just for example
I choose a 2D Spaceship
Click download here
We can now import in several ways
One method is simply drag from folder to our project, in the Assets folder
Or we can create a specific folder
Then, right click on this folder and go to Show in Explorer
From here, we can directly drag and drop from our dowload folder to the Art folder
In unity now we have this
Now we have the asset inside Unity, but in this state we CAN’T use it
Because we import a SPRITE 2D, we have to change some parameters in Inspector to make it works correctly
Here we have to change TEXTURE TYPE to SPRITE (2D AND UI) and click on APPLY
If we try to drag 2D sprite in the Scene View
There are other things to know, for example we have PIXELS PER UNIT.
Normally we have to associate that number with the number of Pixels of the Sprite we import.
In this example the image is 174 x 256.
If we change that number tfrom 100 to 174 and hit apply
A good thing to do is always check the Pixel of image and set Pixel Per Unit on the same value, or at least the nearest.
In this particular case maybe we need some test to find our best solution, but sometimes the image are 45 x 45, or 75 x 75. So we have to change the default number (100) to 45 or 75.
It is just a good practice and is good to know how work import of Sprite.
But what happen if we import 3D models?
Well, even if we are software engineer, we need to know other programs to create assets like Maya , ZBrush, or in this case, Blender. I’m not expert in this, but when I download some assets, and sometimes they are in .bleed format.
I have Blender installed in my PC and 99% of the time I just use it to upload the file and export it to .FBX
You can download Blender here
Don’t worry, is completely free
I try download simple asset
Download, then open in Blender.
We can do this with simply drag and drop
Than simply go on File, Export, FBX
This save the file in .FBX format.
Now we can import in Unity, in Art folder
To understand better, I think this is a good article on how to import Blender files into Unity.
These are just the basics, just to know how work this type of things.