Search Unity

  1. We want you to join us at GDC this year! Take a peek at all of the events we will be hosting during the week of GDC.
    Dismiss Notice
  2. Tell us about your experience here and you’ll get early access to the 2018 Game Studios report + more goodies.
    Dismiss Notice
  3. Unity 2017.3 has arrived! Read about it here.
    Dismiss Notice
  4. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice
  5. We've closed the job boards. If you're looking for work, or looking to hire check out Unity Connect. You can see more information here.
    Dismiss Notice

Learning Unity C# step by step?

Discussion in 'Getting Started' started by BallPitGuy, Feb 15, 2018 at 1:23 AM.

  1. BallPitGuy

    BallPitGuy

    Joined:
    Feb 10, 2018
    Posts:
    4
    Hi!
    I've been trying to learn/teach myself C# and Unity for a little bit, and it's definitely a tough process. I know that other people find it difficult as well.
    So I was hoping that perhaps someone could come up with some kind of baby steps type plan. Not give specific how-to information, but rather a sort of detailed syllabus, just giving baby steps on what to learn and when.
    For example, just like the first day, you learn what variables and functions are. The second day you learn how to use mathf.clamp. (obviously thats kind of a big jump for an absolute beginner, but you get what I mean.)
    Maybe the third day you learn by writing a functioning script for moving a 2D object. Then maybe you learn how to move the 2D object randomly on its own, and then with some constraints. I don't know exactly.
    But it'd be incredibly helpful if someone could outline that for me, since I keep getting distracted and overwhelmed since there are so many things to learn and ways to learn them.
     
  2. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    10,678
    One approach if you're being overwhelmed is to simply focus on one of them. Learn the language by itself without the complications brought by Unity. Install Visual Studio (or Xamarin if you're on macOS), download the free C# Yellow Book, and go through it at a slow pace implementing the code in the book.

    http://www.csharpcourse.com/

    It's basically a college text book intended for people just starting with the language so it does explain the code as it goes.
     
    BallPitGuy, JoeStrout and Kiwasi like this.
  3. Dai-22

    Dai-22

    Joined:
    Jan 19, 2018
    Posts:
    64
    Stick to beginner tutorials from brackeys, charger games, then repeat them to remember the words etc. Also do really basic ball/cube tutorials. The other tutorials involve stuff that very quick to pick up later. Just search for easy unity tutorials on youtube. Roll-a-ball helps you see 3d movement and speed, camera lock etc, others will do different things. I'm only a beginner myself. I find this way best so far, but also watching a couple of random videos in between helps too, just to see the uses. I use C# visual studio old book sometimes also. Going to go over brackeys C# video's 5 to 15 again tomorrow. Just to refresh what iv'e not practiced very well.
     
    BallPitGuy likes this.
  4. BallPitGuy

    BallPitGuy

    Joined:
    Feb 10, 2018
    Posts:
    4

    I appreciate the response. I actually took a look at that book a little while back, but I found that there are some differences between what I know from using Unity, and what the book talks about. Sort of like an app I tried, just called something like "Exercises C#" which asked a question like "if you wanted to print the word "Hello!" what code would you use?" So in Unity you'd use Debug.Log, right? But the app says you would use "System.Console.Write" something or other. Which just confuses me further, since I don't know whether or not it would apply to Unity. The same goes for the SoloLearn learn C# app.
    It's just confusing to me.

    I watched, and took notes, following the Unity scripting tutorials, both the beginner, and intermediate series. But honestly just watch that, I retained about 0% of the information, and even the stuff I did retain, I have no idea how to implement it into any practical form. Does that make sense?
    Learning it is just so tough without any guidance.
     
  5. ThermodynamicsMakesMeHot

    ThermodynamicsMakesMeHot

    Joined:
    Feb 14, 2015
    Posts:
    112
    In coding there will be always more then one way to do something and that's part of the magic. In order to retain anything you have to practice over and over. Watching is not the same as doing it over and over to perfection. Those books and tutorials that talk of learn this and that in 24hrs are are full of it. Sure the content could be decent but it will take a lot longer the 24hrs for you to do anything realistically. Even once you know enough to do things you can fall into that pit of what do I make....or worse yet jump into one project after another never really finishing anything which will leave you even more confused about your skills and place in game dev life.

    All these tutorials about how to code don't teach is the game dev side. You have to draw out and plan your game which I hear some people call "OldSchool". Personally if you draw out a map of what your making and trying to achieve you realize you have all the guidance you need. Ask other for an idea and outline it and then just start doing it. You need a plan, flowchart the actions so you know what's happening. Taking these courses and just copying whats going on is not really learning at an optimal setting. Sure the basics but from there you should just jump right into it. The key is to keep it realistic and timely and don't lose yourself in a project that will take you forever and more. Lots of free and cheap asset complete projects to start you off. I really believe the best way to learn is learning is just start doing it and learning and adapting as you go. Having an asset package project you have a passion for already will help the learning speed exponentially.
     
  6. BallPitGuy

    BallPitGuy

    Joined:
    Feb 10, 2018
    Posts:
    4
    Fair enough, and I agree with you. My only concern is just even still lacking the ability to just "do" anything. Implementing the code is so foreign to me, and I wouldn't know where to start, you know?
     
  7. methos5k

    methos5k

    Joined:
    Aug 3, 2015
    Posts:
    6,217
    Yes, I can understand that. I think everyone is like that in the beginning. That's why writing new things you learn is important, because then you're part of the process (output), not just input lol.
    This is also why I think people learn best with the most fundamental parts, because they're used everywhere. If you skip them, or aren't sure of them, it will trickle through to all of your/their work.

    As for your comment on Console.Write vs Debug.Log (and the like).. yes there are some differences, but if the C# tutorial was just for a console program, and learning basic concepts, most of it could be applied to Unity.
    It doesn't mean you have to do it, it's just an option. I'm sure many people here don't do that. :)
     
  8. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    10,678
    Yes, and it's completely normal for that to be the case. You were vague on the time you've been at it other than it being a "little bit" but I know in my case the time it took before I felt comfortable with my first programming language was at least several weeks if not a month or more and it wasn't anywhere near the complexity of a modern language.
     
  9. Dai-22

    Dai-22

    Joined:
    Jan 19, 2018
    Posts:
    64
    The reason i'm trying to focus on C# in general, is because it is standard for unity and cry engine and visual studio windows console apps etc. Someone online who's a multi-language programmer mentioned that you should learn the "Core" first, it's the same in nearly all programming. That's basically C# visual studio book or similar etc. Covering all basics. Even that is still difficult for me, so i'm looking at C# tutorials also on youtube. It is slow and boring, until I figure something out and can use it. But I haven't figured much out yet :)