Pinkstack/roblox-luau-corpus-text huggingface dataset:
--Made by Luckymaxer



Tool = script.Parent
Handle = Tool:WaitForChild("Handle")
CoilSound = Handle:WaitForChild("CoilSound")

EqualizingForce = (236 / 1.2) -- amount of force required to levitate a mass
Gravity = 0.85 -- things float at > 1

GhostEffect = nil
MassCon1 = nil
MassCon2 = nil

function GetTotalMass(root)
	local force = 0
	
	for _, obj in pairs(root:GetChildren()) do
		if obj:IsA("BasePart") then
			force = force + obj:GetMass() * EqualizingForce * Gravity
		end
		force = force + GetTotalMass(obj)
	end
	
	return force
end

function OnMassChanged(child, character)
	if GhostEffect and GhostEffect.Parent then
		GhostEffect.force = Vector3.new(0, GetTotalMass(Character), 0)
	end
end

function UpdateGhostState(Unequipped)
	if Unequipped then
		GhostEffect:Destroy()
		GhostEffect = nil
		MassCon1:disconnect()
		MassCon2:disconnect()
	else
		if not GhostEffect then
			GhostEffect = Instance.new("BodyForce")
			GhostEffect.Name = "GravityCoilEffect"
			GhostEffect.force = Vector3.new(0, GetTotalMass(Character), 0)
			GhostEffect.Parent = Head
			MassCon1 = Character.ChildAdded:connect(function(Child)
				OnMassChanged(Child, Character)
			end)
			MassCon2 = Character.ChildRemoved:connect(function(Child)
				OnMassChanged(Child, Character)
			end)
		end
	end
end

function OnEquipped()
	Character = Tool.Parent
	Head = Character:FindFirstChild("Head")
	if not Head or not Head.Parent then
		return
	end
	CoilSound:Play()
	UpdateGhostState(false)
end

function OnUnequipped()
	UpdateGhostState(true)
end

Tool.Equipped:connect(OnEquipped)
Tool.Unequipped:connect(OnUnequipped)
-- ScreenSpace -> WorldSpace. Taking a screen width that you want that object to be
-- and a world width that is the size of that object, and returning the position to
-- put that object at to satisfy those.


function ScreenSpace.ScreenToWorldByWidth(x, y, screenWidth, worldWidth)
	local aspectRatio = ScreenSpace.AspectRatio()
	local hfactor = math.tan(math.rad(workspace.CurrentCamera.FieldOfView)/2)
	local wfactor = aspectRatio*hfactor
	local sx, sy = ScreenSpace.ViewSizeX(), ScreenSpace.ViewSizeY()
	--
	local depth = - (sx * worldWidth) / (screenWidth * 2 * wfactor)
	--
	local xf, yf = x/sx*2 - 1, y/sy*2 - 1
	local xpos = xf * -wfactor * depth
	local ypos = yf *  hfactor * depth
	--
	return Vector3.new(xpos, ypos, depth)
end

return ScreenSpace
-- ROBLOX deviation start: no Omit utility in Luau


type AsymmetricMatchersOmitAnyAndAnything = {
	arrayContaining: (Array<unknown>) -> AsymmetricMatcher,
	objectContaining: (Record<string, unknown>) -> AsymmetricMatcher,
	stringContaining: (string) -> AsymmetricMatcher,
	stringMatching: (string | RegExp) -> AsymmetricMatcher,
}

type AsymmetricMatchers = {
	any: (unknown) -> AsymmetricMatcher,
	anything: () -> AsymmetricMatcher,
} & AsymmetricMatchersOmitAnyAndAnything
-- Loading


local CutsceneFolder = workspace.Cutscenes:WaitForChild("welcome") -- The folder that contains the cutscene data (Cameras...)
local Destroy = true -- Destroy folder after loading? you don't want your player to see your cameras floating around!
local NoYield = false -- Generally you want this to be set to false, because loading takes a little bit of time, and you don't want to interact with the cutscene when it's not loaded
local SafeMode = true -- This is adviced to be turned on, especially if the cutscene folder data is too big to load at one frame. when turned on, it loads a camera every frame, not all at once.

local Cutscene = require(CutsceneModule)

local Demo = Cutscene.new(Camera, Looping, Speed, FreezeControls) -- Create cutscene
Demo:Load(CutsceneFolder, Destroy, NoYield, SafeMode) -- Load cutscene data from folder

local PlayOnPartTouch = script:FindFirstChild("PlayOnPartTouch")
local PlayOnPlayerJoin = script:FindFirstChild("PlayOnPlayerJoin")
local PlayOnCharacterAdded = script:FindFirstChild("PlayOnCharacterAdded")
local PlayOnCharacterDied = script:FindFirstChild("PlayOnCharacterDied")
local PlayOnEventFire = script:FindFirstChild("PlayOnEventFire")
local PlayOnRemoteEventFire = script:FindFirstChild("PlayOnEventFire")
local ProtectTheCharacterWhilePlaying = script:FindFirstChild("ProtectTheCharacterWhilePlaying")
local CharacterProtector = script:FindFirstChild("CharacterProtector")
local Music = script:FindFirstChild("Music")
local StopMusicWhenFinished = script:FindFirstChild("StopMusicWhenFinished")
local StopOnEventFire = script:FindFirstChild("StopOnEventFire")
local StopOnRemoteEventFire = script:FindFirstChild("StopOnRemoteEventFire")
local PlayOnce = script:FindFirstChild("PlayOnce")
local Debounce = script:FindFirstChild("Cooldown")
local OnFinishedRemove = script:FindFirstChild("OnFinishedRemove")
local bin = true
local Player = game:GetService("Players").LocalPlayer
local CutsceneGui = script:FindFirstChild("Cutscene")
--[[
	    ___      _______                _       _______
	   / _ |____/ ___/ /  ___ ____ ___ (_)__   /__  __/
	  / __ /___/ /__/ _ \/ _ `(_-<(_-</ (_-<     / /
	 /_/ |_|   \___/_//_/\_,_/___/___/_/___/	/_/   
						SecondLogic @ Inspare
						Avxnturador @ Novena
]]




local autoscaling	= false					--Estimates top speed

local UNITS	= {								--Click on speed to change units
											--First unit is default	
	{
		units			= "MPH"				,
		scaling			= (10/12) * (60/88)	, -- 1 stud : 10 inches | ft/s to MPH
		maxSpeed		= 230				,
		spInc			= 20				, -- Increment between labelled notches
	},
	
	{
		units			= "KM/H"			,
		scaling			= (10/12) * 1.09728	, -- 1 stud : 10 inches | ft/s to KP/H
		maxSpeed		= 370				,
		spInc			= 40				, -- Increment between labelled notches
	},
	
	{
		units			= "SPS"				,
		scaling			= 1					, -- Roblox standard
		maxSpeed		= 400				,
		spInc			= 40				, -- Increment between labelled notches
	}
}
-- This module creates BodyVelocities for certain actions such as pushing and knockback.



return 
	function(Strength, Duration, Parent)
	
	local Velocity = Instance.new('BodyVelocity')
	Velocity.Name = 'Velocity'
	Velocity.MaxForce = Vector3.new(1, 1, 1) * math.huge
	Velocity.Velocity = Strength
	Velocity.Parent = Parent
	game:GetService('Debris'):AddItem(Velocity, Duration)
end
--[[Transmission]]


Tune.TransModes		= {"Auto","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													]]
-- Establishes level of debug output that should occur


Logger.setCutoff(Logger.LOG_LEVEL.Warn)

UserInput.init()
UIController.init()
ClientVehicleManager.init()
CameraController.init()
ClientPlayerStatusHandler.init()

ReplicatedStorage:FindFirstChild("Menu").Parent = workspace

if game.PlaceId ~= 0 and RunService:IsClient() then
	translateDataModel()
end
Logger.log("Client tasks completed")
-- Each note takes up exactly 8 seconds in audio. i.e C2 lasts 8 secs, C2# lasts 8 secs, C3 lasts 8 secs, C3# lasts 8 secs etc. for each audio
-- These are the IDs of the piano sounds.



settings.SoundSource = Piano.Keys.KeyBox

settings.CameraCFrame = CFrame.new(
    (Box.CFrame * CFrame.new(0, 0, 1)).p, -- +z is towards player
    (Box.CFrame * CFrame.new(0, 0, 0)).p
)
--// All global vars will be wiped/replaced except script



return function(data, env)
	if env then
		setfenv(1, env)
	end
	
	local playergui = service.PlayerGui
	local localplayer = service.Players.LocalPlayer
	local scr = client.UI.Prepare(script.Parent.Parent)
	local main = scr.Main
	local t1 = main.Title
	local t2 = main.Message
	local msg = data.Message
	local color = data.Color

	local found = client.UI.Get("Output")
	if found then
		for i,v in pairs(found) do
			local p = v.Object
			if p and p.Parent then
				p.Main.Position = UDim2.new(0, 0, 0.35, p.Main.Position.Y.Offset+50)
			end
		end
	end

	t2.Text = msg
	
	spawn(function()
		local sound = Instance.new("Sound",service.LocalContainer())
		sound.SoundId = "rbxassetid://7152562261"
		sound.Volume = 0.1
		sound:Play()
		wait(0.8)
		sound:Destroy()
	end)

	main.Size = UDim2.new(1, 0, 0, 0)
	gTable.Ready()
	main:TweenSize(UDim2.new(1, 0, 0, 50), Enum.EasingDirection.Out, Enum.EasingStyle.Quad, 0.1)
	wait(5)
	gTable.Destroy()
end
-- setup emote chat hook
--Game.Players.LocalPlayer.Chatted:connect(function(msg)
--	local emote = ""
--	if (string.sub(msg, 1, 3) == "/e ") then
--		emote = string.sub(msg, 4)
--	elseif (string.sub(msg, 1, 7) == "/emote ") then
--		emote = string.sub(msg, 8)
--	end
--	
--	if (pose == "Standing" and emoteNames[emote] ~= nil) then
--		playAnimation(emote, 0.1, Humanoid)
--	end
--	print("===> " .. string.sub(msg, 1, 3) .. "(" .. emote .. ")")
--end)
--[=[
	Gets the value in the children

	@param parent Instance
	@param instanceType string
	@param name string
	@param default any?
	@return any
]=]


function ValueBaseUtils.getValue(parent, instanceType, name, default)
	assert(typeof(parent) == "Instance", "Bad argument 'parent'")
	assert(type(instanceType) == "string", "Bad argument 'instanceType'")
	assert(type(name) == "string", "Bad argument 'name'")

	local foundChild = parent:FindFirstChild(name)
	if foundChild then
		if foundChild:IsA(instanceType) then
			return foundChild.Value
		else
			warn(("[ValueBaseUtils.getValue] - Value of type %q of name %q is of type %q in %s instead")
				:format(instanceType, name, foundChild.ClassName, foundChild:GetFullName()))
			return nil
		end
	else
		return default
	end
end
--// SS3 controls for AC6 by Itzt, originally for 2014 Infiniti QX80. i don't know how to tune ac lol


 
wait(0.1)
local player = game.Players.LocalPlayer
local HUB = script.Parent.HUB
local TR = script.Parent.Tracker
local limitButton = HUB.Name
local lightOn = false
local Camera = game.Workspace.CurrentCamera
local cam = script.Parent.nxtcam.Value
local carSeat = script.Parent.CarSeat.Value
local mouse = game.Players.LocalPlayer:GetMouse()
local windows = false
local winfob = HUB.Parent.Windows
--[[
	Indents a list of strings and then concatenates them together with newlines
	into a single string.
]]


local function indentLines(lines, indentLevel)
	local outputBuffer = {}

	for _, line in ipairs(lines) do
		table.insert(outputBuffer, indent(line, indentLevel))
	end

	return table.concat(outputBuffer, "\n")
end

local logInfoMetatable = {}
-- functions



local function ProcessReceipt(receiptInfo)
	local player	= Players:GetPlayerByUserId(receiptInfo.PlayerId)
	if player then
		if receiptInfo.ProductId == TIER_SKIP_ID then
			print(player.Name .. " skipped a tier")
			local success	= script.Parent.Ranking.RankingScript.SkipTier:Invoke(player)
			if success then
				return Enum.ProductPurchaseDecision.PurchaseGranted
			else
				return Enum.ProductPurchaseDecision.NotProcessedYet
			end
		elseif CURRENCY_IDS[receiptInfo.ProductId] then
			local tickets		= CURRENCY_IDS[receiptInfo.ProductId]
			local playerData	= PLAYER_DATA:FindFirstChild(player.Name)
			
			if playerData then
				print(player, "purchased", tickets, "tickets")
				playerData.Currency.Tickets.Value	= playerData.Currency.Tickets.Value + tickets
				local success	= script.Parent.DataScript.SaveData:Invoke(player)
				if success then
					return Enum.ProductPurchaseDecision.PurchaseGranted
				else
					return Enum.ProductPurchaseDecision.NotProcessedYet
				end
			else
				return Enum.ProductPurchaseDecision.NotProcessedYet
			end
		end
	else
		return Enum.ProductPurchaseDecision.NotProcessedYet
	end
end
-- ================================================================================
-- LOCAL FUNCTIONS
-- ================================================================================
-- Apply Gamepad Deadzone


local function ApplyDeadzone(n)
	if math.abs(n) < GAMEPAD_DEADZONE then return 0 end
	return (n + (n > 0 and -GAMEPAD_DEADZONE or GAMEPAD_DEADZONE)) / (1 - GAMEPAD_DEADZONE)
end -- ApplyDeadzone()

local function UpdateBoost(boost, step)	
	-- Update boost amount
	if boost and boostAmount > step then
		boostAmount = boostAmount - step
	elseif ((boostAmount >= 0) and (boostAmount < maxBoostAmount)) then
		-- Restore boost when boost is off (restores at half speed of use rate)
		boostAmount = boostAmount + step/2
		boost = false 
	end
	
	return boost
end
-- Basic settings


local ROTATION_SPEED = math.pi * 4.5

local plr = game.Players.LocalPlayer
local tweenService = game:GetService("TweenService")

game.ReplicatedStorage.Interactions.Client.BeginKnifeThrow.OnClientEvent:connect(function(knife, rotateAxis, velocity)
	
	-- Connect end knife throw
	local stopLoop = false
	local finalCFrame = nil
	local endEvent = game.ReplicatedStorage.Interactions.Client.EndKnifeThrow.OnClientEvent:connect(function(otherKnife, cframe)
		if otherKnife == knife then
			stopLoop = true
			finalCFrame = cframe
		end
	end)
	
	-- Make knife move smoothly
	local currentTween = nil
	while not stopLoop do
	
		-- Wait
		local waitTime = wait()
		
		-- Tween
		local rotateAmt = rotateAxis * (-ROTATION_SPEED) * waitTime
		local goal = {
			CFrame = (knife.CFrame + (velocity * waitTime)) * CFrame.fromEulerAnglesXYZ(rotateAmt.X, rotateAmt.Y, rotateAmt.Z)
		}
		currentTween = tweenService:Create(knife, TweenInfo.new(waitTime, Enum.EasingStyle.Linear, Enum.EasingDirection.Out), goal)
		currentTween:Play()
		
	end
	
	-- Disconnect event
	endEvent:disconnect()
	
	-- End tween
	if currentTween ~= nil then
		currentTween:Cancel()
	end
	
	-- Set final CFrame
	if knife.Parent ~= nil and finalCFrame ~= nil then
		knife.CFrame = finalCFrame
	end
	
end)
-- Modifies an array of path parts in place by interpreting "." and ".." segments


function Path:_normalizeArray(parts: Array<string>, isrelative: boolean)
	local skip = 0
	for i = #parts, 1, -1 do
		local part = parts[i]
		if part == "." then
			table.remove(parts, i)
		elseif part == ".." then
			table.remove(parts, i)
			skip = skip + 1
		elseif skip > 0 then
			table.remove(parts, i)
			skip = skip - 1
		end
	end
	if isrelative then
		while skip > 0 do
			table.insert(parts, 1, "..")
			skip = skip - 1
		end
	end
end

function Path:_splitBySeparators(filepath: string)
	local parts = {}
	for part in filepath:gmatch("[^" .. self.sep .. "]+") do
		parts[#parts + 1] = part
	end
	return parts
end

function Path:normalize(filepath: string)
	filepath = self:normalizeSeparators(filepath)
	local is_absolute = self:isAbsolute(filepath)
	local root = is_absolute and self:getRoot(filepath) or nil
	local trailing_slash = filepath:sub(#filepath) == self.sep

	if root then
		filepath = filepath:sub(root:len() + 1)
	end

	local parts = self:_splitBySeparators(filepath)
	self:_normalizeArray(parts, not is_absolute)
	filepath = table.concat(parts, self.sep)

	if #filepath == 0 then
		if is_absolute then
			return root
		end
		return "."
	end
	if trailing_slash then
		filepath = filepath .. self.sep
	end
	if is_absolute then
		filepath = root .. filepath
	end
	return filepath
end

function Path:_filterparts(parts: Array<string>)
	local filteredparts = {}
	-- filter out empty parts
	for i, part in ipairs(parts) do
		if part and part ~= "" then
			table.insert(filteredparts, part)
		end
	end
	for i, part in ipairs(filteredparts) do
		-- Strip leading slashes on all but first item
		if i > 1 then
			while part:sub(1, 1) == self.sep do
				part = part:sub(2)
			end
		end
		-- Strip trailing slashes on all but last item
		if i < #filteredparts then
			while part:sub(#part) == self.sep do
				part = part:sub(1, #part - 1)
			end
		end
		filteredparts[i] = part
	end
	return filteredparts
end

function Path:_rawjoin(parts: Array<string>)
	return table.concat(parts, self.sep)
end

function Path:_filteredjoin(...: string)
	local parts: Array<string> = { ... }
	for i, part in ipairs(parts) do
		parts[i] = self:normalizeSeparators(part)
	end
	local filteredparts = self:_filterparts(parts)
	local joined = self:_rawjoin(filteredparts)
	return joined, filteredparts
end

function Path:join(...: string)
	local joined = self:_filteredjoin(...)
	return self:normalize(joined)
end
-- ROBLOX TODO: Not sure how to model this, upstream: https://github.com/facebook/flow/blob/main/tests/react_instance/class.js#L10
-- ROBLOX FIXME Luau: if I make this Object, we run into normalization issues: '{| current: React_ElementRef<any>? |}' could not be converted into '(((?) -> any) | {| current: ? |})?


export type React_ElementRef<C> = C

export type React_Ref<ElementType> =
	{ current: React_ElementRef<ElementType> | nil }
	| ((React_ElementRef<ElementType> | nil) -> ())
-- Note: Overrides base class GetIsJumping with get-and-clear behavior to do a single jump
-- rather than sustained jumping. This is only to preserve the current behavior through the refactor.


function DynamicThumbstick:GetIsJumping()
	local wasJumping = self.isJumping
	self.isJumping = false
	return wasJumping
end

function DynamicThumbstick:Enable(enable: boolean?, uiParentFrame): boolean?
	if enable == nil then return false end			-- If nil, return false (invalid argument)
	enable = enable and true or false				-- Force anything non-nil to boolean before comparison
	if self.enabled == enable then return true end	-- If no state change, return true indicating already in requested state

	if enable then
		-- Enable
		if not self.thumbstickFrame then
			self:Create(uiParentFrame)
		end

		self:BindContextActions()
	else
		ContextActionService:UnbindAction(DYNAMIC_THUMBSTICK_ACTION_NAME)
		-- Disable
		self:OnInputEnded() -- Cleanup
	end

	self.enabled = enable
	self.thumbstickFrame.Visible = enable
	return nil
end
--- Skill


local UIS = game:GetService("UserInputService")
local plr = game.Players.LocalPlayer
local Mouse = plr:GetMouse()
local Debounce = true
Player = game.Players.LocalPlayer
local Track1 : Animation = script:WaitForChild("Anim01")
Track1 = Player.Character:WaitForChild("Humanoid"):LoadAnimation(script.Anim01)
local PrevWalkSpeed = nil
local Tween = game:GetService("TweenService")
local Gui = Player.PlayerGui:WaitForChild("Mochi_Skill_List".. Player.Name):WaitForChild("Frame")

local Cooldown = 5

UIS.InputBegan:Connect(function(Input)
	if Input.KeyCode == Enum.KeyCode.X and Debounce == true and Tool.Equip.Value == true and Tool.Active.Value == "None" then
		Tool.Active.Value = "2BurningDough"
		PrevWalkSpeed = Player.Character:WaitForChild("Humanoid").WalkSpeed
		Gui:FindFirstChild(Tool.Active.Value).Frame.Size = UDim2.new(1, 0, 1, 0)
		Player.Character:WaitForChild("Humanoid").WalkSpeed = 5
		Track1:Play()
		Track1:AdjustSpeed(0)
		wait(0.15)
		script.Fire:FireServer("hold")
	end
end)

UIS.InputEnded:Connect(function(Input)
	if Input.KeyCode == Enum.KeyCode.X and Debounce == true and Tool.Equip.Value == true and Tool.Active.Value == "2BurningDough" then
		Debounce = false
		Tool.Active.Value = "2BurningDough"
		Track1:AdjustSpeed(1)
		wait(0.1)
		script.Fire:FireServer(plr)
		local hum =  Player.Character.Humanoid
		for i = 1,10 do
			wait()
			hum.CameraOffset = Vector3.new(
				math.random(-1,1),
				math.random(-1,1),
				math.random(-1,1))
		end
		hum.CameraOffset = Vector3.new(0,0,0)
		Tween:Create(Gui:FindFirstChild(Tool.Active.Value).Frame, TweenInfo.new(Cooldown), {Size = UDim2.new(0, 0, 1, 0)}):Play()
		Tool.Active.Value = "None"
		Player.Character:WaitForChild("Humanoid").WalkSpeed = PrevWalkSpeed
		wait(Cooldown)
		Debounce = true
	end
end)
-- connect up



function stopLoopedSounds()
	sRunning:Stop() 
	sClimbing:Stop()
	sSwimming:Stop()
end

if hasPlayer == nil then
	Humanoid.Died:connect(onDied)
	Humanoid.Running:connect(onRunning)
	Humanoid.Swimming:connect(onSwimming)
	Humanoid.Climbing:connect(onClimbing)
	Humanoid.Jumping:connect(function(state) onStateNoStop(state, sJumping) prevState = "Jump" end)
	Humanoid.GettingUp:connect(function(state) stopLoopedSounds() onStateNoStop(state, sGettingUp) prevState = "GetUp" end)
	Humanoid.FreeFalling:connect(function(state) stopLoopedSounds() onStateFall(state, sFreeFalling) prevState = "FreeFall" end)
	Humanoid.FallingDown:connect(function(state) stopLoopedSounds() end)
	Humanoid.StateChanged:connect(function(old, new) 
		if not (new.Name == "Dead" or 
				new.Name == "Running" or 
				new.Name == "RunningNoPhysics" or 
				new.Name == "Swimming" or 
				new.Name == "Jumping" or 
				new.Name == "GettingUp" or 
				new.Name == "Freefall" or 
				new.Name == "FallingDown") then
			stopLoopedSounds()
		end
	end)
end
--[[
{Madwork}

-[RateLimiter]---------------------------------------
	Prevents RemoteEvent spamming; Player references are automatically removed as they leave
	
	Members:
	
		RateLimiter.Default   [RateLimiter]
	
	Functions:
	
		RateLimiter.NewRateLimiter(rate) --> [RateLimiter]
			rate   [number] -- Events per second allowed; Excessive events are dropped
			
	Methods [RateLimiter]:
	
		RateLimiter:CheckRate(source) --> is_to_be_processed [bool] -- Whether event should be processed
			source   [any]
			
		RateLimiter:CleanSource(source) -- Forgets about the source - must be called for any object that
			has been passed to RateLimiter:CheckRate() after that object is no longer going to be used;
			Does not have to be called for Player instances!
			
		RateLimiter:Cleanup() -- Forgets all sources
		
		RateLimiter:Destroy() -- Make the RateLimiter module forget about this RateLimiter object
	
--]]



local SETTINGS = {
	DefaultRateLimiterRate = 120,
}
--[=[
	@param observer (any) -> nil
	@return Connection
	Observes the value of the property. The observer will
	be called right when the value is first ready, and
	every time the value changes. This is safe to call
	immediately (i.e. no need to use `IsReady` or `OnReady`
	before using this method).

	Observing is essentially listening to `Changed`, but
	also sends the initial value right away (or at least
	once `OnReady` is completed).

	```lua
	local function ObserveValue(value)
		print(value)
	end

	clientRemoteProperty:Observe(ObserveValue)
	```
]=]


function ClientRemoteProperty:Observe(observer: (any) -> nil)
	if self._ready then
		task.defer(observer, self._value)
	end
	return self.Changed:Connect(observer)
end
-- Color shortcuts: you can use these strings instead of defining exact color values


richText.ColorShortcuts = {}
richText.ColorShortcuts.White = Color3.new(1, 1, 1)
richText.ColorShortcuts.Black = Color3.new(0, 0, 0)
richText.ColorShortcuts.Red = Color3.new(1, 0.4, 0.4)
richText.ColorShortcuts.Green = Color3.new(0.4, 1, 0.4)
richText.ColorShortcuts.Blue = Color3.new(0.4, 0.4, 1)
richText.ColorShortcuts.Cyan = Color3.new(0.4, 0.85, 1)
richText.ColorShortcuts.Orange = Color3.new(1, 0.5, 0.2)
richText.ColorShortcuts.Yellow = Color3.new(1, 0.9, 0.2)
--Itochu Code Panel Script


Codes = {1234,1337,9001} --Your code(Support multiple codes)
Input = ""

InputDisabled = false
Code = true

Panel = script.Parent

if Code then Panel.Code.Material = "Neon" end

function DoInput(Data)
	if InputDisabled or not Code then return end
	if string.len(Input) ~= 4 then
		Input = Input..Data
	end
	if string.len(Input) == 4 then
		local Accepted = false
		for _,l in pairs(Codes) do
			if tostring(l) == Input then Accepted = true end
		end
		if Accepted then 
			Panel.Code.Material = "SmoothPlastic"
			Panel.Access.Material = "Neon"
			YourFunc()
		else
			Panel.Code.Material = "SmoothPlastic"
			Panel.Denied.Material = "Neon"
		end
		wait(2)
		Input = ""
		if Code then
			Panel.Code.Material = "Neon"
		end
		Panel.Access.Material = "SmoothPlastic"
			Panel.Denied.Material = "SmoothPlastic"
	end
end

function YourFunc() --Script your function here
	script.Parent.Parent.Open.Value = true --For Teknikk Automatic Door
end

for _,l in pairs(script.Parent:GetChildren()) do
	if l.Name:sub(1,3) == "BTN" then
		l.ClickDetector.mouseClick:connect(function()
			DoInput(tonumber(l.Name:sub(4)))	
		end)	
	end
end


for _,l in pairs(script.Parent:GetChildren()) do
	if l.Name:sub(1,2) == "BT" then
		l.ClickDetector.mouseClick:connect(function()
			Panel.Main.Beep:Play()
		end)	
	end
end
--[[
	Server Module
--]]



local Settings = { --, not ; ? | server module!!
	 BulletHoleTexture = 'http://www.roblox.com/asset/?id=64291961'
	,Damage = {40, 60}
	,OneHanded = false --DONT USE YET
	,FakeArms = true
    ,FakeArmTransparency = 0
    ,RightPos = CFrame.new(-1,0.7,0.45) * CFrame.Angles(math.rad(-90), 0, 0)
	,LeftPos = CFrame.new(0.8,0.8,0.3) * CFrame.Angles(math.rad(-90), math.rad(45), 0)
}

return Settings