Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local ds = game:GetService("DataStoreService"):GetGlobalDataStore("Test")
- local players = game:GetService("Players")
- local key = "key";
- local function flip(c) return not c end
- players.PlayerAdded:Connect(function(plr)
- plr.Chatted:Connect(function(msg)
- msg = msg:lower();
- if msg:sub(1, 11) == "sendmessage" then
- print(
- ds:UpdateAsync(key,flip)
- end
- end)
- end)
- function printOut()
- for _,v in next, players:GetPlayers() do
- v:Kick();
- end
- end
- ds:OnUpdate(key, printOut);
Advertisement
Add Comment
Please, Sign In to add comment