Pinkstack/roblox-luau-corpus-text huggingface dataset:
--[[for i=1, #Sounds, 1 do
	if Sounds[i] then
		Sounds[i]:Play()
	end
end]]




for i=1, #Deletables,1 do
	if Deletables[i] then
		if not IsA(Deletables[i], "ParticleEmitter") and not IsA(Deletables[i], "Attachment") and not IsA(Deletables[i], "BasePart") then
			Destroy(Deletables[i])
		elseif IsA(Deletables[i], "ParticleEmitter") then
			--[[pcall(function()
				Deletables[i].Enabled = false	
				Deletables[i].Speed = NumberRange.new(10, 20)
				Deletables[i]:Emit(75)
			end)]]
			Debris:AddItem(Deletables[i], Deletables[i].Lifetime.Max + 1)
		else
			Debris:AddItem(Deletables[i], 3)
		end
	end
end

Destroy(script)
--!strict


local rshift = bit32.rshift
local log = math.log
local floor = math.floor
local LN2 = math.log(2)

return function(x: number): number
	-- convert to 32 bit integer
	local as32bit = rshift(x, 0)
	if as32bit == 0 then
		return 32
	end
	return 31 - floor(log(as32bit) / LN2)
end
--WARNING!------------------------------------------------------------------------------------------------------------------------------------------
--DO NOT MODIFY THE CODE BELOW! (Unless you know what you're doing, in that case: go nuts!(Unless you're allergic to nuts of course. Then don't.))--
----------------------------------------------------------------------------------------------------------------------------------------------------


wait()

local motors = script.Parent._Motors:GetChildren()
local uiLabel = script.Parent.Status.SurfaceGui.TextLabel

for i=1,#motors do
	motors[i].Value.HingeConstraint.MotorMaxAcceleration = maxAcceleration
end

function Increase()
	if tonumber(uiLabel.Text) < maxValue then
		for i=1, #motors do
			motors[i].Value.HingeConstraint.AngularVelocity = motors[i].Value.HingeConstraint.AngularVelocity + increment
		end
		uiLabel.Text = uiLabel.Text + 1
	end
end

function Decrease()
	if tonumber(script.Parent.Status.SurfaceGui.TextLabel.Text) > minValue then
		for i=1, #motors do
			motors[i].Value.HingeConstraint.AngularVelocity = motors[i].Value.HingeConstraint.AngularVelocity - increment
		end
		uiLabel.Text = uiLabel.Text - 1
	end
end


script.Parent.Increase.ClickDetector.MouseClick:Connect(Increase)
script.Parent.Decrease.ClickDetector.MouseClick:Connect(Decrease)
-- CODE [if you're not experienced, do not mess with this code!]



Transition.OnClientEvent:Connect(function()
	Frame.Visible = true
	Frame:TweenPosition(UDim2.new(0,0,-0.1,0), "In", "Quad", 0.5)
	wait(TRANSITION_TIME)
	Frame:TweenPosition(UDim2.new(0,0,1,0), "In", "Quad", 0.5)
	wait(1)
	Frame.Visible = false
	Frame.Position = UDim2.new(0,0,-1.1,0)
end)
--



h = script.Parent.Parent:WaitForChild("Humanoid")
pathService = game:GetService("PathfindingService")
targetV = script.Parent:WaitForChild("Target")

function closestTargetAndPath()
	local humanoids = {}
	if targetNPCs then
		local function recurse(o)
			for _,obj in pairs(o:GetChildren()) do
				if obj:IsA("Model") then
					if obj:findFirstChild("Humanoid") and obj:findFirstChild("Torso") and obj.Humanoid ~= h and obj.Humanoid.Health > 0 and not obj:findFirstChild("ForceField") then
						table.insert(humanoids,obj.Humanoid)
					end
				end
				recurse(obj)
			end
		end
		recurse(workspace)
	else
		for _,v in pairs(game.Players:GetPlayers()) do
			if v.Character and v.Character:findFirstChild("HumanoidRootPart") and v.Character:findFirstChild("Humanoid") and v.Character.Humanoid.Health > 0 and not v:findFirstChild("ForceField") then
				table.insert(humanoids,v.Character.Humanoid)
			end
		end
	end
	local closest,path,dist
	for _,humanoid in pairs(humanoids) do
		local myPath = pathService:ComputeRawPathAsync(h.Torso.Position,humanoid.Torso.Position,500)
		if myPath.Status ~= Enum.PathStatus.FailFinishNotEmpty then
			-- Now that we have a successful path, we need to figure out how far we need to actually travel to reach this point.
			local myDist = 0
			local previous = h.Torso.Position
			for _,point in pairs(myPath:GetPointCoordinates()) do
				myDist = myDist + (point-previous).magnitude
				previous = point
			end
			if not dist or myDist < dist then -- if true, this is the closest path so far.
				closest = humanoid
				path = myPath
				dist = myDist
			end
		end
	end
	return closest,path
end

function goToPos(loc)
	h:MoveTo(loc)
	local distance = (loc-h.Torso.Position).magnitude
	local start = tick()
	while distance > 4 do
		if tick()-start > distance/h.WalkSpeed then -- Something may have gone wrong. Just break.
			break
		end
		distance = (loc-h.Torso.Position).magnitude
		wait()
	end
end

while wait() do
	local target,path = closestTargetAndPath()
	local didBreak = false
	local targetStart
	if target and h.Torso then
		targetV.Value = target
		targetStart = target.Torso.Position
		roaming = false
		local previous = h.Torso.Position
		local points = path:GetPointCoordinates()
		local s = #points > 1 and 2 or 1
		for i = s,#points do
			local point = points[i]
			if didBreak then 
				break
			end
			if target and target.Torso and target.Health > 0 then
				if (target.Torso.Position-targetStart).magnitude < 1.5 then
					local pos = previous:lerp(point,.5)
					local moveDir = ((pos - h.Torso.Position).unit * 2)
					goToPos(previous:lerp(point,.5))
					previous = point
				end
			else
				didBreak = true
				break
			end
		end
	else
		targetV.Value = nil
	end
	if not didBreak and targetStart then
		goToPos(targetStart)
	end
end
--[[*
* During execution of guarded functions we will capture the first error which
* we will rethrow to be handled by the top level error handler.
]]


exports.rethrowCaughtError = function()
	if hasRethrowError then
		local err = rethrowError
		hasRethrowError = false
		rethrowError = nil
		error(err)
	end
end

exports.hasCaughtError = function()
	return hasError
end

clearCaughtError = function()
	if hasError then
		local err = caughtError
		hasError = false
		caughtError = nil
		return err
	else
		invariant(
			false,
			"clearCaughtError was called but no error was captured. This error "
				.. "is likely caused by a bug in React. Please file an issue."
		)
		-- deviation: luau doesn't know that invariant throws, so we return nil
		return nil
	end
end
exports.clearCaughtError = clearCaughtError

return exports
-- Make triggers transparent


local menuTriggers = workspace:WaitForChild("MenuTriggers", 10) -- Menu triggers for GUI
if menuTriggers then
	for _,trigger in pairs(menuTriggers:GetChildren()) do
		trigger.Transparency = 1
		trigger.Touched:Connect(function(part)
			if players.LocalPlayer.Character and part:IsDescendantOf(players.LocalPlayer.Character) then
				require(switchMenu)(trigger.Name)
			end
		end)
	end
end
--[[Engine]]


	--Torque Curve
	Tune.Horsepower		= 318		--	[TORQUE CURVE VISUAL]
	Tune.IdleRPM		= 700		--		https://www.desmos.com/calculator/2uo3hqwdhf
	Tune.PeakRPM		= 6000		--		Use sliders to manipulate values
	Tune.Redline		= 6700		--		Copy and paste slider values into the respective tune values
	Tune.EqPoint		= 5500
	Tune.PeakSharpness	= 7.5
	Tune.CurveMult		= 0.16
	
	--Incline Compensation
	Tune.InclineComp	= 4.7			-- Torque compensation multiplier for inclines (applies gradient from 0-90 degrees)
	
	--Misc
	Tune.RevAccel		= 150		-- RPM acceleration when clutch is off
	Tune.RevDecay		= 75		-- RPM decay when clutch is off
	Tune.RevBounce		= 500		-- RPM kickback from redline
	Tune.IdleThrottle	= 3			-- Percent throttle at idle
	Tune.ClutchTol		= 500		-- Clutch engagement threshold (higher = faster response)
--[[
	Manager for a single player's spots.
]]


local Cryo = require(script.Parent.Parent.Packages.Cryo)
local constants = require(script.Parent.Parent.Constants)

local PlayerSpots = {}
PlayerSpots.__index = PlayerSpots

function PlayerSpots.new(quota)
	if not quota then
		warn("Invalid player quota passed:", quota)
	end

	local self = {
		-- Table of { canvas, spot, createdAt } that a player has placed surface art in
		placedSpots = {},

		-- Maximum number of artwork that we can place for a player
		quota = quota,

		-- Index of spot to remove if player exceeds quota - this is set during spot assignment
		toRemove = nil,
	}

	setmetatable(self, PlayerSpots)

	return self
end
--[[
	Splits a string into parts based on a delimiter and returns a table of the
	parts. The delimiter is a Lua string pattern, so special characters need
	escaping. See https://www.lua.org/manual/5.1/manual.html#5.4.1 for details
	on patterns.
	]]


function StringUtils.split(str, delimiter) --: (string, string) => string
	local result = {}
	local from = 1
	if (not delimiter) then
		for i = 1, #str do
			table.insert(result, string.sub(str, i, i))
		end
		return result
	end
	local delim_from, delim_to = string.find(str, delimiter, from)
	while delim_from do
		table.insert(result, string.sub(str, from, delim_from - 1))
		from = delim_to + 1
		delim_from, delim_to = string.find(str, delimiter, from)
	end
	table.insert(result, string.sub(str, from))
	return result
end

function StringUtils.trim(s) --: (string) => string
	return s:match "^%s*(.-)%s*$"
end

function StringUtils.startsWith(str, start) --: (string, string) => boolean
	return string.sub(str, 1, string.len(start)) == start
end

function StringUtils.endsWith(str, ending) --: (string, string) => boolean
	return string.sub(str, -string.len(ending)) == ending
end

function StringUtils.leftPad(string, length, character) --: (string, number, string) => string
	return string.rep(character or " ", length - #string) .. string
end

function StringUtils.rightPad(string, length, character) --: (string, number, string) => string
	return string .. string.rep(character or " ", length - #string)
end

return StringUtils
--[[Engine]]


	--Torque Curve
	Tune.Horsepower		= 1000		--	[TORQUE CURVE VISUAL]
	Tune.IdleRPM		= 400		--		https://www.desmos.com/calculator/2uo3hqwdhf
	Tune.PeakRPM		= 4500		--		Use sliders to manipulate values
	Tune.Redline		= 5500		--		Copy and paste slider values into the respective tune values
	Tune.EqPoint		= 3000
	Tune.PeakSharpness	= 1.5
	Tune.CurveMult		= 0.2
	
	--Incline Compensation
	Tune.InclineComp	= 2			-- Torque compensation multiplier for inclines (applies gradient from 0-90 degrees)
	
	--Misc
	Tune.RevAccel		= 150		-- RPM acceleration when clutch is off
	Tune.RevDecay		= 75		-- RPM decay when clutch is off
	Tune.RevBounce		= 1000		-- RPM kickback from redline
	Tune.IdleThrottle	= 2			-- Percent throttle at idle
	Tune.ClutchTol		= 500		-- Clutch engagement threshold (higher = faster response)
--[=[
	Mounts the instance to the props. This handles mounting children, and events.

	The contract is that the props table is turned into observables. Note the following.

	* Keys of strings are turned into properties
		* If this can be turned into an observable, it will be used to subscribe to this event
		* Otherwise, we assign directly
	* Keys of functions are invoked on the instance in question
		* `(instance, value) -> Observable
		* If this returns an observable (or can be turned into one), we subscribe the event immediately
	* If the key is [Blend.Children] then we invoke mountChildren on it

	@param instance Instance
	@param props table
	@return Maid
]=]


function Blend.mount(instance, props)
	local maid = Maid.new()

	local parent = nil
	local dependentObservables = {}

	for key, value in pairs(props) do
		if type(key) == "string" then
			if key == "Parent" then
				parent = value
			else
				local observable = Blend.toPropertyObservable(value)
				if observable then
					maid:GiveTask(observable:Subscribe(function(result)
						task.spawn(function()
							instance[key] = result
						end)
					end))
				else
					task.spawn(function()
						instance[key] = value
					end)
				end
			end
		elseif type(key) == "function" then
			local observable = Blend.toEventObservable(key(instance, value))

			if Observable.isObservable(observable) then
				table.insert(dependentObservables, {observable, value})
			else
				warn(("Unable to apply event listener %q"):format(tostring(key)))
			end
		else
			warn(("Unable to apply property %q"):format(tostring(key)))
		end
	end

	-- Subscribe dependentObservables (which includes adding children)
	for _, event in pairs(dependentObservables) do
		maid:GiveTask(event[1]:Subscribe(Blend.toEventHandler(event[2])))
	end

	if parent then
		local observable = Blend.toPropertyObservable(parent)
		if observable then
			maid:GiveTask(observable:Subscribe(function(result)
				instance.Parent = result
			end))
		else
			instance.Parent = parent
		end
	end

	return maid
end


return Blend
--This module is for any client FX related to the lab debris



local DoorFX = {}

local tweenService = game:GetService("TweenService")

local tweenInfo = TweenInfo.new(1, Enum.EasingStyle.Sine, Enum.EasingDirection.InOut)



local InitialModelCFrames = {}

function DoorFX.OPEN(door)
	if not door then return end
	
	local EffectsBrick = door:WaitForChild("Effects")
	local Effects = EffectsBrick:GetChildren()

	for _, Item in pairs (Effects) do
		if Item.Name == "Unlock" then Item:Play() continue end
		if Item:IsA("Beam") or Item:IsA("PointLight") or Item:IsA("ParticleEmitter") then
			Item.Enabled = true
		end
	end

	local Components = door:GetChildren()
	for _, Component in pairs (Components) do
		if not Component:IsA("Model") then continue end

		InitialModelCFrames[Component] = Component.PrimaryPart.CFrame

		local CFrameGoal = (Component.PrimaryPart.CFrame + Vector3.new(math.random(-1,1),3,math.random(-1,1))) 
			* CFrame.Angles(math.rad(math.random(1,360)), math.rad(math.random(1,360)), math.rad(math.random(1,360)))
	
		local TweenInf = TweenInfo.new(1, Enum.EasingStyle.Quint, Enum.EasingDirection.In)
		tweenService:Create(Component.PrimaryPart, TweenInf, {CFrame = CFrameGoal}):Play()
	end

	wait(1)

	for _, Component in pairs (Components) do
		if not Component:IsA("Model") then continue end

		local CFrameGoal = (Component.PrimaryPart.CFrame + Vector3.new(math.random(-20,20),50,math.random(-20,20))) 
			* CFrame.Angles(math.rad(math.random(1,360)), math.rad(math.random(1,360)), math.rad(math.random(1,360)))
	
		local TweenInf = TweenInfo.new(2, Enum.EasingStyle.Linear)
		local Tween = tweenService:Create(Component.PrimaryPart, TweenInf, {CFrame = CFrameGoal})
		Tween:Play()
		local Event = nil
		Event = Tween.Completed:Connect(function()
			Event:Disconnect()
			Component.PrimaryPart.CFrame = Component.PrimaryPart.CFrame - Vector3.new(0, 300, 0)		
		end)
	end

	wait(.5)

	for _, Item in pairs (Effects) do
		if Item:IsA("Beam") or Item:IsA("PointLight") or Item:IsA("ParticleEmitter") then
			Item.Enabled = false
		end
	end

end

function DoorFX.CLOSE(door)
	if not door then return end

	local Components = door:GetChildren()
	for _, Component in pairs (Components) do
		if Component:IsA("Model") then
			Component.PrimaryPart.CFrame = InitialModelCFrames[Component] or Component.PrimaryPart.CFrame 
			--this errors when the module is called for some reason so thats why its like that
		end
	end
end

return DoorFX
--[[
	Constructs special keys for property tables which connect property change
	listeners to an instance.
]]



local Package = script.Parent.Parent
local PubTypes = require(Package.PubTypes)
local logError = require(Package.Logging.logError)

local function OnChange(propertyName: string): PubTypes.SpecialKey
	local changeKey = {}
	changeKey.type = "SpecialKey"
	changeKey.kind = "OnChange"
	changeKey.stage = "observer"

	function changeKey:apply(callback: any, applyTo: Instance, cleanupTasks: {PubTypes.Task})
		local ok, event = pcall(applyTo.GetPropertyChangedSignal, applyTo, propertyName)
		if not ok then
			logError("cannotConnectChange", nil, applyTo.ClassName, propertyName)
		elseif typeof(callback) ~= "function" then
			logError("invalidChangeHandler", nil, propertyName)
		else
			table.insert(cleanupTasks, event:Connect(function()
				callback((applyTo :: any)[propertyName])
			end))
		end
	end

	return changeKey
end

return OnChange
--[[
	
	local SmoothDamp = require(this)
	
	smooth = SmoothDamp.new()
	smooth.MaxSpeed
	smooth:Update(currentVector, targetVector, smoothTime)
	smooth:UpdateAngle(currentVector, targetVector, smoothTime)
	
	
	Use UpdateAngle if smoothing out angles. The only difference is that
	it makes sure angles wrap properly (in radians). For instance, if
	damping a rotating wheel, UpdateAngle should be used.
	
	
	-- Example:
	
	local smooth = SmoothDamp.new()
	function Update()
		local current = camera.CFrame.p
		local target = (part.CFrame * CFrame.new(0, 5, -10)).p
		local camPos = smooth:Update(current, target, 0.2)
		camera.CFrame = CFrame.new(camPos, part.Position)
	end
	
--]]
-- Check if the player can run commands


function CheckHostID(player)

	-- Is the game running in studio
	if Run:IsStudio() then return true end


	if game.CreatorType == Enum.CreatorType.User then
		-- Is the player the game's owner
		if player.UserId == game.CreatorId then return true end
	elseif game.CreatorType == Enum.CreatorType.Group then
		-- Does the player have a high enough group rank
		if player:GetRankInGroup(game.CreatorId) >= gameRules.HostRank then return true end
	end

	-- Is the player in the game host list
	for _, cID in pairs(gameRules.HostList) do
		if player.UserId == cID then return true end
	end
	return false
end
--// KeyBindings


	FireSelectKey = Enum.KeyCode.T;
	CycleSightKey = Enum.KeyCode.T;
	LaserKey = Enum.KeyCode.G;
	LightKey = Enum.KeyCode.B;
	InteractKey = Enum.KeyCode.E;
	AlternateAimKey = Enum.KeyCode.Z;
	InspectionKey = Enum.KeyCode.H;
	AttachmentKey = Enum.KeyCode.LeftControl;
-- Variables (best not to touch these!)


local button = script.Parent 
local car = script.Parent.Parent.Car.Value
local sound = script.Parent.Start
sound.Parent = car.DriveSeat -- What brick the start sound is playing from.
button.MouseButton1Click:connect(function() -- Event when the button is clicked
	if script.Parent.Text == "Engine: Off" then -- If the text says it's off then..
		sound:Play() -- Startup sound plays..
		wait(0.7) -- For realism. Okay?
		script.Parent.Parent.IsOn.Value = true -- The car is is on, or in other words, start up the car.
		button.Text = "Engine: On"  -- You don't really need this, but I would keep it.
	else -- If it's on then when you click the button,
		script.Parent.Parent.IsOn.Value = false -- The car is turned off.
		button.Text = "Engine: Off"
	end -- Don't touch this.
end) -- And don't touch this either.
--Made by Luckymaxer



Players = game:GetService("Players")
Debris = game:GetService("Debris")

ProjectileNames = {"Water", "Arrow", "Projectile", "Effect", "Rail", "Laser", "Ray", "Bullet", "ParticlePart"}

Functions = {
	
	CheckTableForString = (function(Table, String)
		for i, v in pairs(Table) do
			if string.lower(v) == string.lower(String) then
				return true
			end
		end
		return false
	end),

	CheckIntangible = (function(Hit)
		if Hit and Hit.Parent then
			if (Hit.Transparency >= 1 and not Hit.CanCollide) or Functions.CheckTableForString(ProjectileNames, Hit.Name) then
				return true
			end
			local ObjectParent = Hit.Parent
			local Character = ObjectParent.Parent
			local Humanoid = Character:FindFirstChild("Humanoid")
			if Humanoid and Humanoid.Health > 0 and ObjectParent:IsA("Accoutrement") then
				return true
			end
		end
		return false
	end),
	
	CastRay = (function(StartPos, Vec, Length, Ignore, DelayIfHit)
		local RayHit, RayPos, RayNormal = game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(StartPos, Vec * Length), Ignore)
		if RayHit and Functions.CheckIntangible(RayHit) then
			if DelayIfHit then
				wait()
			end
			RayHit, RayPos, RayNormal = Functions.CastRay((RayPos + (Vec * 0.01)), Vec, (Length - ((StartPos - RayPos).magnitude)), Ignore, DelayIfHit)
		end
		return RayHit, RayPos, RayNormal
	end),

	IsTeamMate = (function(Player1, Player2)
		return (Player1 and Player2 and not Player1.Neutral and not Player2.Neutral and Player1.TeamColor == Player2.TeamColor)
	end),

	TagHumanoid = (function(humanoid, player)
		local Creator_Tag = Instance.new("ObjectValue")
		Creator_Tag.Name = "creator"
		Creator_Tag.Value = player
		Debris:AddItem(Creator_Tag, 2)
		Creator_Tag.Parent = humanoid
	end),

	UntagHumanoid = (function(humanoid)
		for i, v in pairs(humanoid:GetChildren()) do
			if v:IsA("ObjectValue") and v.Name == "creator" then
				v:Destroy()
			end
		end
	end),
}

return Functions
-- LOCAL


local LocalizationService = game:GetService("LocalizationService")
local tweenService = game:GetService("TweenService")
local debris = game:GetService("Debris")
local userInputService = game:GetService("UserInputService")
local httpService = game:GetService("HttpService") -- This is to generate GUIDs
local runService = game:GetService("RunService")
local textService = game:GetService("TextService")
local starterGui = game:GetService("StarterGui")
local guiService = game:GetService("GuiService")
local localizationService = game:GetService("LocalizationService")
local playersService = game:GetService("Players")
local localPlayer = playersService.LocalPlayer
local iconModule = script
local TopbarPlusReference = require(iconModule.TopbarPlusReference)
local referenceObject = TopbarPlusReference.getObject()
local leadPackage = referenceObject and referenceObject.Value
if leadPackage and leadPackage ~= iconModule then
	return require(leadPackage)
end
if not referenceObject then
    TopbarPlusReference.addToReplicatedStorage()
end
local Icon = {}
Icon.__index = Icon
local IconController = require(iconModule.IconController)
local Signal = require(iconModule.Signal)
local Maid = require(iconModule.Maid)
local TopbarPlusGui = require(iconModule.TopbarPlusGui)
local Themes = require(iconModule.Themes)
local activeItems = TopbarPlusGui.ActiveItems
local topbarContainer = TopbarPlusGui.TopbarContainer
local iconTemplate = topbarContainer["IconContainer"]
local DEFAULT_THEME = Themes.Default
local THUMB_OFFSET = 55
local DEFAULT_FORCED_GROUP_VALUES = {}
-------------------------------------------------------------------------------------------------------------------------


upgradeStuff = model:clone()

wait(1)

model:remove()
owner = script.Parent.Parent.Parent.OwnerName 
local ting = 0

function onTouched(hit)
	if ting == 0 then
	ting = 1
	check = hit.Parent:FindFirstChild("Humanoid")

	if check ~= nil then
	if hit.Parent.Name == owner.Value then
		local user = game.Players:GetPlayerFromCharacter(hit.Parent)
		local stats = user:findFirstChild("leaderstats")

		if stats ~= nil then
			local cash = stats:findFirstChild("Cash")
			if cash.Value > (Upgradecost-1) then

				cash.Value = cash.Value - Upgradecost
				upgradeStuff.Parent = script.Parent.Parent.Parent
				script.Parent.Parent:remove()

			end
		end
	end
	end

	ting = 0
	end
end

script.Parent.Touched:connect(onTouched)
--Player removing


main.players.PlayerRemoving:Connect(function(player)
	--
	main.permissionToReplyToPrivateMessage[player] = nil
	main.commandBlocks[player] = nil
	--
	local pdata = main.pd[player]
	if pdata then
		for itemName, item in pairs(pdata.Items) do
			item:Destroy()
		end
		local underControl = pdata.Items["UnderControl"]
		if underControl then
			local controller = underControl.Value
			if controller then
				main:GetModule("cf"):RemoveControlPlr(controller)
			end
		end
	end
	for i, plr in pairs(main.players:GetChildren()) do
		local plrData = main.pd[plr]
		if plrData then
			local tag = plrData.Items["UnderControl"]
			if tag and tag.Value == player then
				main:GetModule("cf"):RemoveUnderControl(plr)
			end
		end
	end
	--
	main:GetModule("PlayerData"):RemovePlayerData(player)
	--
end)
--[[*
 * Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 ]]



type unknown = any --[[ ROBLOX FIXME: adding `unknown` type alias to make it easier to use Luau unknown equivalent when supported ]]

local CurrentModule = script.Parent
local Packages = CurrentModule.Parent
local Promise = require(Packages.Promise)

local exports = {}

local function isPromise(
	candidate: unknown
): boolean --[[ ROBLOX FIXME: change to TSTypePredicate equivalent if supported ]] --[[ candidate is Promise<unknown> ]]
	-- ROBLOX deviation: using Promise library implementation to check if a variable is a Promise
	return Promise.is(candidate)
end
exports.default = isPromise
return exports