So, I do this:
var intlist:List.<System.Int32>;
intlist.Add(1);
And where I say intlist.Add(1) I get:
NullReferenceException: Object reference not set to an instance of an object
Weird, huh? Apparently, the error is .NET related and List is a .NET thing. So, please clarify the problem. Thank you.
EDIT:
The "add comment" button isn't working, so I will respond in the form of an edit. No, I can't use a JavaScript array because for whatever reason it screws up in the context of my code and the Unity people say I shouldn't use them. The syntax I am using is correct (as far as I know) in JavaScript, but I don't know if it would be null or not. Obviously, it starts out empty. That's sort of the point.
EDIT 2:
It looks like I can't accept answers either. Thanks to the both of you. It turns out I did need to call the constructor, despite some rather strange syntax errors I was getting earlier. Blowing your magic fairy dust on it made the problem go away.