Hello.
I am currently trying to make a very simple script that can check if a Value has changed on ReplicatedStorage (as a test) to work as a stopper of some sort. I've made a simple script for it and it works, however it only checks once, and it's when the player joins, and after any value checks it always remains with the first pick. Say if the value was false at the start, it would run the code if the value was false, but if the value got changed to true afterwards, it would still run the code if the value was false. I seriously cannot wrap my head around this and I need some help.
Here is the simple code:
local Tool = script.Parent
local RP = game:GetService("ReplicatedStorage")
Tool.Activated:Connect(function()
if RP.Value.Value == true then
print("Value is true")
end
if RP.Value.Value == false then
print("Value is false")
end
end)
If I could get some help with this it would be great.
Thanks!

4 comments
Local Script or Server Script?
ServerScript
Did you change the value to true using a different script or by using Roblox Studio during testing?
No, I used the tool itself to change the value, as you can see from the script, as the tool is activated it runs, I also did this using Roblox Studio during testing