Im using linear velocity, and i want to launch the player upwards, How?

I have a script for trampoline, and i want to launch the player up wards or what ever direction the trampoline faces at.

local Pad = script.Parent
Pad.Touched:Connect(function(hit)
	script.Parent.Dust:Emit(5)
	script.Parent.DashLines:Emit(7)
	if hit.Parent:FindFirstChild("Humanoid") then
		local Attachment = Instance.new("Attachment", hit.Parent:WaitForChild("HumanoidRootPart")) 
		local LV = Instance.new("LinearVelocity", Attachment)
		LV.VelocityConstraintMode = Enum.VelocityConstraintMode.Plane
		LV.Attachment0 = Attachment 
		LV.MaxForce = math.huge
		LV.PrimaryTangentAxis = Vector3.new(1, 0, 0)
		LV.SecondaryTangentAxis = Vector3.new(0, 0, 1)
		LV.PlaneVelocity = Vector2.new(0, 1000) --> Or whatever velocity you want to put here
		--LV.VectorVelocity = hit.Parent:WaitForChild("HumanoidRootPart").CFrame.lookVector * 100
		task.wait(0.2)
		LV:Destroy()
		Attachment:Destroy()
	end

end)

This script does not launch the player upwards

I mean can’t you just Apply velocity on the Y axis? Kind of like this:

HumanoidRootPart.Velocity = Vector3.new(0, 10, 0)
2 Likes

Whats the difference between Humanoid velocity and linear velocity, how do i make the player launch the direction the trampoline is facing (such as diagonal)

I know what your talking about I just don’t know how to do it. I would guess that you would have to make like 5 different parts and each part will apply velocity on a different side. Like Part1 Will take you straight and Part2 will take you diagonal. Basically just a bunch of different parts applying velocity on different directions.

Ok thanks, ill figure out my self too.

Maybe get the direction the player is facing and add that to the velocity or something like that.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.