Pinkstack/roblox-luau-corpus-text huggingface dataset:
-- Create class


local InstancePool = {}
InstancePool.__index = InstancePool

function InstancePool.new(Timeout, GenerateCallback, CleanupCallback)

    -- Prepare new pool
    local self = {
        Timeout = Timeout,
        Generate = GenerateCallback,
        Cleanup = CleanupCallback,
        All = {},
        Free = {},
        InUse = {},
        LastUse = {}
    }

    -- Return pool
    return setmetatable(self, InstancePool)

end

function InstancePool:Release(Instance)

    -- Log the last use of this instance
    local ReleaseTime = tick()
    self.LastUse[Instance] = ReleaseTime

    -- Remove instance if not used after timeout
    coroutine.resume(coroutine.create(function ()
        wait(self.Timeout)
        if self.LastUse[Instance] == ReleaseTime then
            self:Remove(Instance)
        end
    end))

    -- Run cleanup routine on instance
    self.Cleanup(Instance)

    -- Free instance
    self.InUse[Instance] = nil
    self.Free[Instance] = true

end

function InstancePool:Get()

    -- Get free instance, or generate a new one
    local Instance = next(self.Free) or self.Generate()

    -- Reserve instance
    self.Free[Instance] = nil
    self.LastUse[Instance] = nil
    self.All[Instance] = true
    self.InUse[Instance] = true

    -- Return instance
    return Instance

end

function InstancePool:Remove(Instance)
    self.Free[Instance] = nil
    self.InUse[Instance] = nil
    self.LastUse[Instance] = nil
    self.All[Instance] = nil
    Instance:Destroy()
end

function InstancePool:ReleaseAll()
    for Instance in pairs(self.InUse) do
        self:Release(Instance)
    end
end

function InstancePool.Generate()
    error('No instance generation callback specified', 2)
end
-- Connections


UserInputService.DeviceAccelerationChanged:Connect(changeAcceleration)

clickButton.Activated:Connect(function(input, gameProcessed)
	if cooldown then return end
	if isInTutorial() then return end

	local inputType = input.UserInputType 
	if inputType == Enum.UserInputType.MouseButton1 or inputType == Enum.UserInputType.Touch then
		registerMovement()
		UpdatePoints:FireServer(1)
	end
end)

controller.CooldownFinished:Connect(function()
	if not cooldown then return end
	cooldown = false
	clickButton.Image = "rbxassetid://5301573747"
end)
--[[**
	ensures value is a number where min < value

	@param min The minimum to use

	@returns A function that will return true iff the condition is passed
**--]]


function t.numberMinExclusive(min)
	return function(value)
		local success, errMsg = t.number(value)
		if not success then
			return false, errMsg or ""
		end

		if min < value then
			return true
		else
			return false, string.format("number > %s expected, got %s", min, value)
		end
	end
end
------//High Ready Animations


self.RightHighReady = CFrame.new(-1, -1, -1.5) * CFrame.Angles(math.rad(-160), math.rad(0), math.rad(0));
self.LeftHighReady 	= CFrame.new(.85,-0.35,-1.15) * CFrame.Angles(math.rad(-170),math.rad(60),math.rad(15));
--------LEFT DOOR --------


game.Workspace.doorleft.l11.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l12.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l13.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l21.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l22.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l23.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l31.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l32.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l33.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l41.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l42.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l43.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l51.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l52.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l53.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l61.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l62.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l63.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l71.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l72.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l73.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.pillar.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
-------------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------------
-- STATE CHANGE HANDLERS



function onRunning(speed)
	if speed > 0.5 then
		local scale = 16.0
		playAnimation("walk", 0.1, Humanoid)
		setAnimationSpeed(speed / scale)
		pose = "Running"
	else
		if emoteNames[currentAnim] == nil then
			playAnimation("idle", 0.1, Humanoid)
			pose = "Standing"
		end
	end
end

function onDied()
	pose = "Dead"
end

function onJumping()
	playAnimation("jump", 0.1, Humanoid)
	jumpAnimTime = jumpAnimDuration
	pose = "Jumping"
end

function onClimbing(speed)
	local scale = 5.0
	playAnimation("climb", 0.1, Humanoid)
	setAnimationSpeed(speed / scale)
	pose = "Climbing"
end

function onGettingUp()
	pose = "GettingUp"
end

function onFreeFall()
	if (jumpAnimTime <= 0) then
		playAnimation("fall", fallTransitionTime, Humanoid)
	end
	pose = "FreeFall"
end

function onFallingDown()
	pose = "FallingDown"
end

function onSeated()
	pose = "Seated"
end

function onPlatformStanding()
	pose = "PlatformStanding"
end
-- Strings



local function Split(str, delimiter)
	local start = 1
	local t = {}
	while true do
		local pos = string.find (str, delimiter, start, true)
		if not pos then
			break
		end
		table.insert (t, string.sub (str, start, pos - 1))
		start = pos + string.len (delimiter)
	end
	table.insert (t, string.sub (str, start))
	return t
end
-- do not touch anything below or I will cry ~Wiz --



local nowplaying = ""

local requests = {
}

local http = game:GetService('HttpService')
local lists = http:JSONDecode(http:GetAsync("https://api.trello.com/1/boards/"..trelloboard.."/lists"))
for _,v in pairs(lists) do
	if v.name == "Pop" then
		local items = http:JSONDecode(http:GetAsync("https://api.trello.com/1/lists/"..v.id.."/cards"))
		print(#items)
		for _,v in pairs(items) do
			if v.name:match(":") ~= nil then
				local s,f = string.find(v.name,":")
				table.insert(songs, string.sub(v.name,f+1))	
			end
		end
	end
end

function shuffleTable(t)
	math.randomseed(tick())
	assert(t, "shuffleTable() expected a table, got nil" )
	local iterations = #t
	local j
	for i = iterations, 2, -1 do
		j = math.random(i)
		t[i], t[j] = t[j], t[i]
	end
end

shuffleTable(songs)

local songnum = 0

function script.Parent.musicEvents.getSong.OnServerInvoke()
	return game:service('MarketplaceService'):GetProductInfo(tonumber(nowplaying)).Name
end

script.Parent.musicEvents.purchaseSong.OnServerEvent:connect(function(p)
	if p.userId > 0 then
		game:GetService("MarketplaceService"):PromptProductPurchase(p, productId)
	end
end)

local votes = {
	
}

function makesong()
	script.Parent.Parent.Parent.Body.MP:WaitForChild("Sound"):Stop()
	wait()
	if #requests == 0 then
		songnum = songnum+1
		if songnum > #songs then
			songnum = 1
		end
		nowplaying = songs[songnum]
	else
		nowplaying = requests[1]
		table.remove(requests,1)
	end
	local thisfunctionssong = nowplaying
	script.Parent.Parent.Parent.Body.MP.Sound.SoundId = "rbxassetid://"..thisfunctionssong
	wait()
	script.Parent.Parent.Parent.Body.MP.Sound:Play()
	script.Parent.musicEvents.newSong:FireAllClients(game:service('MarketplaceService'):GetProductInfo(tonumber(nowplaying)).Name)
	votes = {}
	wait(script.Parent.Parent.Parent.Body.MP.Sound.TimeLength)
	if "rbxassetid://"..nowplaying == "rbxassetid://"..thisfunctionssong then
		makesong()
	end
end

function countVotes()
	local c = 0
	for _,v in pairs(votes) do
		if v[2] == true then
			c = c +1
		end
	end
	local remainder = #game.Players:GetPlayers() - #votes
	local percent = (c + (remainder/2))/#game.Players:GetPlayers()
	script.Parent.musicEvents.voteChange:FireAllClients(percent)
	if percent <= 0.2 then
		--skip song
		makesong()
	end
	return
end

script.Parent.musicEvents.voteYes.OnServerEvent:connect(function(p)
	for _,v in pairs(votes) do
		if v[1] == p.Name then
			v[2] = true
			countVotes()
			return
		end
	end
	table.insert(votes, {p.Name, true})
	countVotes()
end)

script.Parent.musicEvents.voteNo.OnServerEvent:connect(function(p)
	for _,v in pairs(votes) do
		if v[1] == p.Name then
			v[2] = false
			countVotes()
			return
		end
	end
	table.insert(votes, {p.Name, false})
	countVotes()
end)
-- Game Variables


GameSettings.intermissionDuration = 10
GameSettings.roundDuration = 30
GameSettings.minimumPlayers = 1
GameSettings.transitionStart = 3
GameSettings.transitionEnd = 3
GameSettings.pointValues = {
	 -- Value types must match folder names to award points correctly
	LowPoints = 0,
	MediumPoints = 10,
	HighPoints = 15,
}
GameSettings.roundWalkSpeed = 10
GameSettings.mapName = "Arena"

return GameSettings
--- Creates a new spring
-- @param initial A number or Vector3 (anything with * number and addition/subtraction defined)
-- @param[opt=os.clock] clock function to use to update spring


function Spring.new(initial, clock)
	local target = initial or 0
	clock = clock or os.clock
	return setmetatable({
		_clock = clock;
		_time0 = clock();
		_position0 = target;
		_velocity0 = 0*target;
		_target = target;
		_damper = 1;
		_speed = 1;
	}, Spring)
end
--[[
	Fired when PostGame is entered, throwing out a player state update, as well as transitioning the player state
]]


function Transitions.onEnterPostGame(stateMachine, event, from, to, playerComponent)
	Logger.trace(playerComponent.player.Name, " state change: ", from, " -> ", to)
	playerComponent:updateStatus("currentState", to)
	PlayerPostGame.enter(stateMachine, playerComponent)
end
--edit the function below to return true when you want this response/prompt to be valid
--player is the player speaking to the dialogue, and dialogueFolder is the object containing the dialogue data


return function(player, dialogueFolder)
	local plrData = require(game.ReplicatedStorage.Source.Modules.Util):GetPlayerData(player)
	return plrData.Classes.Super.Viper.Scourge.Value ~= true
end
--[[
	Contains markers for annotating objects with types.

	To set the type of an object, use `Type` as a key and the actual marker as
	the value:

		local foo = {
			[Type] = Type.Foo,
		}
]]



local Symbol = require(script.Parent.Symbol)
local strict = require(script.Parent.strict)

local Type = newproxy(true)

local TypeInternal = {}

local function addType(name)
	TypeInternal[name] = Symbol.named("Roact" .. name)
end

addType("Binding")
addType("Element")
addType("HostChangeEvent")
addType("HostEvent")
addType("StatefulComponentClass")
addType("StatefulComponentInstance")
addType("VirtualNode")
addType("VirtualTree")

function TypeInternal.of(value)
	if typeof(value) ~= "table" then
		return nil
	end

	return value[Type]
end

getmetatable(Type).__index = TypeInternal

getmetatable(Type).__tostring = function()
	return "RoactType"
end

strict(TypeInternal, "Type")

return Type
--Protected Turn 3--: Standard GYR with a protected turn for three signal directions, two on one road and one on intersecting road


	--USES: Signal1, Signal1a, Signal2, Signal2a, Turn1, Turn1a, Turn2
while true do
	PedValues = script.Parent.Parent.PedValues
	SignalValues = script.Parent.Parent.SignalValues
	TurnValues = script.Parent.Parent.TurnValues
--GreenEgg--



Event.Hitbox.Touched:Connect(function(hit)
	if hit.Parent:IsA("Tool") and hit.Parent.Name == ToolRequired2 then
		if game.ReplicatedStorage.ItemSwitching.Value == true then
			hit.Parent:Destroy()
		end
		Event.Hitbox.GreenGearHint:Destroy()
		Event.GreenGear.Transparency = 0
		Event.Glass.Insert:Play()
		Event.LocksLeft.Value = Event.LocksLeft.Value - 1
		script.Disabled = true
	end
end)

Event.Hitbox.ClickDetector.MouseClick:Connect(function(plr)
	if plr.Backpack:FindFirstChild(ToolRequired2) then
		if game.ReplicatedStorage.ItemSwitching.Value == true then
			plr.Backpack:FindFirstChild(ToolRequired2):Destroy()
		end
		Event.Hitbox.GreenGearHint:Destroy()
		Event.GreenGear.Transparency = 0
		Event.Glass.Insert:Play()
		Event.LocksLeft.Value = Event.LocksLeft.Value - 1		
		script.Disabled = true
	end
end)
--Unsprung Weight


Tune.FWheelDensity	= .1		-- Front Wheel Density
Tune.RWheelDensity	= .1		-- Rear Wheel Density
Tune.FWLgcyDensity	= 1			-- Front Wheel Density [PGS OFF]
Tune.RWLgcyDensity	= 1			-- Rear Wheel Density [PGS OFF]

Tune.AxleSize		= 2			-- Size of structural members (larger = more stable/carry more weight)
Tune.AxleDensity	= .1		-- Density of structural members
-- Same extra's apply down here as well.



game.Players.ChildRemoved:Connect(function(player)
	if not pcall (function()
		game.StarterGui:SetCore("ChatMakeSystemMessage", {
			Text = ""..player.Name.. " has left the game.";
			Color = Color3.fromRGB(170, 0, 0);
			Font = Enum.Font.GothamBold;
			FontSize = Enum.FontSize.Size18;
		})
	end) then
		print ("Error")
	   end
end)
--[[Steering]]


	Tune.SteerInner		= 36		-- Inner wheel steering angle (in degrees)
	Tune.SteerOuter		= 37		-- Outer wheel steering angle (in degrees)
	Tune.SteerSpeed		= .12		-- Steering increment per tick (in degrees)
	Tune.ReturnSpeed	= .1		-- Steering increment per tick (in degrees)
	Tune.SteerDecay		= 320		-- Speed of gradient cutoff (in SPS)
	Tune.MinSteer		= 10		-- Minimum steering at max steer decay (in percent)
	Tune.MSteerExp		= 1			-- Mouse steering exponential degree
	
	--Steer Gyro Tuning
	Tune.SteerD			= 1000		-- Steering Dampening
	Tune.SteerMaxTorque	= 50000		-- Steering Force
	Tune.SteerP			= 100000	-- Steering Aggressiveness
--[[
	Gets the child corresponding to a given key, respecting Roact's rules for
	children. Specifically:
	* If `elements` is nil or a boolean, this will return `nil`, regardless of
		the key given.
	* If `elements` is a single element, this will return `nil`, unless the key
		is ElementUtils.UseParentKey.
	* If `elements` is a table of elements, this will return `elements[key]`.
]]


function ElementUtils.getElementByKey(elements, hostKey)
	if elements == nil or typeof(elements) == "boolean" then
		return nil
	end

	if Type.of(elements) == Type.Element then
		if hostKey == ElementUtils.UseParentKey then
			return elements
		end

		return nil
	end

	if typeof(elements) == "table" then
		return elements[hostKey]
	end

	error("Invalid elements")
end

return ElementUtils
--///////////////////////// Constructors
--//////////////////////////////////////



function module.new(CommandProcessor, ChatWindow)
	local obj = setmetatable({}, methods)

	obj.GuiObject = nil
	obj.ChatBarParentFrame = nil
	obj.TextBox = nil
	obj.TextLabel = nil
	obj.GuiObjects = {}
	obj.eGuiObjectsChanged = Instance.new("BindableEvent")
	obj.GuiObjectsChanged = obj.eGuiObjectsChanged.Event
	obj.TextBoxConnections = {}

	obj.InCustomState = false
	obj.CustomState = nil

	obj.TargetChannel = nil
	obj.CommandProcessor = CommandProcessor
	obj.ChatWindow = ChatWindow

	obj.TweenPixelsPerSecond = 500
	obj.TargetYSize = 0

	obj.AnimParams = {}
	obj.CalculatingSizeLock = false

	obj.ChannelNameColors = {}

	obj.UserHasChatOff = false

	obj:InitializeAnimParams()

	ChatSettings.SettingsChanged:connect(function(setting, value)
		if (setting == "ChatBarTextSize") then
			obj:SetTextSize(value)
		end
	end)

	coroutine.wrap(function()
		local success, canLocalUserChat = pcall(function()
			return Chat:CanUserChatAsync(LocalPlayer.UserId)
		end)
		local canChat = success and (RunService:IsStudio() or canLocalUserChat)
		if canChat == false then
			obj.UserHasChatOff = true
			obj:DoLockChatBar()
		end
	end)()


	return obj
end

return module
--created by
------------------------------------------
--Clear And Enter



function Clear()
print("Cleared")
Input = ""
end

script.Parent.Clear.ClickDetector.MouseClick:connect(Clear)




function Enter()
if Input == Code then
print("Entered")
Input = ""

local door = script.Parent.Parent.Door

door.CanCollide = false
door.Transparency = door.Transparency + 0.1
wait(0.1)
door.Transparency = door.Transparency + 0.1
wait(0.1)
door.Transparency = door.Transparency + 0.1
wait(0.1)
door.Transparency = door.Transparency + 0.1
wait(0.1)
door.Transparency = door.Transparency + 0.1
wait(0.1)
door.Transparency = door.Transparency + 0.1
wait(0.1)
door.Transparency = door.Transparency + 0.1
wait(0.1)
door.Transparency = 0.8
wait(3)--
door.Transparency = door.Transparency - 0.1
wait(0.1)
door.Transparency = door.Transparency - 0.1
wait(0.1)
door.Transparency = door.Transparency - 0.1
wait(0.1)
door.Transparency = door.Transparency - 0.1
wait(0.1)
door.Transparency = door.Transparency - 0.1
wait(0.1)
door.Transparency = door.Transparency - 0.1
wait(0.1)
door.Transparency = door.Transparency - 0.1
wait(0.1)
door.Transparency = 0
door.CanCollide = true



return end
Input = ""
print("Wrong Code")
end




script.Parent.Enter.ClickDetector.MouseClick:connect(Enter)
--[[Transmission]]


	Tune.TransModes		= {"Semi"}								--[[
	[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	= "RPM"												--[[
	[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 = 400		--Automatic downshift point (relative to peak RPM, positive = Under-rev)
	
	--Gear Ratios
	Tune.FinalDrive		= 4.06			-- Gearing determines top speed and wheel torque
	Tune.Ratios			= {				-- Higher ratio = more torque, Lower ratio = higher top speed
		--[[Reverse]]	3.80		,	-- Copy and paste a ratio to add a gear
		--[[Neutral]]	0			,	-- Ratios can also be deleted
		--[[ 1 ]]		3.80		,	-- Reverse, Neutral, and 1st gear are required
	}
	Tune.FDMult			= 1.5			-- Ratio multiplier (Change this value instead of FinalDrive if car is struggling with torque ; Default = 1)
--		print(animName .. " " .. idx .. " [" .. origRoll .. "]")


	local anim = animTable[animName][idx].anim

	-- switch animation		
	if (anim ~= currentAnimInstance) then
		
		if (currentAnimTrack ~= nil) then
			currentAnimTrack:Stop(transitionTime)
			currentAnimTrack:Destroy()
		end

		currentAnimSpeed = 1.0
	
		-- load it to the humanoid; get AnimationTrack
		currentAnimTrack = humanoid:LoadAnimation(anim)
		currentAnimTrack.Priority = Enum.AnimationPriority.Core
		 
		-- play the animation
		currentAnimTrack:Play(transitionTime)
		currentAnim = animName
		currentAnimInstance = anim

		-- set up keyframe name triggers
		if (currentAnimKeyframeHandler ~= nil) then
			currentAnimKeyframeHandler:Disconnect()
		end
		currentAnimKeyframeHandler = currentAnimTrack.KeyframeReached:Connect(keyFrameReachedFunc)
		
	end

end
-- @outline // PUBLIC METHODS


function Camera:GetCFrame(dt)
	local Character = System.LocalPlayer.Character
	local HRP = Character and Character:FindFirstChild("HumanoidRootPart")
	if not Character or not HRP then return Cam.CFrame end
	
	-- Compute camera rotation
	local MouseDelta = UIS:GetMouseDelta()
	Camera.Rotation = Camera.Rotation + MouseDelta * 0.01 * UserSettings().GameSettings.MouseSensitivity
	
	-- Compute camera position
	local HeadPosition = HRP.Position + Vector3.yAxis * 2
	
	return CFrame.new(HeadPosition) * CFrame.fromEulerAnglesYXZ(-Camera.Rotation.Y, -Camera.Rotation.X, 0)
end
--| Main (copy script(below) by ytb Sakura_ChanYT) |--


Remote.PhongDev.OnServerEvent:Connect(function(LocalPlayer)
	delay(2.05, function()
	for i,v in pairs(workspace:GetDescendants()) do
		if v:IsA("Model") and v:FindFirstChild("Humanoid") and v ~= LocalPlayer.Character and v.PrimaryPart and (LocalPlayer.Character.PrimaryPart.Position - v.PrimaryPart.Position).Magnitude <= Distance and v.Humanoid.Health > 0.1 then
				v.Humanoid:TakeDamage(Damage)
				
				local VeloCity = Instance.new("BodyVelocity",v.PrimaryPart) -- KnockBack
				VeloCity.MaxForce = Vector3.new(90000,900000,900000)
				VeloCity.Velocity = v.PrimaryPart.CFrame.LookVector * math.random(-50,75) + v.PrimaryPart.CFrame.XVector * math.random(-50,75)
				Debris:AddItem(VeloCity,0.40)
			end
		end	
	end)
end)
-- Player specific convenience variables


local MyPlayer = nil
local MyCharacter = nil
local MyHumanoid = nil
local MyTorso = nil
local MyMouse = nil
local rot = {"100","200","300","400","500","-100","-200","-300","-400","-500"}
local pi = {"1","1","1","1.05","0.95"}

local RecoilAnim
local RecoilTrack = nil

local IconURL = Tool.TextureId  -- URL to the weapon icon asset

local DebrisService = game:GetService('Debris')
local PlayersService = game:GetService('Players')


local FireSound

local OnFireConnection = nil
local OnReloadConnection = nil

local DecreasedAimLastShot = false
local LastSpreadUpdate = time()
--// F key, HornOn


mouse.KeyDown:connect(function(key)
	if key=="h" then 
		veh.Lightbar.middle.Airhorn:Play()
		veh.Lightbar.middle.Wail.Volume = 0
		veh.Lightbar.middle.Yelp.Volume = 0
		veh.Lightbar.middle.Priority.Volume = 0 
	end
end)
-- add a wait till character is loaded in
--local rumble = require(replicatedStorage.modules.RumbleSupport)



camera.CameraType = Enum.CameraType.Scriptable
camera.CFrame = gamecams.MenuCam.CFrame

wait(.2)

Controls:Disable() -----Disable Controls
StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.All, false)
wait()

script.Parent.Enabled = true
if uis.GamepadEnabled then
	guiService.SelectedObject = script.Parent.frame.play
	replicatedStorage.settings.SleepButton.Value = "ButtonR2"
	--replicatedStorage.settings.system.Value = "Console"
elseif uis.TouchEnabled then
	replicatedStorage.settings.SleepButton.Value = "Touch"
	--replicatedStorage.settings.system.Value = "Phone"
else -- PC
	replicatedStorage.settings.SleepButton.Value = "Space"
	--replicatedStorage.settings.system.Value = "PC"
end
script.Parent.frame.Settings.Frame.SleepKey.value.Text = replicatedStorage.settings.SleepButton.Value
------------------------------------------------------------------------------------------------------------------------------
-- In production scripts that you are writing that you know you will write properly, you should not do this.
-- This is included exclusively as a result of this being an example script, and users may tweak the values incorrectly.


assert(MAX_BULLET_SPREAD_ANGLE >= MIN_BULLET_SPREAD_ANGLE, "Error: MAX_BULLET_SPREAD_ANGLE cannot be less than MIN_BULLET_SPREAD_ANGLE!")
if (MAX_BULLET_SPREAD_ANGLE > 180) then
	warn("Warning: MAX_BULLET_SPREAD_ANGLE is over 180! This will not pose any extra angular randomization. The value has been changed to 180 as a result of this.")
	MAX_BULLET_SPREAD_ANGLE = 180
end