Changing Unity’s Boilerplate Script Code

“Those files be hidden mate. Hidden, but not buried. That just wouldn't make any sense.”
— Jan de Bouff

Quick tip: if you’re not a fan of the boilerplate code that Unity spits out when you create a new script (for example, if you’d rather have an OnGUI function ready to go rather than Start), you can easily change it to whatever suits you best. In Mac OS X, simply right click on the Unity application, choose “Show Package Contents,” and navigate to Contents → Resources. You’ll see three files named NewBehaviourScript. Open those up, modify them to your liking, and save. The next time you create a script in Unity, you’ll notice with groundless excitement that your changes are there.

Posted on by Matthew Miner in Game Design and tagged

One Response to Changing Unity’s Boilerplate Script Code

  1. Pingback: Improving Unity Project Creation « nick breslin . game developer

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>