Is there a way to lock the Y transition of the FPS controller when using this script?
function OnTriggerEnter () {
var GO = GameObject.Find("Platform");//whatever the name of your moving platform is
var GO1 = GameObject.Find("First Person Controller");
GO1.transform.parent = GO.transform;
}
function OnTriggerExit () {
var GO = GameObject.Find("Platform");
var GO1 = GameObject.Find("First Person Controller");
GO1.transform.parent = null;
}
Thanks