- Home /
UI and Collision Detection zone
hello! firtly i'm sorry for my bad english, let me know if something are not clear so i'll try to explain it better...
actually in my scene i have one object that is rotating, with that i'm taking track of where actually it is with this UI
where the green is my player, and the red zone is a zone where if there is a key input it will rotate again, well, untill here i did it, i'm also able to know where is in that zone, but i did it manually, but setting the scale size of the UI and by just set for example that UI image on 45 degrees, then i'm just checking with Quaternion Angle if it is closest more than 5 degrees to 45 degrees then he are in that zone...
but with this method i have to manually do it for every "red zone" that i'm going to create, i want to do it dinamically, scale that UI by taking the area size that i want to be.... because if i set the detection area not on 5, but 10, i have to re-scale the UI to make it fill with the object
anyone can help me?
Your answer
![](https://koobas.hobune.stream/wayback/20220612190317im_/https://answers.unity.com/themes/thub/images/avi.jpg)