Well, Basically I tried to follow the "RemoteFunction and RemoteEvent Tutorial" Roblox offered. And I ended up with this script in 'ServerScriptService' with another script in that script. I'm not 100% sure about how Server and Local Scripts go in this process. But I got it to work in studio. May I also mention, I have Filtering Enabled Turned ON.
Here is the Server Script [According to What I thought]:
wait(5)
local event = Instance.new("RemoteEvent")
event.Parent = game.Workspace
event.Name = "LeftDoorEvent"
event.OnServerEvent:connect(function()
local Door = game.Workspace.LeftDoor1
local main = Door:GetPrimaryPartCFrame()
local part = Door.PrimaryPart
local clic = Door.ClickDetector
local sound = Door.Sound
if Door.Open.Value == 1 then
sound:Play()
local fix = Door.Main.CFrame
for i = 0,1.5,0.1 do
wait(0.05)
Door:SetPrimaryPartCFrame(Door.Main.CFrame*CFrame.fromEulerAnglesXYZ(0,-0.1,0)*CFrame.new(0.01,0,-0.25))
Door.Open.Value = 0
clic.MaxActivationDistance = 0
end
Door:SetPrimaryPartCFrame(fix*CFrame.fromEulerAnglesXYZ(0,-math.pi/2,0)*CFrame.new(-2.5,0,-2.5))
wait(0.25)
clic.MaxActivationDistance = 15
elseif Door.Open.Value == 0 then
sound:Play()
local fix = Door.Main.CFrame
for i = 0,1.5,0.1 do
wait(0.05)
Door:SetPrimaryPartCFrame(Door.Main.CFrame*CFrame.fromEulerAnglesXYZ(0,0.1,0)*CFrame.new(-0.01,0,0.25))
clic.MaxActivationDistance = 0
end
Door:SetPrimaryPartCFrame(fix*CFrame.fromEulerAnglesXYZ(0,math.pi/2,0)*CFrame.new(-2.5,0,2.5))
wait(0.25)
clic.MaxActivationDistance = 15
Door.Open.Value = 1
end
end)
The Script above activates once the door is clicked from a ServerEvent
This next script is what Roblox called "The Local Script"
wait(5)
local clickDetector = Instance.new("ClickDetector")
clickDetector.Parent = game.Workspace.LeftDoor1
clickDetector.MouseClick:connect(function(hit)
game.Workspace.LeftDoorEvent:FireServer()
end)
The above script is suppose to fire the server thing and cause the door to move. Which activates the server script. This script is a Child of the ServerScript.
I do not understand the problem. Maybe I formatted something wrong, or the scripts are the wrong type, or in the wrong location?
ServerScript:IsA - regular Script just in ServerScriptService LocalScript:IsA - regular Script and its parent is the ServerScript.

2 comments
okay ill try it out thanks!
This again, only worked in studio. I'm so confused!