My chairlift doesn't make it

Hello,
I am wanting to make a game with a chairlift, so I started test building one.

Unfortunately, my chair doesn’t manage to make it up the track (in the beginning)

Here is a video:
https://i.imgur.com/4punsC6.mp4

This is the script I am using for my track:

while wait() do -- If the following lines are "true" then process them.
    script.Parent.Velocity = script.Parent.CFrame.RightVector *script.Parent.Speed.Value
end

How could I fix my chairlift, or at least make it go up?
Anything is welcome!

2 Likes

Don’t use while wait() do, or even wait() as it’s deprecated. Velocity is also deprecated. I also don’t know why it’s multiplying by the RightVector.

I recommend using a different script, assuming that this one is from a tutorial as it’s probably not a great tutorial. If you made it, could you explain why it uses RightVector?

2 Likes

I’d recommend using tweening instead, try using this plugin to make it easier:

3 Likes

I now changed the way my conveyor works, using the new AssemblyLinearVelocity, but still, my chairlift doesn’t manage to make it up the steeper part (same steepness as in the video). Any tips?

No tweening, please.

2 Likes

You might consider finding a way to reduce the amount of time that the CSG comes in contact by the edge. If my 2015 physics attempts have told me anything, edges are the bane of the engine’s existence, rather than collision like others.

What do you mean exactly by that? I do not understand.

1 Like

As far as I could see, your chairlift is using a very large set of four CSG bricks (good job on not Unioning them for this), which are colliding with the edges and causing that dreaded jumping which stops velocity.

1 Like

Indeed I am! Yes, mhm, 30char, you are very right.

1 Like

My other suggestion would be to use the new live unions to attach the chair to the cable when moving, which is actually how the real lifts tend to work… except they aren’t magically fusing together.

1 Like

Could you send a picture of this? My English just isn’t fluent enough to fully comprehend what you are trying to say.
The simplest image will do :stuck_out_tongue:

1 Like

Sure, but you’d need to find the documentation on live unions.
Just a moment whilst I make a quick ‘draft’ version.


On the first, the top section is unioned to the ‘wire’ with a ‘pivot’ below to allow movement of the car itself.
On the mid, the top section is not unioned, and moves freely wherever you want it going (in this case, a slow and circular track at the top and bottom) on a level surface.
The last shows the non-unioned being separate parts, itsself.
Note that the non-unioned does not have a ‘pivot,’ since it’d be of no use for the car to swing whilst passengers attempt to board.

1 Like

I am really sorry, but I don’t understand :joy:
I have read this 3 times, and I just cannot figure it out.

The red brick is one large union with a HingeConstraint (or similar item to make it freely rotate)?
The green brick is what I am currently doing?

The red brick is solid, and it has been unioned to the wire. There is a hinge of sorts (my last experience with hinges was the surface varient) to allow the ‘car’ or ‘chair’ to rotate freely to gravity.
The green brick is the same concept as you currently have, which would make the ‘car’/‘chair’ static and would allow the brick to follow a path.

Why would I want my chairlift to be unioned to the wire though? The whole concept of a chairlift is to make it… Alright I guess they’re “unioned” to the wire in real life, but it’d be really difficult to make the wire move and have my chairlift be on top of it like they do in real life.

I currently have my chairlift be strapped really tightly around my wire though, and have the wire have a velocity to attempt to drag the touching parts along with it. Which doesn’t work…

I see where I may be falling in-to a physics trap, however that was the original issue I was focusing on with this.

There is this really good example gamehttps://web.roblox.com/games/2719560806/Single-Chair-ski-lift-development-place?
(use the example chairlift in the image to see how it works)



I do not understand how it makes it up so easily, and the owner of the game said it was a secret :sob:

It appears that they are not using the technique I use where I just strap my lift around the wire. Do you have any idea of they may have done this?

It is connected with way less,


And yet it works much better

1 Like

I assume you mean this:

I have my conveyor parts have an attachment on each side


image

Then a script loops through all my “Track” (I should’ve named them Conveyor or Wire, but whatever) parts and gives them a velocity which perfectly goes from AttStart (where the velocity goes from) to AttEnd (where the velocity goes to)

for _, d in pairs(script.Parent:GetDescendants()) do

	if d:IsA("BasePart") then

		local conveyor = d

		local attStart = conveyor:FindFirstChild("AttStart")
		local attEnd = conveyor:FindFirstChild("AttEnd")

		local function setVelocity()
			local direction = attEnd.WorldPosition - attStart.WorldPosition

			local conveyorVelocity = direction.Unit * conveyor:GetAttribute("Speed")
			conveyor.AssemblyLinearVelocity = conveyorVelocity
		end

		conveyor:GetAttributeChangedSignal("Speed"):Connect(setVelocity)
		conveyor:GetPropertyChangedSignal("Orientation"):Connect(setVelocity)
		setVelocity()

	end
end

Oh, by the way, my Track part has a “Speed” attribute
image

So you do not get confused on what “Speed” is

1 Like