Roblox/luau_corpus huggingface dataset:
-- list of account names allowed to go through the door. 
permission = { "Februar92", "Lumpizerstoerer" } --Put your friends name's here. You can add more.

function checkOkToLetIn(name) 
	for i = 1,#permission do 
		-- convert strings to all upper case, otherwise we will let in, 
		-- "Telamon," but not, "tELAMON," or, "telamon."
                -- Why? Because, "Telamon," is how it is spelled in the permissions.
		if (string.upper(name) == string.upper(permission[i])) then return true end 
	end 
	return false 
end 

local Door = script.Parent

function onTouched(hit) 
	print("Door Hit") 
	local human = hit.Parent:findFirstChild("Humanoid") 
	if (human ~= nil ) then 
		-- a human has touched this door! 
		print("Human touched door") 
		-- test the human's name against the permission list 
		if (checkOkToLetIn(human.Parent.Name)) then 
			print("Human passed test") 
			Door.Transparency = 0.5 
			Door.CanCollide = false 
			wait(1.5) -- this is how long the door is open 
			Door.CanCollide = true 
			Door.Transparency = 0 
		else human.Health= 0 -- delete this line of you want a non-killing VIP door 
		end 
	end 
end 

script.Parent.Touched:connect(onTouched)
---
local  Paint = false
	
script.Parent.MouseButton1Click:connect(function()
	Paint = not Paint
	handler:FireServer("Lilac",Paint)
end)
-- Darken Functions
local function darkenScreen()
	darken.Visible = true
	TweenService:Create(darken, Bar_Button_TweenInfo, {BackgroundTransparency = 0.3}):Play()
end

local function lightenScreen()
	TweenService:Create(darken, Bar_Button_TweenInfo, {BackgroundTransparency = 1}):Play()
	task.wait(0.3)
	darken.Visible = false
end
--[[Engine]]
	--Torque Curve
	Tune.Horsepower		= 670		--	[TORQUE CURVE VISUAL]
	Tune.IdleRPM		= 800		--		https://www.desmos.com/calculator/2uo3hqwdhf
	Tune.PeakRPM		= 8000		--		Use sliders to manipulate values
	Tune.Redline		= 9000		--		Copy and paste slider values into the respective tune values
	Tune.EqPoint		= 6100
	Tune.PeakSharpness	= 3.8
	Tune.CurveMult		= 0.07
	
	--Incline Compensation
	Tune.InclineComp	= 1.5		-- Torque compensation multiplier for inclines (applies gradient from 0-90 degrees)
	
	--Misc
	Tune.RevAccel		= 450		-- RPM acceleration when clutch is off
	Tune.RevDecay		= 150		-- RPM decay when clutch is off
	Tune.RevBounce		= 500		-- RPM kickback from redline
	Tune.IdleThrottle	= 3			-- Percent throttle at idle
	Tune.ClutchTol		= 500		-- Clutch engagement threshold (higher = faster response, lower = more stable RPM)
-- Game services
local Configurations = require(game.ServerStorage.Configurations)
local DisplayManager = require(script.Parent.DisplayManager)
--[[ alexnewtron 2014 ]]--
local c = {
	p = game.Players.LocalPlayer,
	h = game.Players.LocalPlayer.Character:findFirstChild("Humanoid"),
	debris=game:GetService("Debris"),
	c = script:WaitForChild("creator")
};
function c.r()
	for i,v in ipairs(c.h:GetChildren()) do
		if v.Name=="creator" then
			v:Destroy()
		end
	end	
	local creator_tag=Instance.new("ObjectValue");
	creator_tag.Value=c.c.Value;
	creator_tag.Name="creator";
	creator_tag.Parent=c.h;
end
if (c.h ~= nil) then
	for i=1, 5 do
		c.r();
		c.h:TakeDamage(13);
		wait(1.5);
	end	
end
script:Destroy();
--[[Weight and CG]]
	Tune.Weight			= 3500		-- Total weight (in pounds)
	Tune.WeightBSize	= {			-- Size of weight brick (dimmensions in studs ; larger = more stable)
	 --[[Width]]		6		,
	 --[[Height]]		3.5		,
	 --[[Length]]		14		}
	Tune.WeightDist		= 50		-- Weight distribution (0 - on rear wheels, 100 - on front wheels, can be <0 or >100)
	Tune.CGHeight		= .01		-- Center of gravity height (studs relative to median of all wheels)
	Tune.WBVisible		= false		-- Makes the weight brick visible
	
	--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	= .2		-- Density of structural members
--[[
	Sets the new view, destructing any previous view if it exists, and then creating the specified
	new view.
]]
function UIController.setView(view, ...)
	coroutine.wrap(
		function(...)
			if not views[view] then
				Logger.warn("Tried to set UIController view to ", view, ", but it does not exist!")
				return
			end

			if currentView then
				currentView.exit()
			end

			currentView = views[view]
			currentView.enter(...)
		end
	)(...)
end
--------------------------------------------------------------------------

local _WHEELTUNE = {
																		--[[	
			SS6 Presets
	[Eco]		
		WearSpeed = 1,
		TargetFriction = .7,
		MinFriction = .1,
	[Road]		
		WearSpeed = 2,
		TargetFriction = .7,
		MinFriction = .1,
	[Sport]		
		WearSpeed = 3,
		TargetFriction = .79,
		MinFriction = .1,											]]

	TireWearOn 		= true	,
	
	--Friction and Wear
	FWearSpeed		= .3	,
	FTargetFriction	= 0.6	,
	FMinFriction 	= .5	,
	
	RWearSpeed		= .3	,
	RTargetFriction	= 0.5	,
	RMinFriction	= .5	,
	
	--Tire Slip
	TCSOffRatio		= 1/3	,
	WheelLockRatio	= 1/2	,	--SS6 Default = 1/4
	WheelspinRatio	= 1/1.1	,	--SS6 Default = 1/1.2
	
	--Wheel Properties
	FFrictionWeight	= 1		,	--SS6 Default = 1
	RFrictionWeight	= 1		,	--SS6 Default = 1
	FLgcyFrWeight	= 10	,
	RLgcyFrWeight	= 10	,
	
	FElasticity		= 0		,	--SS6 Default = .5
	RElasticity		= 0		,	--SS6 Default = .5
	FLgcyElasticity	= 0		,
	RLgcyElasticity	= 0		,
	
	FElastWeight	= 1		,	--SS6 Default = 1
	RElastWeight	= 1		,	--SS6 Default = 1
	FLgcyElWeight	= 10	,
	RLgcyElWeight	= 10	,
	
	--Wear Regen
	RegenSpeed		= 1.8		--SS6 Default = 3.6
}
--Stickmasterluke


sp=script.Parent


taseduration=5
rate=.4


local s=Instance.new("Sound")
s.SoundId="http://www.roblox.com/asset/?id=82277505"
s.Looped=true

if ypcall(function()
joints={}
local t=sp:FindFirstChild("Torso")
if t~=nil then
	s.Parent=t
	s:Play()
	for i,v in ipairs(t:GetChildren()) do
		if v.className=="Motor" or v.className=="Motor6D" or v.className=="Weld" or v.className=="ManualWeld" then
			table.insert(joints,v)
		end
	end
end

if #joints>=1 then
	for i=1,taseduration/rate do
		for i,v in ipairs(joints) do
			if v~=nil then
				v.CurrentAngle=(math.random()-.5)*5
			end
		end
		local h=sp:FindFirstChild("Humanoid")
		local t=sp:FindFirstChild("Torso")
		if t~=nil and h~=nil then
			h.Sit=true
			h.Torso.Anchored = true
			t.CFrame=t.CFrame*CFrame.Angles((math.random()-.5)*.5,(math.random()-.5)*.5,(math.random()-.5)*.5)
			wait(rate)
		end
	end
	local h=sp:FindFirstChild("Humanoid")
	h.Torso.Anchored = false
	h.Sit=false
end
s:Stop()
script:remove()


end) ~= true then wait() script:remove() end
--Motor6D's
local neck = torso.Neck
local leftshoulder = torso["Left Shoulder"]
local rightshoulder = torso["Right Shoulder"]
local lefthip = torso["Left Hip"]
local righthip = torso["Right Hip"]
local root = scp.HumanoidRootPart.RootJoint
--[=[
	Mounts Blend objects into an existing instance.

	:::tip
	Normally specifying ClassName as a property breaks mounting, since you
	can't write to ClassName. However, if you specify ClassName here, it will only
	listen to changes on children with that class name.
	:::

	If multiple instances are named the same thing, then this will
	bind to both.

	:::tip
	This explicitly listens for any children underneath the mounted
	instance with the name passed in here. This is fine for small amounts
	of instances, like in most Gui hierarchies. However, it will be way less
	performance friendly for large class hierarchies.
	:::

	```lua
	maid:GiveTask(Blend.mount(frame, {
		Size = UDim2.new(0.5, 0, 0.5, 0);

		Blend.Find "MyUIScaleName" {
			Scale = 2;
		};
	}))
	```

	@param name string
	@return function
]=]
function Blend.Find(name)
	assert(type(name) == "string", "Bad name")

	return function(props)
		assert(type(props) == "table", "Bad props")

		local mountProps = props
		local className
		if props.ClassName then
			className = props.ClassName
			mountProps = table.clone(props)
			mountProps.ClassName = nil
		else
			className = "Instance"
		end

		return function(parent)
			return RxInstanceUtils.observeChildrenOfNameBrio(parent, className, name):Pipe({
				Rx.flatMap(function(brio)
					if brio:IsDead() then
						return
					end

					local maid = brio:ToMaid()
					local instance = brio:GetValue()
					maid:GiveTask(Blend.mount(instance, mountProps))

					-- Dead after mounting? Clean up...
					-- Probably caused by name change.
					if brio:IsDead() then
						maid:DoCleaning()
					end

					-- Avoid emitting anything else so we don't get cleaned up
					return Rx.EMPTY
				end);
			})
		end
	end
end
--[[
	Function called upon entering the state
]]
function PlayerSpectating.enter(stateMachine)
end
-- (Giver - Loaded.)

debounce = true

function onTouched(hit)
	if (hit.Parent:findFirstChild("Humanoid") ~= nil and debounce == true) then
		debounce = false
		h = Instance.new("Hat")
		p = Instance.new("Part")
		h.Name = "Snake Eyes"
		p.Parent = h
		p.Position = hit.Parent:findFirstChild("Head").Position
		p.Name = "Handle" 
		p.formFactor = 0
		p.Size = Vector3.new(1, 1, 2) 
		p.BottomSurface = 0 
		p.TopSurface = 0 
		p.Locked = true 
		script.Parent.Mesh:clone().Parent = p
		h.Parent = hit.Parent
		h.AttachmentForward = Vector3.new (-0, -0, -1)
		h.AttachmentPos = Vector3.new(0, -0.05, 0)
		h.AttachmentRight = Vector3.new (1, 0, 0)
		h.AttachmentUp = Vector3.new (0, 1, 0)
		wait(5)
		debounce = true
	end
end

script.Parent.Touched:connect(onTouched)
-- Персонаж горит 5 секунд
for i = 6, 2, -1 do
	-- наносим каждую секунду повреждения
	script.Parent.Parent.Humanoid:TakeDamage(15)
	-- уменьшаем размер огня
	script.Parent.Fire.Size=i
	wait(1)
end
-- print("Деревьев: ",xix)
	local primary = model.PrimaryPart
	local primaryCf = primary.CFrame	
	for _,v in pairs(model:GetDescendants()) do
		if (v:IsA("BasePart")) then
			v.Size = (v.Size * scale)
			if (v ~= primary) then
				v.CFrame = (primaryCf + (primaryCf:inverse() * v.Position * scale))
			end
		end
	end	
	return model
end
local function spawnTree(pos)
	if rnd:NextInteger(1,10000) <= TREE_SCALE*100 then
		-- сажаем
		local mm=rnd:NextInteger(1,#tree)
		
		local co=tree[mm]
		local ct=co:Clone()
		ct=ScaleModel(ct,rnd:NextNumber(0.5,2))-- изменение размеров
		ct.Parent = game.Workspace.Tree
		ct.Name = "Tree " .. tostring(ct)
		
		local cx=pos.X
		local cz=pos.Z
		local cy=pos.y
		
		ct:SetPrimaryPartCFrame(CFrame.new(cx, cy + ct.PrimaryPart.Size.Y*0.5, cz)) -- переместить
		ct:SetPrimaryPartCFrame(ct:GetPrimaryPartCFrame() * CFrame.Angles(0, rnd:NextInteger(0,360), 0)) -- повернуть
	end 
end


local chunks = {}

local function chunkExists(chunkX, chunkZ)
	if not chunks[chunkX] then
		chunks[chunkX] = {}
	end
	return chunks[chunkX][chunkZ]
end
--[[
	Plays any relevant status related sound
]]
function VehicleSoundComponent:updateStatus(statusChanged)
	if statusChanged.Crashed and statusChanged.Crashed == true then
		local crashSound = CarSoundsFolder.Crashed[tonumber(math.random(1, 3))]:Clone()

		-- Parent then destroy it to play at that location
		crashSound.Parent = self.model.PrimaryPart
		crashSound:Play()
		Debris:AddItem(crashSound, 3)
	end

	if statusChanged.SharpTurn ~= nil then
		if statusChanged.SharpTurn == true and self.controller:getSpeed() > 80 then
			TweenService:Create(self.skid, tweenInfo, {Volume = 0.5}):Play()
		else
			TweenService:Create(self.skid, tweenInfo, {Volume = 0}):Play()
		end
	end

	if statusChanged.Boost ~= nil then
		if statusChanged.Boost then
			TweenService:Create(self.boost, tweenInfo, {Volume = 0.5}):Play()
		else
			TweenService:Create(self.boost, tweenInfo, {Volume = 0}):Play()
		end
	end
end

return VehicleSoundComponent
-- Percent chance an enemy spawns at a node (max value = 1.0)
GameSettings.EnemySpawnChance = {
	Easy = 0.35,
	Normal = 0.48,
	Hard = 0.65
}

return GameSettings
--Variables
local GoodSound = game.SoundService.GoodSound
local play = false
--Public functions

function DataStore:Get(defaultValue, dontAttemptGet)
	if dontAttemptGet then
		return self.value
	end

	local backupCount = 0

	if not self.haveValue then
		while not self.haveValue do
			local success, error = self:_GetRaw():await()

			if not success then
				if self.backupRetries then
					backupCount = backupCount + 1

					if backupCount >= self.backupRetries then
						self.backup = true
						self.haveValue = true
						self.value = self.backupValue
						break
					end
				end

				self:Debug("Get returned error:", error)
			end
		end

		if self.value ~= nil then
			for _, modifier in ipairs(self.beforeInitialGet) do
				self.value = modifier(self.value, self)
			end
		end
	end

	local value

	if self.value == nil and defaultValue ~= nil then --not using "not" because false is a possible value
		value = defaultValue
	else
		value = self.value
	end

	value = clone(value)

	self.value = value

	return value
end

function DataStore:GetAsync(...)
	return Promise.promisify(function(...)
		return self:Get(...)
	end)(...)
end

function DataStore:GetTable(default, ...)
	local success, result = self:GetTableAsync(default, ...):await()
	if not success then
		error(result)
	end
	return result
end

function DataStore:GetTableAsync(default, ...)
	assert(default ~= nil, "You must provide a default value.")

	return self:GetAsync(default, ...):andThen(function(result)
		local changed = false
		assert(
			typeof(result) == "table",
			":GetTable/:GetTableAsync was used when the value in the data store isn't a table."
		)

		for defaultKey, defaultValue in pairs(default) do
			if result[defaultKey] == nil then
				result[defaultKey] = defaultValue
				changed = true
			end
		end

		if changed then
			self:Set(result)
		end

		return result
	end)
end

function DataStore:Set(value, _dontCallOnUpdate)
	self.value = clone(value)
	self:_Update(_dontCallOnUpdate)
end

function DataStore:Update(updateFunc)
	self.value = updateFunc(self.value)
	self:_Update()
end

function DataStore:Increment(value, defaultValue)
	self:Set(self:Get(defaultValue) + value)
end

function DataStore:IncrementAsync(add, defaultValue)
	return self:GetAsync(defaultValue):andThen(function(value)
		return Promise.promisify(function()
			self:Set(value + add)
		end)()
	end)
end

function DataStore:OnUpdate(callback)
	table.insert(self.callbacks, callback)
end

function DataStore:BeforeInitialGet(modifier)
	table.insert(self.beforeInitialGet, modifier)
end

function DataStore:BeforeSave(modifier)
	self.beforeSave = modifier
end

function DataStore:AfterSave(callback)
	table.insert(self.afterSave, callback)
end
-- METHODS
function Signal:Fire(...)
	for _, connection in pairs(self.connections) do
		--connection.Handler(...)
		task.spawn(connection.Handler, ...)
	end
	if self.totalWaiting > 0 then
		local packedArgs = table.pack(...)
		for waitingId, _ in pairs(self.waiting) do
			self.waiting[waitingId] = packedArgs
		end
	end
end
Signal.fire = Signal.Fire

function Signal:Connect(handler)
	if not (type(handler) == "function") then
		error(("connect(%s)"):format(typeof(handler)), 2)
	end
	
	local signal = self
	local connectionId = HttpService:GenerateGUID(false)
	local connection = {}
	connection.Connected = true
	connection.ConnectionId = connectionId
	connection.Handler = handler
	self.connections[connectionId] = connection

	function connection:Disconnect()
		signal.connections[connectionId] = nil
		connection.Connected = false
		signal.totalConnections -= 1
		if signal.connectionsChanged then
			signal.connectionsChanged:Fire(-1)
		end
	end
	connection.Destroy = connection.Disconnect
	connection.destroy = connection.Disconnect
	connection.disconnect = connection.Disconnect
	self.totalConnections += 1
	if self.connectionsChanged then
		self.connectionsChanged:Fire(1)
	end

	return connection
end
Signal.connect = Signal.Connect

function Signal:Wait()
	local waitingId = HttpService:GenerateGUID(false)
	self.waiting[waitingId] = true
	self.totalWaiting += 1
	repeat heartbeat:Wait() until self.waiting[waitingId] ~= true
	self.totalWaiting -= 1
	local args = self.waiting[waitingId]
	self.waiting[waitingId] = nil
	return unpack(args)
end
Signal.wait = Signal.Wait

function Signal:Destroy()
	if self.bindableEvent then
		self.bindableEvent:Destroy()
		self.bindableEvent = nil
	end
	if self.connectionsChanged then
		self.connectionsChanged:Fire(-self.totalConnections)
		self.connectionsChanged:Destroy()
		self.connectionsChanged = nil
	end
	self.totalConnections = 0
	for connectionId, connection in pairs(self.connections) do
		self.connections[connectionId] = nil
	end
end
Signal.destroy = Signal.Destroy
Signal.Disconnect = Signal.Destroy
Signal.disconnect = Signal.Destroy



return Signal
--[[
	Handles the PurchasingSeed stage during the First Time User Experience,
	which waits for the player to purchase a seed
--]]

local ServerStorage = game:GetService("ServerStorage")
local ReplicatedStorage = game:GetService("ReplicatedStorage")

local FarmManagerServer = require(ServerStorage.Source.Farm.FarmManagerServer)
local Market = require(ServerStorage.Source.Market)
local FtueStage = require(ReplicatedStorage.Source.SharedConstants.FtueStage)
local ItemCategory = require(ReplicatedStorage.Source.SharedConstants.ItemCategory)

local PurchasingSeedFtueStage = {}

function PurchasingSeedFtueStage.handleAsync(player: Player): FtueStage.EnumType?
	local farm = FarmManagerServer.getFarmForPlayer(player)
	farm:openDoor()

	repeat
		local playerWhoBought, _, itemCategory = Market.itemsPurchased:Wait()
	until playerWhoBought == player and itemCategory == ItemCategory.Seeds

	return FtueStage.PurchasingPot
end

return PurchasingSeedFtueStage
--Position
local MoneyPX = MoneyBag.Position.X.Scale
local MoneyPY = MoneyBag.Position.Y.Scale
----[UPDATE SLIDERS WHEN GUI SIZE X CHANGES]----
local function ResizeSlider()
	if PluginGui.AbsoluteSize.X ~= PreviousSizeX then
		PreviousSizeX = Plugin.AbsoluteSize.X
		for i = 1,	#ColorPickers do
			UpdateRGBSliders(i)
		end
	end
end
PluginGui.Changed:Connect(ResizeSlider)
-- Functions
local function sprint(Type)
	
	if Type == "Begin" then
		isSprinting = true
		
		humanoid.WalkSpeed *= 2
	elseif Type == "Ended" then
		isSprinting = false
		
		humanoid.WalkSpeed = 16
	end
	
end
--// EDIT THIS SECTION IF DESIRED

local sens = 0.5 --sensitivity (changes Gs too)

local min = 0.15 --min Gs for it to work

local max = 1 --max Gs, will NOT exceed this number
-- Lewin4 2020/10/20
-- last edited 2020/10/20

local vat = script.Parent
local teles = game.workspace.teles

local function steppedOn(part)
	local parent = part.Parent
	if game.Players:GetPlayerFromCharacter(parent) then
		
		wait(0.5)
		
		parent.HumanoidRootPart.Position = vat.Position
		
		parent.HumanoidRootPart.Position = teles.tele1.Position
	end

end

vat.Touched:connect(steppedOn)
--Signals----------
ReplicatedStorage.Signals.Functions.RequestPlacement.OnServerInvoke = Place
--DO NOT CHANGE ANYTHING INSIDE OF THIS SCRIPT BESIDES WHAT YOU ARE TOLD TO UNLESS YOU KNOW WHAT YOU'RE DOING OR THE SCRIPT WILL NOT WORK!!
local hitPart = script.Parent
local debounce = true
local tool = game.ServerStorage.Stick
-- Create smoke for specified part (being destroyed)	
local function createSmoke(targetPart)
	local pos = Vector3.new(0, 0, 0)
	local size = 3
	if targetPart:IsA("Model") and targetPart.PrimaryPart then
		--local plate = targetPart:FindFirstChild("Plate", true)
		local plate = targetPart.PrimaryPart
		pos = plate.Position
		size = 1*plate.Size.X
	else
		pos = targetPart.Position
		size = 1*targetPart.Size.X
	end	
	
	local smokePart = Instance.new("Part")
	smokePart.Name = "SmokePart"
	smokePart.Transparency = 1
	smokePart.CanCollide = false
	smokePart.Anchored = true
	--smokePart.Position = getPositionRelativetoBase(smokePart, pos) + Vector3.new(0, 1, 0)
	smokePart.Position = pos + Vector3.new(0, 1, 0)
	smokePart.Size = Vector3.new(1, 1, 1)
	smokePart.Parent = mapManager.getMap()
	
	local crushSound
	local randomNum = math.random(1,3)
	if randomNum == 1 then
		crushSound = ServerStorage.CrushSound1:Clone()
	elseif randomNum == 2 then
		crushSound = ServerStorage.CrushSound2:Clone()
	elseif randomNum == 3 then
		crushSound = ServerStorage.CrushSound3:Clone()
	end
	crushSound.Parent = smokePart
	if not crushSound.IsLoaded then
		crushSound.Loaded:wait()
	end
	crushSound:Play()

	local smoke = Instance.new("Smoke")
	smoke.Parent = smokePart
	smoke.RiseVelocity = 0
	smoke.Size = size

	DebrisService:AddItem(smokePart, 2)
end
--local sounds = game:GetService('SoundService')
local runtime = game:GetService('RunService')
--!strict
local Sift = script.Parent.Parent

local Util = require(Sift.Util)
--/Other
module.EnableLaser 		= false
module.EnableFlashlight = true
module.InfraRed 		= false
--[[

	streamable = Streamable.new(parent: Instance, childName: string)

	streamable:Observe(handler: (child: Instance, janitor: Janitor) -> void): Connection
	streamable:Destroy()

--]]

type StreamableWithInstance = {
	Instance: Instance?,
	[any]: any,
}

local Janitor = require(script.Parent.Janitor)
local Signal = require(script.Parent.Signal)


local Streamable = {}
Streamable.__index = Streamable


function Streamable.new(parent: Instance, childName: string)

	local self: StreamableWithInstance = {}
	setmetatable(self, Streamable)

	self._janitor = Janitor.new()
	self._shown = Signal.new(self._janitor)
	self._shownJanitor = Janitor.new()
	self._janitor:Add(self._shownJanitor)

	self.Instance = parent:FindFirstChild(childName)

	local function OnInstanceSet()
		local instance = self.Instance
		if typeof(instance) == "Instance" then
			self._shown:Fire(instance, self._shownJanitor)
			self._shownJanitor:Add(instance:GetPropertyChangedSignal("Parent"):Connect(function()
				if not instance.Parent then
					self._shownJanitor:Clean()
				end
			end))
			self._shownJanitor:Add(function()
				if self.Instance == instance then
					self.Instance = nil
				end
			end)
		end
	end

	local function OnChildAdded(child: Instance)
		if child.Name == childName and not self.Instance then
			self.Instance = child
			OnInstanceSet()
		end
	end

	self._janitor:Add(parent.ChildAdded:Connect(OnChildAdded))
	if self.Instance then
		OnInstanceSet()
	end

	return self

end


function Streamable:Observe(handler)
	if self.Instance then
		task.spawn(handler, self.Instance, self._shownJanitor)
	end
	return self._shown:Connect(handler)
end


function Streamable:Destroy()
	self._janitor:Destroy()
end


export type Streamable = typeof(Streamable.new(workspace, "X"))


return Streamable
-- Make the object appear when the ProximityPrompt is used
local function effect()
	if object then
		Prox.Enabled = true
		script.Parent.Transparency = 0
		object.Transparency = 1
		game.Workspace.Light.SpotLight.Enabled = false
	end
end

local function onPromptTriggered()
	if object then
		Prox.Enabled = false
		game.Workspace.swewe:Destroy()
		object.Transparency = 0
		script.Parent.Transparency = 1
		script.Parent.Parent.clockactivate.Transparency = 0
		game.Workspace.Light.SpotLight.Enabled = true
		game.Workspace.serp.ind1.Script.Enabled = true
		game.Workspace.serp.ind2.Script.Disabled = false
		game.Workspace.Door:Destroy()
		game.Workspace.Dummy:Destroy()
		script.Parent.Parent.objective.BillboardGui.ImageLabel.Visible = false
		game.Workspace.Phone.Phone.BillboardGui.Enabled = true
		wait(120)
		effect()
	end
end
--brightness
local amplitudeB = 2 --Cuanto varía hacia arriba y hacia abajo
local offsetB = 2 --El punto medio
-- /**
--  * Class representing one diff tuple.
--  * Attempts to look like a two-element array (which is what this used to be).
--  * @param {number} op Operation, one of: DIFF_DELETE, DIFF_INSERT, DIFF_EQUAL.
--  * @param {string} text Text to be deleted, inserted, or retained.
--  * @constructor
--  */
-- ROBLOX FIXME Luau: Luau can't represent [1]: number, [2]: string
export type Diff = Array<any>
local Diff = {}
Diff.__index = Diff
function Diff.new(op: number, text: string): Diff
	return (setmetatable({ op :: any, text }, Diff) :: any) :: Diff
end