So, I have a time script where tbs, a value, is set to 3.5. I have this script to set the wait time between each minute to 1000000.

local isAdmin = {["bu77_eater"] = true} 

function onChatted(message, player)
    if message == "!timelock on" and isAdmin[player.Name] then
     game.Lighting:WaitForChild("tbs").Value = 999999
	end
end
game.Players.PlayerAdded:connect(function(player)
	player.Chatted:connect(function(message) onChatted(message, player) 
	end)
end)

4 comments

0

try adding message = string.lower(message) above the if statement

0

if string.lower(message) and isAdmin[player.Name] then

0

also define your "message"

0

message is what the player typed out he doesnt need to