help: 3d spaceship movment

ok i am stuck on how to make my spaceship move in 3d space im not a coder and the coder i have is a beginer in javascript so if you can. can someone post code for this i need it to see how the spaceship will move

or if anyone is willing to hel;p code the game that wound be good this game is free to play but we will run most things with in-game rotating ads if you wound like more info just ask :slight_smile:
thanks for your time

If you are using the Rigidbody component, have your coder look at adding forces to it. If you are going with purely kinematic controls, have him read about the Transform component.

hmmm my scripter says he is learning java not javascript now im stuck if anyone is willing to help that wound be good

I guess you don’t have a scripter then, do you?

If this is a paid gig, I will write up something tonight. If it is not a paid gig, you can learn scripting yourself as Javascript is quite easy, or you can head over to the collaboration section and hope somebody is interested.

well its royaltys and parnership so when the game is done all money earned will be split but this means you will have to code for us everything that we need and if this game gose well then you will be the first to be contacted if a new game is going to be made and you will have a say in how everything is run

i have a masive 58 page game doc aswel

That equals unpaid, but you still might be able to get someone onboard, especially if you’re bringing something to the table yourself (e.g. art assets). Anyway, I’d recommend giving the Collaboration forum a try and see if you can find someone there.

so dose anyone got a spare peace of script they can give?

As mentioned, try the Collaboration forum (if you haven’t already).

Yeah, it’s unlikely someone is going to program your game for you. If you can’t even get a start on some basic ship controls then you need to start simpler, follow some tutorials until you at least have an idea how it might be done, or find a coder to join your team.

Plus even if you get this script there is so much more you need to do!

PS If he can code java, picking up javascript is easy.

im just learning javascript now

P.S. java is diffrent to javascript

Here you have some clues
Use Constant forces to simulate the movement. Instead a normal force, use a relative force.

constantForce.relativeForce.z = Input.GetAxis(“Vertical”) * speed * Time.deltaTime; // Moves the spaceship forward

Assuming it’s a spaceship you don’t need to simulate gravity, so deactivate it, anyway, you can make something to toggle it On/Off

Just make the same for the others moves as you want. Attach a constant force to your spaceship and check the possible movements.

i will try it thanks but how to do move the spaceship around with you mouse like not click and move like on a FPS you can look up and down and move around on the spot so the WASD keys are the same but when you look up and then press W it moves up how do i set the gravaty to 0

Java is a million times more like C# than it is anything like Javascript.

If you programmer knows Java, C# should come naturally. I went from Java to C# with the occasional trip to Google when I got stuck, was quite painless.

I also use to code a lot of Actionscript (i still teach Actionscript classes) which is identical to Unity Javascript, but prefer using C# with Monodevelop as the auto-complete and other features speed things up a lot and the stricter compile time checking mean less head-scratching runtime bugs to chase my own tail with.

Vertical Formula:-
Forcesin(angle)+LiftForceCos(angle)-weight=vertical force
Horizontal Force Formula:-
Forcecos(angle)-LiftForceSin(angle)=horizontal force
Please fit this formula into the Java Script
email id:-mkbluesky513@gmail.com or send me answer in my inbox of this forum,but if u do than must send me pls…