Input.GetMouseButtonDown dosnt work

using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Click : MonoBehaviour
{
// Start is called before the first frame update
void Start()
{
GetComponent();

}

// Update is called once per frame



void Update()
{
    var check = Input.GetMouseButtonDown();

You have to specify which button you are pressing Input.GetMouseButtonDown
and with this process, however, you would not get anything …

These are the syntaxies

Input.GetMouseButtonDown(0)   // Left Button
Input.GetMouseButtonDown(1)   // Right Button

You can use also use, the one-to-one

Input.GetMouseButtonDown(Fire1)   // Left Button
Input.GetMouseButtonDown(Fire2)   // Right Button

in Edit > Project Settings > Input Manager > Axis :: You can find all the input value returns set by default and modifiable

  • If you are a beginner I suggest you initially follow some basic Unity and C # tutorials