Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Unity Lesson 1 Draft

Discussion in 'Community Learning & Teaching' started by AnomalusUndrdog, Sep 6, 2011.

Thread Status:
Not open for further replies.
  1. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    Here's a series of tutorials I made when I taught the faculty staff of a school about Unity. Let me know what you guys think!

    EDIT: This first post will always be updated to have the complete list of all the lessons. Here are all of them so far:


    Lesson 1: Introduction To Unity: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson1.pdf
    How To Create A Project
    Familiarizing Yourself With The Unity Editor GUI
    Manipulating The Camera
    Creating And Manipulating Objects
    Introduction To Components


    Lesson 2: Creating A Basic Level: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson2.pdf
    Creating Terrain
    Adding Trees
    Adding Wind
    Adding Grass
    Adding Rocks
    Adding A Campfire
    Using Particle Effects To Add Fire (And Smoke)
    Adding Sky
    Adding Fog
    Adding Sound And Music
    Adding Lens Flare
    Publishing The Game As An .EXE File
    Publishing The Game On The Browser


    Lesson 3: Introduction To Scripting: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson3.pdf
    Creating Your Own Scripts
    Where To Get Online Help


    Lesson 4: Creating The Player: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson4.pdf
    Learning About Folder Organization
    Introducing The Character Controller
    Using Keyboard Input To Move The Player


    Lesson 5: Creating The Camera System: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson5.pdf
    Creating The Camera System
    An Explanation About World Space And Local Space
    Creating The Crosshair Using GUI


    Lesson 6: Basic Enemy AI: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson6.pdf
    Using Tags
    Adding Chasing Behaviour
    About Normalizing


    Lesson 7: Prefabs: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson7.pdf
    Making Prefabs
    Editing Prefabs


    Lesson 8: Damaging: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson8.pdf
    Adding Health
    Using Raycasts To Shoot
    Dealing Damage
    Changing Behaviour On Death


    Lesson 9: 3d Models And Animations: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson9.pdf
    Importing 3d Models
    Using GetComponentInChildren
    Playing Stopping Animations
    An Explanation About Quaternions
    How To Generate Random Numbers
    Mixing Two Animations Together


    Lesson 10: Ragdolls And Death: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson10.pdf
    Using Layers
    Layer Collision Matrix
    Joints
    Deleting Components


    Lesson 11: Enemy Damaging: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson11.pdf
    Using trigger colliders
    Using Time.time to measure time elapsed
    C# Properties


    Lesson 12: Enemy Spawning: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson12.pdf
    Viewport Space
    Layer Masks
    isVisible


    Lesson 13: Winning Conditions: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson13.pdf
    Invoke
    Animation View
    Trigger Colliders


    Lesson 14: Main Menu GUI: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson14.pdf
    GUI: Buttons, Selection Grids, Horizontal Sliders
    GUI Skins
    Saving and Loading Data using Player Prefs


    Lesson 15: Visual And Sound Effects: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson15.pdf
    Unparenting Children


    Lesson 16: Pick-up Items: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson16.pdf


    Lesson 17: Weapons Part 2: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson17.pdf
    Refactoring Code



    Lesson Assets: http://dl.dropbox.com/u/25260770/UnityLessons/Assets/index.htm
    Lesson Assets Zipped: http://dl.dropbox.com/u/25260770/UnityLessons/LessonAssets.zip

    Lesson Archive: http://dl.dropbox.com/u/25260770/UnityLessons/index.htm
     
    Last edited: Apr 16, 2013
  2. shader

    shader

    Joined:
    Apr 4, 2009
    Posts:
    253
    Looks very useful, are you going to add all the tutorials ?
    Thanks
     
  3. BlueRain01

    BlueRain01

    Joined:
    Aug 22, 2010
    Posts:
    86
    nice it help !
     
  4. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    Thanks for the comments guys. Here's all of them so far:

    Lesson 1: Introduction To Unity: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson1.pdf
    How To Create A Project
    Familiarizing Yourself With The Unity Editor GUI
    Manipulating The Camera
    Creating And Manipulating Objects
    Introduction To Components

    Lesson 2: Creating A Basic Level: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson2.pdf
    Creating Terrain
    Adding Trees
    Adding Wind
    Adding Grass
    Adding Rocks
    Adding A Campfire
    Using Particle Effects To Add Fire (And Smoke)
    Adding Sky
    Adding Fog
    Adding Sound And Music
    Adding Lens Flare
    Publishing The Game As An .EXE File
    Publishing The Game On The Browser

    Lesson 3: Introduction To Scripting: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson3.pdf
    Creating Your Own Scripts
    Where To Get Online Help

    Lesson 4: Creating The Player: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson4.pdf
    Learning About Folder Organization
    Introducing The Character Controller
    Using Keyboard Input To Move The Player

    Lesson 5: Creating The Camera System: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson5.pdf
    Creating The Camera System
    An Explanation About World Space And Local Space
    Creating The Crosshair Using GUI

    Lesson 6: Basic Enemy AI: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson6.pdf
    Using Tags
    Adding Chasing Behaviour
    About Normalizing

    Lesson 7: Prefabs: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson7.pdf
    Making Prefabs
    Editing Prefabs

    Lesson 8: Damaging: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson8.pdf
    Adding Health
    Using Raycasts To Shoot
    Dealing Damage
    Changing Behaviour On Death

    Lesson Assets: http://dl.dropbox.com/u/25260770/UnityLessons/Assets/index.htm
    Lesson Assets Zipped: http://dl.dropbox.com/u/25260770/UnityLessons/LessonAssets.zip

    Lesson Archive: http://dl.dropbox.com/u/25260770/UnityLessons/index.htm
     
    Laziemo, EllebSaj and Farrukh_1 like this.
  5. shader

    shader

    Joined:
    Apr 4, 2009
    Posts:
    253
    very well produced, thanks
     
  6. Schlumpfsack

    Schlumpfsack

    Joined:
    May 30, 2010
    Posts:
    608
    Great one...thank you very much
     
  7. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    Oh, and I'll just add:

    It is recommended that you have learned the fundamentals of object-oriented programming before reading these lessons.
     
  8. shader

    shader

    Joined:
    Apr 4, 2009
    Posts:
    253
    looking forward to 9, 10, 11 ..... how many will you produce ?

    Thank you
     
  9. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    As many as it needs to finish teaching the game. I may even go to multiplayer networking after the game is finished.
     
  10. shader

    shader

    Joined:
    Apr 4, 2009
    Posts:
    253
    Great !
     
  11. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
  12. Mordekai

    Mordekai

    Joined:
    Nov 8, 2009
    Posts:
    24
    Thanks for making these!
     
  13. hippocoder

    hippocoder

    Digital Ape

    Joined:
    Apr 11, 2010
    Posts:
    29,723
    Nice work, that should help a lot of people.
     
  14. shader

    shader

    Joined:
    Apr 4, 2009
    Posts:
    253
    Hi

    There seems to be some missing illustrations from the 9th pdf file

    thanks
     
  15. wicked208

    wicked208

    Joined:
    Oct 25, 2010
    Posts:
    83
    very good tutorials thanks for your work
     
  16. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    Yeah its a bug in LibreOffice that corrupts embedded images when autosave kicks in. The OpenOffice devs are too busy pointing fingers instead of fixing it.

    I've fixed the document, let me know if there are any other problems.
     
  17. shader

    shader

    Joined:
    Apr 4, 2009
    Posts:
    253
    Hi

    Where might I find the fixed pdf ?

    Incidentally, I was reading you blog site and I noted your comments on MonoDevelop. I too share your thoughts about it. NotePad++ is also my preference.

    Thank you.
     
  18. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
  19. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
  20. shader

    shader

    Joined:
    Apr 4, 2009
    Posts:
    253
    thanks !
     
  21. Costy

    Costy

    Joined:
    Sep 27, 2011
    Posts:
    65
    You did a great job! you should make it all in a single pdf file. It would make a very good book.
     
  22. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
  23. shader

    shader

    Joined:
    Apr 4, 2009
    Posts:
    253
    Thanks, really good of you.
     
  24. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    Lesson 13: Winning Conditions: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson13.pdf

    Invoke
    Animation View
    Trigger Colliders


    Lesson 14: Main Menu GUI: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson14.pdf

    GUI: Buttons, Selection Grids, Horizontal Sliders
    GUI Skins
    Saving and Loading Data using Player Prefs


    Lesson 15: Visual And Sound Effects: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson15.pdf

    Unparenting Children


    Lesson 16: Pick-up Items: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson16.pdf


    Lesson 17: Weapons Part 2: http://dl.dropbox.com/u/25260770/UnityLessons/FeuUnity3dLesson17.pdf

    Refactoring Code



    That's about all of it for now.
     
  25. Schlumpfsack

    Schlumpfsack

    Joined:
    May 30, 2010
    Posts:
    608
    just awesome!

    Thank you for this!
     
  26. Swearsoft

    Swearsoft

    Joined:
    Mar 19, 2009
    Posts:
    1,632
    wow this looks good.

    bookmarked.
     
    Last edited: Jan 4, 2012
  27. wicked208

    wicked208

    Joined:
    Oct 25, 2010
    Posts:
    83
    wowwwww, thanks very much, very awesome
     
  28. Swearsoft

    Swearsoft

    Joined:
    Mar 19, 2009
    Posts:
    1,632
    I've been going through them and they are really good, simple and to the point.
     
  29. Swearsoft

    Swearsoft

    Joined:
    Mar 19, 2009
    Posts:
    1,632
    If you have done networking before you should most definitely do that too. Your descriptions are clear and I prefer your tutorial to the Unity prodived ones.

    cheers!
     
  30. TwiiK

    TwiiK

    Joined:
    Oct 23, 2007
    Posts:
    1,729
    Seems like a very nice and thorough tutorial, but it honestly didn't get off to a good start for me. :p

    I downloaded the zip with the assets and notice there are 2 folders with the same assets. Instant confusion.

    Then I open the first pdf and it tells me to open the lesson 1 project. Looks through the assets folders, nothing. Looks through your dropbox folder and this forum and still nothing. Confusion growing. Is there a folder missing from the zip file?
     
  31. rockysam888

    rockysam888

    Joined:
    Jul 28, 2009
    Posts:
    650
  32. OMG!Yeti's

    OMG!Yeti's

    Joined:
    Jan 9, 2012
    Posts:
    27
    Nice stuff. Thanks for taking the time to create it.
     
  33. TwiiK

    TwiiK

    Joined:
    Oct 23, 2007
    Posts:
    1,729
    It seems it was just the first lesson that was a little confusing with the missing project folder. The rest of the tutorial is excellent.

    Even though it's a simple tutorial I'm learning quite a bit because you're explaining everything so well. Like what the "out" keyword or "SerializeField" actually does.
     
  34. TwiiK

    TwiiK

    Joined:
    Oct 23, 2007
    Posts:
    1,729
    Absolutely excellent tutorial.

    Thought me a lot about GUI, animation etc. Things I've been avoiding before because they looked boring. :)

    The only thing that bothered me is that you didn't explain the virtual and protected keywords when you used them in the end. Still not sure what they do. :)

    This could easily be a book. Great work.
     
  35. Vimalakirti

    Vimalakirti

    Joined:
    Oct 12, 2009
    Posts:
    755
    Uber cool. Really great. Wow. Talk about community spirit!

    Thank you.
     
  36. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    Oh man, sorry, I completely forgot about that. While I'm busy right now, when I get the time, I'll fix that.
     
  37. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    Ok, I tried my best in explaining virtual and protected in Lesson 17. I added the Lesson 1 project in the Lesson Assets zip file as well.
     
  38. lazyme

    lazyme

    Joined:
    Jan 24, 2012
    Posts:
    4
    Really helpful man.
    Thanks!
     
  39. Ebkac

    Ebkac

    Joined:
    Feb 3, 2012
    Posts:
    62
    Seriously great stuff. As a new to Unity user as of two weeks ago, thank you for the hours you put into this.
     
  40. SevenBits

    SevenBits

    Joined:
    Dec 26, 2011
    Posts:
    1,953
    Very nice tutorials! I see lots of thought was put into this.
     
  41. Kokumo

    Kokumo

    Joined:
    Jul 23, 2010
    Posts:
    416
    To my favourites! :D
    Thanks a lot!
     
  42. KeithInc

    KeithInc

    Joined:
    Feb 13, 2012
    Posts:
    6
    nvm found it
     
    Last edited: Feb 19, 2012
  43. UleaUX

    UleaUX

    Joined:
    Sep 22, 2012
    Posts:
    1
    These tutorials are great!
    except in lesson 9 I didn't have the 'Player-01 Default' material, but it gave me something called 'main_player_diffuse_deleteme'
    any suggestions?
     
    Last edited: Dec 2, 2012
  44. AnomalusUndrdog

    AnomalusUndrdog

    Joined:
    Jul 3, 2009
    Posts:
    1,551
    Probably Unity 4 does things differently now. It shouldn't matter what the exact name is, it should still essentially be the same thing I'm referring to in the tutorial. Send me a PM (so I can get notified) if things don't go working properly.
     
  45. yasirkula

    yasirkula

    Joined:
    Aug 1, 2011
    Posts:
    2,864
    How could I miss these tutorials! They look so great. It is obvious that you've spent lots of time to make them. Thanks a lot. I'll also share their links on my blog.

    P.S: I advise you to change the title of this topic if you can, something like "Free e-book" maybe :)
     
    Last edited: Dec 7, 2012
  46. Zace66

    Zace66

    Joined:
    Dec 11, 2012
    Posts:
    5
    I love this.
    Ive just picked up Unity, so am using this as one of my first walk throughs, then I may use it as a teacher too.
    However Im having problems downloading the assets zip file.

    Is it ok still as i get a 404
     
  47. yasirkula

    yasirkula

    Joined:
    Aug 1, 2011
    Posts:
    2,864
  48. DeZako

    DeZako

    Joined:
    Jan 7, 2013
    Posts:
    3
    Amazing tutorials, getting through the 6º one at the moment! Love the way you explain things, that you have packed the resources... Definitely, a must for begginers like me, seriously. Thanks for putting so much work in this, and giving it away for free.

    edit: Quick question if anyone can help me with it... I´m going through lesson 8, but the raycasting seems to malfunction, returning null reference exceptions. The code is exactly like the one you provided, but it still doesnt work...
     
    Last edited: Jan 9, 2013
  49. yasirkula

    yasirkula

    Joined:
    Aug 1, 2011
    Posts:
    2,864
    Can you give the code here if it is short?
     
  50. DeZako

    DeZako

    Joined:
    Jan 7, 2013
    Posts:
    3
    It is. This is the Health script:

    Code (csharp):
    1. using UnityEngine;
    2. using System.Collections;
    3.  
    4. public class Health : MonoBehaviour {
    5.  
    6.     [SerializeField]
    7.     int _maximumHealth = 100;
    8.     int _damageDealt;
    9.     int _currentHealth = 0;
    10.    
    11.    
    12.     void Start()
    13.     {
    14.     _currentHealth = _maximumHealth;
    15.     }
    16.     public void Damage(int damageValue)
    17.     {
    18.        
    19.          _currentHealth -= damageValue;
    20.        
    21.        
    22.     }
    23. }
    24.  
    And the RifleWeapon script;
    Code (csharp):
    1. using UnityEngine;
    2. using System.Collections;
    3.  
    4. public class RifleWeapon : MonoBehaviour {
    5.  
    6.     [SerializeField]
    7.     int _damageDealt = 50;
    8.    
    9.    
    10.     void Update () {
    11.         if (Input.GetButtonDown("Fire1"))
    12.         {
    13.             Ray mouseRay = Camera.main.ViewportPointToRay(new Vector3(0.5f, 0.5f, 0));
    14.             RaycastHit hitInfo;
    15.    
    16.             if (Physics.Raycast(mouseRay, out hitInfo))
    17.             {
    18.                 Health enemyHealth = hitInfo.transform.GetComponent<Health>();
    19.                 if (enemyHealth != null)
    20.                 {
    21.                    
    22.                     enemyHealth.Damage(_damageDealt);
    23.                 }
    24.                
    25.             }
    26.         }  
    27.     }
    28. }
    29.  
    I´ve tried tweaking here and there, but I can´t put my finger on the problem that pops out the null reference exception... Thanks for the help, anyway :D
     
Thread Status:
Not open for further replies.