Search Unity

Make a prefab appear and disappear based on mouse click / finger touch.

Discussion in 'Editor & General Support' started by etothepowerx, Apr 16, 2022.

  1. etothepowerx

    etothepowerx

    Joined:
    Apr 12, 2022
    Posts:
    1
    I have a canvas on which I have added a 'Fixed Joystick' prefab downloaded from the asset store.
    I want to make this joystick appear on the screen only when the mouse click is detected, or when the finger is touching the screen. When the mouse click is released, or the finger is lifted from the screen, the joystick should disappear.

    I am a beginner at Unity, so trying to figure out how to go ahead with this. Kindly guide..