Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Motor6D welder not working? Trying to make a Motor6D so the Turret can Rotate?.

My script is supposed to make a Motor6D and make the C0 and C1 connect but its not working. D: can someone help? PS: this is for a turret. I need my turret to be able to move around without breaking a weld. --This is my script--

local base = script.Parent.Body
local Base = script.Parent.VehicleSeat

if script.Disabled == false then

    local motor = Instance.new("Motor6D")
        motor.C0 = base
        motor.C1 = Base
        motor.Parent = base
        motor.Parent = script.Parent
end

4 comments

0

This isn't Python, please give us the code with all maintaining end's and proper indentation please.

0

oh sorry

0

btw i made it so my turret will move but the weld would break i want to make it so the weld will stay :(

0

plz respond

1 answer

Heres my script

local VehicleSeat = script.Parent

local Base = VehicleSeat.Parent.Hull.Bottom
local Swivel = VehicleSeat.Parent.Turret.Top

local W = Instance.new("Motor", Base)
W.Part0 = Base
W.Part1 = Swivel
W.C0 = CFrame.new(0, 0, -0.2) * CFrame.fromEulerAnglesXYZ(0,0,0)

Base.Anchored = false
Swivel.Anchored = false

Base.Motor.DesiredAngle = 0
Base.Motor.MaxVelocity = 0.01

Hope this helps

2 comments

0

ok i wil try it

0

it didnt work D:

This discussion is preserved as it was. New answers, comments, and votes are closed.