It’s not impossible…
since its a matchmaking, i believe you could make
--A button, after you click, you will open a GUI to see Current Matches ( Before they Begin )
--[Insert function of that Button [GUI] here --
--If they click, then it will send a RemoteEvent asking to Enter on it...
local Match1 = {
Quantity = 0,
-- Insert Player here if
--Level 9 or Below
}
local Match2 = {
Quantity = 0,
-- Insert Player here if
--Level 10 ~ 19
}
local Match3 = {
Quantity = 0,
-- Insert Player here if
--Level 20 ~ 29
}
local Match4 = {
Quantity = 0, -- what this means is, the amount of players that "Joined on this Queue"
--Level 30 ~ 39
}
local Match5 = {
Quantity = 0,
-- Insert Player here if
--Level 40 or Above
}
--Server script --
---All Data of users, can be Wins, Defeats, Kills, Anything, but don't forget to add a special Stringvalue
--called: "Status" this will define if the player is in a [QUEUE]
for example:
local Status = Instance.new("StringValue", player)
Status.Name = "CurrentMatch"
Status.Value = "None"
---- Important Remote Function ----- [The client sent to Server, and [HERE] the server will change stuff
--OnServerEvent remote event function(plr) -- who fired ( the player )
--The player.CurrentMatch.Value will be changed, depending on your --Level or Skill [Below is an example]
--Ex:
--(I'll use a Instance.new("IntValue") as an example here ( if you know what i'm saying)
local PlrLv = player.Level.Value
if PlrLv <= 9 and if Match1[Quantity] < 11 then -- If the user is Level 9 or Below
--Don't forget to change the "Status" Value
--Ex: player.CurrentMatch.Value = "Match1" -- Changed his "Status"
Match1[Quantity] = Match1[Quantity] + 1 -- [Table] --maybe will work or not
--In case Table dind't worked:
game.ReplicatedStorage.Match1.Value = game.ReplicatedStorage.Match.Value + 1 -- will add +1
--So this will change to everyone, it will look like a Global Queue
else if PlrLv >= 10 and PlrLv <= 19 then -- if he is Between 10 ~ 19 Level
player.CurrentMatch.Value = "Match2"
Match2[Quantity] = Match2[Quantity] + 1
else if PlrLv >= 20 and PlrLv <= 29 and if Match3[Quantity] < 11 then -- Between 20 ~ 29 Level
player.CurrentMatch.Value = "Match3"
Match3[Quantity] = Match3[Quantity] + 1
else if PlrLv >= 30 and PlrLv <= 39 and if Match4[Quantity] < 11 then -- Between 30 ~ 39 Level
player.CurrentMatch.Value = "Match4"
--Update the Table:
Match4[Quantity] = Match4[Quantity] + 1
else if PlrLv >= 40 and Match5[Quantity] < 11 then -- Level 40 ~ ??? [See if Queue has Less than 11 Players] (So, in total, only 10 player can join)
Match5[Quantity] = Match5[Quantity] + 1
player.CurrentMatch.Value = "Match5"
end
end
end
end
end
---------------------------------------------------
--What if player leaves from the Queue?
--Create a [Gui Button] that activates each time the player click
--[Removing the Player from the Match--
--You only need to change this Value:
player.CurrentMatch.Value = "None"
--Subtract -1 in game.ReplicatedStorage.Match(Name of Match)
--Create a function that [if QUEUE is FULL, then it will not insert the player]
--this is more to prevent some Bugs
----- Now, how to teleport them -----
--How:
--After some time, the match starts, but the question is...
--how to Teleport all players at the same time?
---[Insert a function here [after 1 minute or 3 the Match Starts] -- (Server Side)
--After the countdown, the server will grab all tables and teleport them at the same time
—I advise you to check:
RemoteEvent | Roblox Creator Documentation
and learn more about this because
i will not explain here (Sorry)
-- Server Script --
local function TeleportingUsers()
--After 1 minute, this will Run
--SomeReference:FireAllClients()
--Local Script --
local TS = game:GetService("TeleportService")
local Match1Place = 21419285 -- ID of the place here, the place must exist
local Match2Place = 111111111
local Match3Place = 63842813
local Match4Place = 99993923
local Match5Place = 49993923
--[OnClient.Event Stuff here] -- Since the server will Fire all Clients, then anyone with the "CurrentMatch.Value" Changed will:
--automatically Teleport to an specific Match based on "Status" [Ex: Match1, Match2, Match3]
local Plr = game.Players.LocalPlayer
if player.CurrentMatch.Value == "Match1" then -- "CurrentMatch" is a "StringValue" inside the player_
--Level 9 or Below
--if the player has the CurrentMatch.Value , then probaly he is in a [QUEUE]
--Note 2: Hackers can easily change their values, that's where you must add some protection,
--kinda hard to figure it out, but it's easy
TS:Teleport(Match1Place, plr) -- Basic, don't need Player ID, and will Teleport_
else if player.CurrentMatch.Value == "Match2" then --
--Level 10 ~ 19
TS:Teleport(Match2Place, plr) --Place 2
else if player.CurrentMatch.Value == "Match3" then --
--Level 20 ~ 29
TS:Teleport(Match3Place, plr) --Place 3
else if player.CurrentMatch.Value == "Match4" then --
TS:Teleport(Match4Place, plr) --Place 4
--Level 30 ~ 39
else if player.CurrentMatch.Value == "Match5" then --
--Level 40 or Highter
TS:Teleport(Match5Place, plr) --Place 5
end
end
end
end
end
That’s it, probaly will work, and will teleport to the specific [Place]
If anything goes wrong, Check again your script to see if nothing is missing, most of the time i forgot a Word or Two… and this confuses me thinking that the script is wrong
This is just an example, i haven’t tested it, if something goes wrong, probaly you need to put a value as a reference inside ReplicatedStorage, so when a player join in a Queue it will Acrescent +1
and if Leave, -1 … so it will replicate to others users i guess
And there is something else:
i don’t know if tables will work, because i dind’t tested_
Probaly ReplicatedStorage is the best shot,
Value inside ReplicatedStorage called: “Match1” (“IntValue”) = 0
Each time someone join, it will add +1 and If leave, will remove -1