Prompt: -- Signal class

Response:
local Signal = {}
Signal.__index = Signal

function Signal.new(janitor)
	local self = setmetatable({
		_handlerListHead = false,
		_proxyHandler = nil,
	}, Signal)
	if janitor then
		janitor:Add(self)
	end
	return self
end

function Signal.Wrap(rbxScriptSignal, janitor)
	assert(typeof(rbxScriptSignal) == "RBXScriptSignal", "Argument #1 to Signal.Wrap must be a RBXScriptSignal; got " .. typeof(rbxScriptSignal))
	local signal = Signal.new(janitor)
	signal._proxyHandler = rbxScriptSignal:Connect(function(...)
		signal:Fire(...)
	end)
	return signal
end

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

function Signal:Connect(fn)
	local connection = Connection.new(self, fn)
	if self._handlerListHead then
		connection._next = self._handlerListHead
		self._handlerListHead = connection
	else
		self._handlerListHead = connection
	end
	return connection
end

function Signal:GetConnections()
	local items = {}
	local item = self._handlerListHead
	while item do
		table.insert(items, item)
		item = item._next
	end
	return items
end


Prompt:
-- не забыть бы убрать!!!
--local Debris = game:GetService("Debris") -- это сервисная команда
--local TimeForDestroy = 10*60 -- минимальное время жизни (10 минут = 10*60)

Response:
local turret = require(game.ServerScriptService.GAVturret)

local V1 = 10 -- скорострельность
local SPEED = 400 -- скорость снарядов
local MAX_DIST = 70 -- дистанция срабатывания
local DAMAGE = 10 -- наносимые повреждения
local TYPE = "SINGLE" -- AOE, SINGLE

wait()
me=script.Parent
pos = me.PrimaryPart

while true do
	local target = turret.findNearestHead(pos,MAX_DIST) --findNearestHead()
	if target ~= nil then
		if target ~= nil and target.Parent ~= nil and target.Parent.Humanoid.Health>0 then
			alt=turret.lookAt(target.Position,pos.Position) -- пушка только по горизотали!
			me:SetPrimaryPartCFrame(alt) -- направляем туда пушку
			-- вычисляем направление выстрела
			alt=turret.lookAtY(target.Position,me.Rocket.Position)-- ракета (пусковой механизм) полностью ориентируется
			me.Rocket.CFrame= alt
			-- в снаряд суём чья турель
			if me.Rocket:FindFirstChild("Owner") == nil then
				tmp=me.Owner:Clone()
				tmp.Parent = me.Rocket
			end
			turret.Fire(me.Rocket,DAMAGE,SPEED, TYPE) -- стреляем (место снаряда, повреждение) -- добавить создателя пушки
			wait()
		end
	end
	wait(V1/10)
end


Prompt:
--[[

	Returns true if table is array and false for dictionary

	Functions.IsArray(
		table,					<-- |REQ| 	Table
	)

--]]

Response:
return function(array)
	--- Loop through "array"
	for i, v in pairs(array) do
		if type(i) ~= "number" or array[i] == nil then
			return false
		elseif i >= 10 then
			break
		end
	end

	--- Checks out! It's an array.
	return true
end


Prompt: --WeldRec(P.Parent.Lights)

Response:
for _,v in pairs(weldedParts) do
	if v:IsA("BasePart") then
		v.Anchored = false
	end
end

script:Destroy()


Prompt: -- [[ Services ]]

Response:
local RunService = game:GetService("RunService")
local CollectionService = game:GetService("CollectionService")
local ReplicatedStorage = game:GetService("ReplicatedStorage")

local Modules = ReplicatedStorage:WaitForChild("SharedModules")

local Thread = require(Modules.Thread)


Prompt:
--[[
	Higher order component that lets the wrapped component consume the InputContext.
]]

Response:
local function withInputContext(component)
	return function(props)
		if props.inputContext then
			warn("Child component has a prop named `inputContext` and will be overriden by InputContext.")
		end

		return Roact.createElement(Context.Consumer, {
			render = function(inputContext)
				local mergedProps = Cryo.Dictionary.join({ inputContext = inputContext }, props)

				return Roact.createElement(component, mergedProps)
			end,
		})
	end
end

local InputContext = {
	Consumer = Context.Consumer,
	Provider = withConfiguration(InputContextProvider),
	withInputContext = withInputContext,
}

return InputContext


Prompt: -- Variables (best not to touch these!)

Response:
local button = script.Parent
local car = script.Parent.Parent.Car.Value
local sound = script.Parent.StartD
local startsound = script.Parent.StartChime
sound.Parent = car.DriveSeat -- What brick the start sound is playing from.
button.MouseButton1Click:connect(function() -- Event when the button is clicked
	if script.Parent.Text == "Engine: OFF" then -- If the text says it's off then..
		startsound:play()
wait(1)
		sound:Play()
		wait(2.7)
		script.Parent.Parent.IsOn.Value = true -- The car is is on, or in other words, start up the car.
		button.Text = "Engine: On"
		script.Parent.Parent.AC6C_Stock_Gauges:TweenPosition(UDim2.new(0, 0,-0.3, 0), "Out", "Quad", 1)

		wait(3)
		script.Parent.Parent.FollowNotification:TweenPosition(UDim2.new(1, -200,1, -100), "Out", "Quad", 1)
		script.Parent.Notif:play()
		sound:stop()
		startsound:Stop()

		wait(3)
		script.Parent.Parent.FollowNotification:TweenPosition(UDim2.new(1, 0,1, -100), "Out", "Quad", 1)

	else -- If it's on then when you click the button,
		script.Parent.Parent.IsOn.Value = false -- The car is turned off.

		button.Text = "Engine: OFF"
		script.Parent.EngineOff:play()

	end -- Don't touch this.
end) -- And don't touch this either.


Prompt: --[[Wheel Alignment]]

Response:
	--[Don't physically apply alignment to wheels]
	--[Values are in degrees]
	Tune.FCamber		= -8
	Tune.RCamber		= -8
	Tune.FToe			= 0
	Tune.RToe			= 0


Prompt: -- Set the part's initial velocity to 10 units per second in the z direction

Response:
part.Velocity = Vector3.new(0, 0, 20)

part.Touched:Connect(function(hit)
	if hit.Parent:FindFirstChild("Humanoid") then
		local explosion = Instance.new("Explosion")
		explosion.Position = part.Position
		explosion.Parent = workspace
		hit.Parent.Humanoid:TakeDamage(10)
	end
end)


Prompt: -- Mouth Animtion

Response:
local SizeState1 = Vector3.new(0.794, 0.69, 0.949)
local SizeState2 = Vector3.new(0.794, 0.69, 0.849)
local SizeState3 = Vector3.new(0.794, 0.69, 0.749)
local SizeState4 = Vector3.new(0.794, 0.69, 0.649)
local SizeState5 = Vector3.new(0.794, 0.69, 0.549)

while true do
if not AnimDebounce then
AnimDebounce = true
for i = 1,math.random(1,5) do
Mouth.Size = SizeState1
Mouth1_2.Size = SizeState1
wait(0.05)
Mouth.Size = SizeState2
Mouth1_2.Size = SizeState2
wait(0.05)
Mouth.Size = SizeState3
Mouth1_2.Size = SizeState3
wait(0.05)
Mouth.Size = SizeState4
Mouth1_2.Size = SizeState4
wait(0.05)
Mouth.Size = SizeState5
Mouth1_2.Size = SizeState5
wait(0.5)
Mouth.Size = SizeState5
Mouth1_2.Size = SizeState5
wait(0.05)
Mouth.Size = SizeState4
Mouth1_2.Size = SizeState4
wait(0.05)
Mouth.Size = SizeState3
Mouth1_2.Size = SizeState3
wait(0.05)
Mouth.Size = SizeState2
Mouth1_2.Size = SizeState2
wait(0.05)
Mouth.Size = SizeState1
Mouth1_2.Size = SizeState1
wait(math.random(0.05,1))
end
wait(math.random(8,16))
AnimDebounce = false
end
end


Prompt: --//Opens Door (checks ownership)

Response:
prompt.Triggered:Connect(function(player)
	if prompt.ActionText == "Close" and player.Name == owner.Value then
		door.Transparency = 0
		door.knob1.Transparency = 0
		door.knob2.Transparency = 0
		door.CanCollide = true
		door2.Transparency = 1
		door2.knob1.Transparency = 1
		door2.knob2.Transparency = 1
		prompt.ActionText = "Open"
	wait(1)
	elseif 	prompt.ActionText == "Open" and player.Name == owner.Value then
		door.Transparency = 1
		door.knob1.Transparency = 1
		door.knob2.Transparency = 1
		door2.Transparency = 0
		door2.knob1.Transparency = 0
		door2.knob2.Transparency = 0
		door.CanCollide = false
		prompt.ActionText = "Close"
	wait(1)
	end
end)


Prompt: -- / Gun / --

Response:
local Gun = script.Parent.Parent
local BodyAttach = Gun.BodyAttach


Prompt:
--[=[
	@within Gamepad
	@type GamepadState {[Enum.KeyCode]: InputObject}
]=]


Prompt:
--[[
	Performs a right-fold of the list with the given initial value and callback.
]]

Response:
local function foldRight(list, callback, initialValue)
	local accum = initialValue

	for i = #list, 1, -1 do
		accum = callback(accum, list[i], i)
	end

	return accum
end

return foldRight


Prompt:
--[[**
	ensures value is a table and all keys pass keyCheck and all values pass valueCheck

	@param keyCheck The function to use to check the keys
	@param valueCheck The function to use to check the values

	@returns A function that will return true iff the condition is passed
**--]]

Response:
function t.map(keyCheck, valueCheck)
	assert(t.callback(keyCheck), t.callback(valueCheck))
	local keyChecker = t.keys(keyCheck)
	local valueChecker = t.values(valueCheck)
	return function(value)
		local keySuccess, keyErr = keyChecker(value)
		if not keySuccess then
			return false, keyErr or ""
		end

		local valueSuccess, valueErr = valueChecker(value)
		if not valueSuccess then
			return false, valueErr or ""
		end

		return true
	end
end

do
	local arrayKeysCheck = t.keys(t.integer)
	--[[**
		ensures value is an array and all values of the array match check

		@param check The check to compare all values with

		@returns A function that will return true iff the condition is passed
	**--]]
	function t.array(check)
		assert(t.callback(check))
		local valuesCheck = t.values(check)
		return function(value)
			local keySuccess, keyErrMsg = arrayKeysCheck(value)
			if keySuccess == false then
				return false, string.format("[array] %s", keyErrMsg or "")
			end

			-- all keys are sequential
			local arraySize = #value
			for key in pairs(value) do
				if key < 1 or key > arraySize then
					return false, string.format("[array] key %s must be sequential", tostring(key))
				end
			end

			local valueSuccess, valueErrMsg = valuesCheck(value)
			if not valueSuccess then
				return false, string.format("[array] %s", valueErrMsg or "")
			end

			return true
		end
	end
end

do
	local callbackArray = t.array(t.callback)
	--[[**
		creates a union type

		@param ... The checks to union

		@returns A function that will return true iff the condition is passed
	**--]]
	function t.union(...)
		local checks = {...}
		assert(callbackArray(checks))
		return function(value)
			for _, check in pairs(checks) do
				if check(value) then
					return true
				end
			end
			return false, "bad type for union"
		end
	end

	--[[**
		creates an intersection type

		@param ... The checks to intersect

		@returns A function that will return true iff the condition is passed
	**--]]
	function t.intersection(...)
		local checks = {...}
		assert(callbackArray(checks))
		return function(value)
			for _, check in pairs(checks) do
				local success, errMsg = check(value)
				if not success then
					return false, errMsg or ""
				end
			end
			return true
		end
	end
end

do
	local checkInterface = t.map(t.any, t.callback)
	--[[**
		ensures value matches given interface definition

		@param checkTable The interface definition

		@returns A function that will return true iff the condition is passed
	**--]]
	function t.interface(checkTable)
		assert(checkInterface(checkTable))
		return function(value)
			local tableSuccess, tableErrMsg = t.table(value)
			if tableSuccess == false then
				return false, tableErrMsg or ""
			end

			for key, check in pairs(checkTable) do
				local success, errMsg = check(value[key])
				if success == false then
					return false, string.format("[interface] bad value for %s:\n\t%s", tostring(key), errMsg or "")
				end
			end
			return true
		end
	end

	--[[**
		ensures value matches given interface definition strictly

		@param checkTable The interface definition

		@returns A function that will return true iff the condition is passed
	**--]]
	function t.strictInterface(checkTable)
		assert(checkInterface(checkTable))
		return function(value)
			local tableSuccess, tableErrMsg = t.table(value)
			if tableSuccess == false then
				return false, tableErrMsg or ""
			end

			for key, check in pairs(checkTable) do
				local success, errMsg = check(value[key])
				if success == false then
					return false, string.format("[interface] bad value for %s:\n\t%s", tostring(key), errMsg or "")
				end
			end

			for key in pairs(value) do
				if not checkTable[key] then
					return false, string.format("[interface] unexpected field '%s'", tostring(key))
				end
			end

			return true
		end
	end
end


Prompt:
-- place this script into StarterPlayerScripts
-- it will not work otherwise

Response:
local sm = Color3.fromRGB(0, 255, 255)--color of the message
local sm1 = Color3.fromRGB(255, 0, 0)--color of the message

game:GetService('Players').PlayerAdded:Connect(function(plr)

	local message = ("[Server]: Player ".."'"..plr.Name.."'".." Just Joined The Game!")

	game.StarterGui:SetCore("ChatMakeSystemMessage", {
		Text = message;
		Font = Enum.Font.SourceSansBold;
		Color = sm;
		FontSize = Enum.FontSize.Size18;
	})
end)

game:GetSerivce('Players').PlayerRemoving:Connect(function(plr)

	local message = ("[Server]: Player ".."'"..plr.Name.."'".." Just Leave The Game!")

	game.StarterGui:SetCore("ChatMakeSystemMessage", {
		Text = message;
		Font = Enum.Font.SourceSansBold;
		Color = sm1;
		FontSize = Enum.FontSize.Size18;
	})
end)


Response:
local path
local waypoint

local chaseName = nil

function GetTorso(part)
	local chars = game.Workspace:GetDescendants()
	local chaseRoot = nil
	local chaseTorso = nil
	local chasePlr = nil
	local chaseHuman = nil
	local mag = SearchDistance
	for i = 1, #chars do
		chasePlr = chars[i]
		if chasePlr:IsA'Model' and not chasePlr:FindFirstChild("Enemy") and not chasePlr:FindFirstChild("Helper") then
			chaseHuman = getHumanoid(chasePlr)
			chaseRoot = chasePlr:FindFirstChild'HumanoidRootPart'
			if chaseRoot ~= nil and chaseHuman ~= nil and chaseHuman.Health > 0 and not chaseHuman:FindFirstChild("Enemy") and not chasePlr:FindFirstChild("Helper") then
				if (chaseRoot.Position - part).magnitude < mag then
					chaseName = chasePlr.Name
					chaseTorso = chaseRoot
					mag = (chaseRoot.Position - part).magnitude
				end
			end
		end
	end
	return chaseTorso
end

function GetPlayersBodyParts(t)
	local torso = t
	if torso then
		local figure = torso.Parent
		for _, v in pairs(figure:GetChildren())do
			if v:IsA'Part' then
				return v.Name
			end
		end
	else
		return "HumanoidRootPart"
	end
end


Prompt: -- Setting up variables

Response:
module.Diving = false
module.DiveSlideCanceling = false
module.WallJumping = false
module.DiveSliding = false
module.Crouching = false
module.LongJumping = false
module.diveCount = 0
module.totalDives = 0
module.cananimate = true
module.GroundPounding = false
module.backflipping = false
module.canGroundPound = true
module.hitfloor = false
module.DiveSpeed = 0
module.Trail = nil

return module


Response:
script.Parent.Parent.ll1.Transparency = 1
script.Parent.Parent.l1.Transparency = 1
script.Parent.Parent.rr1.Transparency = 1
script.Parent.Parent.h1.Transparency = 1


Prompt: --credit to matt for fixing

Response:
task.wait(0.1)
local Players = game:GetService("Players")
local Check = {"Player1"}
local TeamColor = BrickColor.new("Medium stone grey")
local Blacklist = {}
local seat = script.Parent
local gui = script.Car
local owner = nil
local deletetime = 30
local currTime = 30
local timerdebounce = false

local function StartTimer()
	script.Parent.Parent.Sound.Timeout.Enabled = true
	repeat
		script.Parent.Parent.Sound.Timeout.TextLabel.Text = tostring(currTime) .. ""
		script.Parent.Parent.Sound.Timeout.TextLabel.TextScaled = false
		currTime -= 1
		if currTime == 0 then
			seat.Parent:Destroy()
		end
		task.wait(1)
	until currTime == 0 or owner ~= nil
	currTime = deletetime
	script.Parent.Parent.Sound.Timeout.Enabled = false
end

local function GiveGUI(plr)
	local guiClone = gui:Clone()
	guiClone.Parent = plr.PlayerGui
	guiClone.Frame.Seat.Value = script.Parent
	guiClone.Frame.LocalScript.Disabled = false
end

script.Parent.ChildAdded:connect(function(it)
	if it:IsA("Weld") and it.Name == "SeatWeld" then
		print(it.Name)
		local tempCharacter = it.Part1.Parent
		local tempPlayer = Players:GetPlayerFromCharacter(tempCharacter)

		if owner == nil and tempPlayer.TeamColor == TeamColor then
			owner = tempPlayer
			GiveGUI(tempPlayer)
			seat:SetNetworkOwnershipAuto()
		elseif owner ~= nil and tempPlayer.Name == owner.Name then
			print("welcome back")
			seat:SetNetworkOwnershipAuto()
		else
			seat.Disabled = true
			print("Booted Player.")
			task.wait(1.5)
			seat.Disabled = false
		end
	elseif it:IsA("IntValue") then
		owner = nil
		script.Parent.Parent.Parent = game.Workspace.VehiclesFolder.UnclaimedVehicles
		seat:SetNetworkOwnershipAuto()
		StartTimer()
	end
end)


Prompt:
-- Thanks for Meanwhile & XaXa for this script.
-- Remember this was designed for Meanwhile weapons so any other weapons might not work.
-- You have no permission to repubish this in you model even if it edited.
-- If your found then you will be ban from my place.
-- original Manofthelol Script

Response:
Tool = script.Parent
local Mouse = true
local Spin = script.Parent.Spin.Value
local Heat = script.Parent.Heat.Value
local chamber = true
local Player = Tool.Parent
local Dist = 0.20
local firing = false
local enabled = true
local reloading = false

rotvalueB1 = 90
rotvalueB2 = 30
rotvalueB3 = 330
rotvalueB4 = 270
rotvalueB5 = 210
rotvalueB6 = 150

local arms = nil
local torso = nil
local weld33 = nil -- right arm
local weld55 = nil -- left arm
local welds = {}

function ReloadSequence()
Tool.S1.Transparency = 1
wait()
Tool.S2.Transparency = 1
wait()
Tool.S3.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), 0.2, math.rad(-90))
Tool.S4.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), 0.1, math.rad(-90))
Tool.S5.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), 0, math.rad(-90))
Tool.S6.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.1, math.rad(-90))
Tool.S7.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.2, math.rad(-90))
Tool.S8.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.3, math.rad(-90))
Tool.S9.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.4, math.rad(-90))
Tool.S10.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.5, math.rad(-90))
Tool.S11.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.6, math.rad(-90))
Tool.S12.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.7, math.rad(-90))
local mag = Tool.Mag:clone()
mag.CFrame = Tool.Mag.CFrame
mag.CanCollide = false
mag.Parent = game.Workspace
Tool.Mag.Transparency = 1

local mag = Tool.Mag2:clone()
mag.CFrame = Tool.Mag.CFrame
mag.CanCollide = false
mag.Parent = game.Workspace
Tool.Mag2.Transparency = 1

local mag = Tool.Mag3:clone()
mag.CFrame = Tool.Mag.CFrame
mag.CanCollide = false
mag.Parent = game.Workspace
Tool.Mag3.Transparency = 1

Tool.Handle.M1:play()
wait(1)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.8, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.9, math.rad(-90))
wait(.2)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -1, math.rad(-90))
Tool.Mag.Transparency = 0
Tool.Mag2.Transparency = 0
Tool.Mag3.Transparency = 0
Tool.Mag.Mesh.Offset = Vector3.new(0, 0, 0.4)
Tool.Mag2.Mesh.Offset = Vector3.new(0, 0, 0.4)
Tool.Mag3.Mesh.Offset = Vector3.new(0, 0, 0.4)
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.9, math.rad(-90))
Tool.Mag.Mesh.Offset = Vector3.new(0, 0, 0.3)
Tool.Mag2.Mesh.Offset = Vector3.new(0, 0, 0.3)
Tool.Mag3.Mesh.Offset = Vector3.new(0, 0, 0.3)
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.8, math.rad(-90))
Tool.Mag.Mesh.Offset = Vector3.new(0, 0, 0.2)
Tool.Mag2.Mesh.Offset = Vector3.new(0, 0, 0.2)
Tool.Mag3.Mesh.Offset = Vector3.new(0, 0, 0.2)
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.7, math.rad(-90))
Tool.Mag.Mesh.Offset = Vector3.new(0, 0, 0.1)
Tool.Mag2.Mesh.Offset = Vector3.new(0, 0, 0.1)
Tool.Mag3.Mesh.Offset = Vector3.new(0, 0, 0.1)
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.6, math.rad(-90))
Tool.Mag.Mesh.Offset = Vector3.new(0, 0, 0)
Tool.Mag2.Mesh.Offset = Vector3.new(0, 0, 0)
Tool.Mag3.Mesh.Offset = Vector3.new(0, 0, 0)
Tool.Handle.M2:play()
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(309), -0.61, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(308), -0.62, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(307), -0.63, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(306), -0.64, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(305), -0.65, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(304), -0.66, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(303), -0.67, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(302), -0.68, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(301), -0.69, math.rad(-90))
Tool.S12.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(300), -0.7, math.rad(-90))
Tool.S11.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(301), -0.69, math.rad(-90))
Tool.S10.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(302), -0.68, math.rad(-90))
Tool.S9.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(303), -0.67, math.rad(-90))
Tool.S8.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(304), -0.66, math.rad(-90))
Tool.S7.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(305), -0.65, math.rad(-90))
Tool.S6.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(306), -0.64, math.rad(-90))
Tool.S5.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(307), -0.63, math.rad(-90))
Tool.S4.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(308), -0.62, math.rad(-90))
Tool.S3.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(309), -0.61, math.rad(-90))
Tool.S2.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.6, math.rad(-90))
Tool.S1.Transparency = 0
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.5, math.rad(-90))
wait(.03)
Tool.Mag.Mesh.Offset = Vector3.new(0, 0, 0)
Tool.Handle.M2:play()
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.4, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.3, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.2, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.1, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), 0, math.rad(-90))
wait(.5)
weld33.C1 = CFrame.new(-0.75, -1.2, 0.35) * CFrame.fromEulerAnglesXYZ(math.rad(-70), math.rad(-35), 0)
weld55.C1 = CFrame.new(-0.35, 2, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(295), 0, math.rad(-90))
end

function ReloadSequence2()
Tool.S1.Transparency = 1
wait()
Tool.S2.Transparency = 1
wait()
Tool.S3.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), 0.2, math.rad(-90))
Tool.S4.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), 0.1, math.rad(-90))
Tool.S5.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), 0, math.rad(-90))
Tool.S6.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.1, math.rad(-90))
Tool.S7.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.2, math.rad(-90))
Tool.S8.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.3, math.rad(-90))
Tool.S9.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.4, math.rad(-90))
Tool.S10.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.5, math.rad(-90))
Tool.S11.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.6, math.rad(-90))
Tool.S12.Transparency = 1
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.7, math.rad(-90))
local mag = Tool.Mag:clone()
mag.CFrame = Tool.Mag.CFrame
mag.CanCollide = false
mag.Parent = game.Workspace
Tool.Mag.Transparency = 1

local mag = Tool.Mag2:clone()
mag.CFrame = Tool.Mag.CFrame
mag.CanCollide = false
mag.Parent = game.Workspace
Tool.Mag2.Transparency = 1

local mag = Tool.Mag3:clone()
mag.CFrame = Tool.Mag.CFrame
mag.CanCollide = false
mag.Parent = game.Workspace
Tool.Mag3.Transparency = 1

Tool.Handle.M1:play()
wait(1)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.8, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.9, math.rad(-90))
wait(.2)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -1, math.rad(-90))
Tool.Mag.Transparency = 0
Tool.Mag2.Transparency = 0
Tool.Mag3.Transparency = 0
Tool.Mag.Mesh.Offset = Vector3.new(0, 0, 0.4)
Tool.Mag2.Mesh.Offset = Vector3.new(0, 0, 0.4)
Tool.Mag3.Mesh.Offset = Vector3.new(0, 0, 0.4)
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.9, math.rad(-90))
Tool.Mag.Mesh.Offset = Vector3.new(0, 0, 0.3)
Tool.Mag2.Mesh.Offset = Vector3.new(0, 0, 0.3)
Tool.Mag3.Mesh.Offset = Vector3.new(0, 0, 0.3)
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.8, math.rad(-90))
Tool.Mag.Mesh.Offset = Vector3.new(0, 0, 0.2)
Tool.Mag2.Mesh.Offset = Vector3.new(0, 0, 0.2)
Tool.Mag3.Mesh.Offset = Vector3.new(0, 0, 0.2)
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.7, math.rad(-90))
Tool.Mag.Mesh.Offset = Vector3.new(0, 0, 0.1)
Tool.Mag2.Mesh.Offset = Vector3.new(0, 0, 0.1)
Tool.Mag3.Mesh.Offset = Vector3.new(0, 0, 0.1)
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.6, math.rad(-90))
Tool.Mag.Mesh.Offset = Vector3.new(0, 0, 0)
Tool.Mag2.Mesh.Offset = Vector3.new(0, 0, 0)
Tool.Mag3.Mesh.Offset = Vector3.new(0, 0, 0)
Tool.Handle.M2:play()
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(309), -0.61, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(308), -0.62, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(307), -0.63, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(306), -0.64, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(305), -0.65, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(304), -0.66, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(303), -0.67, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(302), -0.68, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(301), -0.69, math.rad(-90))
Tool.S12.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(300), -0.7, math.rad(-90))
Tool.S11.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(301), -0.69, math.rad(-90))
Tool.S10.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(302), -0.68, math.rad(-90))
Tool.S9.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(303), -0.67, math.rad(-90))
Tool.S8.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(304), -0.66, math.rad(-90))
Tool.S7.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(305), -0.65, math.rad(-90))
Tool.S6.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(306), -0.64, math.rad(-90))
Tool.S5.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(307), -0.63, math.rad(-90))
Tool.S4.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(308), -0.62, math.rad(-90))
Tool.S3.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(309), -0.61, math.rad(-90))
Tool.S2.Transparency = 0
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.6, math.rad(-90))
Tool.S1.Transparency = 0
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.5, math.rad(-90))
wait(.03)
Tool.Mag.Mesh.Offset = Vector3.new(0, 0, 0)
Tool.Handle.M2:play()
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.3, math.rad(-90))
wait(.5)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.4, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.5, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(310), -0.6, math.rad(-90))
Tool.Handle.Close:play()
Tool.Handle.Engine:play()
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1.1, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(308), -0.5, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1.2, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(306), -0.4, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1.3, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(304), -0.3, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1.4, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(302), -0.2, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1.5, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(300), 0.1, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1.6, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(298), 0, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1.7, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(296), 0, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1.8, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(295), 0, math.rad(-90))
wait(.03)
weld55.C1 = CFrame.new(-0.35, 1.9, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(295), 0, math.rad(-90))
wait(.03)
weld33.C1 = CFrame.new(-0.75, -1.2, 0.35) * CFrame.fromEulerAnglesXYZ(math.rad(-70), math.rad(-35), 0)
weld55.C1 = CFrame.new(-0.35, 2, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(295), 0, math.rad(-90))
end

function Reload()
Tool.Left.Value = Tool.Ammo.Value
	if script.Parent.Ammo.Value < script.Parent.MaxAmmo.Value and reloading == false and script.Parent.StoredAmmo.Value >= 1 then
		reloading = true
		script.Parent.Ammo.Value = 0
		ReloadChoose()
      script.Parent.StoredAmmo.Value = script.Parent.StoredAmmo.Value + script.Parent.Left.Value
		if script.Parent.StoredAmmo.Value >= script.Parent.MaxAmmo.Value then
			script.Parent.StoredAmmo.Value = script.Parent.StoredAmmo.Value - script.Parent.MaxAmmo.Value
			script.Parent.Ammo.Value = script.Parent.MaxAmmo.Value
         script.Parent.Recoil.Value = 5
		elseif script.Parent.StoredAmmo.Value < script.Parent.MaxAmmo.Value and script.Parent.StoredAmmo.Value >= 1 then
         script.Parent.Ammo.Value = script.Parent.StoredAmmo.Value
			script.Parent.StoredAmmo.Value = 0
			script.Parent.Recoil.Value = 5
		end
		reloading = false
	end
end

function ReloadChoose()
   if script.Parent.Left.Value == 0 then
      ReloadSequence2()
   elseif script.Parent.Left.Value >= 1 then
      ReloadSequence()
   end
end

function Equip(mouse)
wait(.1)

	print("Equipped")
	if game.Players.LocalPlayer ~= nil then
		Gui = Tool.OverheatBar:clone()
		Gui.Parent = game.Players.LocalPlayer.PlayerGui
			end

wait(0.01)
arms = {Tool.Parent:FindFirstChild("Left Arm"), Tool.Parent:FindFirstChild("Right Arm")}
torso = Tool.Parent:FindFirstChild("Torso")
if arms ~= nil and torso ~= nil then
local sh = {torso:FindFirstChild("Left Shoulder"), torso:FindFirstChild("Right Shoulder")}
if sh ~= nil then
local yes = true
if yes then
yes = false
sh[1].Part1 = nil
sh[2].Part1 = nil
falsearm1 = arms[1]:clone()
local mesh1 = Tool.Larm:clone()
mesh1.Parent = falsearm1
local armweld1 = Instance.new("Weld")
falsearm1.BrickColor = BrickColor.new("Light orange") -- this is the arm colour incase u want to change it
falsearm1.Parent = Tool
armweld1.Parent = falsearm1
armweld1.Part0 = falsearm1
armweld1.Part1 = arms[1]
falsearm2 = arms[2]:clone()
local mesh2 = Tool.Rarm:clone()
mesh2.Parent = falsearm2
local armweld2 = Instance.new("Weld")
falsearm2.BrickColor = BrickColor.new("Light orange") -- this is the 2nd arm colour incase u want to change it
falsearm2.Parent = Tool
armweld2.Parent = falsearm2
armweld2.Part0 = falsearm2
armweld2.Part1 = arms[2]
local weld1 = Instance.new("Weld") -- left arm
weld55 = weld1
weld1.Part0 = torso
weld1.Parent = torso
weld1.Part1 = arms[1]
weld1.C1 = CFrame.new(-0.35, 2, 0.6) * CFrame.fromEulerAnglesXYZ(math.rad(295), 0, math.rad(-90))
welds[1] = weld1
local weld2 = Instance.new("Weld") -- right arm
weld33 = weld2
weld2.Part0 = torso
weld2.Parent = torso
weld2.Part1 = arms[2]
weld2.C1 = CFrame.new(-0.75, -1.2, 0.35) * CFrame.fromEulerAnglesXYZ(math.rad(-70), math.rad(-35), 0)
welds[2] = weld2
end
else
print("sh")
end
else
print("arms")
end
end

function Unequip(mouse)
Gui:Remove()
if arms ~= nil and torso ~= nil then
local sh = {torso:FindFirstChild("Left Shoulder"), torso:FindFirstChild("Right Shoulder")}
if sh ~= nil then
local yes = true
if yes then
yes = false
sh[1].Part1 = arms[1]
sh[2].Part1 = arms[2]
welds[1].Parent = nil
welds[2].Parent = nil
falsearm1:remove()
falsearm2:remove()
end
else
print("sh")
end
else
print("arms")
end
end

colors = {199}

local pellet = Instance.new("Part")
pellet.Name = "Bullet"
pellet.Shape = 1
pellet.formFactor = 3
pellet.BrickColor = BrickColor.new(24)
pellet.Size = Vector3.new(.2,.2,.2)
pellet.Locked = true

Tool.Equipped:connect(function(mouse)

function Shelling()
local ammo = script.Parent.Ammo
if ammo.Value == 12 then
Tool.S12.Transparency = 1
end
if ammo.Value == 11 then
Tool.S11.Transparency = 1
Tool.S12.Transparency = 1
end
if ammo.Value == 10 then
Tool.S10.Transparency = 1
Tool.S11.Transparency = 1
Tool.S12.Transparency = 1
end
if ammo.Value == 9 then
Tool.S9.Transparency = 1
Tool.S10.Transparency = 1
Tool.S11.Transparency = 1
Tool.S12.Transparency = 1
end
if ammo.Value == 8 then
Tool.S8.Transparency = 1
Tool.S9.Transparency = 1
Tool.S10.Transparency = 1
Tool.S11.Transparency = 1
Tool.S12.Transparency = 1
end
if ammo.Value == 7 then
Tool.S7.Transparency = 1
Tool.S8.Transparency = 1
Tool.S9.Transparency = 1
Tool.S10.Transparency = 1
Tool.S11.Transparency = 1
Tool.S12.Transparency = 1
end
if ammo.Value == 6 then
Tool.S6.Transparency = 1
Tool.S7.Transparency = 1
Tool.S8.Transparency = 1
Tool.S9.Transparency = 1
Tool.S10.Transparency = 1
Tool.S11.Transparency = 1
Tool.S12.Transparency = 1
end
if ammo.Value == 5 then
Tool.S5.Transparency = 1
Tool.S6.Transparency = 1
Tool.S7.Transparency = 1
Tool.S8.Transparency = 1
Tool.S9.Transparency = 1
Tool.S10.Transparency = 1
Tool.S11.Transparency = 1
Tool.S12.Transparency = 1
end
if ammo.Value == 4 then
Tool.S4.Transparency = 1
Tool.S5.Transparency = 1
Tool.S6.Transparency = 1
Tool.S7.Transparency = 1
Tool.S8.Transparency = 1
Tool.S9.Transparency = 1
Tool.S10.Transparency = 1
Tool.S11.Transparency = 1
Tool.S12.Transparency = 1
end
if ammo.Value == 3 then
Tool.S3.Transparency = 1
Tool.S4.Transparency = 1
Tool.S5.Transparency = 1
Tool.S6.Transparency = 1
Tool.S7.Transparency = 1
Tool.S8.Transparency = 1
Tool.S9.Transparency = 1
Tool.S10.Transparency = 1
Tool.S11.Transparency = 1
Tool.S12.Transparency = 1
end
if ammo.Value == 2 then
Tool.S2.Transparency = 1
Tool.S3.Transparency = 1
Tool.S4.Transparency = 1
Tool.S5.Transparency = 1
Tool.S6.Transparency = 1
Tool.S7.Transparency = 1
Tool.S8.Transparency = 1
Tool.S9.Transparency = 1
Tool.S10.Transparency = 1
Tool.S11.Transparency = 1
Tool.S12.Transparency = 1
end
if ammo.Value == 1 then
Tool.S1.Transparency = 1
Tool.S2.Transparency = 1
Tool.S3.Transparency = 1
Tool.S4.Transparency = 1
Tool.S5.Transparency = 1
Tool.S6.Transparency = 1
Tool.S7.Transparency = 1
Tool.S8.Transparency = 1
Tool.S9.Transparency = 1
Tool.S10.Transparency = 1
Tool.S11.Transparency = 1
Tool.S12.Transparency = 1
end
end

function fire(v)
if enabled == true then
Spin = Spin + 1
if Spin < 40 then
Heat = Heat + 0.2
return
else
end
if Spin >= 45 then
Spin = 45
end
Heat = Heat + 2
firing = true
local ammo = script.Parent.Ammo
if ammo.Value >= 1 then
	ammo.Value = ammo.Value - 1

	script.Fire:Play()

	local vCharacter = Tool.Parent
	local vPlayer = game.Players:playerFromCharacter(vCharacter)

	local missile = Instance.new("Part")

	local spawnPos = vCharacter.PrimaryPart.Position

	spawnPos  = spawnPos + (v * 8)

	missile.Position = spawnPos
	missile.Size = Vector3.new(1,1,1)
	missile.Velocity = v * 500
	missile.BrickColor = BrickColor.new(24)
	missile.Shape = 0
	missile.BottomSurface = 0
	missile.TopSurface = 0
	missile.Name = "Bullet"
	missile.Elasticity = 0
	missile.Reflectance = .3
	missile.Friction = .9
   missile.CanCollide = false

	local force = Instance.new("BodyForce")
	force.force = Vector3.new(math.random(-5, 5),math.random(95, 105),math.random(-5, 5))
	force.Parent = missile

	local mesh = Instance.new("SpecialMesh")
	mesh.Scale = Vector3.new(.1,.1,.1)
	mesh.MeshType = "Sphere"
	mesh.Parent = missile

	local new_script = script.Parent.Bullet:clone()
	new_script.Disabled = false
	new_script.Parent = missile

	local creator_tag = Instance.new("ObjectValue")
	creator_tag.Value = vPlayer
	creator_tag.Name = "creator"
	creator_tag.Parent = missile

	missile.Parent = game.Workspace

	cam = game.Workspace.CurrentCamera
	local cam_rot = cam.CoordinateFrame - cam.CoordinateFrame.p
	local cam_scroll = (cam.CoordinateFrame.p - cam.Focus.p).magnitude
	local ncf = CFrame.new(cam.Focus.p)*cam_rot*CFrame.fromEulerAnglesXYZ(0.01, 0, 0)
	cam.CoordinateFrame = ncf*CFrame.new(0, 0, cam_scroll)
	Tool.Flash.Transparency = .5
	Tool.Flash.Smoke.Enabled = true
	wait()
	Tool.Flash.Transparency = 1
	Tool.Flash.Smoke.Enabled = false
	Shelling()
	elseif ammo.Value == 0 then
	Reload()
end
elseif enabled == false then
end

end
end)

function KeyDownFunctions(key)
	if key == "r" then
		Reload()
	end
end

function computeDirection(pos)
	local invrtDir = 1 / math.sqrt((pos.magnitude * pos.magnitude))
	local dir = Vector3.new(pos.x * invrtDir, pos.y * invrtDir, pos.z * invrtDir)
	return dir
end

function check(en)
if not Tool.Enabled then
return false
end
if Tool.Enabled then
return true
end
if not enabled then
return false
end
if enabled then
return true
end
end

function onActivated()

	if (not Tool.Enabled) or (not enabled) then
		return
	end

	--Tool.Enabled = false

	local character = Tool.Parent;
	local humanoid = character.Humanoid
	if humanoid == nil or humanoid.Health <= 0 then
		Tool:Remove()
		return
	end

	local targetPos = humanoid.TargetPoint
	local lookAt = (targetPos - character.Head.Position).unit

if (check()) then

end
	fire(lookAt)
wait()
	onActivated()

	return
	--Tool.Enabled = true
end

function onButton1Up(mouse)
firing = false
enabled = false
Tool.Enabled = false
wait(.2)
firing = false
enabled = true
Tool.Enabled = true

end

function onEquippedLocal(mouse)

	if mouse == nil then
		print("Mouse not found")
		return
	end

	mouse.Button1Down:connect(function() onButton1Down(mouse) end)
	mouse.Button1Up:connect(function() onButton1Up(mouse)end)
	mouse.KeyDown:connect(KeyDownFunctions)
end

function onEquippedLocal2(mouse)
wait(.2)
while Mouse == true do

Spin = Spin - .5
if not firing then
Heat = Heat - .75
end

	mouse.Icon = "http://www.roblox.com/asset/?id=45003129"


Prompt: -- Denotes children instances in an instance or component's property table.

Response:
export type ChildrenKey = Symbol & {
	-- name: "Children" (add this when Luau supports singleton types)
}


Prompt: --function onSelected(mouse)

Response:
print("1")
	mouse.Icon = "rbxasset://textures\\GunCursor.png"
print("1")
	mouse.KeyDown:connect(onKeyDown)
print("1")
end
print("1")

function onKeyDown(key)
	if (key~=nil) then
		key = key:lower()
local blade = script.Parent.Handle2
		if (key=="z")  then
blade.Transparency = 0.5
blade.Sound:Play()
			end

			if (key=="x") then
blade.Transparency = 1
blade.Sound:Play()
		 end
	end
end
Tool.Equipped:connect(onEquippedLocal)


Prompt: -- Denotes event  handlers in an instance's property table.

Response:
export type OnEventKey = Symbol & {
	-- name: "OnEvent" (add this when Luau supports singleton types)
	key: string
}


Response:
game.Workspace.rightpalette.l15.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l25.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l16.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l26.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)

game.Workspace.doorleft.l11.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l23.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l32.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l41.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l53.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l62.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l71.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l12.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l21.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l33.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l42.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l51.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l63.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l72.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l13.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l22.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l31.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l43.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l52.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l61.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l73.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)

game.Workspace.doorright.l11.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l23.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l32.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l41.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l53.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l62.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l71.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l12.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l21.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l33.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l42.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l51.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l63.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l72.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l13.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l22.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l31.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l43.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l52.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l61.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.l73.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)

game.Workspace.doorleft.pillar.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorright.pillar.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)

game.Workspace.audiencebackleft1.Part1.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part2.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part3.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part4.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part5.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part6.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part7.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part8.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part9.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)

game.Workspace.audiencebackright1.Part1.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part2.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part3.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part4.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part5.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part6.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part7.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part8.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part9.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.Lighting.flashcurrent.Value = "0"

game.Workspace.sidesquares.l11.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.sidesquares.l12.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.sidesquares.l13.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.sidesquares.l14.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.sidesquares.l15.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.sidesquares.l21.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.sidesquares.l23.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.sidesquares.l24.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.sidesquares.l25.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.sidesquares.l31.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.sidesquares.l33.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.sidesquares.l34.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.sidesquares.l35.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)

game.Workspace.rightpalette.l11.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l12.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l21.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l22.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l13.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l23.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l14.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l24.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l15.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l25.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l16.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.rightpalette.l26.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)

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


Prompt: --If necessary change the last word to:

Response:
	--Signal1
	--Signal1a
	--Signal2
	--Signal2a
	--TurnSignal1
	--TurnSignal1a
	--TurnSignal2
	--TurnSignal2a


Prompt:
--[[
	Gets the Context object for the current node.
]]

Response:
function TestSession:getContext()
	assert(#self.contextStack > 0, "Tried to get context from an empty stack!")
	return self.contextStack[#self.contextStack]
end

function TestSession:getExpectationContext()
	assert(#self.expectationContextStack > 0, "Tried to get expectationContext from an empty stack!")
	return self.expectationContextStack[#self.expectationContextStack]
end


Response:
game.Workspace.audiencebackleft1.Part1.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part2.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part3.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part4.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part5.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part6.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part7.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part8.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackleft1.Part9.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)

game.Workspace.audiencebackright1.Part1.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part2.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part3.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part4.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part5.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part6.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part7.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part8.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part9.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)

game.Workspace.post1.Light.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.post2.Light.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)

if game.Workspace.DoorFlashing.Value == false then
game.Workspace.DoorColored.Value = false


Prompt: --What happens with DepositBox1--

Response:
depositpr1.Triggered:Connect(function(plr)
	if plr.Character:FindFirstChild("Drill",yeeld) then
	driLL1.Transparency = 0
	drilling1.Playing = true
	drillingeffect1.Enabled = true
	driLL1.CanCollide = true
	wait(timetodrill)
	driLL1.CanCollide = false
	drilling1.Playing = false
	drillingeffect1.Enabled = false
	driLL1.Transparency = 1
	explosionvault1.Enabled = true
	explosionvaultsfx1.Playing = true
	wait(1)
	explosionvault1.Enabled = false
	depositpr1.Parent.Parent.Transparency = 1
	depositpr1.Parent.Parent.CanCollide = false
	depositpr1.Enabled = false
	wait(resetcooldown)
	depositpr1.Parent.Parent.Transparency = 0
	depositpr1.Parent.Parent.CanCollide = true
	depositpr1.Enabled = true
end
end)


Prompt: -- Preload animations

Response:
function playAnimation(animName, transitionTime, humanoid)
	local idleFromEmote = (animName == "idle" and emoteNames[currentAnim] ~= nil)
	if (animName ~= currentAnim and not idleFromEmote) then

		if (currentAnimTrack ~= nil) then
			currentAnimTrack:Stop(transitionTime)
			currentAnimTrack:Destroy()
		end

		currentAnimSpeed = 1.0
		local roll = math.random(1, animTable[animName].totalWeight)
		local origRoll = roll
		local idx = 1
		while (roll > animTable[animName][idx].weight) do
			roll = roll - animTable[animName][idx].weight
			idx = idx + 1
		end


Prompt:
--[[**
	Gets an array of the given player's groups.
	@param [Instance<Player>] Player The player you are checking for. Can also be their UserID.
	@returns [Array] All of the groups the player is in.
**--]]

Response:
function GroupService:GetGroupsAsync(Player)
	local UserId = (typeof(Player) == "Instance" and Player:IsA("Player")) and Player.UserId or type(Player) == "number" and Player
	local Success, Groups = pcall(RbxGroupService.GetGroupsAsync, RbxGroupService, UserId)
	return Success and Groups or {}
end


Prompt: ------------Horn

Response:
model = script.Parent
wait(0.5)
currentP = "Off"
script.Parent.Events.Horn.OnServerEvent:Connect( function(player, pattern)
	if script.Parent.Values.Horn.Value == true then
		script.Parent.Values.Horn.Value = false
	else
		script.Parent.Values.Horn.Value = true
	end
end)


Prompt:
-- ROBLOX deviation: this is a built-in flow type, and very complex. we fudge this with `any`
-- type ElementRef<
--   C extends keyof JSX.IntrinsicElements
--   | React.ForwardRefExoticComponent<any>
--   | (new (props: any) -> React.Component<any, {}, any>)
--   | ((props: any, context?: any) -> ReactElement | null)
--   > = "ref" extends keyof ComponentPropsWithRef<C>
--     ? NonNullable<ComponentPropsWithRef<C>["ref"]> extends Ref<infer Instance>
--       ? Instance
--       : never
--     : never


Prompt: --------------------) Settings

Response:
Damage = 0 -- the ammout of health the player or mob will take

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

ZoneModelName = "Nightmare spin tentacle" -- name the zone model

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


Prompt: --------------------[ FIRING FUNCTIONS ]----------------------------------------------

Response:
function Fire_Gun()
	local FireSound = Main:FindFirstChild("FireSound")
	local FlashGui = Main:FindFirstChild("ParticleFX")
	local FlashFX = Main:FindFirstChild("FlashFX")

	if FireSound then FireSound:Play() end

	local MockSpread = (
		((not Aimed) and CurrentSpread <= S.Spread.Max and Idleing)
		and CurrentSpread * S.Spread.Multiplier or CurrentSpread
	)
	CurrentSpread = (MockSpread >= S.Spread.Max and S.Spread.Max or MockSpread)

	----------------------------------------------------------------------------------
	for _ = 1, (S.GunType.Shot and S.ShotAmount or 1) do
		local BSpread = CFANG(
			RAD(RAND(-CurrentSpread, CurrentSpread) / 20),
			RAD(RAND(-CurrentSpread, CurrentSpread) / 20),
			RAD(RAND(-CurrentSpread, CurrentSpread) / 20)
		)
		local OriginCF = (Aimed and (S.GuiScope and Head.CFrame or Handle.CFrame) or Head.CFrame)
		local OriginPos = Main.CFrame.p
		local Direction = (CF(OriginCF.p, OriginCF.p + OriginCF.lookVector) * BSpread).lookVector

		if S.InstantHit then
			local HitObj, HitPos = AdvRayCast(Main.CFrame.p, Direction, S.BulletRange)
			local HitHumanoid = nil
			if HitObj then
				if S.GunType.Explosive then
					if S.ExplosionSound ~= "" then
						local SoundPart = Instance.new("Part")
						SoundPart.Transparency = 1
						SoundPart.Anchored = true
						SoundPart.CanCollide = false
						SoundPart.CFrame = CFrame.new(HitPos)
						SoundPart.Parent = game.Workspace

						local Sound = Instance.new("Sound")
						Sound.Pitch = S.ExplosionSoundPitch
						Sound.SoundId = S.ExplosionSound
						Sound.Volume = S.ExplosionSoundVolume
						Sound.Parent = SoundPart
						Sound:Play()

						delay(1 / 20, function()
							SoundPart:Destroy()
						end)
					end
					CreateBulletHole(HitPos, HitObj)
					CreateShockwave(HitPos, S.ExplosionRadius)
					local E = Instance.new("Explosion")
					E.BlastPressure = S.ExplosionPressure
					E.BlastRadius = S.ExplosionRadius
					E.DestroyJointRadiusPercent = (S.RangeBasedDamage and 0 or 1)
					E.ExplosionType = S.ExplosionType
					E.Position = HitPos
					E.Hit:connect(function(HObj, HDist)
						if HObj.Name == "Torso" and (not HObj:IsDescendantOf(Character)) then
							if S.RangeBasedDamage then
								local Dir = (HObj.Position - HitPos).unit
								local H, P = AdvRayCast(HitPos - Dir, Dir, 999)
								local RayHitHuman = H:IsDescendantOf(HObj.Parent)
								if (S.RayCastExplosions and RayHitHuman) or (not S.RayCastExplosions) then
									local HitHumanoid = FindFirstClass(HObj.Parent, "Humanoid")
									if HitHumanoid and HitHumanoid.Health > 0 and IsEnemy(HitHumanoid) then
										local DistFactor = HDist / S.ExplosionRadius
										local DistInvert = math.max(1 - DistFactor,0)
										local NewDamage = DistInvert * S.Damage

										local CreatorTag = Instance.new("ObjectValue")
										CreatorTag.Value = Player
										CreatorTag.Name = "creator"
										CreatorTag.Parent = HitHumanoid
										HitHumanoid:TakeDamage(NewDamage)
										MarkHit()
									end
								end
							else
								local HitHumanoid = FindFirstClass(HObj.Parent, "Humanoid")
								if HitHumanoid and HitHumanoid.Health > 0 and IsEnemy(HitHumanoid) then
									local CreatorTag = Instance.new("ObjectValue")
									CreatorTag.Value = Player
									CreatorTag.Name = "creator"
									CreatorTag.Parent = HitHumanoid
									MarkHit()
								end
							end
						end
					end)
					E.Parent = game.Workspace
				else
					HitHumanoid = Damage(HitObj, HitPos)
				end
			end
			local FinalHitPos = HitPos
			if S.Penetration > 0 and (not S.GunType.Explosive) then
				FinalHitPos = PenetrateWall(HitPos, Direction, HitHumanoid, OriginPos)
			end
			if S.BulletTrail and S.TrailTransparency ~= 1 then
				local Trail = Instance.new("Part")
				Trail.BrickColor = S.TrailColor
				Trail.Transparency = S.TrailTransparency
				Trail.Anchored = true
				Trail.CanCollide = false
				Trail.Size = VEC3(1, 1, 1)
				local Mesh = Instance.new("BlockMesh")
				Mesh.Offset = VEC3(0, 0, -(FinalHitPos - OriginPos).magnitude / 2)
				Mesh.Scale = VEC3(S.TrailThickness, S.TrailThickness, (FinalHitPos - OriginPos).magnitude)
				Mesh.Parent = Trail
				Trail.Parent = Gun_Ignore
				Trail.CFrame = CF(OriginPos, FinalHitPos)
				delay(S.TrailVisibleTime, function()
					if S.TrailDisappearTime > 0 then
						local X = 0
						while true do
							if X == 90 then break end
							if (not Selected) then break end
							local NewX = X + (1.5 / S.TrailDisappearTime)
							X = (NewX > 90 and 90 or NewX)
							local Alpha = X / 90
							Trail.Transparency = NumLerp(S.TrailTransparency, 1, Alpha)
							RS:wait()
						end
						Trail:Destroy()
					else
						Trail:Destroy()
					end
				end)
			end
		else
			local Bullet = CreateBullet(Direction)
			local LastPos = Main.CFrame.p
			local TotalDistTraveled = 0
			local HitHumanoid = nil
			spawn(function()
				while true do
					RS:wait()
					if TotalDistTraveled >= S.BulletRange then
						Bullet:Destroy()
						break
					end
					local DistTraveled = (Bullet.Position - LastPos).magnitude
					local HitObj, HitPos = AdvRayCast(LastPos, (Bullet.Position - LastPos).unit, DistTraveled)
					if HitObj then
						if S.GunType.Explosive then
							if S.ExplosionSound ~= "" then
								local Sound = Instance.new("Sound")
								Sound.Pitch = S.ExplosionSoundPitch
								Sound.SoundId = S.ExplosionSound
								Sound.Volume = S.ExplosionSoundVolume
								Sound.Parent = Bullet
								Sound:Play()
							end
							CreateBulletHole(HitPos, HitObj)
							CreateShockwave(HitPos, S.ExplosionRadius)
							local E = Instance.new("Explosion")
							E.BlastPressure = S.ExplosionPressure
							E.BlastRadius = S.ExplosionRadius
							E.DestroyJointRadiusPercent = (S.RangeBasedDamage and 0 or 1)
							E.ExplosionType = S.ExplosionType
							E.Position = HitPos
							E.Hit:connect(function(HObj, HDist)
								if HObj.Name == "Torso" and (not HObj:IsDescendantOf(Character)) then
									if S.RangeBasedDamage then
										local Dir = (HObj.Position - HitPos).unit
										local H, P = AdvRayCast(HitPos - Dir, Dir, 999)
										local RayHitHuman = H:IsDescendantOf(HObj.Parent)
										if (S.RayCastExplosions and RayHitHuman) or (not S.RayCastExplosions) then
											local HitHumanoid = FindFirstClass(HObj.Parent, "Humanoid")
											if HitHumanoid and HitHumanoid.Health > 0 and IsEnemy(HitHumanoid) then
												local DistFactor = HDist / S.ExplosionRadius
												local DistInvert = math.max(1 - DistFactor,0)
												local NewDamage = DistInvert * S.Damage

												local CreatorTag = Instance.new("ObjectValue")
												CreatorTag.Value = Player
												CreatorTag.Name = "creator"
												CreatorTag.Parent = HitHumanoid
												HitHumanoid:TakeDamage(NewDamage)
												MarkHit()
											end
										end
									else
										local HitHumanoid = FindFirstClass(HObj.Parent, "Humanoid")
										if HitHumanoid and HitHumanoid.Health > 0 and IsEnemy(HitHumanoid) then
											local CreatorTag = Instance.new("ObjectValue")
											CreatorTag.Value = Player
											CreatorTag.Name = "creator"
											CreatorTag.Parent = HitHumanoid
											MarkHit()
										end
									end
								end
							end)
							E.Parent = game.Workspace
						else
							HitHumanoid = Damage(HitObj, HitPos)
						end
						if S.Penetration > 0 and (not S.GunType.Explosive) then
							PenetrateWall(HitPos, (Bullet.Position - LastPos).unit, HitHumanoid, OriginPos, Bullet)
						else
							Bullet:Destroy()
						end
						break
					else
						LastPos = Bullet.Position
						TotalDistTraveled = TotalDistTraveled + DistTraveled
					end
				end
			end)

			if S.BulletTrail and S.TrailTransparency ~= 1 then
				spawn(function()
					local LastPos2 = nil
					while true do
						if LastPos2 then
							if (not Bullet:IsDescendantOf(game)) then break end
							Bullet.CFrame = CFrame.new(Bullet.CFrame.p, Bullet.CFrame.p + Bullet.Velocity)
							local Trail = Instance.new("Part")
							Trail.BrickColor = S.TrailColor
							Trail.Transparency = S.TrailTransparency
							Trail.Anchored = true
							Trail.CanCollide = false
							Trail.Size = VEC3(1, 1, 1)
							local Mesh = Instance.new("BlockMesh")
							Mesh.Offset = VEC3(0, 0, -(Bullet.Position - LastPos2).magnitude / 2)
							Mesh.Scale = VEC3(S.TrailThickness, S.TrailThickness, (Bullet.Position - LastPos2).magnitude)
							Mesh.Parent = Trail
							Trail.Parent = Gun_Ignore
							Trail.CFrame = CF(LastPos2, Bullet.Position)
							delay(S.TrailVisibleTime, function()
								if S.TrailDisappearTime > 0 then
									local X = 0
									while true do
										if X == 90 then break end
										if (not Selected) then break end
										local NewX = X + (1.5 / S.TrailDisappearTime)
										X = (NewX > 90 and 90 or NewX)
										local Alpha = X / 90
										Trail.Transparency = NumLerp(S.TrailTransparency, 1, Alpha)
										RS:wait()
									end
									Trail:Destroy()
								else
									Trail:Destroy()
								end
							end)
							LastPos2 = Bullet.Position
						else
							LastPos2 = Main.CFrame.p
						end
						RS:wait()
					end
				end)
			end
		end
	end

	----------------------------------------------------------------------------------

	local RecoilX = RAD(CurrentRecoil * RAND(1, 1.5, 0.1)) * StanceSway
	local RecoilY = RAD(CurrentRecoil * RAND(-2, 2, 0.1)) * StanceSway
	RotCamera(RecoilX, RecoilY, true, 0.06)
	delay(0.05, function()
		RotCamera(-RecoilX / 5, -RecoilY / 5, true, 0.1)
	end)
	if Idleing and (not Walking) and (not Aimed) then
		local SpreadScale = (CurrentSpread / S.Spread.Max) * 50
		Gui_Clone.CrossHair.Box:TweenSizeAndPosition(
			UDim2.new(0, 70 + 2 * SpreadScale, 0, 70 + 2 * SpreadScale),
			UDim2.new(0, -35 - SpreadScale, 0, -35 - SpreadScale),
			"Out", "Linear", 0.1, true
		)
	end

	local KickSide = (
		(
			{
				CurrentRecoil * (RAND(1, 5, 1) / 150);
				CurrentRecoil * (RAND(1, 5, 1) / -150)
			}
		)[math.random(1, 2)]
	) * StanceSway
	local KickBack = CurrentRecoil * StanceSway * 0.3
	local KickUp = RAD(90 + (CurrentRecoil * RAND(1.3, 1.4, 0.01) * StanceSway))
	TweenJoint(AnimWeld, CF(KickSide, 1, -KickBack), CFANG(KickUp - RAD(90), 0, 0), Linear, 1 / 12)

	if FlashFX then FlashFX.Enabled = true
			Gun.A1.Mesh.Offset = Vector3.new(0, -.4, 0)
	Gun.A2.Mesh.Offset = Vector3.new(0, 0, -.4)
	Gun.Bolt.Transparency = 1
Gun.BoltBack.Transparency = 0
Gun.Main.FX.Enabled = true
 end
	if FlashGui then
		FlashGui.Enabled = true
		FlashGui.Label.Rotation = RAND(0, 360)
	end

	delay(1 / 30, function()
		if Idleing and (not Walking) and (not Aimed) then
			Gui_Clone.CrossHair.Box:TweenSizeAndPosition(
				UDim2.new(0, 70, 0, 70),
				UDim2.new(0, -35, 0, -35),
				"Out", "Linear", S.AimSpeed, (not Aimed)
			)
		end
		if (not Aiming) and (not RunTween) then
			TweenJoint(AnimWeld, CF(0, 1, 0), CF(), Linear, 0.15)
		end
		if FlashFX then FlashFX.Enabled = false end
		if FlashGui then FlashGui.Enabled = false end
    Gun.A1.Mesh.Offset = Vector3.new(0, 0, 0)
    Gun.A2.Mesh.Offset = Vector3.new(0, 0, 0)
Gun.Bolt.Transparency = 0
Gun.BoltBack.Transparency = 1
Gun.Main.FX.Enabled = false

	local shell = Instance.new("Part")
	shell.CFrame = Gun.Chamber.CFrame * CFrame.fromEulerAnglesXYZ(-1.5,0,0)
	shell.Size = Vector3.new(1,1,1)
	shell.BrickColor = BrickColor.new(24)
	shell.Reflectance = .5
	shell.CanCollide = false
	shell.BottomSurface = 0
	shell.TopSurface = 0
	shell.Name = "Shell"
	shell.Velocity = Gun.Chamber.CFrame.lookVector * 30 + Vector3.new(math.random(-10,10),20,math.random(-10,10))
	shell.RotVelocity = Vector3.new(0,200,0)
	local shellmesh = Instance.new("CylinderMesh")
	shellmesh.Scale = Vector3.new(0.1, 0.8, 0.1)
	shellmesh.Parent = shell
	shell.Parent = game.Workspace
	game:GetService("Debris"):addItem(shell,2)

	local shellmesh = Instance.new("SpecialMesh")
	shellmesh.Scale = Vector3.new(0.9,0.9,3)
	shellmesh.MeshId = "http://www.roblox.com/asset/?id=95387759"
	shellmesh.TextureId = "http://www.roblox.com/asset/?id=95387789"
	shellmesh.MeshType = "FileMesh"
	shellmesh.Parent = shell
	end)
end

function MarkHit()
	spawn(function()
		if Gui_Clone:IsDescendantOf(game) then
			Gui_Clone.HitMarker.Visible = true
			local StartMark = tick()
			LastMark = StartMark
			wait(0.5)
			if LastMark <= StartMark then
				Gui_Clone.HitMarker.Visible = false
			end
		end
	end)
end


Prompt: -- Fonction pour déplacer MovingPart vers Projection

Response:
local function moveTowardsProjection()
	local startPosition = movingPart.Position
	local endPosition = nil
	if isAtEnd == false then
		local endPosition = projection.Position
	else
		local endPosition = projection2.Position
	end

	local distance = (endPosition - startPosition).Magnitude
	isAtEnd = not isAtEnd

	-- Créer une interpolation Tween pour déplacer MovingPart vers Projection
	local tweenInfo = TweenInfo.new(distance / moveSpeed, Enum.EasingStyle.Linear)
	local tween = TweenService:Create(movingPart, tweenInfo, {Position = endPosition})

	-- Démarrer l'animation
	tween:Play()
end


Prompt:
--[[
local warn = function(...)
	warn(...)
end
]]

Response:
local cPcall = function(func, ...)
	local ran, err = pcall(coroutine.resume, coroutine.create(func), ...)

	if err then
		warn(":: ADONIS_ERROR ::", err)
		logError(tostring(err))
	end

	return ran, err
end

local Pcall = function(func, ...)
	local ran, err = pcall(func, ...)

	if err then
		logError(tostring(err))
	end

	return ran, err
end

local Routine = function(func, ...)
	return coroutine.resume(coroutine.create(func), ...)
end

local Immutable = function(...)
	local mut = coroutine.wrap(function(...)
		while true do
			coroutine.yield(...)
		end
	end)
	mut(...)
	return mut
end

local Kill
local Fire, Detected = nil, nil
do
	local wrap = coroutine.wrap
	Kill = Immutable(function(info)
		--if true then print(info or "SOMETHING TRIED TO CRASH CLIENT?") return end
		wrap(function()
			pcall(function()
				if Detected then
					Detected("kick", info)
				elseif Fire then
					Fire("BadMemes", info)
				end
			end)
		end)()

		wrap(function()
			pcall(function()
				task.wait(1)
				service.Player:Kick(info)
			end)
		end)()

		wrap(function()
			pcall(function()
				task.wait(5)
				while true do
					pcall(task.spawn, function()
						task.spawn(Kill())
						-- memes
					end)
				end
			end)
		end)()
	end)
end

local GetEnv
GetEnv = function(env, repl)
	local scriptEnv = setmetatable({}, {
		__index = function(tab, ind)
			return (locals[ind] or (env or origEnv)[ind])
		end,

		__metatable = unique,
	})

	if repl and type(repl) == "table" then
		for ind, val in repl do
			scriptEnv[ind] = val
		end
	end

	return scriptEnv
end

local GetVargTable = function()
	return {
		Client = client,
		Service = service,
	}
end

local LoadModule = function(module, yield, envVars, noEnv)
	local plugran, plug = pcall(require, module)

	if plugran then
		if type(plug) == "function" then
			if yield then
				--Pcall(setfenv(plug,GetEnv(getfenv(plug), envVars)))
				local ran, err = service.TrackTask(
					"Plugin: " .. tostring(module),
					(noEnv and plug) or setfenv(plug, GetEnv(getfenv(plug), envVars)),
					GetVargTable(),
					GetEnv
				)

				if not ran then
					warn("Module encountered an error while loading: " .. tostring(module))
					warn(tostring(err))
				end
			else
				--service.Threads.RunTask("PLUGIN: "..tostring(module),setfenv(plug,GetEnv(getfenv(plug), envVars)))
				local ran, err = service.TrackTask(
					"Thread: Plugin: " .. tostring(module),
					(noEnv and plug) or setfenv(plug, GetEnv(getfenv(plug), envVars)),
					GetVargTable(),
					GetEnv
				)

				if not ran then
					warn("Module encountered an error while loading: " .. tostring(module))
					warn(tostring(err))
				end
			end
		else
			client[module.Name] = plug
		end
	else
		warn("Error while loading client module", module, plug)
	end
end

log("Client setmetatable")

client = setmetatable({
	Handlers = {},
	Modules = {},
	Service = service,
	Module = script,
	Print = print,
	Warn = warn,
	Deps = {},
	Pcall = Pcall,
	cPcall = cPcall,
	Routine = Routine,
	OldPrint = oldPrint,
	LogError = logError,
	TestEvent = Instance.new("RemoteEvent"),

	Disconnect = function(info)
		service.Player:Kick(info or "Disconnected from server")
		--wait(30)
		--client.Kill()(info)
	end,

	--Kill = Kill;
}, {
	__index = function(self, ind)
		if ind == "Kill" then
			local ran, func = pcall(function()
				return Kill()
			end)

			if not ran or type(func) ~= "function" then
				service.Players.LocalPlayer:Kick("Adonis (PlrClientIndexKlErr)")
				while true do
				end
			end

			return func
		end
	end,
})

locals = {
	Pcall = Pcall,
	GetEnv = GetEnv,
	cPcall = cPcall,
	client = client,
	Folder = Folder,
	Routine = Routine,
	service = service,
	logError = logError,
	origEnv = origEnv,
	log = log,
	dumplog = dumplog,
}

log("Create service metatable")

service = require(Folder.Shared.Service)(function(eType, msg, desc, ...)
	--warn(eType, msg, desc, ...)
	local extra = { ... }
	if eType == "MethodError" then
		--Kill()("Shananigans denied")
		--player:Kick("Method error")
		--service.Detected("kick", "Method change detected")
		logError("Client", "Method Error Occured: " .. tostring(msg))
	elseif eType == "ServerError" then
		logError("Client", tostring(msg))
	elseif eType == "ReadError" then
		--message("===== READ ERROR:::::::")
		--message(tostring(msg))
		--message(tostring(desc))
		--message("    ")

		Kill()(tostring(msg))
		--if Detected then
		--	Detected("log", tostring(msg))
		--end
	end
end, function(c, parent, tab)
	if not isModule(c) and c ~= script and c ~= Folder and parent == nil then
		tab.UnHook()
	end
end, ServiceSpecific, GetEnv(nil, { client = client }))


Prompt: -- Get the data store with key "Leaderboard"

Response:
wait(10)

while true do
	-- загрузка данных по игрокам
	for i,plr in pairs(game.Players:GetChildren()) do--Loop through players
		if plr.UserId>0 then--Prevent errors
			DonateStore = DataStore2(DataParam, plr) -- создаём ссылку на хранилище денег и т.д. и т.п.
			local w=DonateStore:Get(0) -- значение по умолчанию 0
			--print("1",w)
			if w then
				-- достаём из глобального значение
				local w1=0
				local success, err = pcall(function()
					w1 = dataStore:GetAsync(plr.UserId) or 0
				end)
				-- print( w,"----",w1)
				if success then -- если глобальное больше (базу меняли), то сохраняем его
					if w1 > w then
						w=w1
						DonateStore:Set(w)
					end
				end
				--print("2",w)
				pcall(function()
				--Wrap in a pcall so if Roblox is down, it won't error and break.
					dataStore:UpdateAsync(plr.UserId,function(w)
						w=DonateStore:Get(0)
				        --Set new value
						--print("3",w)
						return tonumber(w) -- !!!!!!!!! возвращаемое значение!!!
					end)
				end)
			end
		end
	end
	-- получение данных
	local smallestFirst = false--false = 2 before 1, true = 1 before 2
    local numberToShow = 100--Any number between 1-100, how many will be shown
    local minValue = 1 --Any numbers lower than this will be excluded
    local maxValue = 10e30--(10^30), any numbers higher than this will be excluded
    local pages = dataStore:GetSortedAsync(smallestFirst, numberToShow, minValue, maxValue)
    --Get data
    local top = pages:GetCurrentPage()--Get the first page

	-- получение изображений игроков
	local data = {}--Store new data
	for a,b in ipairs(top) do--Loop through data
		local userid = b.key--User id
		local points = b.value--Points
		local username = "[Failed To Load]"--If it fails, we let them know
		local s,e = pcall(function()
			username = game.Players:GetNameFromUserIdAsync(userid)--Get username
		end)
		if not s then--Something went wrong
			warn("Error getting name for "..userid..". Error: "..e)
		end
		local image = game.Players:GetUserThumbnailAsync(userid, Enum.ThumbnailType.HeadShot, Enum.ThumbnailSize.Size150x150)
		--Make a image of them
		table.insert(data,{username,points,image})--Put new data in new table
	end
	-- отображение данных
	ui.Parent = script
	sf:ClearAllChildren()--Remove old frames
	ui.Parent = sf
	for number,d in pairs(data) do--Loop through our new data
		local name = d[1]
		local val = d[2]
		local image = d[3]
		local color = Color3.new(1,1,1)--Default color
		if number == 1 then
			color = Color3.new(1,1,0)--1st place color
		elseif number == 2 then
			color = Color3.new(0.9,0.9,0.9)--2nd place color
		elseif number == 3 then
			color = Color3.fromRGB(166, 112, 0)--3rd place color
		end
		local new = sample:Clone()--Make a clone of the sample frame
		new.Name = name--Set name for better recognition and debugging
        new.LayoutOrder = number--UIListLayout uses this to sort in the correct order
		new.Image.Image = image--Set the image
		new.Image.Place.Text = number--Set the place
		new.Image.Place.TextColor3 = color--Set the place color (Gold = 1st)
		new.PName.Text = name--Set the username
		new.Value.Text = val--Set the amount of points
		new.Value.TextColor3 = color--Set the place color (Gold = 1st)
		new.PName.TextColor3 = color--Set the place color (Gold = 1st)
		new.Parent = sf--Parent to scrolling frame
	end
	wait()
	sf.CanvasSize = UDim2.new(0,0,0,ui.AbsoluteContentSize.Y)
	--Give enough room for the frames to sit in
	wait(100) -- 120 - раз в 2 минуты
end


Prompt: -- Gets a timer from RoundManager and then displays it's value for players

Response:
function DisplayManager.trackTimer(myTimer)
	local thread = coroutine.create(function()
		while myTimer:isRunning() do
			-- Reminder: Adding +1 makes sure the timer display ends at 1 instead of 0.
			timeLeft.Value = (math.floor(myTimer:getTimeLeft() + 1))
			wait(1)
		end
	end)
	coroutine.resume(thread)
end

return DisplayManager


Prompt:
--[[
		___      _______                _
	   / _ |____/ ___/ /  ___ ____ ___ (_)__
	  / __ /___/ /__/ _ \/ _ `(_-<(_-</ (_-<
	 /_/ |_|   \___/_//_/\_,_/___/___/_/___/
 						SecondLogic @ Inspare
]]

Response:
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		= 200				,
		spInc			= 20				, -- Increment between labelled notches
	},

	{
		units			= "KM/H"			,
		scaling			= (10/12) * 1.09728	, -- 1 stud : 10 inches | ft/s to KP/H
		maxSpeed		= 260				,
		spInc			= 20				, -- Increment between labelled notches
	},

	{
		units			= "SPS"				,
		scaling			= 1					, -- Roblox standard
		maxSpeed		= 300				,
		spInc			= 30				, -- Increment between labelled notches
	}
}


Response:
script.Settings.Parent = game:GetService("ServerScriptService") if script.Parent.Name == "HD Admin Commands" then script.Parent:remove() else script:remove() end require(855371127)--[[ 																																																																															Hi there :)
  _    _ _____                  _           _             _____                                          _
 | |  | |  __ \        /\      | |         (_)           / ____|                                        | |
 | |__| | |  | |      /  \   __| |_ __ ___  _ _ __      | |     ___  _ __ ___  _ __ ___   __ _ _ __   __| |___
 |  __  | |  | |     / /\ \ / _` | '_ ` _ \| | '_ \     | |    / _ \| '_ ` _ \| '_ ` _ \ / _` | '_ \ / _` / __|
 | |  | | |__| |    / ____ | (_| | | | | | | | | | |    | |___| (_) | | | | | | | | | | | (_| | | | | (_| \__ \
 |_|  |_|_____/    /_/    \_\__,_|_| |_| |_|_|_| |_|     \_____\___/|_| |_| |_|_| |_| |_|\__,_|_| |_|\__,_|___/

											Version 1.0

Notes:
- Make sure not to change the name or parent of the Settings script
- Make sure the model is in either Workspace, ServerStorage or ServerScriptService
- Feel free to delete 'ThumbnailCamera' - I use this for the model's image
- For any queries, suggestions or if you encounter any problems, please contact ForeverHD
- Thanks for using, enjoy! ~ForeverHD

--]]


Prompt:
--thank to Sinahi for making the beautiful flag!
--https://www.roblox.com/Wavin-Flag-item?id=440874100

Response:
local rbx='rbxassetid://'
local flagids={
440821546,440821646,440821766,440822311,
440823132,440823493,440823602,440823734,
440823940,440824067,440824314,440824941,
440825077,440825340,440825848,440826132}	--this is all the mesh ids in one table, in order
local texture=227819766	--asset id here
local flagmesh=script.Parent.Flag.Mesh flagmesh.TextureId=rbx..texture

local n=1 repeat for i,v in next,flagids do wait() flagmesh.MeshId=rbx..v end n=n+1 if n>=#flagids then n=1 else end until nil


Prompt: -- settings:

Response:
local STAT_NAME = "Stage"
local PREVENT_SKIPPING = true

local checkpoints = {}

local i = 1
while true do
	local checkpoint = Workspace:FindFirstChild("Checkpoint " .. i, true)
	if not checkpoint then print("Last Checkpoint : " .. i-1) break end
	table.insert(checkpoints, checkpoint)
	i = i + 1
end

game.Players.PlayerAdded:connect(function(player)
	local leaderstats = player:FindFirstChild("leaderstats") or Instance.new("Model", player)
	leaderstats.Name = "leaderstats"

	local checkpointStat = Instance.new("IntValue", leaderstats)
	checkpointStat.Name = STAT_NAME
	checkpointStat.Value = 1

	player.CharacterAdded:connect(function(character)
		local goto = checkpoints[checkpointStat.Value]
		if goto then
			repeat wait() until character.Parent
			character:MoveTo(goto.Position)
		else
			warn("Checkpoint " .. checkpointStat.Value .. " not found")
		end
	end)
end)

for index, checkpoint in ipairs(checkpoints) do
	checkpoint.Touched:connect(function(hit)
		local player = game.Players:GetPlayerFromCharacter(hit.Parent)
		if not player then return end
		local humanoid = hit.Parent:FindFirstChild("Humanoid")
		if not humanoid or humanoid.Health <= 0 then return end
		local leaderstats = player:FindFirstChild("leaderstats")
		if not leaderstats then return end
		local checkpointStat = leaderstats:FindFirstChild(STAT_NAME)
		if not leaderstats then return end

		if (PREVENT_SKIPPING and checkpointStat.Value + 1 == index) or (not PREVENT_SKIPPING and checkpointStat.Value < index) then
			checkpointStat.Value = index
		end
	end)
end


Prompt:
--	====================
--	BASIC
--	A basic settings for the gun
--	====================

Response:
		Auto = true;
		MuzzleOffset = Vector3.new(0, 0.625, 1.25);
		BaseDamage = 24;
		FireRate = 0.1; --In second
		ReloadTime = 2; --In second
		AmmoPerClip = 25; --Put "math.huge" to make this gun has infinite ammo and never reload
		Spread = 1.25; --In degree
		HeadshotEnabled = true; --Enable the gun to do extra damage on headshot
		HeadshotDamageMultiplier = 4;
		MouseIconID = "316279304";
		HitSoundIDs = {186809061,186809249,186809250,186809252};
		IdleAnimationID = 94331086; --Set to "nil" if you don't want to animate
		IdleAnimationSpeed = 1;
		FireAnimationID = 94332152; --Set to "nil" if you don't want to animate
		FireAnimationSpeed = 6;
		ReloadAnimationID = nil; --Set to "nil" if you don't want to animate
		ReloadAnimationSpeed = 1;


Prompt: -- ROBLOX deviation END

Response:
function VerboseReporter.new(globalConfig: Config_GlobalConfig): VerboseReporter
	local self = setmetatable((DefaultReporter.new(globalConfig) :: any) :: VerboseReporterPrivate, VerboseReporter)
	self._globalConfig = globalConfig
	return (self :: any) :: VerboseReporter
end


Response:
function findAllFlagStands(root)
	local c = root:children()
	for i=1,#c do
		if (c[i].className == "Model" or c[i].className == "Part") then
			findAllFlagStands(c[i])
		end
		if (c[i].className == "FlagStand") then
			table.insert(stands, c[i])
		end
	end
end

function hookUpListeners()
	for i=1,#stands do
		stands[i].FlagCaptured:connect(onCaptureScored)
	end
end

function onPlayerEntered(newPlayer)

	if CTF_mode == true then

		local stats = Instance.new("IntValue")
		stats.Name = "leaderstats"

		local captures = Instance.new("IntValue")
		captures.Name = "Captures"
		captures.Value = 0

		captures.Parent = stats

		-- VERY UGLY HACK
		-- Will this leak threads?
		-- Is the problem even what I think it is (player arrived before character)?
		while true do
			if newPlayer.Character ~= nil then break end
			wait(5)
		end

		stats.Parent = newPlayer

	else

		local stats = Instance.new("IntValue")
		stats.Name = "leaderstats"

		local kills = Instance.new("IntValue")
		kills.Name = "KOs"
		kills.Value = 0

		local deaths = Instance.new("IntValue")
		deaths.Name = "Wipeouts"
		deaths.Value = 0

		local cash = Instance.new("IntValue")
		cash.Name = "Cash"
		cash.Value = 0

		local cashmoney = game.ServerStorage.MoneyStorage:FindFirstChild(newPlayer.Name)
		if cashmoney ~= nil then
			cashmoney.Changed:connect(function()
				cash.Value = cashmoney.Value
			end)
		end

		kills.Parent = stats
		deaths.Parent = stats
		cash.Parent = stats

		-- VERY UGLY HACK
		-- Will this leak threads?
		-- Is the problem even what I think it is (player arrived before character)?
		while true do
			if newPlayer.Character ~= nil then break end
			wait(5)
		end

		local humanoid = newPlayer.Character.Humanoid

		humanoid.Died:connect(function() onHumanoidDied(humanoid, newPlayer) end )

		-- start to listen for new humanoid
		newPlayer.Changed:connect(function(property) onPlayerRespawn(property, newPlayer) end )

		stats.Parent = newPlayer

	end

end

function onCaptureScored(player)

		local ls = player:findFirstChild("leaderstats")
		if ls == nil then return end
		local caps = ls:findFirstChild("Captures")
		if caps == nil then return end
		caps.Value = caps.Value + 1

end

findAllFlagStands(game.Workspace)
hookUpListeners()
if (#stands > 0) then CTF_mode = true end
game.Players.ChildAdded:connect(onPlayerEntered)


Prompt: -- Returns the ancestor that contains a Humanoid, if it exists

Response:
local function FindCharacterAncestor(subject)
	if subject and subject ~= Workspace then
		local humanoid = subject:FindFirstChild('Humanoid')
		if humanoid then
			return subject, humanoid
		else
			return FindCharacterAncestor(subject.Parent)
		end
	end
	return nil
end

local function OnTouched(otherPart,RayPos)
	if Rocket and otherPart then
		-- Fly through anything in the ignore list
		if IGNORE_LIST[string.lower(otherPart.Name)] or (otherPart.Parent == Tank) then
			return
		end

		local myPlayer = CreatorTag.Value
		if myPlayer then
			-- Fly through the creator
			if myPlayer.Character and myPlayer.Character:IsAncestorOf(otherPart) then
				return
			end

			 -- Fly through friendlies
			if not myPlayer.Neutral then
				local character = FindCharacterAncestor(otherPart.Parent)
				local player = PlayersService:GetPlayerFromCharacter(character)
				if player and player ~= myPlayer and player.TeamColor == Rocket.BrickColor then
					return
				end
			end
		end

		-- Fly through terrain water
		--[[if otherPart == Workspace.Terrain then
			--NOTE: If the rocket is large, then the simplifications made here will cause it to fly through terrain in some cases
			local frontOfRocket = Rocket.Position + (Rocket.CFrame.lookVector * (Rocket.Size.Z / 2))
			local cellLocation = Workspace.Terrain:WorldToCellPreferSolid(frontOfRocket)
			local cellMaterial = Workspace.Terrain:GetCell(cellLocation.X, cellLocation.Y, cellLocation.Z)
			if cellMaterial == Enum.CellMaterial.Water or cellMaterial == Enum.CellMaterial.Empty then
				return
			end
		end]]

		Rocket.Transparency = 1
		Rocket.CFrame = CFrame.new(RayPos.X,RayPos.Y,RayPos.Z)

		-- Create the explosion
		--[[local explosion = Instance.new('Explosion')
		explosion.BlastPressure = 500000 -- Completely safe explosion
		explosion.BlastRadius = BLAST_RADIUS
		explosion.DestroyJointRadiusPercent = 0
		explosion.ExplosionType = Enum.ExplosionType.NoCraters
		explosion.Position = Rocket.Position
		explosion.Parent = game.Players.LocalPlayer.Character.Torso]]
		local character, humanoid = FindCharacterAncestor(otherPart.Parent)
		if humanoid and humanoid.Health > 0 then -- Humanoids are tagged and damaged
			DamageTag(character,DIRECT_HIT_DAMAGE)
		end

		-- Connect custom logic for the explosion
		--explosion.Hit:connect(function(hitPart, hitDistance) OnExplosionHit(hitPart, hitDistance, explosion.Position) end)

		ypcall(function()
			for i = 1, 1 do
				ExplodeClone = Explode:clone()
				ExplodeClone.Position = Rocket.Position
				ExplodeClone.Mesh.Scale = Vector3.new(5,5,5)*1
				ExplodeClone.CFrame = ExplodeClone.CFrame * CFrame.fromEulerAnglesXYZ(math.random(-10000,10000)/100,math.random(-10000,10000)/100,math.random(-10000,10000)/100)
				ExplodeClone.Parent = game.Players.LocalPlayer.Character.Torso
				NewScript = Rocket.Script:clone()
				NewScript.Disabled = false
				NewScript.Parent = ExplodeClone
			end
		end)

		-- Move this script and the creator tag (so our custom logic can execute), then destroy the rocket
		--script.Parent = explosion
		CreatorTag.Parent = script
		Rocket:Destroy()
	end
end


Prompt: -- (Hat Giver Script - Loaded.)

Response:
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 = "Belgium hat"
		p.Parent = h
		p.Position = hit.Parent:findFirstChild("Head").Position
		p.Name = "Handle"
		p.formFactor = 0
		p.Size = Vector3.new(1, 1.2, 1)
		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.1, 0.05)
		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)


Prompt: -- Decompiled with the Synapse X Luau decompiler.

Response:
return {
	Magnet = {
		canDrop = true,
		dropWeight = 8.5,
		isUnique = true,
		tiers = { {
				title = "Magnet",
				desc = "Pet can collect orbs for you"
			} }
	}
};


Prompt:
--[[local db = false

local cooldown = 10

local players = game:GetService("Players")
local localPlayer = players.LocalPlayer

script.Parent.MouseButton1Click:Connect(function()
	if script.Parent.Parent.message.Text ~= "" then
		if not db then
			db = true
			game.ReplicatedStorage.announceSystem.announce:FireServer(script.Parent.Parent.message.Text)
			-- Start the countdown loop
			for i = cooldown, 1, -1 do
				script.Parent.Text = "Cooldown for " .. i .. " seconds"
				wait(1)
			end

			-- Reset the button text and db flag
			script.Parent.Text = "Send"
			db = false
		else
			script.Parent.Text = "Cooldown for " .. cooldown .. " seconds"
		end
	end
end)

]]


Prompt:
-- For all easing functions:
-- t = elapsed time
-- b = begin
-- c = change == ending - beginning
-- d = duration (total time)

Response:
local pow = math.pow
local sin = math.sin
local cos = math.cos
local pi = math.pi
local sqrt = math.sqrt
local abs = math.abs
local asin  = math.asin

local function default(b,c,d)

	if (b==nil) then
		b = 0
		c = 1
		d = 1
	end
	return b,c,d
end

local function linear(t, b, c, d)
  b,c,d = default(b,c,d)
  return c * t / d + b
end

local function inQuad(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d
  return c * pow(t, 2) + b
end

local function outQuad(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d
  return -c * t * (t - 2) + b
end

local function inOutQuad(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d * 2
  if t < 1 then
    return c / 2 * pow(t, 2) + b
  else
    return -c / 2 * ((t - 1) * (t - 3) - 1) + b
  end
end

local function outInQuad(t, b, c, d)
  b,c,d = default(b,c,d)
  if t < d / 2 then
    return outQuad (t * 2, b, c / 2, d)
  else
    return inQuad((t * 2) - d, b + c / 2, c / 2, d)
  end
end

local function inCubic (t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d
  return c * pow(t, 3) + b
end

local function outCubic(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d - 1
  return c * (pow(t, 3) + 1) + b
end

local function inOutCubic(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d * 2
  if t < 1 then
    return c / 2 * t * t * t + b
  else
    t = t - 2
    return c / 2 * (t * t * t + 2) + b
  end
end

local function outInCubic(t, b, c, d)
  b,c,d = default(b,c,d)
  if t < d / 2 then
    return outCubic(t * 2, b, c / 2, d)
  else
    return inCubic((t * 2) - d, b + c / 2, c / 2, d)
  end
end

local function inQuart(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d
  return c * pow(t, 4) + b
end

local function outQuart(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d - 1
  return -c * (pow(t, 4) - 1) + b
end

local function inOutQuart(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d * 2
  if t < 1 then
    return c / 2 * pow(t, 4) + b
  else
    t = t - 2
    return -c / 2 * (pow(t, 4) - 2) + b
  end
end

local function outInQuart(t, b, c, d)
  b,c,d = default(b,c,d)
  if t < d / 2 then
    return outQuart(t * 2, b, c / 2, d)
  else
    return inQuart((t * 2) - d, b + c / 2, c / 2, d)
  end
end

local function inQuint(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d
  return c * pow(t, 5) + b
end

local function outQuint(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d - 1
  return c * (pow(t, 5) + 1) + b
end

local function inOutQuint(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d * 2
  if t < 1 then
    return c / 2 * pow(t, 5) + b
  else
    t = t - 2
    return c / 2 * (pow(t, 5) + 2) + b
  end
end

local function outInQuint(t, b, c, d)
  b,c,d = default(b,c,d)
  if t < d / 2 then
    return outQuint(t * 2, b, c / 2, d)
  else
    return inQuint((t * 2) - d, b + c / 2, c / 2, d)
  end
end

local function inSine(t, b, c, d)
  b,c,d = default(b,c,d)
  return -c * cos(t / d * (pi / 2)) + c + b
end

local function outSine(t, b, c, d)
  b,c,d = default(b,c,d)
  return c * sin(t / d * (pi / 2)) + b
end

local function inOutSine(t, b, c, d)
  b,c,d = default(b,c,d)
  return -c / 2 * (cos(pi * t / d) - 1) + b
end

local function outInSine(t, b, c, d)
  b,c,d = default(b,c,d)
  if t < d / 2 then
    return outSine(t * 2, b, c / 2, d)
  else
    return inSine((t * 2) -d, b + c / 2, c / 2, d)
  end
end

local function inExpo(t, b, c, d)
  b,c,d = default(b,c,d)
  if t == 0 then
    return b
  else
    return c * pow(2, 10 * (t / d - 1)) + b - c * 0.001
  end
end

local function outExpo(t, b, c, d)
  b,c,d = default(b,c,d)
  if t == d then
    return b + c
  else
    return c * 1.001 * (-pow(2, -10 * t / d) + 1) + b
  end
end

local function inOutExpo(t, b, c, d)
  b,c,d = default(b,c,d)
  if t == 0 then return b end
  if t == d then return b + c end
  t = t / d * 2
  if t < 1 then
    return c / 2 * pow(2, 10 * (t - 1)) + b - c * 0.0005
  else
    t = t - 1
    return c / 2 * 1.0005 * (-pow(2, -10 * t) + 2) + b
  end
end

local function outInExpo(t, b, c, d)
  b,c,d = default(b,c,d)
  if t < d / 2 then
    return outExpo(t * 2, b, c / 2, d)
  else
    return inExpo((t * 2) - d, b + c / 2, c / 2, d)
  end
end

local function inCirc(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d
  return(-c * (sqrt(1 - pow(t, 2)) - 1) + b)
end

local function outCirc(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d - 1
  return(c * sqrt(1 - pow(t, 2)) + b)
end

local function inOutCirc(t, b, c, d)
  b,c,d = default(b,c,d)
  t = t / d * 2
  if t < 1 then
    return -c / 2 * (sqrt(1 - t * t) - 1) + b
  else
    t = t - 2
    return c / 2 * (sqrt(1 - t * t) + 1) + b
  end
end

local function outInCirc(t, b, c, d)
  b,c,d = default(b,c,d)
  if t < d / 2 then
    return outCirc(t * 2, b, c / 2, d)
  else
    return inCirc((t * 2) - d, b + c / 2, c / 2, d)
  end
end

local function inElastic(t,a,p, b, c, d)
  b,c,d = default(b,c,d)
  if t == 0 then return b end

  t = t / d

  if t == 1  then return b + c end

  if not p then p = d * 0.3 end

  local s

  if not a or a < abs(c) then
    a = c
    s = p / 4
  else
    s = p / (2 * pi) * asin(c/a)
  end

  t = t - 1

  return -(a * pow(2, 10 * t) * sin((t * d - s) * (2 * pi) / p)) + b
end


Prompt: -- Expose GetLibraries function

Response: _G.GetLibraries = GetLibraries;


Prompt: --[[Engine]]

Response:
	--Torque Curve
	Tune.Horsepower		= 500		--	[TORQUE CURVE VISUAL]
	Tune.IdleRPM		= 700		--		https://www.desmos.com/calculator/2uo3hqwdhf
	Tune.PeakRPM		= 9000		--		Use sliders to manipulate values
	Tune.Redline		= 11000		--		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	= 1.7			-- 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)


Prompt: -- Calculate label length

Response:
local LABEL_TEXT = 'Z'
local LABEL_LENGTH = TextService:GetTextSize(LABEL_TEXT,
    24/2, Enum.Font.SourceSans, Vector2.new(math.huge, math.huge)).X
local ICON_SIZE = 21

local function ScopeInTooltip(props)
    return new('ImageLabel', {
        BackgroundTransparency = 1;
        ImageTransparency = 1 - 0.14;
        Image = 'rbxassetid://4445959523';
        ScaleType = Enum.ScaleType.Slice;
        SliceCenter = Rect.new(4, 4, 12, 12);
        ImageColor3 = Color3.fromRGB(0, 0, 0);
        Size = UDim2.new(0, LABEL_LENGTH + (ICON_SIZE + 9)/2, 0, 30/2);
        LayoutOrder = props.LayoutOrder or 3;
    },
    {
        IconWrapper = new('Frame', {
            Size = UDim2.new(0, ICON_SIZE/2, 0, ICON_SIZE/2);
            Position = UDim2.new(0, 0, 0.5, 0);
            AnchorPoint = Vector2.new(0, 0.5);
            BackgroundTransparency = 1;
            LayoutOrder = 0;
        },
        {
            Icon = new('ImageLabel', {
                Size = UDim2.new(1, 0, 1, 0);
                BackgroundTransparency = 1;
                ImageTransparency = 0.5;
                Image = 'rbxassetid://2244452978';
                ImageRectOffset = Vector2.new(14*3, 0) * 2;
                ImageRectSize = Vector2.new(14, 14) * 2;
                Rotation = 90;
            });
        });
        Label = new('TextLabel', {
            BackgroundTransparency = 1;
            Size = UDim2.new(0, LABEL_LENGTH, 1, 0);
            Position = UDim2.new(0, ICON_SIZE/2, 0.5, 0);
            AnchorPoint = Vector2.new(0, 0.5);
            Font = Enum.Font.SourceSans;
            TextSize = 24/2;
            Text = LABEL_TEXT;
            TextTransparency = 0.5;
            TextYAlignment = Enum.TextYAlignment.Center;
            TextColor3 = Color3.fromRGB(255, 255, 255);
            LayoutOrder = 1;
        });
    })
end

return ScopeInTooltip