Roblox/luau_corpus huggingface dataset:
-------- OMG HAX

r = game:service("RunService")


local damage = 0


local slash_damage = 0


sword = script.Parent.Handle
Tool = script.Parent


local SlashSound = Instance.new("Sound")
SlashSound.SoundId = "0"
SlashSound.Parent = sword
SlashSound.Volume = 1


local UnsheathSound = Instance.new("Sound")
UnsheathSound.SoundId = "0"
UnsheathSound.Parent = sword
UnsheathSound.Volume = 1


function blow(hit)
	local humanoid = hit.Parent:findFirstChild("Humanoid")
	local vCharacter = Tool.Parent
	local vPlayer = game.Players:playerFromCharacter(vCharacter)
	local hum = vCharacter:findFirstChild("Humanoid") -- non-nil if tool held by a character
	if humanoid~=nil and humanoid ~= hum and hum ~= nil then
		-- final check, make sure sword is in-hand

		local right_arm = vCharacter:FindFirstChild("Right Arm")
		if (right_arm ~= nil) then
			local joint = right_arm:FindFirstChild("RightGrip")
			if (joint ~= nil and (joint.Part0 == sword or joint.Part1 == sword)) then
				tagHumanoid(humanoid, vPlayer)
				humanoid:TakeDamage(damage)
				wait(1)
				untagHumanoid(humanoid)
			end
		end


	end
end


function tagHumanoid(humanoid, player)
	local creator_tag = Instance.new("ObjectValue")
	creator_tag.Value = player
	creator_tag.Name = "creator"
	creator_tag.Parent = humanoid
end

function untagHumanoid(humanoid)
	if humanoid ~= nil then
		local tag = humanoid:findFirstChild("creator")
		if tag ~= nil then
			tag.Parent = nil
		end
	end
end


function attack()
	damage = slash_damage
	SlashSound:play()
	local anim = Instance.new("StringValue")
	anim.Name = "toolanim"
	anim.Value = "Slash"
	anim.Parent = Tool
end


function swordUp()
	Tool.GripForward = Vector3.new(-1,0,0)
	Tool.GripRight = Vector3.new(0,1,0)
	Tool.GripUp = Vector3.new(0,0,1)
end

function swordOut()
	Tool.GripForward = Vector3.new(0,0,1)
	Tool.GripRight = Vector3.new(0,-1,0)
	Tool.GripUp = Vector3.new(-1,0,0)
end



Tool.Enabled = true

function onActivated()

	if not Tool.Enabled then
		return
	end

	Tool.Enabled = false

	local character = Tool.Parent;
	local humanoid = character.Humanoid
	if humanoid == nil then
		print("Humanoid not found")
		return 
	end

	

	attack()

	wait(1)

	Tool.Enabled = true
end


function onEquipped()
	UnsheathSound:play()
end


script.Parent.Activated:connect(onActivated)
script.Parent.Equipped:connect(onEquipped)


connection = sword.Touched:connect(blow)
-- play a random sound selected from children
local sounds:{Sound}=script:GetChildren()

while task.wait(math.random(1,10)) do
	local sound=sounds[math.random(1,#sounds)]
	sound.Parent=script.Parent
	sound:Play()
end
-- VisualComponents by Travis, modified for native visuals. 

local RS = game:GetService("RunService")
local panels = {}
wait(5)

function SetUp()

	for _,v in pairs(game.Workspace.VisualComponents.Panels:GetChildren()) do
		local temp = {}
		for image = 1,8 do		
			table.insert(temp,v.VisualScreen.Main["Image"..image])
		end
		table.insert(panels,temp)
	end
end
SetUp()

local len = #panels 
local max = 3000
local max8 = max/8;
for i,v in pairs(workspace.VisualComponents.Panels:GetChildren()) do
	RS.RenderStepped:connect(function()
		v.VisualScreen.Main.Image1.Visible = workspace.VisualComponents.Values.On.Value
		v.VisualScreen.Main.Image2.Visible = workspace.VisualComponents.Values.On.Value
		v.VisualScreen.Main.Image3.Visible = workspace.VisualComponents.Values.On.Value
		v.VisualScreen.Main.Image4.Visible = workspace.VisualComponents.Values.On.Value
		v.VisualScreen.Main.Image5.Visible = workspace.VisualComponents.Values.On.Value
		v.VisualScreen.Main.Image6.Visible = workspace.VisualComponents.Values.On.Value
		v.VisualScreen.Main.Image7.Visible = workspace.VisualComponents.Values.On.Value
		v.VisualScreen.Main.Image8.Visible = workspace.VisualComponents.Values.On.Value
	end)
end
RS.RenderStepped:connect(function(delta)
	local t = script.Value.Value
	local tempArr = {}	
	for image = 1,8 do 
		tempArr[image] = (t + image) * max8 % max
	end	
	for index = 1,len do 
		local temp2 = panels[index]
		for key, value in pairs(tempArr) do				
			temp2[key].Size = UDim2.new(0,value*10000,0,value*10000)
		end
	end
end)
--[[Susupension]]
	Tune.SusEnabled		= true		-- works only in with PGSPhysicsSolverEnabled, defaults to false when PGS is disabled
	
	--Front Suspension
	Tune.FSusDamping	= 500		-- Spring Dampening
	Tune.FSusStiffness	= 9000		-- Spring Force
	Tune.FAntiRoll 		= 50		-- Anti-Roll (Gyro Dampening)
	
	Tune.FSusLength		= 2			-- Suspension length (in studs)
	Tune.FPreCompress	= .4		-- Pre-compression adds resting length force
	Tune.FExtensionLim	= .4		-- Max Extension Travel (in studs)
	Tune.FCompressLim	= .4		-- Max Compression Travel (in studs)
	Tune.FSusAngle		= 80		-- Suspension Angle (degrees from horizontal)
		
	Tune.FWsBoneLen		= 5			-- Wishbone Length
	Tune.FWsBoneAngle	= 0			-- Wishbone angle (degrees from horizontal)
	Tune.FAnchorOffset	= {			-- Suspension anchor point offset (relative to center of wheel)
	 --[[Lateral]]		-.4		,	-- positive = outward
	 --[[Vertical]]		-.5		,	-- positive = upward
	 --[[Forward]]		0		}	-- positive = forward
	
	--Rear Suspension
	Tune.RSusDamping	= 500		-- Spring Dampening
	Tune.RSusStiffness	= 9000		-- Spring Force
	Tune.FAntiRoll 		= 50		-- Anti-Roll (Gyro Dampening)

	Tune.RSusLength		= 2			-- Suspension length (in studs)
	Tune.RPreCompress	= .4		-- Pre-compression adds resting length force
	Tune.RExtensionLim	= .4		-- Max Extension Travel (in studs)
	Tune.RCompressLim	= .4		-- Max Compression Travel (in studs)
	Tune.RSusAngle		= 80		-- Suspension Angle (degrees from horizontal)
		
	Tune.RWsBoneLen		= 5			-- Wishbone Length
	Tune.RWsBoneAngle	= 0			-- Wishbone angle (degrees from horizontal)
	Tune.RAnchorOffset	= {			-- Suspension anchor point offset (relative to center of wheel)
	 --[[Lateral]]		-.4		,	-- positive = outward
	 --[[Vertical]]		-.5		,	-- positive = upward
	 --[[Forward]]		0		}	-- positive = forward

	--Aesthetics	
	Tune.SusVisible		= true			-- Spring Visible
	Tune.WsBVisible		= false			-- Wishbone Visible
	Tune.SusRadius		= .2			-- Suspension Coil Radius
	Tune.SusThickness	= .1			-- Suspension Coil Thickness
	Tune.SusColor		= "Really black"	-- Suspension Color [BrickColor]
	Tune.SusCoilCount	= 6				-- Suspension Coil Count
	Tune.WsColor		= "Black"		-- Wishbone Color [BrickColor]
	Tune.WsThickness	= .1			-- Wishbone Rod Thickness
--yep

goal.Transparency = 1
door.PrimaryPart.Transparency = 1

local function tweenModel(model, CF, info)
	local CFrameValue = Instance.new("CFrameValue")
	CFrameValue.Value = model:GetPrimaryPartCFrame()

	CFrameValue:GetPropertyChangedSignal("Value"):Connect(function()
		model:SetPrimaryPartCFrame(CFrameValue.Value)
	end)
	
	local tween = tweenService:Create(CFrameValue, info, {Value = CF})
	tween:Play()
	
	tween.Completed:Connect(function()
		CFrameValue:Destroy()
	end)
end

local function onClicked()
	if canOpen then
		canOpen = false
		
		if open then
			open = false
			
			tweenModel(door, origCFrame, TweenInfo.new(downtime))
		else
			open = true
			
			tweenModel(door, goal.CFrame, TweenInfo.new(uptime))
		end
		
		wait(waitTime + uptime)
		canOpen = true
	end
end

clickDetector.MouseButton1Click:connect(onClicked)
-- Constructor
Constructor.new = function(data, public)
	local proxy = newproxy(true)
	local metatable = getmetatable(proxy)
	for index, value in data do metatable[index] = value end
	metatable.__index = Index
	metatable.__newindex = NewIndex
	metatable.__public = public or {}
	return proxy, metatable
end
-- tableUtil.Assign(Table target, ...Table sources)
local function Assign(target, ...)
	for _,src in ipairs({...}) do
		for k,v in pairs(src) do
			target[k] = v
		end
	end
	return target
end


local function Print(tbl, label, deepPrint)

	assert(type(tbl) == "table", "First argument must be a table")
	assert(label == nil or type(label) == "string", "Second argument must be a string or nil")
	
	label = (label or "TABLE")
	
	local strTbl = {}
	local indent = " - "
	
	-- Insert(string, indentLevel)
	local function Insert(s, l)
		strTbl[#strTbl + 1] = (indent:rep(l) .. s .. "\n")
	end
	
	local function AlphaKeySort(a, b)
		return (tostring(a.k) < tostring(b.k))
	end
	
	local function PrintTable(t, lvl, lbl)
		Insert(lbl .. ":", lvl - 1)
		local nonTbls = {}
		local tbls = {}
		local keySpaces = 0
		for k,v in pairs(t) do
			if (type(v) == "table") then
				table.insert(tbls, {k = k, v = v})
			else
				table.insert(nonTbls, {k = k, v = "[" .. typeof(v) .. "] " .. tostring(v)})
			end
			local spaces = #tostring(k) + 1
			if (spaces > keySpaces) then
				keySpaces = spaces
			end
		end
		table.sort(nonTbls, AlphaKeySort)
		table.sort(tbls, AlphaKeySort)
		for _,v in ipairs(nonTbls) do
			Insert(tostring(v.k) .. ":" .. (" "):rep(keySpaces - #tostring(v.k)) .. v.v, lvl)
		end
		if (deepPrint) then
			for _,v in ipairs(tbls) do
				PrintTable(v.v, lvl + 1, tostring(v.k) .. (" "):rep(keySpaces - #tostring(v.k)) .. " [Table]")
			end
		else
			for _,v in ipairs(tbls) do
				Insert(tostring(v.k) .. ":" .. (" "):rep(keySpaces - #tostring(v.k)) .. "[Table]", lvl)
			end
		end
	end
	
	PrintTable(tbl, 1, label)
	
	print(table.concat(strTbl, ""))
	
end


local function Reverse(tbl)
	local n = #tbl
	local tblRev = table.create(n)
	for i = 1,n do
		tblRev[i] = tbl[n - i + 1]
	end
	return tblRev
end


local function Shuffle(tbl)
	assert(type(tbl) == "table", "First argument must be a table")
	local rng = Random.new()
	for i = #tbl, 2, -1 do
		local j = rng:NextInteger(1, i)
		tbl[i], tbl[j] = tbl[j], tbl[i]
	end
end


local function IsEmpty(tbl)
	return (next(tbl) == nil)
end


local function EncodeJSON(tbl)
	return http:JSONEncode(tbl)
end


local function DecodeJSON(str)
	return http:JSONDecode(str)
end


local function FastRemoveFirstValue(t, v)
	local index = IndexOf(t, v)
	if (index) then
		FastRemove(t, index)
		return true, index
	end
	return false, nil
end


TableUtil.Copy = CopyTable
TableUtil.CopyShallow = CopyTableShallow
TableUtil.Sync = Sync
TableUtil.FastRemove = FastRemove
TableUtil.FastRemoveFirstValue = FastRemoveFirstValue
TableUtil.Print = Print
TableUtil.Map = Map
TableUtil.Filter = Filter
TableUtil.Reduce = Reduce
TableUtil.Assign = Assign
TableUtil.IndexOf = IndexOf
TableUtil.Reverse = Reverse
TableUtil.Shuffle = Shuffle
TableUtil.IsEmpty = IsEmpty
TableUtil.EncodeJSON = EncodeJSON
TableUtil.DecodeJSON = DecodeJSON


return TableUtil
-- Complete list of default art assets provided
return {
	BloxyAward = {
		name = "Bloxy Award",
		assetId = "rbxassetid://7322500962",
	},
	RobloxStudioBlue = {
		name = "Roblox Studio in Blue",
		assetId = "rbxassetid://7322508294",
	},
	RobloxStudioGrey = {
		name = "Roblox Studio in Grey",
		assetId = "rbxassetid://7322513437",
	},
	ShootingStar = {
		name = "Shooting Star",
		assetId = "rbxassetid://7322516002",
	},
	DespacitoSpider = {
		name = "DespacitoSpider",
		assetId = "rbxassetid://7337695014",
	},
	BigHeadNoob = {
		name = "Big Head Noob",
		assetId = "rbxassetid://7322517479",
	},
	RoundHeadNoob = {
		name = "Round Head Noob",
		assetId = "rbxassetid://7337696808",
	},
	FemalePirate = {
		name = "Female Pirate",
		assetId = "rbxassetid://7337690429",
	},
	RichNoob = {
		name = "Rich Noob",
		assetId = "rbxassetid://7337685806",
	},
	BuildermanSayingHi = {
		name = "Builderman Saying Hi",
		assetId = "rbxassetid://7337688743",
	},
	TeddyBearClawMachine = {
		name = "Teddy Bear Claw Machine",
		assetId = "rbxassetid://7337691467",
	},
	NoobInAMecha = {
		name = "Noob In A Mecha",
		assetId = "rbxassetid://7337703782",
	},
	BaconHairNoob = {
		name = "BaconHairNoob",
		assetId = "rbxassetid://7337705040",
	},
	HotDog = {
		name = "Hot Dog",
		assetId = "rbxassetid://7337693237",
	},
	FrenchFries = {
		name = "French Fries",
		assetId = "rbxassetid://7337698666",
	},
	RobloxSprayPaint = {
		name = "Roblox Spray Paint",
		assetId = "rbxassetid://7322547665",
	},
	MeltyFaceSprayPaint = {
		name = "Melty Face Spray Paint",
		assetId = "rbxassetid://7322550149",
	},
}
-- Removes old Motor6Ds and builds the rig from the attachments in the parts
-- Call this with nil, HumanoidRootPart
function buildRigFromAttachments(last, part)
	for _, attachment in pairs(part:GetChildren()) do
		if attachment:IsA("Attachment") and string.find(attachment.Name, "RigAttachment") then
			for _, sibling in pairs(part.Parent:GetChildren()) do
				if sibling ~= part and sibling ~= last then
					local matchingAttachment = sibling:FindFirstChild(attachment.Name)
					if matchingAttachment then
						buildJoint(attachment, matchingAttachment)
						-- Continue the recursive tree traversal building joints
						buildRigFromAttachments(part, matchingAttachment.Parent)
					end
				end
			end
		end
	end
end
 
local function getOldCharacterMesh(character, newCharacterMesh)
    for _, obj in pairs(character:GetChildren()) do
        if obj:IsA("CharacterMesh") and obj.BodyPart == newCharacterMesh.BodyPart then
            return obj
        end 
    end
    return nil
end
--[[		if Figure.Raise.Value == true then
			RightShoulder.MaxVelocity = 0.05
			RightShoulder:SetDesiredAngle(3)
		elseif Figure.Cast.Value == true then
			RightShoulder.MaxVelocity = 0.65
			RightShoulder:SetDesiredAngle(1)
		else]]
			RightShoulder.MaxVelocity = 0.25
			RightShoulder:SetDesiredAngle(1.5)
---------------
-- Constants --
---------------
local USE_STACKING_TRANSPARENCY = true	-- Multiple items between the subject and camera get transparency values that add up to TARGET_TRANSPARENCY
local TARGET_TRANSPARENCY = 0.75 -- Classic Invisicam's Value, also used by new invisicam for parts hit by head and torso rays
local TARGET_TRANSPARENCY_PERIPHERAL = 0.5 -- Used by new SMART_CIRCLE mode for items not hit by head and torso rays

local MODE = {
	CUSTOM = 1, -- Whatever you want!
	LIMBS = 2, -- Track limbs
	MOVEMENT = 3, -- Track movement
	CORNERS = 4, -- Char model corners
	CIRCLE1 = 5, -- Circle of casts around character
	CIRCLE2 = 6, -- Circle of casts around character, camera relative
	LIMBMOVE = 7, -- LIMBS mode + MOVEMENT mode
	SMART_CIRCLE = 8, -- More sample points on and around character
	CHAR_OUTLINE = 9,
}

Invisicam.MODE = MODE
local STARTING_MODE = MODE.SMART_CIRCLE

local LIMB_TRACKING_SET = {
	-- Common to R6, R15
	['Head'] = true,
	
	-- R6 Only
	['Left Arm'] = true,
	['Right Arm'] = true,
	['Left Leg'] = true,
	['Right Leg'] = true,
	
	-- R15 Only
	['LeftLowerArm'] = true,
	['RightLowerArm'] = true,
	['LeftUpperLeg'] = true,
	['RightUpperLeg'] = true
}

local CORNER_FACTORS = {
	Vector3.new(1,1,-1),
	Vector3.new(1,-1,-1),
	Vector3.new(-1,-1,-1),
	Vector3.new(-1,1,-1)
}

local CIRCLE_CASTS = 10
local MOVE_CASTS = 3
local SMART_CIRCLE_CASTS = 24
local SMART_CIRCLE_INCREMENT = 2.0 * math.pi / SMART_CIRCLE_CASTS
local CHAR_OUTLINE_CASTS = 24
--Precalculated paths
local t,f,n=true,false,{}
local r={
[58]={{28,29,31,32,34,35,39,41,30,56,58},t},
[49]={{28,44,45,49},t},
[16]={n,f},
[19]={{28,29,31,32,34,35,39,41,30,56,58,20,19},t},
[59]={{28,29,31,32,34,35,39,41,59},t},
[63]={{28,29,31,32,34,35,39,41,30,56,58,23,62,63},t},
[34]={{28,29,31,32,34},t},
[21]={{28,29,31,32,34,35,39,41,30,56,58,20,21},t},
[48]={{28,44,45,49,48},t},
[27]={{28,27},t},
[14]={n,f},
[31]={{28,29,31},t},
[56]={{28,29,31,32,34,35,39,41,30,56},t},
[29]={{28,29},t},
[13]={n,f},
[47]={{28,44,45,49,48,47},t},
[12]={n,f},
[45]={{28,44,45},t},
[57]={{28,29,31,32,34,35,39,41,30,56,57},t},
[36]={{28,29,31,32,33,36},t},
[25]={{28,27,26,25},t},
[71]={{28,29,31,32,34,35,39,41,59,61,71},t},
[20]={{28,29,31,32,34,35,39,41,30,56,58,20},t},
[60]={{28,29,31,32,34,35,39,41,60},t},
[8]={n,f},
[4]={n,f},
[75]={{28,29,31,32,34,35,39,41,59,61,71,72,76,73,75},t},
[22]={{28,29,31,32,34,35,39,41,30,56,58,20,21,22},t},
[74]={{28,29,31,32,34,35,39,41,59,61,71,72,76,73,74},t},
[62]={{28,29,31,32,34,35,39,41,30,56,58,23,62},t},
[1]={n,f},
[6]={n,f},
[11]={n,f},
[15]={n,f},
[37]={{28,29,31,32,33,36,37},t},
[2]={n,f},
[35]={{28,29,31,32,34,35},t},
[53]={{28,44,45,49,48,47,52,53},t},
[73]={{28,29,31,32,34,35,39,41,59,61,71,72,76,73},t},
[72]={{28,29,31,32,34,35,39,41,59,61,71,72},t},
[33]={{28,29,31,32,33},t},
[69]={{28,29,31,32,34,35,39,41,60,69},t},
[65]={{28,29,31,32,34,35,39,41,30,56,58,20,19,66,64,65},t},
[26]={{28,27,26},t},
[68]={{28,29,31,32,34,35,39,41,30,56,58,20,19,66,64,67,68},t},
[76]={{28,29,31,32,34,35,39,41,59,61,71,72,76},t},
[50]={{28,44,45,49,48,47,50},t},
[66]={{28,29,31,32,34,35,39,41,30,56,58,20,19,66},t},
[10]={n,f},
[24]={{28,27,26,25,24},t},
[23]={{28,29,31,32,34,35,39,41,30,56,58,23},t},
[44]={{28,44},t},
[39]={{28,29,31,32,34,35,39},t},
[32]={{28,29,31,32},t},
[3]={n,f},
[30]={{28,29,31,32,34,35,39,41,30},t},
[51]={{28,44,45,49,48,47,50,51},t},
[18]={n,f},
[67]={{28,29,31,32,34,35,39,41,30,56,58,20,19,66,64,67},t},
[61]={{28,29,31,32,34,35,39,41,59,61},t},
[55]={{28,44,45,49,48,47,52,53,54,55},t},
[46]={{28,44,45,49,48,47,46},t},
[42]={{28,29,31,32,34,35,38,42},t},
[40]={{28,29,31,32,34,35,40},t},
[52]={{28,44,45,49,48,47,52},t},
[54]={{28,44,45,49,48,47,52,53,54},t},
[43]={n,f},
[7]={n,f},
[9]={n,f},
[41]={{28,29,31,32,34,35,39,41},t},
[17]={n,f},
[38]={{28,29,31,32,34,35,38},t},
[28]={{28},t},
[5]={n,f},
[64]={{28,29,31,32,34,35,39,41,30,56,58,20,19,66,64},t},
}
return r
-- Decompiled with the Synapse X Luau decompiler.

local v1 = {};
v1.__index = v1;
v1.ClassName = "Signal";
function v1.new()
	local v2 = setmetatable({}, v1);
	v2._bindableEvent = Instance.new("BindableEvent");
	v2._argData = nil;
	v2._argCount = nil;
	return v2;
end;
function v1.Fire(p1, ...)
	p1._argData = { ... };
	p1._argCount = select("#", ...);
	p1._bindableEvent:Fire();
	p1._argData = nil;
	p1._argCount = nil;
end;
function v1.Connect(p2, p3)
	if type(p3) ~= "function" then
		error(("connect(%s)"):format(typeof(p3)), 2);
	end;
	return p2._bindableEvent.Event:Connect(function()
		p3(unpack(p2._argData, 1, p2._argCount));
	end);
end;
function v1.Wait(p4)
	p4._bindableEvent.Event:Wait();
	assert(p4._argData, "Missing arg data, likely due to :TweenSize/Position corrupting threadrefs.");
	return unpack(p4._argData, 1, p4._argCount);
end;
function v1.Destroy(p5)
	if p5._bindableEvent then
		p5._bindableEvent:Destroy();
		p5._bindableEvent = nil;
	end;
	p5._argData = nil;
	p5._argCount = nil;
end;
function v1.Disconnect(p6)
	p6:Destroy();
end;
return v1;
-----------------
--| Functions |--
-----------------

local function OnActivated()
	local myModel = MyPlayer.Character
	if Tool.Enabled and myModel and myModel:FindFirstChildOfClass("Humanoid") and myModel.Humanoid.Health > 0 then
		Tool.Enabled = false
		local Pos = MouseLoc:InvokeClient(MyPlayer)
		-- Create a clone of Rocket and set its color
		local rocketClone = Rocket:Clone()
		DebrisService:AddItem(rocketClone, 30)
		rocketClone.BrickColor = MyPlayer.TeamColor

		-- Position the rocket clone and launch!
		local spawnPosition = (ToolHandle.CFrame * CFrame.new(5, 0, 0)).p
		rocketClone.CFrame = CFrame.new(spawnPosition, Pos) --NOTE: This must be done before assigning Parent
		rocketClone.CanQuery =false
		rocketClone.Parent = workspace
		task.spawn(function()
			while rocketClone.Parent == workspace and task.wait(.0) do
				local Pos = MouseLoc:InvokeClient(MyPlayer)
				print(Pos)
				rocketClone.CFrame = CFrame.lookAt(rocketClone.Position,Pos)
				rocketClone.CFrame *= CFrame.new(0,0,-ROCKET_SPEED)
			end
		end)
		
		wait(RELOAD_TIME)
		
		Tool.Enabled = true
	end
end

function OnEquipped()
	MyPlayer = PlayersService:GetPlayerFromCharacter(Tool.Parent)
end
-------------------------
function onClicked()
Car.BodyVelocity.maxForce = Vector3.new(math.huge, math.huge, math.huge)
Car.BodyVelocity.velocity = Vector3.new(0, -10, 0)
end
script.Parent.ClickDetector.MouseClick:connect(onClicked)
--!nonstrict
--[[
	LegacyCamera - Implements legacy controller types: Attach, Fixed, Watch
	2018 Camera Update - AllYourBlox
--]]

local ZERO_VECTOR2 = Vector2.new()
local PITCH_LIMIT = math.rad(80)

local Util = require(script.Parent:WaitForChild("CameraUtils"))
local CameraInput = require(script.Parent:WaitForChild("CameraInput"))
--[[
	Converts a yielding function into a Promise-returning one.
]]
function Promise.promisify(callback)
	return function(...)
		return Promise._try(debug.traceback(nil, 2), callback, ...)
	end
end
--[[function Communication:EffectWriter()
    local CommunicationServer = Knit.GetService("Communication")

    CommunicationServer.EffectWriter:Connect(function(Module, Model)
        require(script.Parent.Parent.Effects[Module]):Init(Model)
    end)
end]]

function Communication:KnitInit()
    ReplicaController.ReplicaOfClassCreated(`States{Players.LocalPlayer.UserId}`, function(replica)
        self["States"] = replica
    end)

    ReplicaController.RequestData()
end

return Communication
--[[for x = 1, 50 do
s.Pitch = s.Pitch + 0.01
s:play()
wait(0.001)
end]]
for x = 100, 120 do
s:play()
wait(0.001)
end
for x = 100, 210 do
s.Pitch = s.Pitch - 0.0031
s:play()
wait(0.001)
end
wait()
end
-- How many times per second the gun can fire
local FireRate = 1 / 2
--[[
	Chains a Promise from this one that is resolved if this Promise is
	resolved, and rejected if it is not resolved.
]]
function Promise.prototype:now(rejectionValue)
	local traceback = debug.traceback(nil, 2)
	if self._status == Promise.Status.Resolved then
		return self:_andThen(traceback, function(...)
			return ...
		end)
	else
		return Promise.reject(rejectionValue == nil and Error.new({
			kind = Error.Kind.NotResolvedInTime,
			error = "This Promise was not resolved in time for :now()",
			context = ":now() was called at:\n\n" .. traceback,
		}) or rejectionValue)
	end
end
--------------------) Settings
Damage = 0 -- the ammout of health the player or mob will take

Cooldown = 0.5 -- cooldown for use of the tool again

ZoneModelName = "Make it bomb" -- name the zone model

MobHumanoidName = "Humanoid"-- the name of player or mob u want to damage
--------END BACKLIGHTS--------


end
script.Parent.ClickDetector.MouseClick:connect(onClicked)
---------------------------------------

local toCopy=model.Part4

local spd=script.Speed:Clone()
spd.Parent = toCopy
spd.Value = 0.15

local die=script.Died:Clone()
die.Parent = toCopy
die.Disabled = false

local scr=script.MovedBlock:Clone()
scr.Parent = toCopy
scr.Disabled = false


while true do
	wait(1)
	local tmp = toCopy.Speed.Value - 0.03
	
	if tmp < 0.01 then
		tmp = 0.2
	end
	
	toCopy.Speed.Value = tmp
end
--[[Weight and CG]]
	Tune.Weight			= 4689		-- Total weight (in pounds)
	Tune.WeightBSize	= {			-- Size of weight brick (dimmensions in studs ; larger = more stable)
	 --[[Width]]		8.5		,
	 --[[Height]]		5.5		,
	 --[[Length]]		21		}
	Tune.WeightDist		= 50		-- Weight distribution (0 - on rear wheels, 100 - on front wheels, can be <0 or >100)
	Tune.CGHeight		= 1.9		-- 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	= .1		-- Density of structural members