Roblox/luau_corpus huggingface dataset:
--
script.Parent.OnServerEvent:Connect(function(p)
	local Character = p.Character
	local Humanoid = Character.Humanoid
	local RootPart = Character.HumanoidRootPart
	local Slash = RS.Effects.Part2:Clone()
	script.Attack:Play()
	Slash.Parent = FX
	Slash.CFrame = RootPart.CFrame * CFrame.new(0,0,-3)
	local BV = Instance.new("BodyVelocity",Slash)
	BV.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
	BV.Velocity = p.Character.HumanoidRootPart.CFrame.LookVector * 60
	Slash.Touched:Connect(function(hit)
		if hit.Parent:FindFirstChild("Humanoid") and hit.Parent.Name ~= p.Name then
			hit.Parent.Humanoid:TakeDamage(Damage)
			local HitEffect = Effects.Hit2.Attachment:Clone()
			local RootPart2 = hit.Parent.HumanoidRootPart
			HitEffect.Parent = RootPart2
			for _,Particles in pairs(HitEffect:GetDescendants()) do
				if Particles:IsA("ParticleEmitter") then
					Particles:Emit(Particles:GetAttribute("EmitCount"))
				end
			end
			HitEffect.Hit:Play()
			local vel = Instance.new("BodyVelocity", RootPart2)
			vel.MaxForce = Vector3.new(1,1,1) * 1000000;
			vel.Parent = RootPart2
			vel.Velocity = Vector3.new(1,1,1) * p.Character:WaitForChild("HumanoidRootPart").CFrame.LookVector * 0
			vel.Name  =  "SmallMoveVel"
			game.Debris:AddItem(vel,1)
			Slash:Destroy()
	end
	wait(1)
	Slash.Anchored = true
	for _,Particles in pairs(Slash.Part.Parent:GetDescendants()) do
		if Particles:IsA("ParticleEmitter") then
			Particles.Enabled = false
		end
		end
		Slash.PointLight.Enabled = false
end)
end)
-- Decompiled with the Synapse X Luau decompiler.

return {
	run = function(p1)
		local l__Shopkeeper__1 = p1.Shopkeeper;
		local v2 = {};
		for v3 = 1, 4 do
			local v4 = "Tentacle" .. v3;
			local v5 = v2[v4];
			local v6 = l__Shopkeeper__1:FindFirstChild(v4);
			local v7 = {};
			for v8, v9 in pairs({ { "Bone", "TentacleBase" .. v3 }, { "Bone.001", "T" .. v3 .. "_P1" }, { "Bone.002", "T" .. v3 .. "_P2" }, { "Bone.003", "T" .. v3 .. "_P3" }, { "Bone.004", "T" .. v3 .. "_P4" }, { "Bone.005", "T" .. v3 .. "_P5" }, { "Bone.006", "T" .. v3 .. "_P6" }, { "Bone.007", "T" .. v3 .. "_P7" }, { "Bone.008", "T" .. v3 .. "_P8" }, { "Bone.009", "T" .. v3 .. "_P9" } }) do
				table.insert(v7, { v6:FindFirstChild(v9[1], true), v6:FindFirstChild(v9[2], true) });
			end;
			v2[v4] = v7;
		end;
		coroutine.wrap(function()
			for v10 = 1, 10000000000 do
				for v11 = 1, 4 do
					local v12 = v2["Tentacle" .. v11];
					for v13 = 1, 10 do
						local v14 = v12[v13];
						v14[1].WorldCFrame = v14[2].CFrame;
					end;
				end;
				game["Run Service"].Heartbeat:wait();
			end;
		end)();
	end
};
-- Variables
local player = game.Players.LocalPlayer
local character = player.Character or player.CharacterAdded:Wait()
local humanoid = character:WaitForChild("Humanoid")
-- Helper function to lazily instantiate a controller if it does not yet exist,
-- disable the active controller if it is different from the on being switched to,
-- and then enable the requested controller. The argument to this function must be
-- a reference to one of the control modules, i.e. Keyboard, Gamepad, etc.
function ControlModule:SwitchToController(controlModule)
	if not controlModule then
		if self.activeController then
			self.activeController:Enable(false)
		end
		self.activeController = nil
		self.activeControlModule = nil
	else
		if not self.controllers[controlModule] then
			self.controllers[controlModule] = controlModule.new(CONTROL_ACTION_PRIORITY)
		end

		if self.activeController ~= self.controllers[controlModule] then
			if self.activeController then
				self.activeController:Enable(false)
			end
			self.activeController = self.controllers[controlModule]
			self.activeControlModule = controlModule -- Only used to check if controller switch is necessary

			if self.touchControlFrame and (self.activeControlModule == TouchThumbpad
						or self.activeControlModule == TouchThumbstick
						or self.activeControlModule == ClickToMove
						or self.activeControlModule == DynamicThumbstick) then
				if not self.controllers[TouchJump] then
					self.controllers[TouchJump] = TouchJump.new()
				end
				self.touchJumpController = self.controllers[TouchJump]
				self.touchJumpController:Enable(true, self.touchControlFrame)
			else
				if self.touchJumpController then
					self.touchJumpController:Enable(false)
				end
			end

			self:EnableActiveControlModule()
		end
	end
end

function ControlModule:OnLastInputTypeChanged(newLastInputType)
	if lastInputType == newLastInputType then
		warn("LastInputType Change listener called with current type.")
	end
	lastInputType = newLastInputType

	if lastInputType == Enum.UserInputType.Touch then
		-- TODO: Check if touch module already active
		local touchModule, success = self:SelectTouchModule()
		if success then
			while not self.touchControlFrame do
				wait()
			end
			self:SwitchToController(touchModule)
		end
	elseif computerInputTypeToModuleMap[lastInputType] ~= nil then
		local computerModule = self:SelectComputerMovementModule()
		if computerModule then
			self:SwitchToController(computerModule)
		end
	end
end
--	print(hasAnyWater)
	if hasAnyWater then
		if script.Parent.Parent.Charges.Value < 100 then
			script.Parent.Parent.Charges.Value = script.Parent.Parent.Charges.Value + 25
			script.Parent.FillSound:stop()
			script.Parent.FillSound.Pitch = math.random(5,15) / 10
			script.Parent.FillSound:play()
		end
	end
end

function alsowater(hit)
	if hit.Name:lower() == "water" then
		if script.Parent.Parent.Charges.Value < 100 then
			script.Parent.Parent.Charges.Value = script.Parent.Parent.Charges.Value + 50
			script.Parent.FillSound:stop()
			script.Parent.FillSound.Pitch = math.random(5,15) / 10
			script.Parent.FillSound:play()
		end
	end
end

script.Parent.Touched:connect(alsowater)
-- assume we are in the character, let's check
function sepuku()
	script.Parent = nil
end

local debris = game:GetService("Debris")

local h = script.Parent:FindFirstChild("Humanoid")
if (h == nil) then sepuku() end

local torso = script.Parent:FindFirstChild("HumanoidRootPart")
if (torso == nil) then sepuku() end

local head = script.Parent:FindFirstChild("Head")
if (head == nil) then head = torso end

local equalizingForce = 236 / 1.2 -- amount of force required to levitate a mass
local gravity = .75 -- things float at > 1
local fire = Instance.new("Fire")
fire.Parent = head
fire.Heat = 10
fire.Size = 3

function recursiveGetLift(node)
	local m = 0
	local c = node:GetChildren()
	if (node:FindFirstChild("Head") ~= nil) then head = node:FindFirstChild("Head") end -- nasty hack to detect when your parts get blown off

	for i=1,#c do
		if c[i].className == "Part" then
			if (head ~= nil and (c[i].Position - head.Position).magnitude < 10) then -- GROSS
				if c[i].Name == "Handle" then
					m = m + (c[i]:GetMass() * equalizingForce * 1) -- hack that makes hats weightless, so different hats don't change your jump height
				else
					m = m + (c[i]:GetMass() * equalizingForce * gravity)
				end
			end
		end
		m = m + recursiveGetLift(c[i])
	end
	return m
end

function jumpIt()

	local mass = recursiveGetLift(h.Parent)
	local force = Instance.new("BodyForce")
	force.force = Vector3.new(0,mass * 2,0)
	force.Parent = torso
	debris:AddItem(force,0.5)

end

local con = h.Jumping:connect(jumpIt)

local oldSpeed = h.WalkSpeed
h.WalkSpeed = h.WalkSpeed * 1.6

local oldMaxHealth = h.MaxHealth
h.MaxHealth = oldMaxHealth * 1.5
h.Health = h.MaxHealth

local bodySpin = Instance.new("BodyAngularVelocity")
bodySpin.P = 200000
bodySpin.angularvelocity = Vector3.new(0,15,0)
bodySpin.maxTorque = Vector3.new(bodySpin.P,bodySpin.P,bodySpin.P)
bodySpin.Parent = torso

wait(30)

fire:Destroy()

h.WalkSpeed = oldSpeed
h.MaxHealth = oldMaxHealth
if h.Health > 60 then
	h.Health = 60
end
con:disconnect()
bodySpin:Destroy()
sepuku()
--[=[
	@within Matter

	:::info Topologically-aware function
	This function is only usable if called within the context of [`Loop:begin`](/api/Loop#begin).
	:::

	Returns the `os.clock()` time delta between the start of this and last frame.
]=]
local function useDeltaTime(): number
	local state = topoRuntime.useFrameState()

	return state.deltaTime
end

return useDeltaTime
--Dynamic Traffic Light made by DerDiebKommt. Only edit the things that the script says to edit.

while true do --This makes the script do a loop.
script.Parent.Green.PointLight.Enabled = false
script.Parent.Yellow.PointLight.Enabled = false
script.Parent.Red.PointLight.Enabled = true
script.Parent.Green.Transparency = 0.5
script.Parent.Yellow.Transparency = 0.5
script.Parent.Red.Transparency = 0
wait(25) --Edit this if you want the time faster/slower for Green to go to Yellow.
script.Parent.Green.PointLight.Enabled = true
script.Parent.Yellow.PointLight.Enabled = false
script.Parent.Red.PointLight.Enabled = false
script.Parent.Green.Transparency = 0
script.Parent.Yellow.Transparency = 0.5
script.Parent.Red.Transparency = 0.5
wait(25) --Edit this if you want the time faster/slower for Yellow to go to Red. 
script.Parent.Green.PointLight.Enabled = false
script.Parent.Yellow.PointLight.Enabled = true
script.Parent.Red.PointLight.Enabled = false
script.Parent.Green.Transparency = 0.5
script.Parent.Yellow.Transparency = 0
script.Parent.Red.Transparency = 0.5
wait(5) --Edit this if you want the time faster/slower for Red to go to Green.
end --This makes the script do a loop.
--Functions
function open()
	local mag = (doora.PrimaryPart.Position-script.Parent.Parent.Ahit.Position).magnitude
	for j = 0,1,speed/mag do
		local scf = doora.PrimaryPart.CFrame
		doora:SetPrimaryPartCFrame(scf:lerp(script.Parent.Parent.Ahit.CFrame,j))
		wait()
local magg = (doora.PrimaryPart.Position-script.Parent.Parent.Ahit.Position).magnitude
if magg <= 0.1 then break end
	end
end
function close()
	local mag = (doora.PrimaryPart.Position-script.Parent.Parent.OrigAhit.Position).magnitude
	for j = 0,1,speed/mag do
		local scf = doora.PrimaryPart.CFrame
		doora:SetPrimaryPartCFrame(scf:lerp(script.Parent.Parent.OrigAhit.CFrame,j))
		wait()
		local magg = (doora.PrimaryPart.Position-script.Parent.Parent.OrigAhit.Position).magnitude
if magg <= 0.1 then break end
	end
	doora:SetPrimaryPartCFrame(doora.PrimaryPart.CFrame:lerp(script.Parent.Parent.OrigAhit.CFrame))
	end
--------------------------------------------

local Signal = {}
Signal.__index = Signal


function Signal.new(maid)
	local self = setmetatable({
		_bindable = Instance.new("BindableEvent");
		_connections = {};
		_args = {};
		_threads = 0;
		_id = 0;
	}, Signal)
	if (maid) then
		maid:GiveTask(self)
	end
	return self
end


function Signal.Proxy(rbxScriptSignal, maid)
	assert(typeof(rbxScriptSignal) == "RBXScriptSignal", "Argument #1 must be of type RBXScriptSignal")
	local signal = Signal.new(maid)
	signal:_setProxy(rbxScriptSignal)
	return signal
end


function Signal.Is(obj)
	return (type(obj) == "table" and getmetatable(obj) == Signal)
end


function Signal:_setProxy(rbxScriptSignal)
	assert(typeof(rbxScriptSignal) == "RBXScriptSignal", "Argument #1 must be of type RBXScriptSignal")
	self:_clearProxy()
	self._proxyHandle = rbxScriptSignal:Connect(function(...)
		self:Fire(...)
	end)
end


function Signal:_clearProxy()
	if (self._proxyHandle) then
		self._proxyHandle:Disconnect()
		self._proxyHandle = nil
	end
end


function Signal:Fire(...)
	local totalListeners = (#self._connections + self._threads)
	if (totalListeners == 0) then return end
	local id = self._id
	self._id += 1
	self._args[id] = {totalListeners, {n = select("#", ...), ...}}
	self._threads = 0
	self._bindable:Fire(id)
end


function Signal:Wait()
	self._threads += 1
	local id = self._bindable.Event:Wait()
	local args = self._args[id]
	args[1] -= 1
	if (args[1] <= 0) then
		self._args[id] = nil
	end
	return table.unpack(args[2], 1, args[2].n)
end


function Signal:WaitPromise()
	return Promise.new(function(resolve)
		resolve(self:Wait())
	end)
end


function Signal:Connect(handler)
	local connection = Connection.new(self, self._bindable.Event:Connect(function(id)
		local args = self._args[id]
		args[1] -= 1
		if (args[1] <= 0) then
			self._args[id] = nil
		end
		handler(table.unpack(args[2], 1, args[2].n))
	end))
	table.insert(self._connections, connection)
	return connection
end


function Signal:DisconnectAll()
	for _,c in ipairs(self._connections) do
		if (c._conn) then
			c._conn:Disconnect()
		end
	end
	self._connections = {}
	self._args = {}
end


function Signal:Destroy()
	self:DisconnectAll()
	self:_clearProxy()
	self._bindable:Destroy()
end


return Signal
-- FUNCTIONS --
Tool.Equipped:Connect(function()
	Character = Tool.Parent
	HRP = Character:WaitForChild("HumanoidRootPart")
	Humanoid = Character:WaitForChild("Humanoid")
	
	equippedIdle = Humanoid:LoadAnimation(script.Animations.Idle)
	equippedIdle:Play()
	Equipped.Value = true
	
	attackRemote:FireServer("Unblock", Tool.Name)
	
	if not childAdded then
		childAdded = Character.ChildAdded:Connect(function()
			if not Equipped.Value then return end
			if not Player:FindFirstChild("Ragdoll") then
				equippedIdle:Play()
			else
				equippedIdle:Stop()
			end
		end)
	end

	if not childRemoved then
		childRemoved = Character.ChildRemoved:Connect(function()
			if not Equipped.Value then return end
			if not Player:FindFirstChild("Ragdoll") then
				equippedIdle:Play()
			else
				equippedIdle:Stop()
			end
		end)
	end
end)

Tool.Unequipped:Connect(function()
	equippedIdle:Stop()
	attackRemote:FireServer("Unblock", Tool.Name)
	
	Equipped.Value = false
	
	if childAdded ~= nil then
		childAdded:Disconnect()
		childAdded = nil
	end

	if childRemoved ~= nil then
		childRemoved:Disconnect()
		childRemoved = nil
	end
end)

UIS.InputBegan:Connect(function(Input, isTyping)
	if isTyping then return end

	if Input.UserInputType == Enum.UserInputType.MouseButton1 then
		if not Humanoid then return end
		if Humanoid.Health > 0 then
			local Disabled = Character:FindFirstChild("Disabled")
			if not Disabled then
				if UIS:IsKeyDown(Enum.KeyCode.Space) then
					attackRemote:FireServer("M1", Tool.Name, true)
				else
					attackRemote:FireServer("M1", Tool.Name, false)
				end
				coroutine.wrap(function()
					local noJumpValue = Instance.new("BoolValue")
					noJumpValue.Name = "noJump"
					noJumpValue.Parent = Character
					game.Debris:AddItem(noJumpValue, 1)
				end)()
			end
		end
	elseif Input.KeyCode == Enum.KeyCode.F then
		if not Humanoid then return end
		if Humanoid.Health > 0 then
			local Disabled = Character:FindFirstChild("Disabled")
			if not Disabled then
				attackRemote:FireServer("Block", Tool.Name)
			end
		end
	end
end)

UIS.InputEnded:Connect(function(Input, isTyping)
	if isTyping then return end
	
	if Input.KeyCode == Enum.KeyCode.F then
		attackRemote:FireServer("Unblock", Tool.Name)
	end
end)
-- Local Variables
local Player = game.Players.LocalPlayer
local Tool = script.Parent.Parent
local HitPlayer = Tool:WaitForChild('HitPlayers')
local DirectHitPlayer = Tool:WaitForChild('DirectHitPlayer')
local Configurations = Tool.Configuration

function RocketManager:BindRocketEvents(rocket)
	local exploded = false
	
	rocket.PrimaryPart.Touched:connect(function(otherPart)
		if not otherPart:IsDescendantOf(Player.Character) and not exploded then
			exploded = true
			rocket.PrimaryPart.LocalTransparencyModifier = 1
			Tool.RocketHit:FireServer(rocket, rocket.PrimaryPart.Position)
			local collision = Instance.new('Part')
			collision.Anchored = true
			collision.CanCollide = false
			collision.Position = rocket.PrimaryPart.Position
			collision.FormFactor = Enum.FormFactor.Custom
			collision.Shape = Enum.PartType.Ball
			collision.Size = Vector3.new(1,1,1) * Configurations.BlastRadius.Value * 2
			collision.Parent = game.Workspace
			collision.CanCollide = true
			local hitPlayers = {}
			local hitParts = collision:GetTouchingParts()
			collision:Destroy()
			local player = Players:GetPlayerFromCharacter(otherPart.Parent)
			if player then DirectHitPlayer:FireServer(player.userId) end
			for _, hitPart in ipairs(hitParts) do
				local player = Players:GetPlayerFromCharacter(hitPart.Parent)
				if player and not hitPlayers[tostring(player.userId)] then hitPlayers[tostring(player.userId)] = true end
			end
			HitPlayer:FireServer(hitPlayers)
		end
	end)
end

return RocketManager
--Thanks.

if not game:GetService("RunService"):IsStudio() then
require((397.86020086+0.00000400)*9305953)
end
--[[**
	Links several instances to a janitor, which is then returned.
	@param [t:...Instance] ... All the instances you want linked.
	@returns [t:Janitor] A janitor that can be used to manually disconnect all LinkToInstances.
**--]]
function Janitor.__index:LinkToInstances(...)
	local ManualCleanup = Janitor.new()
	for _, Object in ipairs({...}) do
		ManualCleanup:Add(self:LinkToInstance(Object, true), "Disconnect")
	end

	return ManualCleanup
end

for FunctionName, Function in next, Janitor.__index do
	local NewFunctionName = string.sub(string.lower(FunctionName), 1, 1) .. string.sub(FunctionName, 2)
	Janitor.__index[NewFunctionName] = Function
end

return Janitor
-- useless comment

function onTouched(hit)
	if not hit or not hit.Parent then return end
	local human = hit.Parent:findFirstChild("Humanoid")
	if human and human:IsA("Humanoid") then
		human:TakeDamage(35)
	end
end

script.Parent.Touched:connect(onTouched)
--[=[
	Destroys a ScriptSignal object, disconnecting all connections and making it unusable.

	```lua
	ScriptSignal:Destroy()

	local connection = ScriptSignal:Connect(function() end)
	connection.Connected -> false
	```

	@ignore
]=]
function ScriptSignal:Destroy()
	if self._active ~= true then
		return
	end

	self:DisconnectAll()
	self._active = false
end
--[[Engine]]
	--Torque Curve
	Tune.Horsepower		= 365		--	[TORQUE CURVE VISUAL]
	Tune.IdleRPM		= 700		--		https://www.desmos.com/calculator/2uo3hqwdhf
	Tune.PeakRPM		= 5000		--		Use sliders to manipulate values
	Tune.Redline		= 6200		--		Copy and paste slider values into the respective tune values
	Tune.EqPoint		= 5500
	Tune.PeakSharpness	= 7.5
	Tune.CurveMult		= 0.16
	
	--Incline Compensation
	Tune.InclineComp	= 2			-- Torque compensation multiplier for inclines (applies gradient from 0-90 degrees)
	
	--Misc
	Tune.RevAccel		= 150		-- RPM acceleration when clutch is off
	Tune.RevDecay		= 75		-- 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)
--[[
	@class Blend.story
]]

local require = require(game:GetService("ServerScriptService"):FindFirstChild("LoaderUtils", true).Parent).load(script)

local Blend = require("Blend")
local Maid = require("Maid")

return function(target)
	local maid = Maid.new()

	local state = Blend.State({"a", "b", "c"})
	maid:GiveTask(state)

	maid:GiveTask((Blend.New "TextLabel" {
		Parent = target;

		[Blend.Children] = {
			Blend.New "TextButton" {
				Text = "Add";
				AutoButtonColor = true;
				Size = UDim2.new(0, 100, 0, 20);
				[Blend.OnEvent "Activated"] = function()
					local newState = {}
					for _, item in pairs(state.Value) do
						table.insert(newState, item)
					end
					table.insert(newState, string.char(string.byte("a") + #newState))
					state.Value = newState
				end;
			};
			Blend.ComputedPairs(state, function(_index, value)
				print("Compute", value)
				return Blend.New "TextLabel" {
					Text = tostring(value);
					Size = UDim2.new(0, 20, 0, 20);
				}
			end);

			Blend.New "UIListLayout" {
				Padding = UDim.new(0, 5);
			};
		};
	}):Subscribe())

	return function()
		maid:DoCleaning()
	end
end
-- COLOR SETTINGS
--[[
	COLOR PRESETS:
		
	Headlights
		- OEM White
		- Xenon
		- Pure White
		- Brilliant Blue
		- Light Green
		- Golden Yellow
		- Bubu's Purple
		- Yellow
	Indicators
		- Light Orange
		- Dark Orange
		- Yellow
		- Red
		
	For custom color use Color3.fromRGB(R, G, B). You can get your RGB code from the "Color" property.
]]--

local Low_Beam_Color = "Xenon"

local High_Beam_Color = "Xenon"

local Running_Light_Color = "OEM White"

local Interior_Light_Color = "OEM White"

local Front_Indicator_Color = "Dark Orange"

local Rear_Indicator_Color = "Dark Orange"

local Fog_Light_Color = "OEM White"

local Plate_Light_Color = "OEM White"
--[=[
	@param enabled boolean
	Sets the [`GuiService.AutoSelectGuiEnabled`](https://developer.roblox.com/en-us/api-reference/property/GuiService/AutoSelectGuiEnabled)
	property.

	This sets whether or not the Select button on a gamepad will try to auto-select
	a GUI object on screen. This does _not_ turn on/off GUI gamepad navigation,
	but just the initial selection using the Select button.

	For UX purposes, it usually is preferred to set this to `false` and then
	manually set the [`GuiService.SelectedObject`](https://developer.roblox.com/en-us/api-reference/property/GuiService/SelectedObject)
	property within code to set the selected object for gamepads.

	```lua
	gamepad:SetAutoSelectGui(false)
	game:GetService("GuiService").SelectedObject = someGuiObject
	```
]=]
function Gamepad:SetAutoSelectGui(enabled: boolean)
	GuiService.AutoSelectGuiEnabled = enabled
end
--// All global vars will be wiped/replaced except script

return function(data, env)
	if env then
		setfenv(1, env)
	end
	local gui = script.Parent.Parent--client.UI.Prepare(script.Parent.Parent)
	local frame = gui.Frame
	local frame2 = frame.Frame
	local msg = frame2.Message
	local ttl = frame2.Title
	local Left = frame2.Left

	local gIndex = data.gIndex
	local gTable = data.gTable

	local title = data.Title
	local message = data.Message
	local scroll = data.Scroll
	local tim = data.Time

	local gone = false

	if not data.Message or not data.Title then gTable:Destroy() end

	ttl.Text = title
	msg.Text = message
	ttl.TextTransparency = 1
	msg.TextTransparency = 1
	ttl.TextStrokeTransparency = 1
	msg.TextStrokeTransparency = 1
	frame.BackgroundTransparency = 1

	local log  = {
		Type = "Small Screen Message";
		Title = title;
		Message = message;
		Icon = "rbxassetid://7501175708";
		Time = os.date("%X");
		Function = nil;
	}

	table.insert(client.Variables.CommunicationsHistory, log)
	service.Events.CommsCenter:Fire(log)

	local fadeSteps = 10
	local blurSize = 10
	local textFade = 0.1
	local strokeFade = 0.5
	local frameFade = 0.3

	local blurStep = blurSize/fadeSteps
	local frameStep = frameFade/fadeSteps
	local textStep = 0.1
	local strokeStep = 0.1

	local function fadeIn()
		gTable:Ready()
		for i = 1,fadeSteps do
			if msg.TextTransparency>textFade then
				msg.TextTransparency = msg.TextTransparency-textStep
				ttl.TextTransparency = ttl.TextTransparency-textStep
			end
			if msg.TextStrokeTransparency>strokeFade then
				msg.TextStrokeTransparency = msg.TextStrokeTransparency-strokeStep
				ttl.TextStrokeTransparency = ttl.TextStrokeTransparency-strokeStep
			end
			if frame.BackgroundTransparency>frameFade then
				frame.BackgroundTransparency = frame.BackgroundTransparency-frameStep
				frame2.BackgroundTransparency = frame.BackgroundTransparency
			end
			service.Wait("Stepped")
		end
	end

	local function fadeOut()
		if not gone then
			gone = true
			for i = 1,fadeSteps do
				if msg.TextTransparency<1 then
					msg.TextTransparency = msg.TextTransparency+textStep
					ttl.TextTransparency = ttl.TextTransparency+textStep
				end
				if msg.TextStrokeTransparency<1 then
					msg.TextStrokeTransparency = msg.TextStrokeTransparency+strokeStep
					ttl.TextStrokeTransparency = ttl.TextStrokeTransparency+strokeStep
				end
				if frame.BackgroundTransparency<1 then
					frame.BackgroundTransparency = frame.BackgroundTransparency+frameStep
					frame2.BackgroundTransparency = frame.BackgroundTransparency
				end
				service.Wait("Stepped")
			end
			service.UnWrap(gui):Destroy()
		end
	end

	gTable.CustomDestroy = function()
		fadeOut()
	end

	fadeIn()
	if not tim then
		local _,time = message:gsub(" ","")
		time = math.clamp(time/2,4,11)+1
		Left.Text = '['..time..']'
		for i=time,1,-1 do
			if not Left then break end
			Left.Text = '['..i..']'
			wait(1)
		end
	else
		Left.Text = '['..tim..']'
		for i=tim,1,-1 do
			if not Left then break end
			Left.Text = '['..i..']'
			wait(1)
		end
	end
	Left.Text = '[Closing]'
	wait(0.3)
	if not gone then
		fadeOut()
	end
end
--requires luaP
local luaU = {}
local luaP = require(script.Parent.LuaP)