I’m trying to create an accelerating bicycle using a VectorForce. However, when it is applied, my bike spins around in circles. If anyone could advise me on how to properly apply this force, or of an alternative method instead of a VectorForce to achieve an accelerating bicycle, that would be greatly appreciated. I don’t need to turn the bike for it to start spinning in circles
I have a VehicleSeat in the center of which this VectorForce is parented and applied to. ApplyToCenterOfMass = true
function UpdateVehicle()
local force = 5000
if seat.Throttle == 1 and carRunning then
vectorForce.Force = Vector3.new(force, 0, 0) -- apply force if throttle = 1, ie player is moving forward
elseif seat.Throttle == -1 and carRunning then
vectorForce.Force = Vector3.new(-force, 0, 0) -- the opposite for reversing
else
vectorForce.Force = Vector3.new(0, 0, 0) -- stop the bike
end
end
Also, I’m not too sure if I need to change the direction of the force when the player turns the bike, since it appears the force is always applied on the x-axis.
Still having issues with this. Would appreciate if anyone else could help. I’ve tried using AlignPosition and the same issue occurs. It could be because the force is not on center, causing it to rotate?
Oh yes. I don’t know how to fix this. I am applying a VectorForce to the VehicleSeat and I don’t know what I should do to make it spin properly. It’s weird that the front one works fine though
It will tell you what the wheel is colliding with, and then you can add no collision constraints between the wheel and the parts that are stopping the wheel from spinning
Hm, ok in that case in the top left corner press file, studio settings, physics, then scroll down and turn on “Are Contact Points Shown” option, it will allow you to see where the wheel is colliding