I am working on a train system for my miniature city simulator and the parts with velocity keep falling so I added this script into one of the carriages
game.Workspace.TrainFront.BodyForce.force = Vector3.new(0, TrainFront:GetMass(),-2)
and in the output it says as an error Workspace.TrainFront.Script:2: attempt to index global 'TrainFront' (a nil value) Can anyone help?
It should be
Workspace.TrainFront.BodyForce.Force = Vector3.new(0,Workspace.TrainFront:GetMass(),-2)