Hello Guys,
I’ve been learning C# for 1week now and i think i know about basics…So,should i go ahead and start learning from Unity3d tutorial or i will learn more c#.
I want to start my career for Game programmer and i dont know where to start about.Can i have some help please?
Also,Unity3d C# and normal c# is different so,should i keep learning normal c# or i learn c# with unity3d?
As i mentioned i want to be game programmer,so what should i do?
what to learn and from where?
Doesn’t hurt to keep learning C#, in general. If you feel you have the basics, though, it should be totally okay to go ahead and start with some simple tutorials. There are some parts of C# that aren’t available in Unity, because Unity is running an earlier/younger version, but generally speaking the languages are the same. Not sure which things you found different…
Plus, you’ll be the best judge as you progress forward, as to what you understand and what you have to learn/look over again, if you do go ahead and try some of the tutorials. Of course, the Unity specific stuff will be entirely new to you, but I meant about the language itself
It’s definitely possible to learn programming as you learn Unity at the same time, but my advice is if you want to be a programmer (Even game programmer), is to focus on learning how to program in general. Most professionals that I know who went to work for companies as game developers had a general programming background (Computer Science education for most part). Knowing how to program in general will not just help you in gamedev, but also other areas of development.
The other big advantage of learning how to program is it will make it easier to learn other programming languages if you have to (So long as it’s the same paradigm). In your case if you learn programming fundamentals and become proficient in C#, you’ll have very little to no problem in the future if you switch to languages like Java, JavaScript, Python, Ruby, Swift, etc.
If you learn better by watching videos, the Unity learn section has tutorials on C#. Work through them all.
If books are more your ting, Rob Miles has released his university’s intro C# course for free. It’s the “C# Yellow Book”.
I honestly recommend you do both, and then keep looking for more sources of learning. However, don’t just passively read or watch. Get out there and experiment. You’ll learn more from doing.
Another good way to learn about code is to read and try to understand other people’s code. That’s another place the Unity tutorial section can help you. After you have the basics of C# down like methods and variables, start dong the basic Unity tutorials. Spend time making sure you understand what is happening in the code. Don’t know what a particular line of code does? Do some web research or look at the docs and figure it out. Sometimes you’ll hit a wall, so make a note to come back to that topic later when you know more.
I tend to suggest people learn Unity and C# at the same time, preferably via the scripting page in the learn section.
Learning C# on its own is a valid approach. But it will take a while before you learn things that translate directly into Unity. The average ‘hello world’ tutorial has zero relevance to Unity.
The big patterns you’re REALLY going to need to know are object pool, singleton, factories, and most of all the MVC framework.
Don’t let the scary sounding names throw you off. They’re quite simple if you just try them out, I promise.
For example MVC stands for “Model Viewer Controller” which sounds really complicated, but in reality it’s just saying that you divide your scripts into scripts that take input, scripts that do stuff, and scripts that have stuff done to them.
You’ll also need to learn FSM’s, but for that I highly recommend Play Maker. Play Maker is just simply a must for new devs, plain and simple. It lets you do FSM on a flow chart, which is invaluable when you’re getting down how they work. Without it you’re left sifting through a pile of code that expands exponentially. Also, professionals (like devs at Blizzard) use it.
Other than that. Hit up all the tutorials and live trainings.
Just beware of neck-beards. You’ll quickly find that programming is packed full of people who like to argue about nothing to no end and seemingly make things more complicated than they need to be just so they can feel smug.
And @Kiwasi is correct. Doing both at the same time is the way to go. If you just do programming it’s really hard to contextualize. If you just do Unity, you end up pressing the “I believe” button too many times and find you learn very little.
But do bot at the same time and you will be making tons of connections you never would have otherwise.
With the way people keep bringing up singletons there are times I wonder if I’m approaching a task incorrectly. About the only times it has occurred to me that it might have been useful I ended up creating the classes in a difference fashion.
My manager scripts are placed within certain scenes (application-wide, current game-wide, scene-wide, etc) depending on when they should be loaded and unloaded. Most of the non-MonoBehaviour/ScriptableObject scripts I write that would benefit from being singletons ended up being written as static.
While the former seems to be the way Unity was intended to be used (namely the new scene management), the latter while very rare due to Unity always feels odd.
Since your link doesn’t seem to have a C# entry for singletons I’ll point towards the one I stumbled upon. It’s more in-depth than a beginner is likely to find useful but it does offer different ways to implement it with different degrees of performance and thread safety.
Full disclosure. I also don’t know why people like them so much and am just mentioning it because so many people love them. Now excuse me, I have to go groom my neck.
Well the singleton is just a pattern like any other. There’s nothing magical or mandatory about it; it’s just handy to get right if your application needs it. It’s probably not very useful in a Unity project, but it might be in a corporate environment. For instance, having an ‘EmployeeManager’ that’s available from several modules in your application.