x


How much does a new Unity dev need to know?

Hi there, I'm working for a small game development company who primarily use the Unity engine. I'm not directly involved with the game development itself (web master), but I would one day, perhaps many years in the future like to venture into that territory. I have two years of experience in Java programming, and I've spent a semester in school working with C#. I've dabbled in Java game development in the past but this was primarily simple 2D plat-formers and such so I didn't really get to work with any of the low-level concepts. I checked out the Unity IDE and I didn't actually see any code - it looked like it's based around drag and drop assets that can be configured through a GUI (please correct me if I'm completely oblivious in this regard). As an aspiring game programmer I had just had a couple of questions to start with:

  1. How much coding is involved when programming in Unity/when does the coding come into place? Can one code their own custom assets?
  2. Given my background, is jumping straight into Unity before learning the fundamental concepts of game programming through Java a bad move? Should I continue to dabble in Unity to pick up these concepts or take a step back and experiment some more with Java?

Also, I'm really digging this stackoverflow-esque help section. :)

more ▼

asked Jun 24, 2012 at 03:27 AM

Amenos gravatar image

Amenos
32 1 2 3

If you can program, you can program. You're either born with it or not.

There is no difference at all between programming languages (they are all Stupid) and there is no difference at all between different fields of programming.

If you can program machine vision, you can program texas hold 'em AI, and you can program multiuser servers, and you can program scrabble solvers, and you can program finite element analysis for engineers, and so on and so forth.

Unity3D is all programming, all day, every day.

Enjoy!!!!!!!!!!

If you can program, just buy a license and start using Unity3D immediately.

One thing -- with video game programming, it is great if you have a "feel" for physics. You just have to have a natural built-in feel for space, time and the differentials of those two things. if you're a glider pilot or superb soccer player or the like, you're in. If you have that, you will love programming physics. But if you don't have that, there is HEAPS - HEAPS - of other stuff to program in games, all of which is awesome and enjoyable and totally awesome. You can jump right in to AI, networking, modelling, whatever.

One thing, be sure to bring your engineering hat. Video games are the most difficult thing humans have created so far. There's no room for spaghetti code. You have to build like the freakin' Romans from the ground up.

{Actually that's a very bad analogy. Those guys built everything with crap concrete and added lovely stone facing. That's exactly what you DO NOT want!! You can get away with that in all other fields, but not video game development.} Enjoy!

Jun 24, 2012 at 10:14 AM Fattie

Shouldn't someone close this question because it's just a lot of chat ?

Jun 24, 2012 at 10:14 AM Fattie
(comments are locked)
10|3000 characters needed characters left

4 answers: sort voted first

The coding is mainly done in UnityScript (which is sometimes erroneously referred to as and has little relation to Javascript) or C# (use C#).

Basically it's very, very object-oriented by design. You write a class that extends the basic Unity object, and then you have easy access to necessary functions like position and rotation and lots of helper functions to do all the Hard Math. You can then drag that class onto however many GameObjects you need.

You can still write just normal, standalone classes for like utility functions and whatnot.

It's possible to make an entertaining little time-waster with a minimum amount of coding, but you have nearly full control over just about anything - you can even extend or override the Unity editor itself!

I'd recommend using one of the official Unity tutorials (I'm partial to Lerpz myself for range of lessons). Scan through it and see if you can understand what the game-related words mean and you can hopefully get a good idea of whether or no you want more school-learnin'.

more ▼

answered Jun 24, 2012 at 03:43 AM

Loius gravatar image

Loius
14.8k 34 47 89

Object-oriented is good; I was afraid I wouldn't be able to get into the nitty-gritty when I didn't see any syntax. I'll definitely take a look at those tutorials.

Jun 24, 2012 at 04:01 AM Amenos

Actually, the programming languages are object-oriented but Unity itself is more component-oriented.

Most of the time, you will look for a component to access its properties rather than designing a complex object-oriented hierarchy.

Jun 25, 2012 at 02:28 PM Kryptos
(comments are locked)
10|3000 characters needed characters left
  1. You can code your own custom assets. It takes more code than somebody outside of software programming would be used to (I come from a web background and I'm betting you're not a very heavy JS user). Unless you use a framework for your site development.
  2. I didn't bother learning any concepts of game programming before I jumped in. It's just like any other language you learn: you just throw effort into it. Having a clear purpose for what you want to get done will really help though. I was honestly COMPLETELY lost when I started using Unity because I didn't know how it would compile, but after working past the first milestone (AKA the "it somehow worked" milestone), it just clicked.

A little note that Unity is NOT as powerful as you would imagine because of the Unity Free VS Unity Pro gap. That gap really annoys me...

more ▼

answered Jun 24, 2012 at 03:46 AM

Mizuho gravatar image

Mizuho
467 10 10 14

Fortunately I do use a framework and I'm no stranger to JS so hopefully the learning curve won't be too steep. By gap do you mean functionality wise or usability?

Jun 24, 2012 at 04:07 AM Amenos

@Amenos: I mean functionality. Basic things like drawing a line through the code are very consuming if you need a bend (eg. if you were to draw a simple "V" letter in Unity, you need to make two lines). DLC-use features like AssetBundle aren't accessible in the free version. If you want water, shadows (there's something in the Asset Store for this though), and a bunch of generally nice things, it's all hidden in Unity Pro.

Jun 24, 2012 at 04:13 AM Mizuho
(comments are locked)
10|3000 characters needed characters left

Unity is actually quite heavily code-oriented. You write code when you want to make anything happen. The editor is for laying out levels, hooking up assets to scripts, and so on. It would be helpful if you were reasonably familiar with programming before using Unity.

more ▼

answered Jun 24, 2012 at 03:54 AM

Eric5h5 gravatar image

Eric5h5
110k 55 181 659

(comments are locked)
10|3000 characters needed characters left
  1. Yes you code your own assets all the time in a way. The basic "class" of each asset is created and referred to as a game object. After that you further define each object by attaching other "sub classes" referred to as components. The coding comes into play when it comes to how each of those things behaves at run time. This is where you create a script using either C# or Javascript. The above poster said it wasn't really JS but it actually is, just using different libraries.

  2. You can do whatever you want, as long as you have a drive and will to do something you can achieve. The only limit is how much work you want to put into it. The unity engine is great because it handles a lot of the stuff you typically don't want to deal with when starting a new project. It's like drawing a picture, you can either code your own drawing program or just get Photoshop. The fundamental concepts of game design are the same just like drawing, the only difference is how you arrive at the final product.

more ▼

answered Jun 24, 2012 at 04:40 AM

TheDavil86 gravatar image

TheDavil86
73 13 10 11

Please be clear it is not JavaScript, it's not even close to browser JavaScript - Unity Script is based on Boo and is more like ActionScript than real JavaScript. The languages share some of the same syntax but there are massive differences between them. If you try to program Unity Script while learning from a JavaScript reference work then you will get totally confused.

E.g. Unity Script is a .NET language that uses classical inheritance not prototype based inheritance like JavaScript.

Jun 24, 2012 at 05:32 AM whydoidoit

Not sure if you're aware of this but you actually create .js files, .cs files, and .boo files. I was referring to when you create actual scripts, which I prefer writing everything in javascript. If you're talking about the engine itself ok, but that actual javascript files, ARE JAVASCRIPT.

Jun 24, 2012 at 09:09 AM TheDavil86

I'm sorry but you are wrong.

Files have a .js extension. The fact that those files contain some words which are syntactically the same as ECMAScript (JavaScript) does not make them what what most non-unity programmers call JavaScript. The language is different. If you know ECMAScript (browser JavaScript) it will help you a bit, but hinder you too because you will find that the LANGUAGE is different.

Jun 24, 2012 at 11:06 AM whydoidoit

@TheDavil86: If I had written Unity, I could've made the Unity Script files have a .omgwtfbbq extension, and it would still resemble Javascript. The Javascript files are not Javascript. Try writing in a static variable in Unity using your "Javascript". Then try using it on a browser. Your script will get a parser error because the functionality doesn't exist in Javascript.

Jun 24, 2012 at 11:11 AM Mizuho

No, they are not ECMAScript files. UnityScript is way different like whydoidoit has already mentioned. The name choice of "Javascript" is probably not a good one by Unity.

All classes, no matter if written in C#, UnityScript it boo are compiled into .NET / Mono assemblies. The assembly created for "Untiy's Javascript" is even called "Assembly-UnityScript.dll"

Here you can read about the differences between UnityScript and JavaScript

Jun 24, 2012 at 11:12 AM Bunny83
(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x481
x168
x33

asked: Jun 24, 2012 at 03:27 AM

Seen: 5382 times

Last Updated: Jun 25, 2012 at 02:29 PM