1
Fork 0
mirror of https://github.com/Steffo99/beat-td.git synced 2024-11-22 23:34:19 +00:00
beat-td/Assets/Scripts/InstantiateOnClick.cs

18 lines
392 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class InstantiateOnClick : MonoBehaviour
{
public GameObject original = null;
void Update () {
if (Input.GetMouseButtonDown(0))
{
if (original != null)
{
Instantiate(original, transform.position, transform.rotation);
}
}
}
}