using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
using UnityEngine.EventSystems;

namespace MPStudio
{
    [RequireComponent(typeof(ScaleBigToSmall))]
    public class BtnHover : MonoBehaviour,IPointerEnterHandler
    {
        public string audioName = "";


        private Text _txt;
        private void Awake()
        {
            _txt = GetComponentInChildren<Text>();
        }

        // Start is called before the first frame update
        void Start()
        {

        }

        private void OnMouseOver()
        {
  
        }

        public void OnPointerEnter(PointerEventData eventData)
        {
            print("over");
            if (audioName != "")
            {
                AudioManager.Inst.EffectPlay(this.audioName);
            }
            SendMessage("ScaleAnimal");
        }
    }
}