- Home /
This question was
closed Jun 26, 2011 at 03:48 AM by
Bravini for the following reason:
Other
How you change another script value smoothly on trigger
Hello friendlies
I do following but it has two problem, first it happens on any collider and I want that only when player trigger it, and more the change is instant and I want it to be smooth over time, how to fix it?
function OnTriggerEnter (other : Collider) {
var go = GameObject.FindWithTag("MainCamera");
go.GetComponent("SmoothFollow").distance = Mathf.SmoothStep(6, 20, 5);
}
Sorry for my English I use google translated
Comment
Follow this Question
Related Questions
Moving player in an arc, from startPoint to endPoint 2 Answers
Player triggered cutscene with collider? 1 Answer
Help with Lerp 0 Answers
Modified SmoothFollow 0 Answers
How to make sliding room transitions like in Mega Man? 1 Answer