This is a script that is inside a "hatchdoor". Everything works perfectly in the studio, but once I enter through the Roblox server it does not. Any ideas?
-- For Air Compression Tank Button Door Hatch Door 1 local sound= script.Parent.Sound local emit= script.Parent.Parent.emitter local lever= script.Parent.Parent.Parent.airmachine.handle:FindFirstChild("leverscript") lever.Disabled= true wait(0.1) script.Parent.Anchored = true function onClicked() if lever.Disabled== true then lever.Disabled = false else return end local char= game.Players.LocalPlayer.Character local char= game.Players.LocalPlayer.Character local check=char:FindFirstChild("Value") if check ~= true then local value= Instance.new("IntValue") value.Parent= char end sound:Play() script.Parent.Anchored = true local door = script.Parent.CFrame for i = 0,1.5,0.1 do wait(0.1) emit.ParticleEmitter.Enabled= true script.Parent.CFrame = script.Parent.CFrame*CFrame.fromEulerAnglesXYZ(0,0.1,0)*CFrame.new(-0.01,0,0.25) script.Parent.CFrame = door*CFrame.fromEulerAnglesXYZ(0,math.pi/2,0)*CFrame.new(-2.5,0,2.5) script.Parent.Anchored = true end emit.ParticleEmitter.Enabled= false wait(3) script.Parent.Anchored = true local door = script.Parent.CFrame for i = 0,1.5,0.1 do wait(0.1) script.Parent.CFrame = script.Parent.CFrame*CFrame.fromEulerAnglesXYZ(0,-0.1,0)*CFrame.new(0.01,0,-0.25) end script.Parent.CFrame = door*CFrame.fromEulerAnglesXYZ(0,-math.pi/2,0)*CFrame.new(-2.5,0,-2.5) script.Parent.Anchored = true wait(1) end script.Parent.Parent.button.ClickDetector.MouseClick:connect(onClicked)
Thank you for any advice!