- Home /
Question by
Play4FreedomDE · Apr 17, 2016 at 12:12 PM ·
animationscripting problemontriggerenterhelicopter
Another script problem... Where´s the failure??
Hey guys, i wrote a script for entering a helicopter with an animation. the heli in the world (not functionable) is named "model" and the working one is called "work". when i save the script, a lot of bugreports arrive (missing semicolons, unknown "function OnTriggerEnter" and so on). I have NO idea what the problems are and would be extremly happy if someone could help me / or even writes an example. If it works, i´ll put it in the asset store (of course for free) another question: after i enter the heli, how can i parent the PlayerObject? Regards, me
the code:
var model = Transform;
var work = Transform;
function Start () {
model = true;
work = false;
}
function Update () {
function OnTriggerEnter (other : Collider) {
model = false;
work = true;
function GetComponent(Animation)("Enter");
}
}
PS: the animation also doesnt work...
Comment