matchmaking_document - Notepad
eloData = game:GetService("DataStoreService"):GetDataStore("Elo")
debugmode = true
UpdateRate = 3
local ModuleScript = script:WaitForChild("ModuleScript")
local _M = require(ModuleScript)
function debugPrint(msg)
if debugmode then
print("DB="..msg)
end
end
function FigureTeams(Match)
end
local PlayerA = {
Pl########## "BigDJohnson";
Elo = 30;
Range = 50;
Matched = false;
Partyid = 0;
}
local PlayerB = {
PlayerName = "Smurf";
Elo = 0;
Range = 50;
Matched = false;
Partyid = 0;
}
local PlayersInQueue = {PlayerA,PlayerB}
local JoinQueueQueue = {}
function game.ReplicatedStorage.JoinQueue.OnServerInvoke(Player)
local PlayerData =
{
PlayerName = "";
Elo = 0;
Range = 50;
Matched = false;
Partyid = 0;## #
# #l################# # #-eloData:GetAsync(tostring(Player.userId))
PlayerData["PlayerName"] = Player.Name
table.insert(JoinQueueQueue,1,PlayerData)
return true
end
local Matches = {}
function LeaveQueue(PlayerName