onTriggerEnter2D kod satırı çalışmıyor sebebi ne olabilir. prefabs olan mermi ve balonum var mermi balona değdiğinde kaybolsun istiyorum fakat çalışmıyor değdiğine dair geri dönüt vermiyor. kodu ateş etmesi için yazdığım koda ekledim.
onTriggerEnter2D kod satırı çalışmıyor sebebi ne olabilir. prefabs olan mermi ve balonum var mermi balona değdiğinde kaybolsun istiyorum fakat çalışmıyor değdiğine dair geri dönüt vermiyor. kodu ateş etmesi için yazdığım koda ekledim.
Translation:
Remove public
from your method definition. Not sure if you can have that method as public (I don’t think I have ever seen anyone trying to do that before).
It is supposed to be OnTriggerEnter2D
not onTriggerEnter2D
. Capitalisation matters when coding.
I would also recommend posting in English next time so people don’t have to translate what you have posted before they can help. Even using Google Translate would be fine (it’s what I did).
First of all, thank you very much. I did it the way you said and it worked. I’m very happy. I am so inexperienced in this forum and coding, sorry for making you busy about translating etc… , I will act in accordance with your recommendations from now on.
It shouldn’t make a difference. Making the method public
just means other scripts can call it, which is likely not necessary, but it wouldn’t prevent the Unity callback from working.