I really hate to ask such a n00b question, but this is getting pretty annoying and everything I have searched and tried has not worked.
his is so confusing… I have a simple area that I want the player to interact with using a Trigger… and it doesn’t seem to work.
I DO have a Rigidbody2D on my player, and this is the script I have added to the object I want to interact with, and it has a Box Collider 2D on it. The collision isn’t working though, as whenever I walk into it I do not see my Debug.Log.
What is going on?
Here is the code
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class DeliveryZone : MonoBehaviour
{
void OnTriggerEnter2D(Collider2D other) {
if (other.gameObject.tag == "Player")
{
Debug.Log("working");
}
}
}