Roblox/luau_corpus huggingface dataset:
------------------------------------------------------------------------
--
-- * used only in luaK:codearith()
------------------------------------------------------------------------
function luaK:constfolding(op, e1, e2)
  local r
  if not self:isnumeral(e1) or not self:isnumeral(e2) then return false end
  local v1 = e1.nval
  local v2 = e2.nval
  if op == "OP_ADD" then
    r = self:numadd(v1, v2)
  elseif op == "OP_SUB" then
    r = self:numsub(v1, v2)
  elseif op == "OP_MUL" then
    r = self:nummul(v1, v2)
  elseif op == "OP_DIV" then
    if v2 == 0 then return false end  -- do not attempt to divide by 0
    r = self:numdiv(v1, v2)
  elseif op == "OP_MOD" then
    if v2 == 0 then return false end  -- do not attempt to divide by 0
    r = self:nummod(v1, v2)
  elseif op == "OP_POW" then
    r = self:numpow(v1, v2)
  elseif op == "OP_UNM" then
    r = self:numunm(v1)
  elseif op == "OP_LEN" then
    return false  -- no constant folding for 'len'
  else
    assert(0)
    r = 0
  end
  if self:numisnan(r) then return false end  -- do not attempt to produce NaN
  e1.nval = r
  return true
end
--rope.BrickColor = BrickColor.new("Black")
rope.TopSurface = 0
rope.BottomSurface = 0
rope.formFactor = "Symmetric"
rope.Name = "Rope"
rope.CanCollide = false
rope.Anchored = true
local mesh = Instance.new("CylinderMesh")
mesh.Parent = rope
--[=[
	Converts a set to a list
	@param set table
	@return table
]=]
function Set.toList(set)
	local list = {}

	for value, _ in pairs(set) do
		table.insert(list, value)
	end

	return list
end
--[[
	@class ClientMain
]]

local ReplicatedFirst = game:GetService("ReplicatedFirst")

local packages = ReplicatedFirst:WaitForChild("_SoftShutdownClientPackages")

local SoftShutdownServiceClient = require(packages.SoftShutdownServiceClient)
local serviceBag = require(packages.ServiceBag).new()

serviceBag:GetService(SoftShutdownServiceClient)

serviceBag:Init()
serviceBag:Start()
--// This module is for stuff specific to cross server communication
--// NOTE: THIS IS NOT A *CONFIG/USER* PLUGIN! ANYTHING IN THE MAINMODULE PLUGIN FOLDERS IS ALREADY PART OF/LOADED BY THE SCRIPT! DO NOT ADD THEM TO YOUR CONFIG>PLUGINS FOLDER!
return function(Vargs, GetEnv)
	local env = GetEnv(nil, {script = script})
	setfenv(1, env)

	local server = Vargs.Server;
	local service = Vargs.Service;

	local Settings = server.Settings
	local Functions, Commands, Admin, Anti, Core, HTTP, Logs, Remote, Process, Variables, Deps =
		server.Functions, server.Commands, server.Admin, server.Anti, server.Core, server.HTTP, server.Logs, server.Remote, server.Process, server.Variables, server.Deps

	-- // Remove legacy trello board
	local epix_board_index = type(Settings.Trello_Secondary) == "table" and table.find(Settings.Trello_Secondary, "9HH6BEX2")
	if epix_board_index then
		table.remove(Settings.Trello_Secondary, epix_board_index)
		Logs:AddLog("Script", "Removed legacy trello board")
	end

	Logs:AddLog("Script", "Misc Features Module Loaded")
end
-- ================================================================================
-- EVENTS
-- ================================================================================
local buttonDown = Instance.new("BindableEvent")
local buttonUp = Instance.new("BindableEvent")
local changed = Instance.new("BindableEvent")
local connected = Instance.new("BindableEvent")
local disconnected = Instance.new("BindableEvent")

Gamepad.ButtonDown = buttonDown.Event
Gamepad.ButtonUp = buttonUp.Event
Gamepad.Changed = changed.Event
Gamepad.Connected = connected.Event
Gamepad.Disconnected = disconnected.Event
--Set up teleport arrival.
TeleportService.LocalPlayerArrivedFromTeleport:Connect(function(Gui,Data)
	if Data and Data.IsTemporaryServer then
		--If it is a temporary server, keep showing the Gui, wait, then teleport back.
		Gui.Parent = Players.LocalPlayer:WaitForChild("PlayerGui",10^99)
		StarterGui:SetCore("TopbarEnabled",false)
		StarterGui:SetCoreGuiEnabled("All",false)
		task.wait(5)
		TeleportService:Teleport(Data.PlaceId,Players.LocalPlayer,nil,Gui)
	else
		--If the player is arriving back from a temporary server, remove the Gui.
		if Gui and Gui.Name == "SoftShutdownGui" then Gui:Destroy() end
	end
end)
--//Script\\--
function whileTouching()
	--wait(4)
	script.Parent.AutomaticT.Disabled = false
	script.Parent.Lighted.Disabled = false
end

function letGo()
	script.Parent.AutomaticT.Disabled = true
	script.Parent.Lighted.Disabled = true
	script.Parent.LightedOff.Disabled = false
end
-- ROBLOX TODO: fix PrettyFormat types imports
type PrettyFormatOptions = PrettyFormat_.PrettyFormatOptions

local chalk = require(Packages.ChalkLua)

local getType = require(Packages.JestGetType).getType

local cleanupSemanticModule = require(CurrentModule.CleanupSemantic)
local DIFF_DELETE = cleanupSemanticModule.DIFF_DELETE
local DIFF_EQUAL = cleanupSemanticModule.DIFF_EQUAL
local DIFF_INSERT = cleanupSemanticModule.DIFF_INSERT
local Diff = cleanupSemanticModule.Diff
export type Diff = cleanupSemanticModule.Diff

local normalizeDiffOptions = require(CurrentModule.NormalizeDiffOptions).normalizeDiffOptions

local diffLinesRaw = require(CurrentModule.DiffLines).diffLinesRaw
local diffLinesUnified = require(CurrentModule.DiffLines).diffLinesUnified
local diffLinesUnified2 = require(CurrentModule.DiffLines).diffLinesUnified2

local diffStringsRaw = require(CurrentModule.PrintDiffs).diffStringsRaw
local diffStringsUnified = require(CurrentModule.PrintDiffs).diffStringsUnified

local typesModule = require(CurrentModule.types)
export type DiffOptions = typesModule.DiffOptions
export type DiffOptionsColor = typesModule.DiffOptionsColor

local NO_DIFF_MESSAGE = require(CurrentModule.Constants).NO_DIFF_MESSAGE
local SIMILAR_MESSAGE = require(CurrentModule.Constants).SIMILAR_MESSAGE
--Sets up touched events for Behaviours
function setupTouchedEvents(character)
	local parts = character:GetChildren()
	for i = 1, #parts do
		if parts[i]:isA("BasePart") then
			parts[i].Touched:connect(characterTouchedBrick)
		end
	end
end

function characterAdded(newCharacter)
	local humanoid = newCharacter:WaitForChild("Humanoid")
	humanoid.WalkSpeed = 0
	local splashScreen = player.PlayerGui:WaitForChild("StartScreen")
	setupTouchedEvents(newCharacter)
	if UserInputService.TouchEnabled == false then
		splashScreen.StartInstructions.StartLabel.Text = "Press Space to Start"
	end
	if reviving == true then
		reviving = false
		splashScreen:Destroy()
		humanoid.WalkSpeed = characterWalkSpeed
	end
end
player.CharacterAdded:connect(characterAdded)

function checkReviving(addedGui)
	if addedGui.Name == "RevivingGUI" then
		reviving = true
	end
end
player.PlayerGui.ChildAdded:connect(checkReviving)

if UserInputService.TouchEnabled then
	UserInputService.ModalEnabled = true
	UserInputService.TouchStarted:connect(function(inputObject, gameProcessedEvent) if gameProcessedEvent == false then doJump = true end end)
	UserInputService.TouchEnded:connect(function() doJump = false end)
else
	ContextActionService:BindAction("Jump", function(action, userInputState, inputObject) doJump = (userInputState == Enum.UserInputState.Begin) end, false, Enum.KeyCode.Space, Enum.KeyCode.ButtonA)
end

game:GetService("RunService").RenderStepped:connect(function()
	if player.Character ~= nil then
		if player.Character:FindFirstChild("Humanoid") then
			if doJump == true then
				jump()
			end
			player.Character.Humanoid:Move(Vector3.new(0,0,-1), false)
		end
	end
end)
--heroking--

local door = script.Parent
local door1 = door.Door1 
local door2 = door.Door2 
local ret1 = door1.CFrame 
local ret2 = door2.CFrame 
local spd = script.Parent.Parent.Speed.Value
for i = 1, 58/(15*spd) do 
wait() 
door1.CFrame = door1.CFrame+spd*door1.CFrame.lookVector 
door2.CFrame = door2.CFrame-spd*door1.CFrame.lookVector 
end 
wait(2)
for i = 1, 58/(15*spd) do
wait()
door1.CFrame = door1.CFrame-spd*door1.CFrame.lookVector
door2.CFrame = door2.CFrame+spd*door1.CFrame.lookVector 
end 
door2.CFrame = ret2
door1.CFrame = ret1 
wait() 
script:remove()
-- for debuging animations dont delete
wait()
local rake = script.Parent.Parent
if rake:FindFirstChild("DebugAnimateSource") and rake:FindFirstChild("AnimateSource") then
    if script.Debug.Value == true then
        rake.DebugAnimateSource.Disabled = false
        rake.AnimateSource:Destroy()
    else
        rake.DebugAnimateSource:Destroy()
        rake.AnimateSource.Disabled = false
    end
    script:Destroy()
else
    script:Destroy()
end
-- Note: DotProduct check in CoordinateFrame::lookAt() prevents using values within about
-- 8.11 degrees of the +/- Y axis, that's why these limits are currently 80 degrees
local MIN_Y = math.rad(-80)
local MAX_Y = math.rad(80)

local TOUCH_ADJUST_AREA_UP = math.rad(30)
local TOUCH_ADJUST_AREA_DOWN = math.rad(-15)

local TOUCH_SENSITIVTY_ADJUST_MAX_Y = 2.1
local TOUCH_SENSITIVTY_ADJUST_MIN_Y = 0.5

local VR_ANGLE = math.rad(15)
local VR_LOW_INTENSITY_ROTATION = Vector2.new(math.rad(15), 0)
local VR_HIGH_INTENSITY_ROTATION = Vector2.new(math.rad(45), 0)
local VR_LOW_INTENSITY_REPEAT = 0.1
local VR_HIGH_INTENSITY_REPEAT = 0.4

local ZERO_VECTOR2 = Vector2.new(0,0)
local ZERO_VECTOR3 = Vector3.new(0,0,0)

local TOUCH_SENSITIVTY = Vector2.new(0.00945 * math.pi, 0.003375 * math.pi)
local MOUSE_SENSITIVITY = Vector2.new( 0.002 * math.pi, 0.0015 * math.pi )

local SEAT_OFFSET = Vector3.new(0,5,0)
local VR_SEAT_OFFSET = Vector3.new(0,4,0)
local HEAD_OFFSET = Vector3.new(0,1.5,0)
local R15_HEAD_OFFSET = Vector3.new(0, 1.5, 0)
local R15_HEAD_OFFSET_NO_SCALING = Vector3.new(0, 2, 0)
local HUMANOID_ROOT_PART_SIZE = Vector3.new(2, 2, 1)

local GAMEPAD_ZOOM_STEP_1 = 0
local GAMEPAD_ZOOM_STEP_2 = 10
local GAMEPAD_ZOOM_STEP_3 = 20

local PAN_SENSITIVITY = 20
local ZOOM_SENSITIVITY_CURVATURE = 0.5

local abs = math.abs
local sign = math.sign

local FFlagUserCameraToggle do
	local success, result = pcall(function()
		return UserSettings():IsUserFeatureEnabled("UserCameraToggle")
	end)
	FFlagUserCameraToggle = success and result
end

local FFlagUserDontAdjustSensitvityForPortrait do
	local success, result = pcall(function()
		return UserSettings():IsUserFeatureEnabled("UserDontAdjustSensitvityForPortrait")
	end)
	FFlagUserDontAdjustSensitvityForPortrait = success and result
end

local FFlagUserFixZoomInZoomOutDiscrepancy do
	local success, result = pcall(function()
		return UserSettings():IsUserFeatureEnabled("UserFixZoomInZoomOutDiscrepancy")
	end)
	FFlagUserFixZoomInZoomOutDiscrepancy = success and result
end

local Util = require(script.Parent:WaitForChild("CameraUtils"))
local ZoomController = require(script.Parent:WaitForChild("ZoomController"))
local CameraToggleStateController = require(script.Parent:WaitForChild("CameraToggleStateController"))
local CameraInput = require(script.Parent:WaitForChild("CameraInput"))
local CameraUI = require(script.Parent:WaitForChild("CameraUI"))
--Variables
wait()
local NPC = script.Parent
local Humanoid = NPC:FindFirstChildOfClass("Humanoid")
Humanoid.BreakJointsOnDeath = false
local Anim = script.Animation
local DeathAnimation = Humanoid:LoadAnimation(Anim)
local newNPC = NPC:Clone()
local TweenService = game:GetService("TweenService")
--[[
	Assert that our expectation value is not nil
]]
function Expectation:ok()
	local result = (self.value ~= nil) == self.successCondition

	local message = formatMessage(self.successCondition,
		("Expected value %q to be non-nil"):format(
			tostring(self.value)
		),
		("Expected value %q to be nil"):format(
			tostring(self.value)
		)
	)

	assertLevel(result, message, 3)
	self:_resetModifiers()

	return self
end
-- Do not edit these values, they are not the developer-set limits, they are limits
-- to the values the camera system equations can correctly handle
local MIN_ALLOWED_ELEVATION_DEG = -80
local MAX_ALLOWED_ELEVATION_DEG = 80

local externalProperties = {}
externalProperties["InitialDistance"] 	= 25
externalProperties["MinDistance"] 		= 10
externalProperties["MaxDistance"] 		= 100
externalProperties["InitialElevation"] 	= 35
externalProperties["MinElevation"] 		= 35
externalProperties["MaxElevation"] 		= 35
externalProperties["ReferenceAzimuth"] 	= -45	-- Angle around the Y axis where the camera starts. -45 offsets the camera in the -X and +Z directions equally
externalProperties["CWAzimuthTravel"] 	= 90	-- How many degrees the camera is allowed to rotate from the reference position, CW as seen from above
externalProperties["CCWAzimuthTravel"] 	= 90	-- How many degrees the camera is allowed to rotate from the reference position, CCW as seen from above
externalProperties["UseAzimuthLimits"] 	= false -- Full rotation around Y axis available by default

local refAzimuthRad
local curAzimuthRad
local minAzimuthAbsoluteRad
local maxAzimuthAbsoluteRad
local useAzimuthLimits
local curElevationRad
local minElevationRad
local maxElevationRad
local curDistance
local minDistance
local maxDistance

local UNIT_Z = Vector3.new(0,0,1)
local TAU = 2 * math.pi

local changedSignalConnections = {}
--[[Transmission]]
	Tune.TransModes		= {"Auto", "Semi", "Manual"}								--[[
	[Modes]
		"Auto"		: Automatic shifting
		"Semi"		: Clutchless manual shifting, dual clutch transmission
		"Manual"	: Manual shifting with clutch
		
		>Include within brackets
			eg: {"Semi"} or {"Auto", "Manual"}								
		>First mode is default mode													]]
	
	--Automatic Settings
	Tune.AutoShiftMode	= "Speed"												--[[
	[Modes]
		"Speed"		: Shifts based on wheel speed
		"RPM"		: Shifts based on RPM											]]	
	Tune.AutoUpThresh	= -200		--Automatic upshift point 	(relative to peak RPM, positive = Over-rev)
	Tune.AutoDownThresh = 1400		--Automatic downshift point (relative to peak RPM, positive = Under-rev)
	
	--Gear Ratios
	Tune.FinalDrive		= 3			-- Gearing determines top speed and wheel torque
	Tune.Ratios			= {				-- Higher ratio = more torque, Lower ratio = higher top speed
		--[[Reverse]]	3.70		,	-- Copy and paste a ratio to add a gear
		--[[Neutral]]	0			,	-- Ratios can also be deleted
		--[[ 1 ]]		3.53		,	-- Reverse, Neutral, and 1st gear are required
		--[[ 2 ]]		2.04		,
		--[[ 3 ]]		1.38		,
		--[[ 4 ]]		1.03		,
		--[[ 5 ]]		0.81		,
		--[[ 6 ]]		0.64		,
	}
	Tune.FDMult			= 1.5			-- Ratio multiplier (Change this value instead of FinalDrive if car is struggling with torque ; Default = 1)
--// [[ INTRO PLAY HOVER ]] \\--
IntroGui.ButtonFrame.PlayButton.MouseEnter:Connect(function()
	IntroGui.ButtonFrame.PlayButton.GreenDot.Visible = true
end)
IntroGui.ButtonFrame.PlayButton.MouseLeave:Connect(function()
	IntroGui.ButtonFrame.PlayButton.GreenDot.Visible = false
end)
--[[Susupension]]
	Tune.SusEnabled		= true		-- works only in with PGSPhysicsSolverEnabled, defaults to false when PGS is disabled
	
	--Front Suspension
	Tune.FSusDamping	= 400		-- Spring Dampening
	Tune.FSusStiffness	= 17000		-- Spring Force
	Tune.FSusLength		= 1.9		-- Resting Suspension length (in studs)
	Tune.FSusMaxExt		= .15		-- Max Extension Travel (in studs)
	Tune.FSusMaxComp	= .05		-- Max Compression Travel (in studs)
	Tune.FSusAngle		= 75		-- Suspension Angle (degrees from horizontal)
		
	Tune.FWsBoneLen		= 6			-- Wishbone Length
	Tune.FWsBoneAngle	= 3			-- Wishbone angle (degrees from horizontal)
	Tune.FAnchorOffset	= {			-- Suspension anchor point offset (relative to center of wheel)
	 --[[Lateral]]		-.4		,	-- positive = outward
	 --[[Vertical]]		-.5		,	-- positive = upward
	 --[[Forward]]		0		}	-- positive = forward
	
	--Rear Suspension
	Tune.RSusDamping	= 400		-- Spring Dampening
	Tune.RSusStiffness	= 17000		-- Spring Force
	Tune.RSusLength		= 2.1		-- Resting Suspension length (in studs)
	Tune.RSusMaxExt		= .15		-- Max Extension Travel (in studs)
	Tune.RSusMaxComp	= .05		-- Max Compression Travel (in studs)
	Tune.RSusAngle		= 80		-- Suspension Angle (degrees from horizontal)
	
	Tune.RWsBoneLen		= 5			-- Wishbone Length
	Tune.RWsBoneAngle	= 2			-- Wishbone angle (degrees from horizontal)
	Tune.RAnchorOffset	= {			-- Suspension anchor point offset (relative to center of wheel)
	 --[[Lateral]]		-.4		,	-- positive = outward
	 --[[Vertical]]		-.5		,	-- positive = upward
	 --[[Forward]]		0		}	-- positive = forward

	--Aesthetics	
	Tune.SusVisible		= false			-- Spring Visible
	Tune.WsBVisible		= false			-- Wishbone Visible
	Tune.SusRadius		= .2			-- Suspension Coil Radius
	Tune.SusThickness	= .1			-- Suspension Coil Thickness
	Tune.SusColor		= "Bronze"		-- Suspension Color [BrickColor]
	Tune.SusCoilCount	= 8				-- Suspension Coil Count
	Tune.WsColor		= "White"		-- Wishbone Color [BrickColor]
	Tune.WsThickness	= .1			-- Wishbone Rod Thickness
--[[Drivetrain]]	
	Tune.Config			= "RWD"		--"FWD" , "RWD" , "AWD"
	Tune.TorqueVector	= 0.5			--AWD ONLY, "-1" has a 100% front bias, "0" has a 50:50 bias, and "1" has a 100% rear bias. Can be any number between that range.
	
	--Differential Settings	
	Tune.FDiffSlipThres	= 50		-- 1 - 100%				(Max threshold of applying full lock determined by deviation from avg speed)
	Tune.FDiffLockThres	= 50		-- 0 - 100%				(0 - Bias toward slower wheel, 100 - Bias toward faster wheel)
	Tune.RDiffSlipThres	= 80		-- 1 - 100%
	Tune.RDiffLockThres	= 20		-- 0 - 100%
	Tune.CDiffSlipThres	= 50		-- 1 - 100%				[AWD Only]
	Tune.CDiffLockThres	= 50		-- 0 - 100%				[AWD Only]
	
	--Traction Control Settings
	Tune.TCSEnabled		= true		-- Implements TCS
	Tune.TCSThreshold	= 20		-- Slip speed allowed before TCS starts working (in SPS)
	Tune.TCSGradient	= 20		-- Slip speed gradient between 0 to max reduction (in SPS)
	Tune.TCSLimit		= 10		-- Minimum amount of torque at max reduction (in percent)
-- Roact
local new = Roact.createElement
local Frame = require(UI:WaitForChild 'Frame')
local ImageLabel = require(UI:WaitForChild 'ImageLabel')
local ImageButton = require(UI:WaitForChild 'ImageButton')
local TextLabel = require(UI:WaitForChild 'TextLabel')
local ItemList = require(script:WaitForChild 'ItemList')
----------------------
for i,plr in pairs(game.Players:GetPlayers()) do
	repeat
		local userData = storage.LoadData(plr.UserId)
		wait(0.5)
		if not userData then  end
	until userData == true
end
--// bolekinds

local plr = script.Parent.Parent.Parent.Parent.Parent.Parent.Parent

script.Parent.MouseButton1Click:Connect(function()
	if plr.YouCash.Value >= 110 and game.ServerStorage.ServerData.contract.Value == false then
		script.Parent.Parent.Parent.Ching:Play()
		plr.YouCash.Value -= 110
		game.ServerStorage.ServerData.contract.Value = true
	end
end)
--////////////////////////////// Methods
--//////////////////////////////////////
local methods = {}
methods.__index = methods

function ReturnToObjectPoolRecursive(instance, objectPool)
	local children = instance:GetChildren()
	for i = 1, #children do
		ReturnToObjectPoolRecursive(children[i], objectPool)
	end
	instance.Parent = nil
	objectPool:ReturnInstance(instance)
end

function GetMessageCreators()
	local typeToFunction = {}
	local creators = messageCreatorModules:GetChildren()
	for i = 1, #creators do
		if creators[i]:IsA("ModuleScript") then
			if creators[i].Name ~= "Util" then
				local creator = require(creators[i])
				typeToFunction[creator[messageCreatorUtil.KEY_MESSAGE_TYPE]] = creator[messageCreatorUtil.KEY_CREATOR_FUNCTION]
			end
		end
	end
	return typeToFunction
end

function methods:WrapIntoMessageObject(messageData, createdMessageObject)
	local BaseFrame = createdMessageObject[messageCreatorUtil.KEY_BASE_FRAME]
	local BaseMessage = nil
	if messageCreatorUtil.KEY_BASE_MESSAGE then
		BaseMessage = createdMessageObject[messageCreatorUtil.KEY_BASE_MESSAGE]
	end
	local UpdateTextFunction = createdMessageObject[messageCreatorUtil.KEY_UPDATE_TEXT_FUNC]
	local GetHeightFunction = createdMessageObject[messageCreatorUtil.KEY_GET_HEIGHT]
	local FadeInFunction = createdMessageObject[messageCreatorUtil.KEY_FADE_IN]
	local FadeOutFunction = createdMessageObject[messageCreatorUtil.KEY_FADE_OUT]
	local UpdateAnimFunction = createdMessageObject[messageCreatorUtil.KEY_UPDATE_ANIMATION]

	local obj = {}

	obj.ID = messageData.ID
	obj.BaseFrame = BaseFrame
	obj.BaseMessage = BaseMessage
	obj.UpdateTextFunction = UpdateTextFunction or function() warn("NO MESSAGE RESIZE FUNCTION") end
	obj.GetHeightFunction = GetHeightFunction
	obj.FadeInFunction = FadeInFunction
	obj.FadeOutFunction = FadeOutFunction
	obj.UpdateAnimFunction = UpdateAnimFunction
	obj.ObjectPool = self.ObjectPool
	obj.Destroyed = false

	function obj:Destroy()
		ReturnToObjectPoolRecursive(self.BaseFrame, self.ObjectPool)
		self.Destroyed = true
	end

	return obj
end

function methods:CreateMessageLabel(messageData, currentChannelName)
	local messageType = messageData.MessageType
	if self.MessageCreators[messageType] then
		local createdMessageObject = self.MessageCreators[messageType](messageData, currentChannelName)
		if createdMessageObject then
			return self:WrapIntoMessageObject(messageData, createdMessageObject)
		end
	elseif self.DefaultCreatorType then
		local createdMessageObject = self.MessageCreators[self.DefaultCreatorType](messageData, currentChannelName)
		if createdMessageObject then
			return self:WrapIntoMessageObject(messageData, createdMessageObject)
		end
	else
		error("No message creator available for message type: " ..messageType)
	end
end
--[=[
	Clones a brio, such that it may be killed without affecting the original
	brio.

	@param brio Brio<T>
	@return Brio<T>
]=]
function BrioUtils.clone(brio)
	assert(brio, "Bad brio")

	if brio:IsDead() then
		return Brio.DEAD
	end

	local newBrio = Brio.new(brio:GetValue())

	newBrio:ToMaid():GiveTask(brio:GetDiedSignal():Connect(function()
		newBrio:Kill()
	end))

	return newBrio
end
-- ================================================================================
-- LOCAL FUNCTIONS
-- ================================================================================
local function getCheckpointFromPart(part)
	for _, checkpoint in pairs(checkpoints) do
		if checkpoint.CollisionBody == part then
			return checkpoint
		end
	end
	return nil
end -- getCheckpointFromPart()

local function hasPlayerFinishedLap(player, lap)
	for _, checkpoint in pairs(checkpoints) do
		if checkpoint:PlayerLapPassed(player, lap) ~= lap then
			return false
		end
	end
	return true
end -- hasPlayerFinishedLap()

local function addRacer(player)
	racers[player] = Racer.new()
end -- addRacer()

local function checkAllFinished()
	for _, racer in pairs(racers) do
		if not racer:HasFinishedLap(numLaps) then
			return false
		end
	end
	return true
end -- checkAllFinished()
-- Functions --

local function playSoundLocal(sId,sParent)
	local sound = Instance.new("Sound",sParent)
	sound.SoundId = "rbxassetid://"..sId
	sound:Play()
	sound:Destroy()
end

local function onClicked(player)
	playSoundLocal(152206246,player)	-- Declaring the sound ID and Parent
	
	local foundShirt = player.Character:FindFirstChild("Shirt") -- Tries to find Shirt
	if not foundShirt then -- if there is no shirt
		local newShirt = Instance.new("Shirt",player.Character)
		newShirt.Name = "Shirt"
	else if foundShirt then -- if there is a shirt
		player.Character.Shirt:remove()
		local newShirt = Instance.new("Shirt",player.Character)
		newShirt.Name = "Shirt"
	end
	end
	
	
	
	
	local foundPants = player.Character:FindFirstChild("Pants") -- Tries to find Pants
	if not foundPants then -- if there are no pants
		local newPants = Instance.new("Pants",player.Character)
		newPants.Name = "Pants"
	else if foundPants then -- if there are pants
		player.Character.Pants:remove()
		local newPants = Instance.new("Pants",player.Character)
		newPants.Name = "Pants"
	end
	end
	
	player.Character.Shirt.ShirtTemplate = shirtId
	player.Character.Pants.PantsTemplate = pantsId
	end




local function onHoverEnter(player)
	cPart.BrickColor = BrickColor.White()
end



local function onHoverLeave(player)
	cPart.BrickColor = BrickColor.Gray()
end