Is there a way to trigger the skybox to change when the PC collides with an object (or, more specifically, when the PC collides with an object while possessing another object). I just want to add the skybox change to the changes I have already when the FPC collides with this object.
I have been looking for an answer also and this is what worked for me, very simple.
var mat:Material;
function OnTriggerEnter(trigger: Collider){
RenderSettings.skybox=mat;
}
You add the script to an object and when the player collides with the object it changes the skybox material to what ever you set it to in the inspector panel.
Are you getting an error? If your not, I'd say it looks fine... But, its a little hard to read...
– AVividLight