-
Notifications
You must be signed in to change notification settings - Fork 0
Tutorials
untroublee edited this page Nov 11, 2024
·
8 revisions
- Download the model directly from github
- Click on
uQueueService.rbxm, then clickView rawto download
- Click on
- Put the module inside
ServerScriptService
Note: This will not be uploaded on the roblox marketplace due to requiring assets inside of the module
Here are a few guides on how to get started with uQueueService after installation
-- Services --
local SSS = game:GetService("ServerScriptService")
local Players = game:GetService("Players")
-- Modules --
local uQueueService = require(SSS:WaitForChild("uQueueService"))local queueParams : uQueueService.QueueParams = {
MinPlayers = 2,
MaxPlayers = 4,
Countdown = 3,
PlaceId = 9618129346831261326489321694862134686213468698132468689132646871326486813264683216483264868312646312643612648612648613264,
-- Pretend that's a real place id lmao
}
local newQueue = uQueueService.new(queueParams)Players.PlayerAdded:Connect(function(plr)
newQueue:AddPlayer(plr)
end)Players.PlayerRemoved:Connect(function(plr)
newQueue:RemovePlayer(plr)
end)-- new script
-- Services --
local SSS = game:GetService("ServerScriptService")
local Players = game:GetService("Players")
-- Modules --
local uQueueService = require(SSS:WaitForChild("uQueueService"))
-- Variables --
local queueParams : uQueueService.QueueParams = {
MinPlayers = 2,
MaxPlayers = 4,
Countdown = 3,
PlaceId = 5862384328632478273,
TpData = {
msg = "Hello World!"
}
-- TpData can be any value
}
local newQueue = uQueueService.new(queueParams)-- Services --
local SSS = game:GetService("ServerScriptService")
local Players = game:GetService("Players")
-- Modules --
local uQueueService = require(SSS:WaitForChild("uQueueService"))
local Types = require(SSS:WaitForChild("uQueueService"):WaitForChild("Types"))
-- Variables --
local queueParams : Types.Queue = {
MinPlayers = 2,
MaxPlayers = 4,
Countdown = 3,
PlaceId = 5862384328632478273,
TpData = "Hello world!"
-- Can be any value
}
local newQueue = uQueueService.new(queueParams)
-- Events --
Players.PlayerAdded:Connect(function(plr)
newQueue:AddPlayer(plr)
end)
Players.PlayerRemoved:Connect(function(plr)
newQueue:RemovePlayer(plr)
end)
newQueue:Initiated:Connect(function()
print(`Queue has been initated! Teleporting players {newQueue.queued}...`)
end)Brought to you by signupredirectlol | Original module by RequiredModule