How do you make a car door to open?, I’ve tried using animations but I could not figure out how to rig it or use it for the animation editor, and I don’t know how to use motor6 or something to open it up, I also don’t want to use the classic invisible door trick, and Tweening won’t work as it is suppose to move.
Can you help me set it up? heres the setup Those 2 parts at the bottom are suppose to be for the door hinge
local check = game:GetService("ProximityPromptService")
local Hinge = script.Parent.Part.HingeConstraint
local function open()
if Hinge.TargetAngle == 0 then
Hinge.TargetAngle = 75
elseif Hinge.TargetAngle == 75 then
Hinge.TargetAngle = 0
end
end
check.PromptTriggered:Connect(open)
heres the simple script
My problem is the hinge wont connect and im not sure if any of those extra contraints did something to stop it.
Edit: the hinge can connect now and moves, just gotta figure how the door wont go with it
Get rid of the extra Parts, and just move the Attachments into the LeftDoor and Chassis. You can move the Attachment in the Chassis to the e
It’s almost always easier to use less Parts.
Also don’t have the LeftDoor welded to the Chassis or anything else.
Have the LeftWindow welded to the LeftDoor since they’ll be moving together.
Here’s a simple door script that I made that should show you how everything should be attached:
Probably because you’ve got Parts that are supposed to be moving with the door script like the door and the window and you have them welded to Parts that aren’t supposed to be moving with the door script like the Chassis. If you get rid of the extra Parts you added it should make it easier to keep track of things like this.
Yes, but I’m wondering if BOTH ProximityPrompts are being activated at the same time with the same input because they are so close.
Try decreasing the activation distance so if you’re sitting in the left seat you aren’t activating the right door’s ProximityPrompt.
You want to open both doors with the same Prompt? I thought you wanted them individually opened since the Prompt is in the LeftDoor, not the Chassis.
Then put the Prompt in the Chassis, and add both hinge parts to the script:
local lhinge = script.Parent.LHInge.HingeConstraint
local rhinge = script.Parent.RHInge.HingeConstraint
then add the lhinge and rhinge TargetAngles inside the function.
That’s what I meant the first time. If you are too close to both doors when you click the Prompt, then both doors Prompts will be activated.
Make the activation distance smaller so you can only ‘reach’ the left door Prompt when sitting in the left seat, and the right door Prompt when sitting in the right seat.