Files
forest/Assets/scripts/mainstick.cs
2022-09-24 17:41:59 +03:00

20 lines
415 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
public class mainstick : MonoBehaviour
{
public Fireplace Firething;
private void OnTriggerEnter(Collider other)
{
if(other.tag == "Player")
{
other.GetComponent<PlayerMovement>().stickCount += 1;
GameObject.Destroy(gameObject);
}
}
}