This commit is contained in:
2026-01-29 15:31:57 +05:30
commit 17b8f48e8f
162 changed files with 74683 additions and 0 deletions

15
Assets/Scripts/Goal.cs Normal file
View File

@@ -0,0 +1,15 @@
using UnityEngine;
public class Goal : MonoBehaviour
{
public Team team;
void OnTriggerEnter2D(Collider2D collision)
{
if(collision.gameObject.CompareTag("Player")){
Debug.Log("GOAL!");
Ball ball = collision.gameObject.GetComponent<Ball>();
Debug.Log(ball.name);
GameManager.instance.OnGoal(team);
}
}
}