- Home /
Question by
colopto · Jun 08, 2011 at 09:24 AM ·
movementcharactercontrollerflight
I need help with movement script
Heres my script and from what I know about scripting it should work
function Update() {
if (Input.GetButtonDown ("W")) {
(transform.Translate(1, 0, 0));
}
}
but it dosnt i was gonna add on to it and make it so the mouse look would drive it and i could hit the "W" button to move forward so i could fly (I have yet to achieve flight)
can someone please help me in what i am doing wrong it lets me play but when i hit "W" nothing happens
i did what you told me nothing happend
Comment
Answer by G_Sacristan · Jun 08, 2011 at 10:02 AM
Input.GetKeyDown("w") or Input.GetButtonDown("Forward")
Your answer
![](https://koobas.hobune.stream/wayback/20220612101307im_/https://answers.unity.com/themes/thub/images/avi.jpg)