본문 바로가기

스터디/▢ 코딩

update()

code

void OnTriggerEnter(Collider other) 

	{

		if (other.gameObject.CompareTag ("Pick Up"))

		{

			other.gameObject.SetActive (false);



			count = count + 1;

           

            SetCountText ();

            Debug.Log(count);

}