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

Hey guys need help with this i followed a YouTube video and now am stuck

Discussion in 'Scripting' started by reececass, Oct 21, 2019.

  1. reececass

    reececass

    Joined:
    Oct 21, 2019
    Posts:
    1
    so am following a YouTube video to make a game as am new to coding and with unity and all but anyway i got to near the end and i pressed play and it came up fix error CS0103.


    upload_2019-10-21_22-37-46.png
     

    Attached Files:

  2. MrArcher

    MrArcher

    Joined:
    Feb 27, 2014
    Posts:
    106
    Yeah, you're much better off posting the code as well as the full error. Luckily, the error is visible in the screenshot. You've misspelled 'FindObjectOfType' on line 27.
     
    Batuhan13 and Yoreki like this.
  3. Yoreki

    Yoreki

    Joined:
    Apr 10, 2019
    Posts:
    2,605
    As the others missed their opportunity to do so, i'd like to add a "welcome to the forum" to this post :)

    What MrArcher said is true, even tho spelling mistakes like these should be underlined with a red squiggly line. I'm not sure why that's not happening for you. You may wanna look into that. Or maybe somebody who knows adds an explanation below.
     
  4. Batuhan13

    Batuhan13

    Joined:
    Apr 9, 2017
    Posts:
    117
    Firstly you need to change your IDE theme to black we coders dont like white IDE theme and we dont want to help people who is using white theme secondly you made misspelling in line 27("FindObjectOfType").
     
  5. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,753
    I assume you are just joking....

    If someone prefer to use bright UI that is fine. Maybe don't know different. But next I expect to hear, "I don't help anyone using Unity bright theme". Btw, is 'You' not 'Us', nor even 'Most'.
     
  6. Batuhan13

    Batuhan13

    Joined:
    Apr 9, 2017
    Posts:
    117
    Ofc mate I am just kidding =) as you see in the end of my line I showed what is problem on his code =)