Search Unity

How can i use free-look cameras in a multiplayer game

Discussion in 'Cinemachine' started by Pedronsa_, Sep 12, 2021.

  1. Pedronsa_

    Pedronsa_

    Joined:
    May 8, 2021
    Posts:
    3
    I'm making a multiplayer third-person network game, how can i use multiple free-look cameras because every time another player joins the camera moves to the other player.
     
  2. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    7,728
    Don't instantiate a FreeLook for every player. Have a single FreeLook in your scene, and set its LookAt and Follow targets to the player you want to follow.
     
  3. Pedronsa_

    Pedronsa_

    Joined:
    May 8, 2021
    Posts:
    3
    Should i do it by code?
     
  4. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    7,728
    That's what you need to do, yes.
     
  5. Pedronsa_

    Pedronsa_

    Joined:
    May 8, 2021
    Posts:
    3
    Thank you!