Pinkstack/roblox-luau-corpus-text huggingface dataset:
-- Customize the sprint speed multiplier as desired


local sprintSpeedMultiplier = 2 -- Change this value to adjust the sprint speed
local sprintDuration = 5 -- Change this value to set the sprint duration in seconds
local defaultWalkSpeed = 16 -- Change this value to set the default walk speed

local player = game.Players.LocalPlayer
local character = player.Character
local humanoid = character:WaitForChild("Humanoid")

local isSprinting = false
local meterX = 19
local meterV = meterX
-- Mode status:
-- 0/4 = Off
-- 1 = Auto
-- 2 = On



local motionSensor = script.Parent.Parent.Parent.SensorFunction.SensorScript
local Mode = script.Parent.Parent.Parent.Parent.Mode.Value
local LED = script.Parent.Parent.Parent.LED
local Off = script.Parent.Parent.Off
local On = script.Parent.Parent.On
local Auto = script.Parent.Parent.Sensor
local status = script.Parent.Parent.Parent.Parent.State

function onClicked()
	--Auto to Off
	if Mode == 1 then
		script.Parent.Sound_:Play()
		status.Value = 0
		motionSensor.Disabled = true
		Auto.Transparency = 1	
		On.Transparency = 1
		Off.Transparency = 0
		LED.BrickColor = BrickColor.new("Maroon")
		LED.Material = "Neon"
		Mode = 0
		wait(1)
		script.Parent.Sound:Play()
		--Off to On	
	elseif Mode == 0 then
		script.Parent.Sound_:Play()
		status.Value = 1
		motionSensor.Disabled = true
		Auto.Transparency = 1
		On.Transparency = 0
		Off.Transparency = 1		
		LED.BrickColor = BrickColor.new("Really red")
		LED.Material = "Neon"
		Mode = 2
		wait(1)
		script.Parent.Sound:Play()
		--On to Off		
	elseif Mode == 2 then
		script.Parent.Sound_:Play()
		status.Value = 0
		motionSensor.Disabled = true
		Auto.Transparency = 1	
		On.Transparency = 1
		Off.Transparency = 0
		LED.BrickColor = BrickColor.new("Maroon")
		LED.Material = "Neon"
		Mode = 4
		wait(1)
		script.Parent.Sound:Play()
		--Off to Auto		
	elseif Mode == 4 then
		script.Parent.Sound_:Play()
		status.Value = 0
		motionSensor.Disabled = false
		Auto.Transparency = 0
		On.Transparency = 1
		Off.Transparency = 1
		LED.BrickColor = BrickColor.new("Forest green")	
		LED.Material = "Neon"	
		Mode = 1
		wait(1)
		script.Parent.Sound:Play()
	end
end

script.Parent.ClickDetector.MouseClick:Connect(onClicked)
--if hood.Velocity.magnitude < 15 then return end  -- must be going decently fast to break stuff...  can add invisible "prebumpers" in the future to make collisions smoother


if hood.CFrame:vectorToObjectSpace(hood.Velocity):Dot(direction) < 40 then return end -- must be going fast in correct direction to break stuff

	if hit and hit.Parent then
		if hit.Parent:FindFirstChild("Humanoid") then
			--hit.Parent:BreakJoints()  let's not kill 'em...  for now
			hit.Parent.Humanoid.Sit = true  -- but we do make 'em flyyyy!  XD
		elseif hit:FindFirstChild("RobloxModel") and not hit:FindFirstChild("RunOver") and isSmallerThanVehicle(hit) then
			local newModel = hit:Clone()
			local modelParent = hit.Parent
			local newRunOverTag = Instance.new("BoolValue")
			newRunOverTag.Name = "RunOver"
			newRunOverTag.Parent = hit

			hit:BreakJoints()
			debris:AddItem(hit, timeToRespawn)
			coroutine.resume(coroutine.create(respawnIt), newModel, modelParent)
		elseif hit.Parent:FindFirstChild("RobloxModel") and not hit.Parent:FindFirstChild("RunOver") and isSmallerThanVehicle(hit.Parent) then
			local newModel = hit.Parent:Clone()
			local modelParent = hit.Parent.Parent
			local newRunOverTag = Instance.new("BoolValue")
			newRunOverTag.Name = "RunOver"
			newRunOverTag.Parent = hit.Parent

			hit.Parent:BreakJoints()
			debris:AddItem(hit.Parent, timeToRespawn)
			coroutine.resume(coroutine.create(respawnIt), newModel, modelParent)
		end
	end
end
--[=[
	@param name string
	@param inboundMiddleware ClientMiddleware?
	@param outboundMiddleware ClientMiddleware?
	@return ClientRemoteProperty
	Returns a new ClientRemoteProperty that mirrors the matching RemoteProperty created by
	ServerComm with the same matching `name`.

	Take a look at the ClientRemoteProperty documentation for more info, such as
	understanding how to wait for data to be ready.

	```lua
	local mapInfo = clientComm:GetProperty("MapInfo")

	-- Observe the initial value of mapInfo, and all subsequent changes:
	mapInfo:Observe(function(info)
		print("Current map info", info)
	end)

	-- Check to see if data is initially ready:
	if mapInfo:IsReady() then
		-- Get the data:
		local info = mapInfo:Get()
	end

	-- Get a promise that resolves once the data is ready (resolves immediately if already ready):
	mapInfo:OnReady():andThen(function(info)
		print("Map info is ready with info", info)
	end)

	-- Same as above, but yields thread:
	local success, info = mapInfo:OnReady():await()
	```
]=]


function ClientComm:GetProperty(
	name: string,
	inboundMiddleware: Types.ClientMiddleware?,
	outboundMiddleware: Types.ClientMiddleware?
)
	return Comm.GetProperty(self._instancesFolder, name, inboundMiddleware, outboundMiddleware)
end
-- You may turn both of these on at once. In that case, zone-specific music will play in the appropriate zones, and global background music will play whenever you're not within any zone.



	
settings.DisplayMuteButton = true  -- If set to true, there will be a button in the bottom-right corner of the screen allowing players to mute the background music.
	
settings.MusicFadeoutTime = 1.5  -- How long music takes to fade out, in seconds.

settings.MusicOnlyPlaysWithinZones = false  -- (This setting only applies when UseGlobalBackgroundMusic is set to false) If a player walks into an area that's not covered by any music zone, what should happen? If true, music will stop playing. If false, the music from the previous zone will continue to play.

return settings
--[[
	Assert that our functoid expectation value throws an error when called.
	An optional error message can be passed to assert that the error message
	contains the given value.
]]


function Expectation:throw(messageSubstring)
	local ok, err = pcall(self.value)
	local result = ok ~= self.successCondition

	if messageSubstring and not ok then
		if self.successCondition then
			result = err:find(messageSubstring, 1, true) ~= nil
		else
			result = err:find(messageSubstring, 1, true) == nil
		end
	end

	local message

	if messageSubstring then
		message = formatMessage(
			self.successCondition,
			("Expected function to throw an error containing %q, but it %s"):format(
				messageSubstring,
				err and ("threw: %s"):format(err) or "did not throw."
			),
			("Expected function to never throw an error containing %q, but it threw: %s"):format(
				messageSubstring,
				tostring(err)
			)
		)
	else
		message = formatMessage(
			self.successCondition,
			"Expected function to throw an error, but it did not throw.",
			("Expected function to succeed, but it threw an error: %s"):format(tostring(err))
		)
	end

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

	return self
end

return Expectation
-------------------------------------Gun info


ToolName="Mark IV"

ClipSize=30
ReloadTime=2
Firerate=.2
MinSpread=1
MaxSpread=6
SpreadRate=1
BaseDamage=30
automatic=true
burst=false
shot=false			--shotgun
BarrlePos=Vector3.new(0,0.70,-2.90)
Cursors={"rbxasset://textures\\GunCursor.png"}
ReloadCursor="rbxasset://textures\\GunWaitCursor.png"
--Set up returned table


local Input = {}
	Input.Triggers = 0 --Triggers
	Input.LStickX = 0 --L/R on left stick
	Input.LStickY = 0	--F/B on left stick	
	Input.Forward = 0 --W/S or Up/Down
	Input.Strafe = 0 --A/D or Left/Right
	Input.Shift = 0 --LShift/LControl
	--Input.Flip = 0 --C key / Y button
	--TODO: Include inputs for Entering Car (E) and redress (C)
	Input.InputMode = "Keyboard"
	Input.TypeChanged = script.TypeChanged.Event --Allow the vehicle to know when the input changed
	Input.ActionFired = script.ActionFired.Event --Allow vehicle to know when special key is fired
--[[
Welds two parts.
--]]


local function WeldBetween(Part1,Part2)
	local Weld = Instance.new("Weld")
	Weld.Part0 = Part1
	Weld.Part1 = Part2
	Weld.C0 = Part1.CFrame:inverse()
	Weld.C1 = Part2.CFrame:inverse()
	Weld.Parent = Part1
end
-------------------------


while true do
Puerta1.BodyVelocity.velocity = Vector3.new(0, 0, 0.5)
Puerta2.BodyVelocity.velocity = Vector3.new(0, 0, -0.5)
wait(8)
Puerta1.BodyVelocity.velocity = Vector3.new(0, 0, 0)
Puerta2.BodyVelocity.velocity = Vector3.new(0, 0, 0)
break
end
--
--


Monster:Initialize()
Monster:InitializeUnique()

game:GetService("RunService").Heartbeat:Connect(function()
	if not Monster:IsAlive() then
		if Data.IsDead == false then
			Data.IsDead = true
			Data.TimeOfDeath = tick()
			Self.Died:Fire()
		end
		if Data.IsDead == true then
			if tick()-Data.TimeOfDeath > Info.RespawnWaitTime then
				Monster:Respawn()
			end
		end
	end
	
	if Monster:IsAlive() then
		Monster:Update()
	end
end)
--Setup animation here--


setup(animation.SL1,0.001)
setup(animation.SL2,0.001)
setup(animation.SL3,0.001)
setup(animation.SL4,0.001)
setup(animation.F1,0.001)
setup(animation.F2,0.001)
setup(animation.F3,0.001)
setup(animation.F4,0.001)
setup(animation.FF1,0.001)
setup(animation.FF2,0.001)
setup(animation.FF3,0.001)
setup(animation.FF4,0.001)
setup(animation.S1,0.01)
setup(animation.S2,0.01)
setup(animation.S3,0.01)
setup(animation.S4,0.01)
setup(animation.FLDoor,0.01)
setup(animation.FRDoor,0.01)
setup(animation.RLDoor,0.01)
setup(animation.RRDoor,0.01)
setup(animation.CDoor1,0.01)
setup(animation.CDoor2,0.01)
setup(animation.Engine1)
setup(animation.Engine2)
setup(animation.NGear,0.008)
setup(animation.LGear,0.005)
setup(animation.RGear,0.005)
setup(animation.NGDoorL,0.013)
setup(animation.NGDoorR,0.013)
setup(animation.LGDoor,0.005)
setup(animation.RGDoor,0.005)
setupInside(animation.F1.T,0.001)
setupInside(animation.F2.T,0.001)
setupInside(animation.F3.T,0.001)
setupInside(animation.F4.T,0.001)
setupInside(animation.LGDoor.Door)
setupInside(animation.LGDoor.Door.Door,0.005)
setupInside(animation.RGDoor.Door)
setupInside(animation.RGDoor.Door.Door,0.005)
setupInside(animation.LGear.Gear,0.005)
setupInside(animation.RGear.Gear,0.005)
setupInside(animation.LGear.Gear.Strut,0.025)
setupInside(animation.RGear.Gear.Strut,0.025)
setupInside(animation.NGear.Wheel)
setupInside(animation.LGear.Gear.Wheel)
setupInside(animation.RGear.Gear.Wheel)
setup(animation.RThrust)
wait(2)
animation.NGDoorL.A.Motor.DesiredAngle = 1.35
animation.NGDoorR.A.Motor.DesiredAngle = 1.35
animation.LGDoor.A.Motor.DesiredAngle = 1.5
animation.RGDoor.A.Motor.DesiredAngle = 1.5
animation.LGDoor.Door.Door.A.Motor.DesiredAngle = 1
animation.RGDoor.Door.Door.A.Motor.DesiredAngle = 1
animation.Engine1.A.Motor.DesiredAngle = 100e100
animation.Engine2.A.Motor.DesiredAngle = 100e100
animation.NGear.Wheel.A.Motor.C1 = animation.NGear.Wheel.A.Motor.C1 * CFrame.new(0,-0.6,0)
animation.LGear.Gear.Wheel.A.Motor.C1 = animation.LGear.Gear.Wheel.A.Motor.C1 * CFrame.new(0,-0.6,0)
animation.RGear.Gear.Wheel.A.Motor.C1 = animation.RGear.Gear.Wheel.A.Motor.C1 * CFrame.new(0,-0.6,0)
animation.LGDoor.Door.A.Motor.C1 = animation.LGDoor.Door.A.Motor.C1 * CFrame.new(-1.45,0,0)
animation.RGDoor.Door.A.Motor.C1 = animation.RGDoor.Door.A.Motor.C1 * CFrame.new(-1.45,0,0)
script.Parent.Weld.Disabled = false
unAnchor(script.Parent.AnimationParts)
--Made by Luckymaxer



Part = script.Parent

Duration = Part:WaitForChild("Duration")

wait(Duration.Value)

if Part:IsA("Part") then
	for i, v in pairs(Part:GetChildren()) do
		if v:IsA("ParticleEmitter") then
			v.Enabled = false
		end
	end
elseif Part:IsA("ParticleEmitter") then
	Part.Enabled = false
end
--// # key, Yelp


mouse.KeyDown:connect(function(key)
	if key=="t" then 
		if veh.Lightbar.middle.Yelp.IsPlaying == true then
		veh.Lightbar.middle.Beep:Play()
		veh.Lightbar.middle.Yelp:Stop()
		script.Parent.Parent.Sirens.Yelp.BackgroundColor3 = Color3.fromRGB(62, 62, 62)
		else
		veh.Lightbar.middle.Beep:Play()
		veh.Lightbar.middle.Yelp:Play()
		veh.Lightbar.middle.Priority:Stop()
		script.Parent.Parent.Sirens.Yelp.BackgroundColor3 = Color3.fromRGB(215, 135, 110)
		script.Parent.Parent.Sirens.Wail.BackgroundColor3 = Color3.fromRGB(62, 62, 62)
		script.Parent.Parent.Sirens.Priority.BackgroundColor3 = Color3.fromRGB(62, 62, 62)
		end
	end
end)
-- Waits for the child of the specified parent


local function WaitForChild(parent, childName)
	while not parent:FindFirstChild(childName) do parent.ChildAdded:wait() end
	return parent[childName]
end


local Tool = script.Parent
local Handle = WaitForChild(Tool, 'Handle')
local Debounce = false

local TouchConnection


function OnTouched(hit)
	local humanoid = hit.Parent:findFirstChild('Humanoid')
	if Debounce == false then
		Debounce = true
		if humanoid then
			Handle.DeadPlayer:Play()
		else
		end
	end
	wait(0.5)
	Debounce = false
end


Tool.Equipped:connect(function()
	TouchConnection = Handle.Touched:connect(OnTouched)
end)

Tool.Unequipped:connect(function()
	if TouchConnection then
		TouchConnection:disconnect()
		TouchConnection = nil
	end
end)
-- events



EVENTS.Gun.Event:connect(function(action, ...)
	if action == "Enable" then
		currentSize, currentAmmo	= ...
		
		Update()
		GUN_GUI.Visible	= true
		
		if ammoConnection then
			ammoConnection:Disconnect()
			ammoConnection	= nil
		end
		
		if character then
			ammoConnection	= ammo[currentSize].Changed:connect(function()
				Update()
			end)
		end
	elseif action == "Disable" then
		GUN_GUI.Visible	= false
	elseif action == "Update" then
		currentAmmo	= ...
		Update()
	end
end)

PLAYER.CharacterAdded:connect(HandleCharacter)
--[[*
 * Match the basename of a filepath.
 *
 * ```js
 * const picomatch = require('picomatch');
 * // picomatch.matchBase(input, glob[, options]);
 * console.log(picomatch.matchBase('foo/bar.js', '*.js'); // true
 * ```
 * @param {String} `input` String to test.
 * @param {RegExp|String} `glob` Glob pattern or regex created by [.makeRe](#makeRe).
 * @return {Boolean}
 * @api public
 ]]
--------
--Main--
--------



for i,v in next, Gui.Frame:GetChildren() do
	v.Visible = false
end

local OSize = Gui.Frame.Size
local OPos = Gui.Frame.Position
Gui.Frame.Position = Gui.Frame.Position + UDim2.new(0, Gui.Frame.AbsoluteSize.X/2, 0, Gui.Frame.AbsoluteSize.Y/2)
Gui.Frame.Size = UDim2.new(0,0,0,0)

Gui.Frame.Visible = true
Gui.Frame:TweenSizeAndPosition(OSize,OPos)
wait(1)

for i,v in next, Gui.Frame:GetChildren() do
	v.Visible = true
end

Gui.Frame.Close.MouseButton1Click:connect(function ()
	for i,v in next, Gui.Frame:GetChildren() do
		v.Visible = false
	end
	Gui.Frame:TweenSizeAndPosition(UDim2.new(0,0,0,0),Gui.Frame.Position + UDim2.new(0, Gui.Frame.AbsoluteSize.X/2, 0, Gui.Frame.AbsoluteSize.Y/2))
	wait(1)
	Gui:Destroy()
end)
-- functions for calculating data for text from spritesheets



local function getStringWidth(text, sizeSet)
	local length, ntext = 0, #text;
	for i = 1, ntext do
		local i2 = i + 1 <= #text and i + 1;
		local b = byte(sub(text, i, i));
		local b2 = i2 and byte(sub(text, i2, i2));
		local character = sizeSet.characters[b];
		local kernx = 0
		if (b2 and sizeSet.kerning[b] and sizeSet.kerning[b][b2]) then
			kernx = sizeSet.kerning[b][b2].x;
		end;
		length = length + sizeSet.characters[b].xadvance + kernx;
	end;
	return length;
end;

local function getMaxHeight(text, sizeSet)
	local mheight, ntext = 0, #text;
	for i = 1, ntext do
		local b = byte(sub(text, i, i));
		local character = sizeSet.characters[b];
		local height = sizeSet.characters[b].height + sizeSet.characters[b].yoffset;
		if (height > mheight) then
			mheight = height;
		end;
	end;
	return mheight;
end;
--[[local EffectFunctions = 
{
	function(hum,dir) hum:TakeDamage(1) end,
	function(hum,dir) hum:TakeDamage(-1) end,
	function(hum,dir) 
		if hum.Torso then
			local nforce = Instance.new('BodyForce')
			nforce.force = dir*3000
			nforce.Parent = hum.Torso
			hum.Sit = true
			game.Debris:AddItem(nforce,.2)
			Delay(.2,function() hum.Sit = false end)
		end
	end
}]]


Tool.Equipped:connect(function(mouse)
	--game.Players.LocalPlayer:GetMouse()
	Spawn(function()
		--local colorChoice = 1
		if not Tool.Parent:FindFirstChild('Torso') or not Tool.Parent.Torso:FindFirstChild('Right Shoulder') or not Tool.Parent:FindFirstChild('Humanoid') then return end
		--LazerSound:Play()
		nweld = Tool.Parent.Torso['Right Shoulder']
		oldC0 = nweld.C0
		nweld.CurrentAngle = 0
		nweld.DesiredAngle = 0
		nweld.MaxVelocity = 0
		--[[mouse.Button1Down:connect(function()
			colorChoice=colorChoice+1
			if colorChoice>#ColorChoices then colorChoice =1 end
			LazerSound.Pitch = .75+((colorChoice*.25)*3)
		end)]]
		equipped = true
		while equipped and Tool.Parent:FindFirstChild('Torso') do
			local tframe = Tool.Parent.Torso.CFrame
			tframe = tframe + tframe:vectorToWorldSpace(Vector3.new(1, 0.5, 0))
			local taim = mouse.Hit.p -( tframe.p )
			nweld.C0 = (CFrame.new(Vector3.new(),tframe:vectorToObjectSpace(taim))*CFrame.Angles(0,math.pi/2,0))+Vector3.new( 1, 0.5, 0 )
			--rayparts = CastLightRay(Handle.CFrame.p+Handle.CFrame:vectorToWorldSpace(StartOffset[colorChoice]),mouse.Hit.p,ColorChoices[colorChoice], 5, .2,rayparts, EffectFunctions[colorChoice])
			--LazerSound.Volume = ((math.sin(tick()*3)+1)*.25)+.25
			wait()
		end
		nweld.C0 =oldC0
		--LazerSound:Stop()
	end)
end)

Tool.Unequipped:connect(function(mouse)
	equipped= false
	--LazerSound:Stop()
	for i=1,50,1 do
		--[[if rayparts[i] then
			rayparts[i]:Destroy()
			rayparts[i]=nil		
		end]]
	end
	if nweld then
		nweld.MaxVelocity =.15
		nweld.C0 =oldC0
	end
	
end)
-- LOCAL FUNCTIONS


local function checkTopbarEnabled()
	local success, bool = xpcall(function()
		return starterGui:GetCore("TopbarEnabled")
	end, function(err)
		--has not been registered yet, but default is that is enabled
		return true
	end)
	return (success and bool)
end

local function checkTopbarEnabledAccountingForMimic()
	local topbarEnabledAccountingForMimic = (checkTopbarEnabled() or not IconController.mimicCoreGui)
	return topbarEnabledAccountingForMimic
end
------------------------------------------------------------------------------------------------------------------------------
--// Classes



local event = {};

function event.new(t)
	local evnts = {};
	local self = setmetatable({},{
		__index = t;
		__newindex = function(tt, k, v)
			if (t[k] ~= v) then
				t[k] = v;
				if (type(evnts[k]) == "function") then
					evnts[k](v);
				end;
			end;
		end;
		__metatable = "The metatable is locked.";
	});
	
	function self:connect(k, f)
		evnts[k] = f;
	end;
	
	return self;
end;

local settings = {};

function settings.new(fontModule, attached, child)
	local self = setmetatable({}, {__index = settings});
	
	settings.child = child;
	settings.attached = attached;
	
	-- place data in new format for easy access
	self.information = fontModule.font.information;
	self.atlases = fontModule.atlases;
	self.styles = fontModule.font.styles;
	
	-- sort from least to greatest
	sort(self.information.sizes, function(a, b) return a > b; end);
	
	-- establish some settings variables
	self.style = self.information.styles[1];
	self.size = child.TextSize;
	
	-- failsafes
	for styleName, style in next, self.styles do
		-- characters that DNE
		for sizeName, size in next, style do
			setmetatable(size.characters, {
				__index = function(t, k)
					local k = tostring(k);
					local v = rawget(t, k)
					if (not v) then
						warn(k, "is not a valid character. Replaced with, \"" .. char(REPLACE) .. "\"");
						return rawget(t, tostring(REPLACE));
					end;
					return v;
				end;
			})
		end;
		-- sizes that DNE
		setmetatable(style, {
			__index = function(t, k)
				local k = tostring(k);
				local v = rawget(t, k);
				if (not v) then
					local closest = getClosestNumber(k, self.information.sizes);
					self.size = closest;
					child.TextSize = closest;
					warn(k, "is not a valid size. Using the closest size,", closest);
					return rawget(t, tostring(closest));
				end;
				return v;
			end;
		});
	end;
	-- styles that DNE
	setmetatable(self.styles, {
		__index = function(t, k)
			local v = rawget(t, k);
			if (not v) then 
				local nstyle = self.information.styles[1];
				self.style = nstyle;
				attached.Style = nstyle;
				warn(k, "is not a valid style. Using first style found", nstyle);
				return rawget(t, nstyle);
			end;
			return v;
		end;
	});
	
	return self;
end;

function settings:preload()
	for _, atlas in next, self.atlases do
		content:Preload(atlas);
	end;
end;
-- Customization


	AntiTK = false; -- Set to false to allow TK and damaging of NPC, true for no TK. (To damage NPC, this needs to be false)
	
	MouseSense = 0.5;

	CanAim = true; -- Allows player to aim
	CanBolt = true; -- When shooting, if this is enabled, the bolt will move (SCAR-L, ACR, AK Series)
	
	LaserAttached = true;
	LightAttached = true;
	TracerEnabled = true;
-- Division of index intervals in sequences a and b at the middle change.
-- Invariant: intervals do not have common items at the start or end.


type Division = {
	-- The end of interval preceding division is open like array slice method.
	nChangePreceding: number, -- number of change items
	aEndPreceding: number,
	bEndPreceding: number,

	nCommonPreceding: number, -- 0 if no common items preceding middle change
	aCommonPreceding: number, -- ignore prop value if nCommonPreceding === 0
	bCommonPreceding: number, -- ignore prop value if nCommonPreceding === 0

	nCommonFollowing: number, -- 0 if no common items following middle change
	aCommonFollowing: number, -- ignore prop value if nCommonFollowing === 0
	bCommonFollowing: number, -- ignore prop value if nCommonFollowing === 0

	-- The start of interval following division is closed like array slice method.
	nChangeFollowing: number, -- number of change items
	aStartFollowing: number,
	bStartFollowing: number,
}

local pkg = "diff-sequences" -- for error messages
local NOT_YET_SET = 0 -- small int instead of undefined to avoid deopt in V8
-- constants



local PLAYER	= Players.LocalPlayer
local EVENTS	= ReplicatedStorage:WaitForChild("Events")
local REMOTES	= ReplicatedStorage:WaitForChild("Remotes")
local MODULES	= ReplicatedStorage:WaitForChild("Modules")
	local CONFIG		= require(MODULES:WaitForChild("Config"))
	local MOUSE			= require(MODULES:WaitForChild("Mouse"))
	local EFFECTS		= require(MODULES:WaitForChild("Effects"))
	local DAMAGE		= require(MODULES:WaitForChild("Damage"))
	
local EQUIP_COOLDOWN	= 0.2
---------------------------------------------------



This = script.Parent
Elevator = This.Parent.Parent.Parent
CustomLabel = require(This.Parent.Parent.Parent.CustomLabel)
Characters = require(script.Characters)

CustomText = CustomLabel["CUSTOMFLOORLABEL"]

Elevator:WaitForChild("Floor").Changed:connect(function(floor)
  --custom indicator code--
  ChangeFloor(tostring(floor))
end)

function ChangeFloor(SF)
	if CustomText[tonumber(SF)] then
		SF = CustomText[tonumber(SF)]
	end
	SetDisplay(1,(string.len(SF) == 2 and SF:sub(1,1) or "NIL"))		
	SetDisplay(2,(string.len(SF) == 2 and SF:sub(2,2) or SF))
end



function SetDisplay(ID,CHAR)
	if This.Display:FindFirstChild("DIG"..ID) and Characters[CHAR] ~= nil then
 		for i,l in pairs(Characters[CHAR]) do 
			for r=1,16 do	
				This.Display["DIG"..ID]["D"..r].BrickColor = (l:sub(r,r) == "1" and BrickColor.new(ActiveColour) or BrickColor.new(InactiveColour))
			end
		end
	end
end