FragMate CommunityLog in

FragMate - Software and Game Developer Community, including Resources, Forums, Marketplace & More.

Share

descriptionNeed Help. Code Doesnt Work.

more_horiz
hello... i have a cube in my project and i made this script to make him move forward... i fixed the "Axes" i applied the script to my player... all corect... but when i press play and i click w it doesnt move! ! why?

thats my code


Code:

#pragma strict

var moveSpeed : float;

function Start () {

}

function Update () {
if(Input.GetButton("Forward")) {
  transform.Translate(transform.forward * moveSpeed * Time.deltaTime);
  }
}

descriptionRe: Need Help. Code Doesnt Work.

more_horiz
PROBLEM SOLVED

descriptionRe: Need Help. Code Doesnt Work.

more_horiz
May you please write what was the problem, just if anyone else experiences this same problem they would know what to do.

--New Developer

descriptionRe: Need Help. Code Doesnt Work.

more_horiz
@NewDeveloper wrote:
May you please write what was the problem, just if anyone else experiences this same problem they would know what to do.

--New Developer


i didnt had colour to my terain so my player at reality was moving but i coudnt see it in the screen cause terain was black... i had puted a directional light at full dark so... that was the prob
Permissions in this forum:
You cannot reply to topics in this forum