local BV = Instance.new("BodyVelocity")
BV.Parent = script.Parent
BV.MaxForce = Vector3.new(math.huge, math.huge, math.huge)
BV.Velocity = workspace.Part.Position.Unit*50

This script has the velocity a bit offset; however if you change line 4 to this:

local BV = Instance.new("BodyVelocity")
BV.Parent = script.Parent
BV.MaxForce = Vector3.new(math.huge, math.huge, math.huge)
BV.Velocity = (workspace.Part.Position - script.Parent.Position).Unit*50

it works.

Why does the bottom one work but not the top one? What is happening at the bottom one?

3 comments

0

Here's a vague explanation. The first one is the Position of the Part. The 2nd one is very different: it's the DISTANCE between the two parts. A Unit of that will be the direction of the two parts. The first one doesn't really make any sense to be normalizing.

0

Imagine if the first part is at world space (0, 0, 0) and the 2nd one is at (0, 1, 0). First part minus the 2nd part would be (0, -1, 0), right? That's the direction the parts are facing (up/down depending on relativity)

0

Sorry that it's not 'in depth', but it's simple enough