Game Development Reference
In-Depth Information
Assets folder should be treated with a bit of reverence, and not filled with
garbage or files that won't be part of the game.
I've seen developers and students just throw their entire Maya project folder
inside of this Assets folder. This is really a poor work flow as it forces Unity to
analyze all the files (including all the raw texture construction files, swatches,
incremental saves, etc.) and indeed to then chug away to convert all that stuff into
forms Unity likes to work with. There really isn't a “please stop importing” button
or a “ignore this stuff” option, so it becomes important that only the assets that are
going to be used in the game end up in that Assets folder. Otherwise, there will be
much waiting done as Unity chews on mounds of stuff that will never be used.
Exactly which items to actually place in the Assets folder is actually a little
trickier than it might sound. Some developers like placing their Maya file (.mb
or .ma) there and then sorting through their sourceimages folder to pull out
the textures they know they finally used in their project and including those in
the Assets folder. I'm not a fan of this approach because it quickly becomes an
unmanageable collection of files if there are multiple Maya files and keeping
track of what textures are used where can be a chore.
Instead (and much more on this later), I prefer to export my files manually from
Maya as a .fbx file and simply have that file embed the media it uses for the
material creation. A streamlined collection of files into the Assets folder means
a streamlined import process and a much more streamlined production cycle.
Deleting or Rearranging Items
While placing assets into the Unity project happens in the OS, deleting files
from the project shouldn't be done in this way. When assets are dropped into
the Assets folder, and Unity imports them, it creates a series of metadata files
that help Unity keep track of where files are at and how they are tied to other
files. The problem is that if files are deleted or moved around in the OS, the
metadata doesn't go with it—or update to represent these changes. This can
really mess Unity up as it loses track of where assets are.
Warnings and Pitfalls
I know I just said it,
but it bears repeating.
Reorganize or delete the
asset files only within
Unity. Do not do so in the
OS's file browser.
Instead, whenever an already imported asset needs to be deleted or
reorganized, do it within Unity. This will happen within the Inspector window
and we will look at how to do this in the tutorials to come. However, just keep
in mind, from the project's inception, to bring in assets to be used in the game
outside of Unity (in the OS), but once the assets are in Unity do all organizing
and deletion within Unity—it will save much frustration. The details of Unity's
import process will be covered in the coming pages.
Unity Interface
Figure 5.2 shows the Unity interface and what the parts of the interface are.
We aren't going to spend a huge amount of time picking through this since,
by this time, I'm sure you're anxious to get into it, but a quick overview will
help in understanding how Unity “thinks.”
 
Search WWH ::




Custom Search