Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How could I make my controller better and more normal?

Asked by 7 years ago

I'm trying to make a mini game and the player is replaced with a cube, I need to be able to move the cube more efficiently. Any and all answers are appreciated.


Object = workspace.PlayerCube game:GetService("UserInputService").InputBegan:connect(function(Input) if Input.KeyCode == Enum.KeyCode.D then Object.BodyForce.Force = Vector3.new(7,196.2,0) * Object:GetMass() end if Input.KeyCode == Enum.KeyCode.S then Object.BodyForce.Force = Vector3.new(0,196.2,7) * Object:GetMass() end end)

I used 196.2 in the Y axis to get rid of the downward force of gravity but then it gets tricky for me to script the rest.

Answer this question