Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Duicen
- local TrelloModule = {};
- local Players = game:GetService("Players");
- local TeleportService = game:GetService("TeleportService");
- local HttpService = game:GetService("HttpService");
- local BoardId = "rAp1Mci7";
- local BoardAddress = "https://api.trello.com/1/boards/"..BoardId.."/lists"
- local BoardHttp = HttpService:GetAsync(BoardAddress);
- local BoardJSon = HttpService:JSONDecode(BoardHttp);
- --
- local TeleportGameId;
- --
- local Boolean = false;
- function TrelloModule.SendGameID(Int,...)
- TeleportCardHttpRequest = HttpService:GetAsync("https://api.trello.com/1/boards/"..BoardId.."/cards");
- TeleportCardJson = HttpService:JSONDecode(TeleportCardHttpRequest);
- TeleportGameId = "";
- for a = 1,#TeleportCardJson do
- print(TeleportCardJson[a]["name"]);
- if string.len(TeleportCardJson[a]["name"]) <=3 then
- print(TeleportCardJson[a]["name"]);
- if TeleportCardJson[a]["name"] == "On" then
- Boolean = true;
- elseif TeleportCardJson[a]["name"] == "Off" then
- Boolean = false;
- end
- end
- end
- for i = 1,#TeleportCardJson do
- if Boolean ~= true then return end;
- if string.len(TeleportCardJson[i]["name"]) >= 7 then
- TeleportGameId = tostring(TeleportGameId..TeleportCardJson[i]["name"]);
- if tonumber(TeleportGameId) ~= Int then
- local PlayersA = Players:GetPlayers();
- for i = 1,#PlayersA do
- TeleportService:Teleport(tonumber(TeleportGameId),PlayersA[i]);
- wait();
- end
- end
- end
- wait();
- end
- print(tonumber(TeleportGameId))
- end
- while wait(5) do
- if script.Parent.Name ~= "TrelloScript" and script == nil then
- local PlayersA = Players:GetPlayers();
- for i = 1,#PlayersA do
- PlayersA[i]:Kick("Something went wrong");
- wait();
- end
- end
- print(game.PlaceId,TeleportGameId)
- TrelloModule.SendGameID(game.PlaceId);
- end
- return TrelloModule;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement