Roblox/luau_corpus huggingface dataset:
----------------------------------------------------------------------------------------------------
-----------------=[ RECOIL & PRECISAO ]=------------------------------------------------------------
----------------------------------------------------------------------------------------------------
	,VRecoil = {13,17}				--- Vertical Recoil
	,HRecoil = {6,8}				--- Horizontal Recoil
	,AimRecover = .75				---- Between 0 & 1
	
	,RecoilPunch = .15
	,VPunchBase = 2.75				--- Vertical Punch
	,HPunchBase = 1.35				--- Horizontal Punch
	,DPunchBase = 1 				--- Tilt Punch | useless
	
	,AimRecoilReduction = 5 		--- Recoil Reduction Factor While Aiming (Do not set to 0)
	,PunchRecover = 0.2
	,MinRecoilPower = .5
	,MaxRecoilPower = 3.5
	,RecoilPowerStepAmount = .25
	
	,MinSpread = 1.25				--- Min bullet spread value | Studs
	,MaxSpread = 40					--- Max bullet spread value | Studs
	,AimInaccuracyStepAmount = 0.75
	,WalkMultiplier = 0				--- Bullet spread based on player speed

	,SwayBase = 0.05				--- Weapon Base Sway | Studs
	,MaxSway =	1.5					--- Max sway value based on player stamina | Studs
------------------------------------------------------------------------------------------------------------------------------
--// Module

local module = {};

for _, class in next, {"TextLabel", "TextBox", "TextButton", "TextReplace"} do
	module[string.sub(class, 5)] = function(child)
		return customFont.new("A", class == "TextReplace" and child or class, class == "TextButton" or (class == "TextReplace" and child:IsA("TextButton")));
	end;
end;

wait(); -- top bar can mess with stuff if fonts called instantly

return module;
-- ProfileVersionQuery object:

local ProfileVersionQuery = {
	--[[
		_profile_store = profile_store,
		_profile_key = profile_key,
		_sort_direction = sort_direction,
		_min_date = min_date,
		_max_date = max_date,

		_query_pages = pages, -- [DataStoreVersionPages]
		_query_index = index, -- [number]
		_query_failure = false,

		_is_query_yielded = false,
		_query_queue = {},
	--]]
}
ProfileVersionQuery.__index = ProfileVersionQuery

function ProfileVersionQuery:_MoveQueue()
	while #self._query_queue > 0 do
		local queue_entry = table.remove(self._query_queue, 1)
		task.spawn(queue_entry)
		if self._is_query_yielded == true then
			break
		end
	end
end

function ProfileVersionQuery:NextAsync(_is_stacking) --> [Profile] or nil

	if self._profile_store == nil then
		return nil
	end

	local profile
	local is_finished = false

	local function query_job()

		if self._query_failure == true then
			is_finished = true
			return
		end

		-- First "next" call loads version pages:

		if self._query_pages == nil then

			self._is_query_yielded = true
			task.spawn(function()
				profile = self:NextAsync(true)
				is_finished = true
			end)
			
			local list_success, error_message = pcall(function()
				self._query_pages = self._profile_store._global_data_store:ListVersionsAsync(
					self._profile_key,
					self._sort_direction,
					self._min_date,
					self._max_date
				)
				self._query_index = 0
			end)

			if list_success == false or self._query_pages == nil then
				warn("[ProfileService]: Version query fail - " .. tostring(error_message))
				self._query_failure = true
			end

			self._is_query_yielded = false
			self:_MoveQueue()

			return

		end

		local current_page = self._query_pages:GetCurrentPage()
		local next_item = current_page[self._query_index + 1]

		-- No more entries:
		
		if self._query_pages.IsFinished == true and next_item == nil then
			is_finished = true
			return
		end

		-- Load next page when this page is over:

		if next_item == nil then

			self._is_query_yielded = true
			task.spawn(function()
				profile = self:NextAsync(true)
				is_finished = true
			end)

			local success = pcall(function()
				self._query_pages:AdvanceToNextPageAsync()
				self._query_index = 0
			end)

			if success == false or #self._query_pages:GetCurrentPage() == 0 then
				self._query_failure = true
			end

			self._is_query_yielded = false
			self:_MoveQueue()

			return

		end

		-- Next page item:

		self._query_index += 1
		profile = self._profile_store:ViewProfileAsync(self._profile_key, next_item.Version)
		is_finished = true

	end

	if self._is_query_yielded == false then
		query_job()
	else
		if _is_stacking == true then
			table.insert(self._query_queue, 1, query_job)
		else
			table.insert(self._query_queue, query_job)
		end
	end

	while is_finished == false do
		task.wait()
	end

	return profile

end
-- Bind functions to when player equips/unequips the tool. Right now just need to turn on and
-- off AutoRotate
equipEvent.OnServerEvent:connect(function(player)
	player.Character.Humanoid.AutoRotate = false
end)
unequipEvent.OnServerEvent:connect(function(player)
	player.Character.Humanoid.AutoRotate = true
end)
-- ROBLOX deviation: moved to RobloxShared to avoid reaching into internals with rotriever workspaces
local getObjectSubset = RobloxShared.expect.getObjectSubset
--[[
	Create a promise that represents the immediately resolved value.
]]
function Promise.resolve(value)
	return Promise.new(function(resolve)
		resolve(value)
	end)
end
-- show and hide animations
local function show()
	UITween.fade(welcomeFrame1, 0, 2, 0)
	UITween.size(welcomeFrame1, frameSizeStart, 0.4, 0, false)
	UITween.size(welcomeBg, bgSizeStart, 0.6, 0, false)
	UITween.fade(welcomeFrame2, 0, 2, 0)
	UITween.size(welcomeFrame2, frame2SizeStart, 0.4, 0, false)
	wait(0.25)
	UITween.turnOn(welcomeUIPointLight, 1, 2)
	UITween.fade(welcomeBg, 0.6, 2, 0)
	UITween.size(welcomeFrame1, frameSizeMid, 0.4, 0, false)
	UITween.size(welcomeFrame2, frame2SizeMid, 0.4, 0, false)
	UITween.size(welcomeBg, bgSizeStart, 0.4, 0, false)
	wait(0.25)
	UITween.size(welcomeFrame1, frameSizeEnd, 0.4, 0, false)
	UITween.size(welcomeFrame2, frame2SizeEnd, 0.4, 0, false)
	UITween.size(welcomeBg, bgSizeMid, 0.4, 0, false)
	UITween.turnOn(welcomeUIGlow, 2, 0.5)
	--UITween.turnOn(welcomeConsoleGlow, 2, 0.5)
	wait(0.25)
	UITween.size(welcomeFrame1, frameSizeEnd, 0.4, 0, false)
	UITween.size(welcomeBg, bgSizeEnd, 0.4, 0, false)
	UITween.fade(welcomeGrid, 0.8, 0.5, 0)
	UITween.fade(btnLeft, 0, 2, 0)
	UITween.fade(btnRight, 0, 2, 0)
	UITween.fade(lobbyScreen1, 0, 2, 0)
	welcomeMenuIsShowing = true	
end

local function hide()
	UITween.fade(lobbyScreen1, 1, 0.5, 0)
	UITween.fade(lobbyScreen2, 1, 0.5, 0)
	UITween.fade(lobbyScreen3, 1, 0.5, 0)
	UITween.fade(btnLeft, 1, 0.5, 0)
	UITween.fade(btnRight, 1, 0.5, 0)
	UITween.fade(welcomeGrid, 1, 0.5, 0)
	UITween.turnOn(welcomeUIGlow, 0, 0.5)
	--UITween.turnOn(welcomeConsoleGlow, 0, 0.5)
	UITween.turnOn(welcomeUIPointLight, 0, 0.5)
	UITween.size(welcomeBg, bgSizeEnd, 0.4, 0, false)
	UITween.size(welcomeBg, bgSizeMid, 0.4, 0, false)
	wait(0.25)
	UITween.size(welcomeBg, bgSizeMid, 0.4, 0, false)
	UITween.size(welcomeFrame1, frameSizeEnd, 0.4, 0, false)
	UITween.size(welcomeFrame1, frameSizeMid, 0.4, 0, false)
	UITween.size(welcomeFrame2, frame2SizeEnd, 0.4, 0, false)
	UITween.size(welcomeFrame2, frame2SizeMid, 0.4, 0, false)
	wait(0.25)
	UITween.size(welcomeBg, bgSizeStart, 0.4, 0, false)
	UITween.fade(welcomeBg, 1, 2, 0)
	wait(0.25)
	UITween.size(welcomeFrame1, frameSizeStart, 0.4, 0, false)
	UITween.fade(welcomeFrame1, 1, 2, 0)
	UITween.size(welcomeFrame2, frame2SizeStart, 0.4, 0, false)
	UITween.fade(welcomeFrame2, 1, 2, 0)
	welcomeMenuIsShowing = false
end
-- Barrier visualization variables
local barrierPartsFolder = workspace:WaitForChild("BarrierParts")
local barrierPartInfos = {}
local NUMBER_OF_LARGEST_SUBDIVISIONS = 40 -- initial number of barrierParts
local BARRIER_HEIGHT = 2048
local BARRIER_THICKNESS = 0.05
local FRACTION_OF_RADIUS_BEFORE_SPLITTING = 0.5 -- this is the fraction of the current storm radius that an initial barrierPart will split.
												-- following subdivisions will split based on SPLIT_FACTOR
local SPLIT_FACTOR = 0.75 -- this should always be less than 1. The lower the value, the closer the player must be for a barrierPart to split
local MAX_SPLIT_LEVEL = 7 -- max number of times an initial barrierPart can split
local MIN_BARRIERPART_WIDTH = 4
local TRANSPARENCY_FALLOFF_RANGE = NumberRange.new(0, 3000)
local BARRIERPART_COLOR = Color3.fromRGB(195, 14, 255)
--[[
	Connects the events for UI state.

	Returns a Rodux Signal class. This has the same API as RBXScriptSignal but
	lowercase. For example:

	```lua
	local store = Rodux.Store.new(reducer)
	local conn = uiStateEvents.connect(store)

	conn:disconnect()
	```
]]
function uiStatesEvents.connect(store)
	return store.changed:connect(function(newState: reducer.State, oldState: reducer.State)
		-- 3 booleans, one for each of the UI states
		local oldClosedState = not oldState.ui.merchBoothOpen
		local oldCatalogState = oldState.ui.merchBoothOpen and oldState.ui.viewedItemId == nil
		local oldItemState = oldState.ui.merchBoothOpen and oldState.ui.viewedItemId ~= nil

		local newClosedState = not newState.ui.merchBoothOpen
		local newCatalogState = newState.ui.merchBoothOpen and newState.ui.viewedItemId == nil
		local newItemState = newState.ui.merchBoothOpen and newState.ui.viewedItemId ~= nil

		if not oldClosedState and newClosedState then
			uiStatesEvents.merchBoothClosed:Fire()
		end
		if oldClosedState and not newClosedState then
			uiStatesEvents.merchBoothOpened:Fire()
		end

		if not oldCatalogState and newCatalogState then
			uiStatesEvents.catalogViewOpened:Fire()
		end
		if oldCatalogState and not newCatalogState then
			uiStatesEvents.catalogViewClosed:Fire()
		end

		if not oldItemState and newItemState then
			uiStatesEvents.itemViewOpened:Fire(newState.ui.viewedItemId)
		end
		if oldItemState and not newItemState then
			uiStatesEvents.itemViewClosed:Fire(oldState.ui.viewedItemId)
		end
	end)
end

return uiStatesEvents
-- ok
script.Parent.PrimaryPart:SetNetworkOwner(nil)

local RunS = game:GetService('RunService')
local PFS = game:GetService('PathfindingService')
--	elseif loca == 10 then
--		if sel == 1 then
--			light("solar")
--		elseif sel == 2 then
--			light("lunar")
--		elseif sel == 3 then
--			light("aurora")
--		elseif sel == 4 then
--			light("clarity")
--		elseif sel == 5 then
--			home()
--		end
	end
	names()
	wait()
	hov(sel)
end)

inf.up.MouseButton1Click:connect(function()
	sel = math.max(sel-1,min)
	inf.Main.Select.Hover:TweenPosition(UDim2.new(0, 0, (sel/5)-.2, 0),"InOut","Quad",.5,true)
	hov(sel)
end)

inf.dn.MouseButton1Click:connect(function()
	sel = math.min(sel+1,max)
	inf.Main.Select.Hover:TweenPosition(UDim2.new(0, 0, (sel/5)-.2, 0),"InOut","Quad",.5,true)
	hov(sel)
end)

inf.Music.mg.Input.FocusLost:connect(function(t)
	if t == true then
		if loca == 6 then
			inf.Main.Background.Image = "rbxassetid://"..(inf.Music.mg.Input.Text)
			wait()
			inf.Music.mg.Input.Text = "ENTER ID"
			input(false)
		end
	else
		inf.Music.mg.Input.Text = "ENTER ID"
		input(false)
	end
end)
-- Ajedi32

speed = 0.25

door1 = script.Parent.SlidingDoor1
door2 = script.Parent.SlidingDoor2
open = script.open

function stateChanged()
	if open.Value then
		for i=1,(door1.Size.z/speed) + 1 do
			wait()
			door1.CFrame = door1.CFrame - (door1.CFrame.lookVector * speed)
			door2.CFrame = door2.CFrame - (door2.CFrame.lookVector * speed)
		end
	else
		for i=1,(door1.Size.z/speed) + 1 do
			wait()
			door1.CFrame = door1.CFrame + (door1.CFrame.lookVector * speed)
			door2.CFrame = door2.CFrame + (door2.CFrame.lookVector * speed)
		end
	end
end

open.Changed:connect(stateChanged)
--[[
	Assert that the expectation value is the given type.

	expect(5).to.be.a("number")
]]
function Expectation:a(typeName)
	local result = (type(self.value) == typeName) == self.successCondition

	local message = formatMessage(self.successCondition,
		("Expected value of type %q, got value %q of type %s"):format(
			typeName,
			tostring(self.value),
			type(self.value)
		),
		("Expected value not of type %q, got value %q of type %s"):format(
			typeName,
			tostring(self.value),
			type(self.value)
		)
	)

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

	return self
end
--// Ammo Settings			
	Ammo = 71;
	StoredAmmo = 71;
	MagCount = math.huge; --  If you want infinate ammo, set to math.huge EX. MagCount = math.huge;
	ExplosiveAmmo = 0;
-- teererererererphof
--local player = game.Players:GetPlayerFromCharacter(script.Parent.Parent)
--player.PlayerGui:FindFirstChild("Client_HurtS").Blunt:FireClient(player)

wait(7)
script.Parent.PlatformStand = false
wait(0.5)
script:Destroy()
--[[position and movement]]--
while wait() do
	local closestPlayer, smallestMagnitude = nil,math.huge
	for _, player in pairs(game.Players:GetPlayers()) do
		local distance = player:DistanceFromCharacter(script.Parent.HumanoidRootPart.Position)
		if distance < smallestMagnitude then
			smallestMagnitude = distance
			closestPlayer = player
			if closestPlayer and closestPlayer.Character and closestPlayer.Character:FindFirstChild("HumanoidRootPart") then
				script.Parent.BenHumanoid:MoveTo(closestPlayer.Character.HumanoidRootPart.Position)
			end
		end
	end
end
-----------------------------------------------------------------------------------------------

ItemID = 90423800 -- The ID of the Gamepass/T-Shirt.
OpenTime = 0 -- The time the door is open for.
OpenTrans = 1 -- The transparency of the door when it is open.
CloseTrans = 1 -- The transparency of the door when it is closed.
BuyGUI = true -- Set to false to stop the BuyGUI appearing.
KillOnTouch = false -- Set to false to stop players being killed when they touch it.
--[[Susupension]]
	Tune.SusEnabled		= true		-- works only in with PGSPhysicsSolverEnabled, defaults to false when PGS is disabled
	
	--Front Suspension
	Tune.FSusDamping	= 500		-- Spring Dampening
	Tune.FSusStiffness	= 9000		-- Spring Force
	Tune.FAntiRoll 		= 50		-- Anti-Roll (Gyro Dampening)
	
	Tune.FSusLength		= 2			-- Suspension length (in studs)
	Tune.FPreCompress	= .3		-- Pre-compression adds resting length force
	Tune.FExtensionLim	= .3		-- Max Extension Travel (in studs)
	Tune.FCompressLim	= .1		-- Max Compression Travel (in studs)
	Tune.FSusAngle		= 80		-- Suspension Angle (degrees from horizontal)
		
	Tune.FWsBoneLen		= 5			-- Wishbone Length
	Tune.FWsBoneAngle	= 0			-- 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	= 500		-- Spring Dampening
	Tune.RSusStiffness	= 9000		-- Spring Force
	Tune.FAntiRoll 		= 50		-- Anti-Roll (Gyro Dampening)

	Tune.RSusLength		= 2			-- Suspension length (in studs)
	Tune.RPreCompress	= .3		-- Pre-compression adds resting length force
	Tune.RExtensionLim	= .3		-- Max Extension Travel (in studs)
	Tune.RCompressLim	= .1		-- Max Compression Travel (in studs)
	Tune.RSusAngle		= 80		-- Suspension Angle (degrees from horizontal)
		
	Tune.RWsBoneLen		= 5			-- Wishbone Length
	Tune.RWsBoneAngle	= 0			-- 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		= true			-- Spring Visible
	Tune.WsBVisible		= false			-- Wishbone Visible
	Tune.SusRadius		= .2			-- Suspension Coil Radius
	Tune.SusThickness	= .1			-- Suspension Coil Thickness
	Tune.SusColor		= "Black"	-- Suspension Color [BrickColor]
	Tune.SusCoilCount	= 6				-- Suspension Coil Count
	Tune.WsColor		= "Black"		-- Wishbone Color [BrickColor]
	Tune.WsThickness	= .1			-- Wishbone Rod Thickness
-- local emptyObject = require(CurrentModule.utils).emptyObject

local utils = Object.freeze(Object.assign({}, matcherUtils, {
	iterableEquality = iterableEquality,
	subsetEquality = subsetEquality,
}))

local AsymmetricMatcher = {}
AsymmetricMatcher.__index = AsymmetricMatcher
function AsymmetricMatcher.new(sample: any, inverse: boolean?)
	local self = {
		sample = sample,
		inverse = if inverse == nil then false else inverse,
		["$$typeof"] = Symbol.for_("jest.asymmetricMatcher"),
	}

	setmetatable(self, AsymmetricMatcher)
	return self
end

type State_ = MatcherState
function AsymmetricMatcher:getMatcherContext(): State_
	return Object.assign({}, getState(), {
		equals = equals,
		isNot = self.inverse,
		utils = utils,
	})
end
--

if Util.isPlayerBot(localPlayer) then
	print("Configuring player as bot")
end

require(script.Parent:WaitForChild("PlayerModule"):WaitForChild("ControlModule"))

local PlayerBehaviorManager = require(ReplicatedStorage.PlayerBehaviorManager)
PlayerBehaviorManager.init()

local DamageHandler = require(ReplicatedStorage.DamageHandler)
DamageHandler.setup()

require(ReplicatedStorage.Libraries.BTDebugger)
--unfreeze the character
for i = 1, #iceParts do
	local C = iceParts[i]:GetChildren()
    for ii = 1, #C do
        if C[ii].className == "Weld" then
            C[ii]:Destroy()
        end
    end
	local dir = (iceParts[i].Position - iceParts[i].CFrame.p + Vector3.new(0, 1, 0)).unit
	iceParts[i].Velocity = (dir + Vector3.new(math.random() - 0.5, 1, math.random() - 0.5)) * 20
	iceParts[i].RotVelocity = (dir + Vector3.new(math.random() - 0.5, math.random() - 0.5, math.random() - 0.5)) * 10
	local force = Instance.new("BodyForce")
	force.Force = dir * 50 * iceParts[i]:GetMass()
	force.Parent = iceParts[i]
	task.delay(0.25, function() force:Destroy() end)
end

for i, v in pairs(welds) do
	if v then
		v:Destroy()
	end
end

EnableMove()

IceShatter = Instance.new("Sound")
IceShatter.Name = "IceShatter"
IceShatter.SoundId = "rbxassetid://"..shatterSounds[math.random(1, #shatterSounds)]
IceShatter.Parent = Head
IceShatter.PlaybackSpeed = 1
IceShatter.Volume = 1.5
game.Debris:AddItem(IceShatter, 10)
task.delay(0, function() IceShatter:Play() end)
IceShatter.Ended:Connect(function()
	if script then
		script:Destroy()
	end
end)
-- Roblox NPC sound script

local Players = game:GetService("Players")
local RunService = game:GetService("RunService")

local SOUND_DATA = {
	Climbing = {
		SoundId = "rbxasset://sounds/action_footsteps_plastic.mp3",
		Looped = true,
	},
	Died = {
		SoundId = "rbxassetid://3361342315",
	},
	FreeFalling = {
		SoundId = "rbxasset://sounds/action_falling.mp3",
		Looped = true,
	},
	GettingUp = {
		SoundId = "rbxasset://sounds/action_get_up.mp3",
	},
	Jumping = {
		SoundId = "rbxasset://sounds/action_jump.mp3",
	},
	Landing = {
		SoundId = "rbxasset://sounds/action_jump_land.mp3",
	},
	Running = {
		SoundId = "rbxasset://sounds/action_footsteps_plastic.mp3",
		Looped = true,
		Pitch = 1.85,
	},
	Splash = {
		SoundId = "rbxasset://sounds/impact_water.mp3",
	},
	Swimming = {
		SoundId = "rbxasset://sounds/action_swim.mp3",
		Looped = true,
		Pitch = 1.6,
	},
}
-- this script removes its parent from the workspace after 29 to 30 seconds

function rnd1()
	local i = math.random(-5000,5000)*.001
	return i
end

function rnd2()
	local i = math.random(-12500,12500)*.001
	return i
end

function rnd3()
	local i = math.random(12500,25000)*.001
	return i
end

wait(1+math.random(20000,20000)*.001)
script.Parent:BreakJoints()
script.Parent.CanCollide = false
script.Parent.Velocity = Vector3.new(rnd2(),rnd3(),rnd2())
script.Parent.RotVelocity = Vector3.new(rnd1(),rnd2(),rnd1())
for i = 0, 1, .1 do
	wait()
	script.Parent.Transparency = i
end
script.Parent.Parent = nil
--sounds
soundsdisabledfromrefit = {""}
local boltpsound = Instance.new("Sound", handle)
boltpsound.SoundId = "rbxassetid://456267525"
boltpsound.Volume = 0.8
boltpsound.Name = "boltpsound"
boltpsound.RollOffMinDistance = 1
boltpsound.RollOffMaxDistance = 300
local shellsound = Instance.new("Sound", handle)
shellsound.SoundId = "rbxassetid://2712533735"
shellsound.Volume = 0.5
shellsound.Name = "shellsound"
shellsound.RollOffMinDistance = 1
shellsound.RollOffMaxDistance = 300
local magoutsound = Instance.new("Sound", handle)
magoutsound.SoundId = "rbxassetid://268445237"
magoutsound.Volume = 0.8
magoutsound.Name = "magoutsound"
magoutsound.RollOffMinDistance = 1
magoutsound.RollOffMaxDistance = 300
local maginsound = Instance.new("Sound", handle)
maginsound.SoundId = "rbxassetid://2546411966"
maginsound.Volume = 0.8
maginsound.Name = "magoutsound"
maginsound.RollOffMinDistance = 1
maginsound.RollOffMaxDistance = 300
local magreachsound = Instance.new("Sound", handle)
magreachsound.SoundId = "rbxassetid://7329457810"
magreachsound.Volume = 3
magreachsound.Name = "magreachsound"
magreachsound.RollOffMinDistance = 1
magreachsound.RollOffMaxDistance = 300
local shootsound = Instance.new("Sound", handle)
shootsound.SoundId = "rbxassetid://6530496628"
shootsound.Volume = 1.5
shootsound.Name = "shootsound"
shootsound.RollOffMinDistance = 1
shootsound.RollOffMaxDistance = 300
concretesoundtick = tick()
local hitconcrete = Instance.new("Sound", handle)
hitconcrete.SoundId = "rbxassetid://6962153997"
hitconcrete.Volume = 1
hitconcrete.Name = "hitcsound"
hitconcrete.RollOffMinDistance = 1
hitconcrete.RollOffMaxDistance = 200
hitcsounds = {"6962154328", "6962154691", "6962155378", "6962153997"}

function playsound(sound, timep, playbacks, volume)
	pcall(function() -- so the script wont die if someone renames sounds/attempts to play something that isnt a sound
		sound.TimePosition = timep
		sound.PlaybackSpeed = playbacks
		sound.Volume = volume
		sound:Play()
	end)
end
-- Return the number of common items that follow in forward direction.
-- The length of what Myers paper calls a “snake” in a forward path.
local function countCommonItemsF(aIndex: number, aEnd: number, bIndex: number, bEnd: number, isCommon: IsCommon): number
	local nCommon = 0
	while aIndex < aEnd and bIndex < bEnd and isCommon(aIndex, bIndex) do
		aIndex += 1
		bIndex += 1
		nCommon += 1
	end
	return nCommon
end
--[[
	Returns a new promise that:
		* is resolved when all input promises resolve
		* is rejected if ANY input promises reject
]]
function Promise.all(promises)
	if type(promises) ~= "table" then
		error("Please pass a list of promises to Promise.all", 2)
	end

	-- If there are no values then return an already resolved promise.
	if #promises == 0 then
		return Promise.resolve({})
	end

	-- We need to check that each value is a promise here so that we can produce
	-- a proper error rather than a rejected promise with our error.
	for i = 1, #promises do
		if not Promise.is(promises[i]) then
			error(("Non-promise value passed into Promise.all at index #%d"):format(i), 2)
		end
	end

	return Promise.new(function(resolve, reject)
		-- An array to contain our resolved values from the given promises.
		local resolvedValues = {}

		-- Keep a count of resolved promises because just checking the resolved
		-- values length wouldn't account for promises that resolve with nil.
		local resolvedCount = 0

		-- Called when a single value is resolved and resolves if all are done.
		local function resolveOne(i, ...)
			resolvedValues[i] = ...
			resolvedCount = resolvedCount + 1

			if resolvedCount == #promises then
				resolve(resolvedValues)
			end
		end

		-- We can assume the values inside `promises` are all promises since we
		-- checked above.
		for i = 1, #promises do
			promises[i]:andThen(
				function(...)
					resolveOne(i, ...)
				end,
				function(...)
					reject(...)
				end
			)
		end
	end)
end