Hello how are you? , the map of my game this very large with many details and this giving lag, so I tried do this script that activates objects when entering a trigger, more did not work alguem can help me?
var Cena: GameObject;
function OnTriggerEnter(otherObj: Collider){
if (otherObj.tag == "Player"){
Cena.SetActive.active = true ;
}
else {
Cena.SetActive.active = false ;
}
}
↧