of     1   

harvest109
#139429849Sunday, July 06, 2014 4:43 PM GMT

12:42:20.458 - Workspace.testModuleScript:11: attempt to index global 'hit' (a nil value) 12:42:20.459 - Stack Begin 12:42:20.460 - Script 'Workspace.testModuleScript', Line 11 - field DoorOpen 12:42:20.460 - Script 'Players.Player1.PlayerGui.Main_V0.03.Main_V0.03', Line 137 12:42:20.460 - Stack End ^^^^^^^^^^^^^^^^^^Error^^^^^^^^^^ local open = script.Parent.Parent.DoorPart.Open local close = script.Parent.Parent.DoorPart.Closed if close.Value == true and open.Value == false then wait() print'Open' testModule.DoorOpen() else if open.Value == true and close.Value == false then wait() print'Close' testModule.DoorClose() end end ^^^^^^^^^^^^^script^^^^^^^^^^^^^^^^ local testModule = {} testModule.DoorOpen = function() wait() print"Open" for i = 1, 4.9, 0.1 do hit.Parent.DoorPart.CFrame=script.Parent.CFrame*CFrame.new(0.2,0,0) wait() wait(WaitTime) hit.Parent.DoorPart.Open.Value=true end end testModule.DoorClose = function() wait() print'Close Function ran' for i = 1, 4.9, 0.1 do script.Parent.CFrame=script.Parent.CFrame*CFrame.new(-0.2,0,0) wait() wait(WaitTime) hit.Parent.Parent.DoorPart.Open.Value=false hit.Parent.Parent.DoorPart.Closed.Value=true hit.Parent.DoorPart.Closed.Value=true wait() end end return testModule ^^^^^^^^^^^^^^^^^^^^^^^^^Module script^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
harvest109
#139429926Sunday, July 06, 2014 4:44 PM GMT

This is in a local script its only a bit of code, the bit that has to do with the door. PLR.Character["Torso"].Touched:connect(function(hit) if hit.Name == "DoorOpen" then game.Players.LocalPlayer:GetMouse().KeyDown:connect(function(key) if key == " " then print'Opened Localscript' if hit.Parent.DoorPart.Open.Value ~= true and hit.Parent.DoorPart.Closed.Value ~= false then testModule.DoorOpen() end if key == " " then print'Closed Localscript' if hit.Parent.DoorPart.Closed.Value ~= true and hit.Parent.DoorPart.Open.Value ~= false then testModule.DoorClose() end wait(5) hit.Parent.DoorPart.Script.Disabled=true elseif hit.Parent.DoorPart.Script.Running.Value == true then return end end end) end end)
harvest109
#139430578Sunday, July 06, 2014 4:52 PM GMT

....bump
[rfa#hidefromsearch]
#139430769Sunday, July 06, 2014 4:55 PM GMT

[rfa#hidefromsearch]
harvest109
#139431180Sunday, July 06, 2014 5:00 PM GMT

For the local or the door script?
harvest109
#139431225Sunday, July 06, 2014 5:00 PM GMT

Or the module script?
harvest109
#139433656Sunday, July 06, 2014 5:30 PM GMT

got it, but now it says cframe is not a vaild member of workspace/

    of     1