Skip to main content

Backing Up Your Projects

What Prompted This Post:
Over the summer while working on one of my games, Unity 3D released an update which required your project to be "upgraded".It warned me to back up my project, but of course me being the stupid little high-school student I am, didn't even think twice and upgraded the project without any precautions. Upon the re opening of my Unity project, I was in shock. Where as the skeletons for all my prefabs, models, and materials still existed, they were all out of place and not put together. So a prefab of a enemy had the mesh component, but the mesh was not linked to it to render, the material was not linked to be rendered. The attached script was said to be missing (although still existed within my project, just not linked). This existed not only in prefabs but every game object in every scene. I was never able to get back my terrain (although height maps existed) so I had to end up remaking it. The whole process of linking everything back together took a good 4 hours. I ended up re-importing some meshes and re-creating some of the prefabs over. An experience I hope never to repeat.

Why It's Good To Back Up Your Project:
My scenario came out of pure ignorance, but other reasons might not be so ignorant. Sometimes you'll need a piece of code that you've deleted, or you might want to look at a certain way you set up a scene.Maybe you can use one of your older back ups as a template for a new game you'd like to start.

My Method Of Backing Up A Project:
I simply go to where ever all my unity projects are stored (for me the documents folder). You want to back up the entire project, so that means backing up the folder that contains your projects assets, project settings, library, and the rest of the stuff.

All I do is copy my entire project to a zipped folder, rename to the date backed up, and keep it there for later usage.

I back up my project when ever I make substantial progress in it which in return makes me think of all I lost over the summer and back it up. I suggest though backing up your project at least once a week though, which is better practice. Your going to want to stay organized so a method I use is making a separate folder for backups, then a sub folder for project, and within the sub folder holds the history of backups.

Taking Further Measures
I suggest also going at least one step further and backing your projects up on to a separate hard drive off your computer. There is no telling when your computer is going to fail on you being it a virus, or actual physical harm to it. Then again can't your separate hard drive be ruined also? If you haven't heard of Dropbox yet, you might want to look into it. The site gives you 2 GB of free storage on a cloud upon sign up. Having backed up on the internet frees you of the risk of loosing anything. Backing up to a separate source makes it easier when switching to a new computer.

Hope this makes you want to start backing up if  you haven't already began!

Comments

  1. Unity BackupProject: http://u3d.as/content/yaroslav-petrichka/backup-project

    ReplyDelete

Post a Comment

Popular posts from this blog

How To Import and Use Fonts

-Made by Chrome Fx Films

To use different fonts in your game, your going to have to acquire some fonts. You can go somewhere like 1001 free fonts and download ones you like and want to use.

When you download the file, you'll need to extract the file if its in  a .zip

The text file should have the extension .ttf. If you text files have a FFIL extension, simply rename the font file (yourname.ttf).
Drag the text file into unity to import. By default the Character variable should be labeled Dynamic.

The Dynamic setting means  that Unity won't pre-generate the texture, so if you look at your material containing your font, It probably will be blank. (read more here)
Now your over all objective should be getting your font to look like this (unless you prefer dynamic):
Where the characters of the font are not jumbled up and visible.
Now usually all you have to do to achieve this is change the Character variable from Dynamic to Unicode.
and that should work.
Now what some people over…

Handling Music and Sound Effects In Your Games

Initiative  While developing Treva's Adventure I had to figure out a way to handle multiple music tracks and sound effects in a clean manner or suffer horribly.  What was going to help me achieve a simple solution was taking all the different sounds and centralizing them in a single class in order to black box them.  Any other code trying to play a sound wouldn't even know the sound file's name.  All code trying to play a music track would reference a enum that defines all the track names.
Defining The Class Creating The Enum When I first started defining types in my enumeration,  I was naming the types to be exactly like the file name.  For a scary sound effect I had found a file named "ghost breath".  So around my code would be scattered lines like SoundManager.Play(SoundEffectType.GhostBreath);  This was fine until I found a sound that better fit the situation it was being used in,  and decided to use "ghost breath" for a different situation like a …

Don't Destroy On Load..

So if you want to keep an object or script that keeps up variables (or for any other reason) when you go from scene to scene, you need to attach a don't destroy on load static function, which goes something like this:

function Awake () {
    DontDestroyOnLoad (transform.gameObject);
}

The Awake function is call only once, when all the objects in the scene have been created. Read more about it here.

DontDestroyOnLoad has what ever is in the ( ) to not be destroyed when creating a new scene.

(transform.gameObject) is what will not be destroyed when the new scene is loaded, in this case, it will be the game object and all it's children the script is attached to.