3. Adım: Düşmanı ve PowerUp’ı test edin
PowerUp yalnızca çok özel bir durumda devreye girer: oyuncunun bir PowerUp’ı olduğunda VE bir düşmanla çarpıştıklarında - bu yüzden önce bu çok özel durumu test edeceğiz.
- Yeni bir "Düşman" etiketi oluşturun ve bunu Düşman Hazır Yapısına uygulayın
- PlayerController.cs'de OnCollisionEnter() işlevini ekleyin
- Düşman etiketi ve hasPowerup boolean için çift koşul testi ile if ifadesini oluşturun
- Çalıştığından emin olmak için bir Debug.Log oluşturun

Lesson discussion
Swap insights and ask questions about Unity Junior Programmer
Be the first to start the discussion
Ask a question or share your thoughts about this lesson.