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

public class DebugDrillSpawner : MonoBehaviour
{
    [SerializeField] private DebugDrill _drillPrefab;
    void Update()
    {
#if UNITY_EDITOR
        if (Input.GetMouseButtonDown(0) && GameManager.Instance.IsGamePlaying)
        {
            Vector2 pos = Camera.main.ScreenToWorldPoint(Input.mousePosition);
            GameObject.Instantiate(_drillPrefab, pos, Quaternion.identity, transform);
        }

        if (Input.GetMouseButtonDown(1))
        {
            GameManager.Instance.GameOver();
        }
#endif // UNITY_EDITOR
    }
}
