From 555298f9c0ad1d962f8b582f0450bb68a72aacf4 Mon Sep 17 00:00:00 2001 From: Vivek Singh Negi Date: Tue, 1 Oct 2019 19:56:21 +0530 Subject: [PATCH] Start and Update not needed. --- Assets/Scripts/Button.cs | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/Assets/Scripts/Button.cs b/Assets/Scripts/Button.cs index 8b53c9e..1b328e9 100644 --- a/Assets/Scripts/Button.cs +++ b/Assets/Scripts/Button.cs @@ -7,17 +7,8 @@ public class Button : MonoBehaviour { public UnityEvent invokeMethod; // Set in editor - // Use this for initialization - void Start () { - - } - - // Update is called once per frame - void Update () { - - } - - void OnMouseDown() { + void OnMouseDown() + { invokeMethod.Invoke(); } }