So I am trying to connect some events in order that the server should change an object value, containg a teleport’s destination. The value is changing, but the destination, not. I want something that could refresh the script, or change the teleport’s destination. The destination is an ObjectValue. Anyone could help?

Code that changes location:

local programs = workspace.SuperComputer.ComputerPrograms

RemotesFolder.ChangeScannerDestinationCore.OnServerEvent:Connect(function()
	workspace.Scanner.Destination.Value = workspace.ScannerExitPointCore
end)

RemotesFolder.ChangeScannerDestinationWorkTower.OnServerEvent:Connect(function()
	workspace.Scanner.Destination.Value = workspace.ScannerExitPointTower
end)

(the teleporter code is quite big so if anyone wants to see reply below)

3 comments

0

use print("test") or something to see if the code runs

0

well on the server it changes, but when i touch the teleporter again it doesnt change destination

0

you get me?