Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Switching Between Two Characters Mid Game

Discussion in 'Scripting' started by DJMakkro, Apr 22, 2021.

  1. DJMakkro

    DJMakkro

    Joined:
    Apr 22, 2021
    Posts:
    2
    How would you go about, with a click of a button, switching between two characters in a first-person game? Like switching between an operator and a drone in Rainbow Six Siege?
     
  2. PraetorBlue

    PraetorBlue

    Joined:
    Dec 13, 2012
    Posts:
    7,723
    At the most basic level all you need is for each character to have a control script and a camera.

    When you press the button, you disable the control script and camera on one character, and enable the control script and camera on the other.
     
  3. DJMakkro

    DJMakkro

    Joined:
    Apr 22, 2021
    Posts:
    2
    How would you switch between them, though?
     
  4. PraetorBlue

    PraetorBlue

    Joined:
    Dec 13, 2012
    Posts:
    7,723
    The way I just said...