Search Unity

error CS0103

Discussion in 'Editor & General Support' started by TegrityStudio, Sep 16, 2020.

  1. TegrityStudio

    TegrityStudio

    Joined:
    Sep 14, 2020
    Posts:
    2
    Hello in need of assistance for fixing this error. I am trying to set boundaries to my camera after using the 2d CineMachine to follow the player. Console.PNG Script.PNG
     
  2. Valjuin

    Valjuin

    Joined:
    May 22, 2019
    Posts:
    481
    TegrityStudio likes this.
  3. PraetorBlue

    PraetorBlue

    Joined:
    Dec 13, 2012
    Posts:
    7,911
    You can't use variables that you never declared. I don't see any variables called
    targetPosition
    declared in your script.

    Maybe you meant to write
    target.position
    ?
     
    TegrityStudio likes this.
  4. TegrityStudio

    TegrityStudio

    Joined:
    Sep 14, 2020
    Posts:
    2
    Thank you both! I had learned from some Cinemachine tutorials that you can adda confiner extension and use a Bounding shape 2d to make the boundaries for the Camera. Again thank you for your time!