---
tags:
    - "Click"
    - "Press"
    - "Collider"
    - "Cursor"
    - "Pick"
    - "Touch"
---

# On Mouse Down

[Input](../index.md) / [Cursor](index.md) / **On Mouse Down**

## Description

Executed when the mouse button is pressed over the target collider

## Code

```cs
using System;
using UnityEngine;
using VisualScript.Icons;

namespace VisualScript.Runtime
{
    [Title("On Mouse Down")]
    [Image(typeof(IconMouse), ColorTheme.Type.Blue, typeof(BadgeArrowDown))]

    [Description("Executed when the mouse button is pressed over the target collider")]
    [Category("Input/Cursor/On Mouse Down")]

    [Keywords("Click", "Press", "Collider", "Cursor", "Pick", "Touch")]

    [Serializable]
    public class TriggerCoreMouseDown : TriggerHandleSourceBase<HandleOnMouseDown>
    {
        // PROPERTIES: ----------------------------------------------------------------------------

        protected override string GetTitle(GameObject source) => $"{this.SourceName} Mouse Down";

        // OVERRIDE METHODS: ----------------------------------------------------------------------

        protected override void OnTrigger(GameObject target)
        {
            using Args args = Args.Get(this.Component, target);
            this.Run(args);
        }
    }
}
```

