Prompt: -- light functions

Response:
F.SignalLeft = function(flash_rate, state, active, tb, type, seq, max_segs, current_segment)
	if active then
		if not seq then
			if state then
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[5], t, {ImageTransparency = 0})
					gtwe:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							local tw = TweenService:Create(child, t, {Brightness = 1, Range = 16})
							tw:Play()
						elseif child.Name == "LN" then
							local tw = TweenService:Create(child, t, {Transparency = 0.02})
							tw:Play()
						end
					end
				elseif type == "LED" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[5], t, {ImageTransparency = 0})
					gtwe:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							child.Brightness = 1
							child.Range = 16
						elseif child.Name == "LN" then
							child.Transparency = 0.02
						end
					end
				end
				wait(flash_rate)
			else
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[5], t, {ImageTransparency = 1})
					gtwe:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
							tw:Play()
						elseif child.Name == "LN" then
							local tw = TweenService:Create(child, t, {Transparency = 1})
							tw:Play()
						end
					end
				elseif type == "LED" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[5], t, {ImageTransparency = 1})
					gtwe:Play()

						for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							child.Brightness = 0
							child.Range = 0
						elseif child.Name == "LN" then
							child.Transparency = 1
						end
					end
				end
				wait(flash_rate)
			end
		else
			if state then
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[5], t, {ImageTransparency = 0})
					gtwe:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child.Name == "SI"..tostring(current_segment) then
							local tw = TweenService:Create(child, t, {Transparency = 0.02})
							tw:Play()
						end
					end
				elseif type == "LED" then
					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child.Name == "SI"..tostring(current_segment) then
							child.Transparency = 0.02
						end
					end
				end
			else
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[5], t, {ImageTransparency = 1})
					gtwe:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if string.sub(child.Name, 1, 2) == "SI" then
							local tw = TweenService:Create(child, t, {Transparency = 1})
							tw:Play()
						end
					end
				elseif type == "LED" then
					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if string.sub(child.Name, 1, 2) == "SI" then
							child.Transparency = 1
						end
					end
				end
			end
		end
	else
		if not seq then
			if type == "Halogen" then
				local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

				local gtwe = TweenService:Create(tb[5], t, {ImageTransparency = 1})
				gtwe:Play()

				for idx, child in pairs(lights.LeftInd:GetDescendants()) do
					if child:IsA("SpotLight") then
						local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
						tw:Play()
					elseif child.Name == "LN" then
						local tw = TweenService:Create(child, t, {Transparency = 1})
						tw:Play()
					end
				end
			elseif type == "LED" then
				for idx, child in pairs(lights.LeftInd:GetDescendants()) do
					if child:IsA("SpotLight") then
						child.Brightness = 0
						child.Range = 0
					elseif child.Name == "LN" then
						child.Transparency = 1
					end
				end
			end
			wait(flash_rate)
		else
			if state then
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[5], t, {ImageTransparency = 0})
					gtwe:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child.Name == "SI"..tostring(current_segment) then
							local tw = TweenService:Create(child, t, {Transparency = 0.02})
							tw:Play()
						end
					end
				elseif type == "LED" then
					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child.Name == "SI"..tostring(current_segment) then
							child.Transparency = 0.02
						end
					end
				end
			else
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[5], t, {ImageTransparency = 1})
					gtwe:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if string.sub(child.Name, 1, 2) == "SI" then
							local tw = TweenService:Create(child, t, {Transparency = 1})
							tw:Play()
						end
					end
				elseif type == "LED" then
					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if string.sub(child.Name, 1, 2) == "SI" then
							child.Transparency = 1
						end
					end
				end
			end
		end
	end
end

F.SignalRight = function(flash_rate, state, active, tb, type, seq, max_segs, current_segment)
	if active then
		if not seq then
			if state then
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[6], t, {ImageTransparency = 0})
					gtwe:Play()

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							local tw = TweenService:Create(child, t, {Brightness = 1, Range = 16})
							tw:Play()
						elseif child.Name == "LN" then
							local tw = TweenService:Create(child, t, {Transparency = 0.02})
							tw:Play()
						end
					end
				elseif type == "LED" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[6], t, {ImageTransparency = 0})
					gtwe:Play()

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							child.Brightness = 1
							child.Range = 16
						elseif child.Name == "LN" then
							child.Transparency = 0.02
						end
					end
				end
				wait(flash_rate)
			else
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[6], t, {ImageTransparency = 1})
					gtwe:Play()

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
							tw:Play()
						elseif child.Name == "LN" then
							local tw = TweenService:Create(child, t, {Transparency = 1})
							tw:Play()
						end
					end
				elseif type == "LED" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[6], t, {ImageTransparency = 1})
					gtwe:Play()

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							child.Brightness = 0
							child.Range = 0
						elseif child.Name == "LN" then
							child.Transparency = 1
						end
					end
				end
				wait(flash_rate)
			end
		else
			if state then
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[6], t, {ImageTransparency = 0})
					gtwe:Play()

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child.Name == "SI"..tostring(current_segment) then
							local tw = TweenService:Create(child, t, {Transparency = 0.02})
							tw:Play()
						end
					end
				elseif type == "LED" then
					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child.Name == "SI"..tostring(current_segment) then
							child.Transparency = 0.02
						end
					end
				end
			else
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[6], t, {ImageTransparency = 1})
					gtwe:Play()

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if string.sub(child.Name, 1, 2) == "SI" then
							local tw = TweenService:Create(child, t, {Transparency = 1})
							tw:Play()
						end
					end
				elseif type == "LED" then
					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if string.sub(child.Name, 1, 2) == "SI" then
							child.Transparency = 1
						end
					end
				end
			end
		end
	else
		if not seq then
			if type == "Halogen" then
				local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

				local gtwe = TweenService:Create(tb[6], t, {ImageTransparency = 1})
				gtwe:Play()

				for idx, child in pairs(lights.RightInd:GetDescendants()) do
					if child:IsA("SpotLight") then
						local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
						tw:Play()
					elseif child.Name == "LN" then
						local tw = TweenService:Create(child, t, {Transparency = 1})
						tw:Play()
					end
				end
			elseif type == "LED" then
				for idx, child in pairs(lights.RightInd:GetDescendants()) do
					if child:IsA("SpotLight") then
						child.Brightness = 0
						child.Range = 0
					elseif child.Name == "LN" then
						child.Transparency = 1
					end
				end
			end
			wait(flash_rate)
		else
			if state then
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[6], t, {ImageTransparency = 0})
					gtwe:Play()

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child.Name == "SI"..tostring(current_segment) then
							local tw = TweenService:Create(child, t, {Transparency = 0.02})
							tw:Play()
						end
					end
				elseif type == "LED" then
					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child.Name == "SI"..tostring(current_segment) then
							child.Transparency = 0.02
						end
					end
				end
			else
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe = TweenService:Create(tb[6], t, {ImageTransparency = 1})
					gtwe:Play()

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if string.sub(child.Name, 1, 2) == "SI" then
							local tw = TweenService:Create(child, t, {Transparency = 1})
							tw:Play()
						end
					end
				elseif type == "LED" then
					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if string.sub(child.Name, 1, 2) == "SI" then
							child.Transparency = 1
						end
					end
				end
			end
		end
	end
end

F.Hazards = function(flash_rate, state, active, tb, type, seq, max_segs, current_segment)
	if active then
		if not seq then
			if state then
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe1 = TweenService:Create(tb[5], t, {ImageTransparency = 0})
					local gtwe2 = TweenService:Create(tb[6], t, {ImageTransparency = 0})
					gtwe1:Play()
					gtwe2:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child:IsA("SpotLight") then
						local tw = TweenService:Create(child, t, {Brightness = 1, Range = 16})
							tw:Play()
						elseif child.Name == "LN" then
							local tw = TweenService:Create(child, t, {Transparency = 0.02})
							tw:Play()
						end
					end

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							local tw = TweenService:Create(child, t, {Brightness = 1, Range = 16})
							tw:Play()
						elseif child.Name == "LN" then
							local tw = TweenService:Create(child, t, {Transparency = 0.02})
							tw:Play()
						end
					end
				elseif type == "LED" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe1 = TweenService:Create(tb[5], t, {ImageTransparency = 0})
					local gtwe2 = TweenService:Create(tb[6], t, {ImageTransparency = 0})
					gtwe1:Play()
					gtwe2:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							child.Brightness = 2
							child.Range = 16
						elseif child.Name == "LN" then
							child.Transparency = 0
						end
					end

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							child.Brightness = 2
							child.Range = 16
						elseif child.Name == "LN" then
							child.Transparency = 0
						end
					end
				end

				wait(flash_rate)
			else
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe1 = TweenService:Create(tb[5], t, {ImageTransparency = 1})
					local gtwe2 = TweenService:Create(tb[6], t, {ImageTransparency = 1})
					gtwe1:Play()
					gtwe2:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
							tw:Play()
						elseif child.Name == "LN" then
							local tw = TweenService:Create(child, t, {Transparency = 1})
							tw:Play()
						end
					end

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
							tw:Play()
						elseif child.Name == "LN" then
							local tw = TweenService:Create(child, t, {Transparency = 1})
							tw:Play()
						end
					end
				elseif type == "LED" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe1 = TweenService:Create(tb[5], t, {ImageTransparency = 1})
					local gtwe2 = TweenService:Create(tb[6], t, {ImageTransparency = 1})
					gtwe1:Play()
					gtwe2:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							child.Brightness = 0
							child.Range = 0
						elseif child.Name == "LN" then
							child.Transparency = 1
						end
					end

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child:IsA("SpotLight") then
							child.Brightness = 0
							child.Range = 0
						elseif child.Name == "LN" then
							child.Transparency = 1
						end
					end
				end
				wait(flash_rate)
			end
		else
			if state then
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe1 = TweenService:Create(tb[5], t, {ImageTransparency = 0})
					local gtwe2 = TweenService:Create(tb[6], t, {ImageTransparency = 0})
					gtwe1:Play()
					gtwe2:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child.Name == "SI"..tostring(current_segment) then
							local tw = TweenService:Create(child, t, {Transparency = 0.02})
							tw:Play()
						end
					end

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child.Name == "SI"..tostring(current_segment) then
							local tw = TweenService:Create(child, t, {Transparency = 0.02})
							tw:Play()
						end
					end
				elseif type == "LED" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe1 = TweenService:Create(tb[5], t, {ImageTransparency = 0})
					local gtwe2 = TweenService:Create(tb[6], t, {ImageTransparency = 0})
					gtwe1:Play()
					gtwe2:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if child.Name == "SI"..tostring(current_segment) then
							child.Transparency = 0.02
						end
					end

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if child.Name == "SI"..tostring(current_segment) then
							child.Transparency = 0.02
						end
					end
				end

				wait(flash_rate)
			else
				if type == "Halogen" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe1 = TweenService:Create(tb[5], t, {ImageTransparency = 1})
					local gtwe2 = TweenService:Create(tb[6], t, {ImageTransparency = 1})
					gtwe1:Play()
					gtwe2:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if string.sub(child.Name, 1, 2) == "SI" then
							local tw = TweenService:Create(child, t, {Transparency = 1})
							tw:Play()
						end
					end

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if string.sub(child.Name, 1, 2) == "SI" then
							local tw = TweenService:Create(child, t, {Transparency = 1})
							tw:Play()
						end
					end
				elseif type == "LED" then
					local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

					local gtwe1 = TweenService:Create(tb[5], t, {ImageTransparency = 1})
					local gtwe2 = TweenService:Create(tb[6], t, {ImageTransparency = 1})
					gtwe1:Play()
					gtwe2:Play()

					for idx, child in pairs(lights.LeftInd:GetDescendants()) do
						if string.sub(child.Name, 1, 2) == "SI" then
							child.Transparency = 1
						end
					end

					for idx, child in pairs(lights.RightInd:GetDescendants()) do
						if string.sub(child.Name, 1, 2) == "SI" then
							child.Transparency = 1
						end
					end
				end
				wait(flash_rate)
			end
		end
	else
		if not seq then
			if type == "Halogen" then
				local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

				local gtwe1 = TweenService:Create(tb[5], t, {ImageTransparency = 1})
				local gtwe2 = TweenService:Create(tb[6], t, {ImageTransparency = 1})
				gtwe1:Play()
				gtwe2:Play()

				for idx, child in pairs(lights.LeftInd:GetDescendants()) do
					if child:IsA("SpotLight") then
						local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
						tw:Play()
					elseif child.Name == "LN" then
						local tw = TweenService:Create(child, t, {Transparency = 1})
						tw:Play()
					end
				end

				for idx, child in pairs(lights.RightInd:GetDescendants()) do
					if child:IsA("SpotLight") then
						local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
						tw:Play()
					elseif child.Name == "LN" then
						local tw = TweenService:Create(child, t, {Transparency = 1})
						tw:Play()
					end
				end
			elseif type == "LED" then
				local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

				local gtwe1 = TweenService:Create(tb[5], t, {ImageTransparency = 1})
				local gtwe2 = TweenService:Create(tb[6], t, {ImageTransparency = 1})
				gtwe1:Play()
				gtwe2:Play()

				for idx, child in pairs(lights.LeftInd:GetDescendants()) do
					if child:IsA("SpotLight") then
						child.Brightness = 0
						child.Range = 0
					elseif child.Name == "LN" then
						child.Transparency = 1
					end
				end

				for idx, child in pairs(lights.RightInd:GetDescendants()) do
					if child:IsA("SpotLight") then
						child.Brightness = 0
						child.Range = 0
					elseif child.Name == "LN" then
						child.Transparency = 1
					end
				end
			end
			wait(flash_rate)
		else
			if type == "Halogen" then
				local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

				local gtwe1 = TweenService:Create(tb[5], t, {ImageTransparency = 1})
				local gtwe2 = TweenService:Create(tb[6], t, {ImageTransparency = 1})
				gtwe1:Play()
				gtwe2:Play()

				for idx, child in pairs(lights.LeftInd:GetDescendants()) do
					if string.sub(child.Name, 1, 2) == "SI" then
						local tw = TweenService:Create(child, t, {Transparency = 1})
						tw:Play()
					end
				end

				for idx, child in pairs(lights.RightInd:GetDescendants()) do
					if string.sub(child.Name, 1, 2) == "SI" then
						local tw = TweenService:Create(child, t, {Transparency = 1})
						tw:Play()
					end
				end
			elseif type == "LED" then
				local t = TweenInfo.new(flash_rate / 2.5, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

				local gtwe1 = TweenService:Create(tb[5], t, {ImageTransparency = 1})
				local gtwe2 = TweenService:Create(tb[6], t, {ImageTransparency = 1})
				gtwe1:Play()
				gtwe2:Play()

				for idx, child in pairs(lights.LeftInd:GetDescendants()) do
					if string.sub(child.Name, 1, 2) == "SI" then
						child.Transparency = 1
					end
				end

				for idx, child in pairs(lights.RightInd:GetDescendants()) do
					if string.sub(child.Name, 1, 2) == "SI" then
						child.Transparency = 1
					end
				end
			end
			wait(flash_rate)
		end
	end
end

F.Headlights = function(state, fade_time, tb, type)
	if type == "Halogen" then
		if state == 0 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()
			gtwe2:Play()

			if plactive then
				for idx, child in pairs(lights.Headlights.Low:GetDescendants()) do
					if child:IsA("SpotLight") then
						local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
						tw:Play()
					elseif child.Name == "LN" then
						local tw = TweenService:Create(child, t, {Transparency = 0.7})
						tw:Play()
					end
				end
				for idx, child in pairs(lights.Headlights.High:GetDescendants()) do
					if child:IsA("SpotLight") then
						local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
						tw:Play()
					elseif child.Name == "LN" then
						local tw = TweenService:Create(child, t, {Transparency = 1})
						tw:Play()
					end
				end
			elseif not plactive then
				for idx, child in pairs(lights.Headlights:GetDescendants()) do
					if child:IsA("SpotLight") then
						local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
						tw:Play()
					elseif child.Name == "LN" then
						local tw = TweenService:Create(child, t, {Transparency = 1})
						tw:Play()
					end
				end
			end
		elseif state == 1 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			gtwe1:Play()
			gtwe2:Play()

			for idx, child in pairs(lights.Headlights.Low:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 2, Range = 48})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 0.2})
					tw:Play()
				end
			end
		elseif state == 2 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()
			gtwe2:Play()

			for idx, child in pairs(lights.Headlights:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 3.5, Range = 60})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 0.02})
					tw:Play()
				end
			end
		elseif state == 3 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()
			gtwe2:Play()

			for idx, child in pairs(lights.Headlights:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 4.25, Range = 60})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 0.02})
					tw:Play()
				end
			end
		end
	elseif type == "LED" then
		if state == 0 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()
			gtwe2:Play()

			if plactive then
				for idx, child in pairs(lights.Headlights.Low:GetDescendants()) do
					if child:IsA("SpotLight") then
						child.Brightness = 0
						child.Range = 0
					elseif child.Name == "LN" then
						child.Transparency = 0.7
					end
				end
				for idx, child in pairs(lights.Headlights.High:GetDescendants()) do
					if child:IsA("SpotLight") then
						child.Brightness = 0
						child.Range = 0
					elseif child.Name == "LN" then
						child.Transparency = 1
					end
				end
			elseif not plactive then
				for idx, child in pairs(lights.Headlights:GetDescendants()) do
					if child:IsA("SpotLight") then
						child.Brightness = 0
						child.Range = 0
					elseif child.Name == "LN" then
						child.Transparency = 1
					end
				end
			end
		elseif state == 1 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			gtwe1:Play()
			gtwe2:Play()

			for idx, child in pairs(lights.Headlights:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 2
					child.Range = 48
				elseif child.Name == "LN" then
					child.Transparency = 0.2
				end
			end
		elseif state == 2 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()
			gtwe2:Play()

			for idx, child in pairs(lights.Headlights:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 3.5
					child.Range = 60
				elseif child.Name == "LN" then
					child.Transparency = 0.02
				end
			end
		elseif state == 3 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()
			gtwe2:Play()

			for idx, child in pairs(lights.Headlights:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 4.25
					child.Range = 60
				elseif child.Name == "LN" then
					child.Transparency = 0.02
				end
			end
		end
	end
end

F.Popups = function(state, enabled)
	if enabled then
		local motor = PHeadlights.Hinge:WaitForChild("Motor")
		motor.MaxVelocity = 0.08

		if state then
			motor.DesiredAngle = -0.75
		elseif not state then
			motor.DesiredAngle = 0
		end
	end
end

F.PopupLights = function(state, fade_time, tb, type)
	if type == "Halogen" then
		if state == 0 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()
			gtwe2:Play()

			if plactive then
				for idx, child in pairs(PHeadlights.Parts.Headlights:GetDescendants()) do
					if child:IsA("SpotLight") then
						local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
						tw:Play()
					elseif child.Name == "LN" then
						local tw = TweenService:Create(child, t, {Transparency = 0.7})
						tw:Play()
					end
				end
			elseif not plactive then
				for idx, child in pairs(PHeadlights.Parts.Headlights:GetDescendants()) do
					if child:IsA("SpotLight") then
						local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
						tw:Play()
					elseif child.Name == "LN" then
						local tw = TweenService:Create(child, t, {Transparency = 1})
						tw:Play()
					end
				end
			end
		elseif state == 1 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			gtwe1:Play()
			gtwe2:Play()

			for idx, child in pairs(PHeadlights.Parts.Headlights:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 2, Range = 48})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 0.2})
					tw:Play()
				end
			end
		elseif state == 2 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()
			gtwe2:Play()

			for idx, child in pairs(PHeadlights.Parts.Headlights:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 3.5, Range = 60})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 0.02})
					tw:Play()
				end
			end
		elseif state == 3 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()
			gtwe2:Play()

			for idx, child in pairs(PHeadlights.Parts.Headlights:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 4.25, Range = 60})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 0.02})
					tw:Play()
				end
			end
		end
	elseif type == "LED" then
		if state == 0 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()
			gtwe2:Play()

			if plactive then
				for idx, child in pairs(lights.Headlights:GetDescendants()) do
					if child:IsA("SpotLight") then
						child.Brightness = 0
						child.Range = 0
					elseif child.Name == "LN" then
						child.Transparency = 0.7
					end
				end
			elseif not plactive then
				for idx, child in pairs(lights.Headlights:GetDescendants()) do
					if child:IsA("SpotLight") then
						child.Brightness = 0
						child.Range = 0
					elseif child.Name == "LN" then
						child.Transparency = 1
					end
				end
			end
		elseif state == 1 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			gtwe1:Play()
			gtwe2:Play()

			for idx, child in pairs(lights.Headlights:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 2
					child.Range = 48
				elseif child.Name == "LN" then
					child.Transparency = 0.2
				end
			end
		elseif state == 2 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()
			gtwe2:Play()

			for idx, child in pairs(lights.Headlights:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 3.5
					child.Range = 60
				elseif child.Name == "LN" then
					child.Transparency = 0.02
				end
			end
		elseif state == 3 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[1], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			local gtwe2 = TweenService:Create(tb[2], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()
			gtwe2:Play()

			for idx, child in pairs(lights.Headlights:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 4.25
					child.Range = 60
				elseif child.Name == "LN" then
					child.Transparency = 0.02
				end
			end
		end
	end
end

F.FogLights = function(state, fade_time, tb, type)
	if state then
		if type == "Halogen" then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[4], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			gtwe1:Play()

			for idx, child in pairs(lights.Fog:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 3.75, Range = 60})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 0.02})
					tw:Play()
				end
			end
		elseif type == "LED" then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[4], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
			gtwe1:Play()

			for idx, child in pairs(lights.Fog:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 3.75
					child.Range = 60
				elseif child.Name == "LN" then
					child.Transparency = 0.02
				end
			end
		end
	elseif not state then
		if type == "Halogen" then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[4], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()

			for idx, child in pairs(lights.Fog:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 1})
					tw:Play()
				end
			end
		elseif type == "LED" then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			local gtwe1 = TweenService:Create(tb[4], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
			gtwe1:Play()

			for idx, child in pairs(lights.Fog:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 0
					child.Range = 0
				elseif child.Name == "LN" then
					child.Transparency = 1
				end
			end
		end
	end
end

F.ParkLights = function(state, tb)
	if state then
		local gtwe = TweenService:Create(tb[3], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 0})
		gtwe:Play()

		plactive = true
	else
		local gtwe = TweenService:Create(tb[3], TweenInfo.new(0.05, Enum.EasingStyle.Quint), {ImageTransparency = 1})
		gtwe:Play()

		plactive = false
	end
end

F.BrakeLights = function(state, fade_time, type)
	if type == "Halogen" then
		if state then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			for idx, child in pairs(lights.Brake:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 2.5, Range = 38})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 0.02})
					tw:Play()
				end
			end
		else
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			for idx, child in pairs(lights.Brake:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 1})
					tw:Play()
				end
			end
		end
	elseif type == "LED" then
		if state then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			for idx, child in pairs(lights.Brake:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 3.5
					child.Range = 38
				elseif child.Name == "LN" then
					child.Transparency = 0.02
				end
			end
		else
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			for idx, child in pairs(lights.Brake:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 0
					child.Range = 0
				elseif child.Name == "LN" then
					child.Transparency = 1
				end
			end
		end
	end
end

F.RearLights = function(state, fade_time, type)
	if type == "Halogen" then
		if state == 0 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			if plactive then
				for idx, child in pairs(lights.Rear:GetDescendants()) do
					if child:IsA("SpotLight") then
						local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
						tw:Play()
					elseif child.Name == "LN" then
						local tw = TweenService:Create(child, t, {Transparency = 0.7})
						tw:Play()
					end
				end
			elseif not plactive then
				for idx, child in pairs(lights.Rear:GetDescendants()) do
					if child:IsA("SpotLight") then
						local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
						tw:Play()
					elseif child.Name == "LN" then
						local tw = TweenService:Create(child, t, {Transparency = 1})
						tw:Play()
					end
				end
			end
		elseif state == 1 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			for idx, child in pairs(lights.Rear:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 1.5, Range = 25})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 0.2})
					tw:Play()
				end
			end
		end
	elseif type == "LED" then
		if state == 0 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			if plactive then
				for idx, child in pairs(lights.Rear:GetDescendants()) do
					if child:IsA("SpotLight") then
						child.Brightness = 0
						child.Range = 0
					elseif child.Name == "LN" then
						child.Transparency  = 0.7
					end
				end
			elseif not plactive then
				for idx, child in pairs(lights.Rear:GetDescendants()) do
					if child:IsA("SpotLight") then
						child.Brightness = 0
						child.Range = 0
					elseif child.Name == "LN" then
						child.Transparency  = 1
					end
				end
			end
		elseif state == 1 then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			for idx, child in pairs(lights.Rear:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 1.5
					child.Range = 25
				elseif child.Name == "LN" then
					child.Transparency  = 0.2
				end
			end
		end
	end
end

F.DashboardIndicators = function(headlights, indicators, parklights)

end

F.Reverse = function(state, fade_time, type)
	if type == "Halogen" then
		if state then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			for idx, child in pairs(lights.Reverse:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 1, Range = 20})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 0.03})
					tw:Play()
				end
			end
		else
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			for idx, child in pairs(lights.Reverse:GetDescendants()) do
				if child:IsA("SpotLight") then
					local tw = TweenService:Create(child, t, {Brightness = 0, Range = 0})
					tw:Play()
				elseif child.Name == "LN" then
					local tw = TweenService:Create(child, t, {Transparency = 1})
					tw:Play()
				end
			end
		end
	elseif type == "LED" then
		if state then
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			for idx, child in pairs(lights.Reverse:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 1
					child.Range = 20
				elseif child.Name == "LN" then
					child.Transparency = 0.03
				end
			end
		else
			local t = TweenInfo.new(fade_time, Enum.EasingStyle.Quint, Enum.EasingDirection.Out, 0, false, 0)

			for idx, child in pairs(lights.Reverse:GetDescendants()) do
				if child:IsA("SpotLight") then
					child.Brightness = 0
					child.Range = 0
				elseif child.Name == "LN" then
					child.Transparency = 1
				end
			end
		end
	end
end

F.IndsOnLeave = function(left, right, hazard, sequential, segs, fr, type)
	event.IndicatorsAfterLeave.Disabled = false
	wait()
	leaveseatevent:Fire(left, right, hazard, sequential, segs, fr, type)
end

event.OnServerEvent:Connect(function(pl, Fnc, ...)
	F[Fnc](...)
end)


Prompt: -- Customized explosive effect that doesn't affect teammates and only breaks joints on dead parts

Response:
local TaggedHumanoids = {}
local function OnExplosionHit(hitPart, hitDistance, blastCenter)
	if hitPart and hitDistance then
		local character, humanoid = FindCharacterAncestor(hitPart.Parent)

		if character then
			local myPlayer = CreatorTag.Value
			if myPlayer and not myPlayer.Neutral then -- Ignore friendlies caught in the blast
				local player = PlayersService:GetPlayerFromCharacter(character)
				if player and player ~= myPlayer and player.TeamColor == Rocket.BrickColor then
					return
				end
			end
		end

		if humanoid and humanoid.Health > 0 then -- Humanoids are tagged and damaged
			if not IsInTable(TaggedHumanoids,humanoid) then
				print("Tagged")
				table.insert(TaggedHumanoids,humanoid)
				ApplyTags(humanoid)
				humanoid:TakeDamage(BLAST_DAMAGE)
			end
		else -- Loose parts and dead parts are blasted
			if hitPart.Name ~= 'Handle' then
				hitPart:BreakJoints()
				local blastForce = Instance.new('BodyForce', hitPart) --NOTE: We will multiply by mass so bigger parts get blasted more
				blastForce.Force = (hitPart.Position - blastCenter).unit * BLAST_FORCE * hitPart:GetMass()
				DebrisService:AddItem(blastForce, 0.1)
			end
		end
	end
end
local Isexplosion = false
local function OnTouched(otherParts)
	for i,otherPart in ipairs(otherParts)do
		if Rocket then
			-- Fly through anything in the ignore list
			if IGNORE_LIST[string.lower(otherPart.Name)] 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
			Isexplosion = true
			-- Create the explosion
			local explosion = Instance.new('Explosion')
			explosion.BlastPressure = 0 -- Completely safe explosion
			explosion.BlastRadius = BLAST_RADIUS
			explosion.ExplosionType = Enum.ExplosionType.NoCraters
			explosion.Position = Rocket.Position
			explosion.Parent = workspace

			-- Connect custom logic for the explosion
			explosion.Hit:Connect(function(hitPart, hitDistance) OnExplosionHit(hitPart, hitDistance, explosion.Position) 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
end


Prompt:
--These are all donations that can be done. You must set this up with your own products to make money of it.
--To make a product you have to make a Developer Product in your game's settings page.
--You can make as many as you want, Once you made one, copy it's ID and past it in the 'ProductId' variable in this script.
--Change the 'ProductPrice' to what the Developer Product Costs.

Response:
local module = {}
module.Products = {

	{
		ProductPrice = 5, --The price from the Developer Product.
		ProductId = 1234585054 -- The ID from the Developer Product.
	},
	{
		ProductPrice = 10, --The price from the Developer Product.
		ProductId = 1234585087 -- The ID from the Developer Product.
	},
	{
		ProductPrice = 50, --The price from the Developer Product.
		ProductId = 1234585114 -- The ID from the Developer Product.
	},
	{
		ProductPrice = 100, --The price from the Developer Product.
		ProductId = 1234585216 -- The ID from the Developer Product.
	},

}


Prompt: -- << Functions >> --

Response:
UserInputService.MouseIconEnabled = false

function lerp(a, b, c)
	return a + (b - a) * c
end

bobbing = game:GetService("RunService").RenderStepped:Connect(function(deltaTime)
	deltaTime = deltaTime * 60
	if Humanoid.Health <= 0 then
		bobbing:Disconnect()
		return
	end
	local rootMagnitude = Humanoid.RootPart and Vector3.new(Humanoid.RootPart.Velocity.X, 0, Humanoid.RootPart.Velocity.Z).Magnitude or 0
	local calcRootMagnitude = math.min(rootMagnitude, 50)
	if deltaTime > 3 then
		func1 = 0
		func2 = 0
	else
		func1 = lerp(func1, math.cos(tick() * 0.5 * math.random(10, 15)) * (math.random(5, 20) / 200) * deltaTime, 0.05 * deltaTime)
		func2 = lerp(func2, math.cos(tick() * 0.5 * math.random(5, 10)) * (math.random(2, 10) / 200) * deltaTime, 0.05 * deltaTime)
	end
	Camera.CFrame = Camera.CFrame * (CFrame.fromEulerAnglesXYZ(0, 0, math.rad(func3)) * CFrame.fromEulerAnglesXYZ(math.rad(func4 * deltaTime), math.rad(val * deltaTime), val2) * CFrame.Angles(0, 0, math.rad(func4 * deltaTime * (calcRootMagnitude / 5))) * CFrame.fromEulerAnglesXYZ(math.rad(func1), math.rad(func2), math.rad(func2 * 10)))
	val2 = math.clamp(lerp(val2, -Camera.CFrame:VectorToObjectSpace((Humanoid.RootPart and Humanoid.RootPart.Velocity or Vector3.new()) / math.max(Humanoid.WalkSpeed, 0.01)).X * 0.08, 0.1 * deltaTime), -0.35, 0.2)
	func3 = lerp(func3, math.clamp(UserInputService:GetMouseDelta().X, -5, 5), 0.25 * deltaTime)
	func4 = lerp(func4, math.sin(tick() * int) / 5 * math.min(1, int2 / 10), 0.25 * deltaTime)
	if rootMagnitude > 1 then
		val = lerp(val, math.cos(tick() * 0.5 * math.floor(int)) * (int / 200), 0.25 * deltaTime)
	else
		val = lerp(val, 0, 0.05 * deltaTime)
	end
	if rootMagnitude > 12 then
		int = 20
		int2 = 18
	elseif rootMagnitude > 0.1 then
		int = 12
		int2 = 14
	else
		int2 = 0
	end
	Player.CameraMaxZoomDistance = 0.5
	Player.CameraMinZoomDistance = 0.5
	vect3 = lerp(vect3, Camera.CFrame.LookVector, 0.125 * deltaTime)
end)


Prompt: -- UI elements

Response:
local intro = script.Parent:WaitForChild("Intro")
intro.Visible = true

wait(2)

game.Workspace.Camera.CameraType = Enum.CameraType.Scriptable
game.Workspace.Camera.CFrame = CFrame.new(game.Workspace.IntroTunnel.CameraOrigin.Position,game.Workspace.IntroTunnel.CameraFace.Position)

local topStatus = script.Parent:WaitForChild("TopStatus")
topStatus.Text = status.Value

status:GetPropertyChangedSignal("Value"):Connect(function()
	topStatus.Text = status.Value
end)

intro.Play.MouseButton1Click:Connect(function()

	if game.ReplicatedStorage.MapVoting.Value == true then
		script.Parent.MapVoting.Visible = true
	end

	intro.Visible = false
	topStatus.Visible = true
	game.ReplicatedStorage.MenuPlay:FireServer()
	game.Workspace.Camera.CameraType = Enum.CameraType.Custom
end)

game.ReplicatedStorage.KillFeed.OnClientEvent:Connect(function(text)
	script.Parent.KillFeed.Visible = true
	script.Parent.KillFeed.Text = text
	wait(2)
	script.Parent.KillFeed.Visible = false
end)

game.ReplicatedStorage.Announcement.OnClientEvent:Connect(function(text)
	script.Parent.Announcement.Text = text
	script.Parent.Announcement.Visible = true
	wait(5)
	script.Parent.Announcement.Visible = false
end)


Prompt:
-----------------
--| Functions |--
-----------------

Response:
local function OnActivated()
	local myModel = MyPlayer.Character
	if Tool.Enabled and myModel and myModel:FindFirstChild('Humanoid') and myModel.Humanoid.Health > 0 then
		Tool.Enabled = false

		-- Create a clone of Rocket and set its color
		local rocketClone = Rocket:Clone()
		DebrisService:AddItem(rocketClone, 30)
		rocketClone.BrickColor = MyPlayer.TeamColor

		-- Position the rocket clone and launch!
		local spawnPosition = (ToolHandle.CFrame * CFrame.new(2, 0, 0)).p
		rocketClone.CFrame = CFrame.new(spawnPosition, myModel.Humanoid.TargetPoint) --NOTE: This must be done before assigning Parent
		rocketClone.Velocity = rocketClone.CFrame.lookVector * ROCKET_SPEED --NOTE: This should be done before assigning Parent
		rocketClone.Parent = Workspace

		wait(RELOAD_TIME)

		Tool.Enabled = true
	end
end


Prompt: --Gear Ratios

Response:
Tune.FinalDrive		= 2.78			-- Gearing determines top speed and wheel torque
Tune.Ratios			= {				-- Higher ratio = more torque, Lower ratio = higher top speed
	--[[Reverse]]	2.34		,	-- Copy and paste a ratio to add a gear
	--[[Neutral]]	0			,	-- Ratios can also be deleted
	--[[ 1 ]]		3.53		,	-- Reverse, Neutral, and 1st gear are required
	--[[ 2 ]]		2.04		,
	--[[ 3 ]]		1.38		,
	--[[ 4 ]]		1.03		,
	--[[ 5 ]]		0.81		,
	--[[ 6 ]]		0.64		,
	--[[ 7 ]]		0.48		,
}
Tune.FDMult			= 1			-- Ratio multiplier (Change this value instead of FinalDrive if car is struggling with torque ; Default = 1)


Prompt: -- Get references to the DockShelf and its children

Response:
local dockShelf = script.Parent.Parent.Parent.Parent.Parent.DockShelf
local aFinderButton = dockShelf.FTerminal
local Minimalise = script.Parent
local window = script.Parent.Parent.Parent


Prompt: -- FUNCTIONS --

Response:
CS:GetInstanceAddedSignal("OnFire"):Connect(function(Character)
	local Humanoid = Character:WaitForChild("Humanoid")
	Replicate:FireAllClients("Burn", Character, true)
	coroutine.wrap(function()
		repeat
			Humanoid:TakeDamage(math.random(4, 12))
			task.wait(1)
		until not CS:HasTag(Character, "OnFire")
	end)()
end)

CS:GetInstanceRemovedSignal("OnFire"):Connect(function(Character)
	Replicate:FireAllClients("Burn", Character, false)
end)


Prompt: --// Core

Response:
return function(Vargs, GetEnv)
	local env = GetEnv(nil, {script = script})
	setfenv(1, env)

	local _G, game, script, getfenv, setfenv, workspace,
		getmetatable, setmetatable, loadstring, coroutine,
		rawequal, typeof, print, math, warn, error,  pcall,
		xpcall, select, rawset, rawget, ipairs, pairs,
		next, Rect, Axes, os, time, Faces, unpack, string, Color3,
		newproxy, tostring, tonumber, Instance, TweenInfo, BrickColor,
		NumberRange, ColorSequence, NumberSequence, ColorSequenceKeypoint,
		NumberSequenceKeypoint, PhysicalProperties, Region3int16,
		Vector3int16, require, table, type, wait,
		Enum, UDim, UDim2, Vector2, Vector3, Region3, CFrame, Ray, delay =
		_G, game, script, getfenv, setfenv, workspace,
		getmetatable, setmetatable, loadstring, coroutine,
		rawequal, typeof, print, math, warn, error,  pcall,
		xpcall, select, rawset, rawget, ipairs, pairs,
		next, Rect, Axes, os, time, Faces, unpack, string, Color3,
		newproxy, tostring, tonumber, Instance, TweenInfo, BrickColor,
		NumberRange, ColorSequence, NumberSequence, ColorSequenceKeypoint,
		NumberSequenceKeypoint, PhysicalProperties, Region3int16,
		Vector3int16, require, table, type, wait,
		Enum, UDim, UDim2, Vector2, Vector3, Region3, CFrame, Ray, delay

	local script = script
	local service = Vargs.Service
	local client = Vargs.Client
	local Anti, Core, Functions, Process, Remote, UI, Variables
	local function Init()
		UI = client.UI;
		Anti = client.Anti;
		Core = client.Core;
		Variables = client.Variables
		Functions = client.Functions;
		Process = client.Process;
		Remote = client.Remote;

		Core.Name = "\0"
		Core.Special = client.DepsName
		Core.MakeGui = UI.Make;
		Core.GetGui = UI.Get;
		Core.RemoveGui = UI.Remove;

		Core.Init = nil;
	end

	local function RunAfterPlugins(data)
		Core.GetEvent()

		Core.RunAfterPlugins = nil;
	end

	local function RunLast()
		--// API
		if service.NetworkClient then
			service.TrackTask("Thread: API Manager", Core.StartAPI)
			--service.Threads.RunTask("_G API Manager",client.Core.StartAPI)
		end

		--[[client = service.ReadOnly(client, {
				[client.Variables] = true;
				[client.Handlers] = true;
				G_API = true;
				G_Access = true;
				G_Access_Key = true;
				G_Access_Perms = true;
				Allowed_API_Calls = true;
				HelpButtonImage = true;
				Finish_Loading = true;
				RemoteEvent = true;
				ScriptCache = true;
				Returns = true;
				PendingReturns = true;
				EncodeCache = true;
				DecodeCache = true;
				Received = true;
				Sent = true;
				Service = true;
				Holder = true;
				GUIs = true;
				LastUpdate = true;
				RateLimits = true;

				Init = true;
				RunLast = true;
				RunAfterInit = true;
				RunAfterLoaded = true;
				RunAfterPlugins = true;
		}, true)--]]

		Core.RunLast = nil
	end

	getfenv().client = nil
	getfenv().service = nil
	getfenv().script = nil

	client.Core = {
		Init = Init;
		RunLast = RunLast;
		--RunAfterLoaded = RunAfterLoaded;
		RunAfterPlugins = RunAfterPlugins;
		Name = script.Name;
		Special = script.Name;
		ScriptCache = {};

		GetEvent = function()
			if Core.RemoteEvent then
				log("Disconnect old RemoteEvent")

				for name,event in Core.RemoteEvent.Events do
					event:Disconnect()
				end

				Core.RemoteEvent = nil;
			end

			log("Getting RemoteEvent");

			local eventData = {}
			local remoteParent = service.ReplicatedStorage;
			local event = remoteParent:WaitForChild(client.RemoteName, 300)

			if not event then
				Anti.Detected("Kick", "RemoteEvent Not Found");
			else
				log("Getting RemoteFunction");

				local rFunc = event:WaitForChild("__FUNCTION", 120);

				if not rFunc then
					Anti.Detected("Kick", "RemoteFunction Not Found");
				else
					local events = {};

					rFunc.OnClientInvoke = Process.Remote;

					eventData.Object = event;
					eventData.Function = rFunc;
					eventData.FireServer = event.FireServer;
					eventData.Events = events;

					events.ProcessRemote = event.OnClientEvent:Connect(Process.Remote)
					events.ParentChildRemoved = remoteParent.ChildRemoved:Connect(function(child)
						if (Core.RemoteEvent == eventData) and child == event and task.wait() then
							warn("::ADONIS:: REMOTE EVENT REMOVED? RE-GRABBING");
							log("~! REMOTEEVENT WAS REMOVED?")
							Core.GetEvent();
						end
					end)

					Core.RemoteEvent = eventData

					if not Core.Key then
						log("~! Getting key from server")
						Remote.Fire(`{client.DepsName}GET_KEY`)
					end
				end
			end
		end;

		LoadPlugin = function(plugin)
			local plug = require(plugin)
			local func = setfenv(plug,GetEnv(getfenv(plug)))
			cPcall(func)
		end;

		LoadBytecode = function(str, env)
			return require(client.Shared.FiOne)(str, env)
		end;

		LoadCode = function(str, env)
			return Core.LoadBytecode(str, env)
		end;

		StartAPI = function()
			local ScriptCache = Core.ScriptCache
			local FiOne = client.Shared.FiOne
			local Get = Remote.Get
			local GetFire = Remote.GetFire
			local G_API = client.G_API
			local Allowed_API_Calls = client.Allowed_API_Calls
			local NewProxy = service.NewProxy
			local MetaFunc = service.MetaFunc
			local ReadOnly = service.ReadOnly
			local StartLoop = service.StartLoop
			local ReadOnly = service.ReadOnly
			local UnWrap = service.UnWrap
			local service = nil
			local client = nil
			local _G = _G
			local setmetatable = setmetatable
			local type = type
			local print = print
			local error = error
			local pairs = pairs
			local warn = warn
			local next = next
			local table = table
			local rawset = rawset
			local rawget = rawget
			local getfenv = getfenv
			local setfenv = setfenv
			local require = require
			local tostring = tostring
			local client = client
			local Routine = Routine
			local cPcall = cPcall

			--// Get Settings
			local API_Special = {

			}

			setfenv(1,setmetatable({}, {__metatable = getmetatable(getfenv())}))

			local API_Specific = {
				API_Specific = {
					Test = function()
						print("We ran the api specific stuff")
					end
				};
				Service = service;
			}

			local API = {
				Access = ReadOnly({}, nil, nil, true);
				--[[
				Access = service.MetaFunc(function(...)
					local args = {...}
					local key = args[1]
					local ind = args[2]
					local targ

					setfenv(1,setmetatable({}, {__metatable = getmetatable(getfenv())}))

					if API_Specific[ind] then
						targ = API_Specific[ind]
					elseif client[ind] and client.Allowed_API_Calls[ind] then
						targ = client[ind]
					end

					if client.G_Access and key == client.G_Access_Key and targ and client.Allowed_API_Calls[ind] then
						if type(targ) == "table" then
							return service.NewProxy {
								__index = function(tab,inde)
									if targ[inde] ~= nil and API_Special[inde] == nil or API_Special[inde] == true then
										if targ[inde]~=nil and type(targ[inde]) == "table" and client.G_Access_Perms == "Read" then
											return service.ReadOnly(targ[inde])
										else
											return targ[inde]
										end
									elseif API_Special[inde] == false then
										error(`Access Denied: {inde}`)
									else
										error(`Could not find {inde}`)
									end
								end;
								__newindex = function(tabl,inde,valu)
									error("Read-only")
								end;
								__metatable = true;
							}
						end
					else
						error("Incorrect key or G_Access is disabled")
					end
				end);
				--]]

				Scripts = ReadOnly({
					ExecutePermission = (function(srcScript, code)
						local exists;

						for i,v in ScriptCache do
							if UnWrap(v.Script) == srcScript then
								exists = v
							end
						end

						if exists and exists.noCache ~= true and (not exists.runLimit or (exists.runLimit and exists.Executions <= exists.runLimit)) then
							exists.Executions = exists.Executions+1
							return exists.Source, exists.Loadstring
						end

						local data = Get("ExecutePermission", srcScript, code, true)
						if data and data.Source then
							local module;
							if not exists then
								module = require(FiOne:Clone())
								table.insert(ScriptCache,{
									Script = srcScript;
									Source = data.Source;
									Loadstring = module;
									noCache = data.noCache;
									runLimit = data.runLimit;
									Executions = data.Executions;
								})
							else
								module = exists.Loadstring
								exists.Source = data.Source
							end
							return data.Source, module
						end
					end);
				}, nil, nil, true);
			}

			local AdonisGTable = NewProxy({
				__index = function(tab,ind)
					if ind == "Scripts" then
						return API.Scripts
					elseif G_API and Allowed_API_Calls.Client == true then
						if type(API[ind]) == "function" then
							return MetaFunc(API[ind])
						else
							return API[ind]
						end
					else
						error("_G API is disabled")
					end
				end;
				__newindex = function()
					error("Read-only")
				end;
				__metatable = "API";
			})

			if not rawget(_G, "Adonis") then
				if table.isfrozen and not table.isfrozen(_G) or not table.isfrozen then
					rawset(_G, "Adonis", AdonisGTable)
					StartLoop("APICheck", 1, function()
						if rawget(_G, "Adonis") ~= AdonisGTable then
							if table.isfrozen and not table.isfrozen(_G) or not table.isfrozen then
								rawset(_G, "Adonis", AdonisGTable)
							else
								warn("ADONIS CRITICAL WARNING! MALICIOUS CODE IS TRYING TO CHANGE THE ADONIS _G API AND IT CAN'T BE SET BACK! PLEASE SHUTDOWN THE SERVER AND REMOVE THE MALICIOUS CODE IF POSSIBLE!")
							end
						end
					end, true)
				else
					warn("The _G table was locked and the Adonis _G API could not be loaded")
				end
			end
		end;
	};
end


Prompt: ----Handle the enabling and disabling of the default roblox jump button----

Response:
local function getLocalHumanoid()
	if LocalPlayer.Character then
		return LocalPlayer.Character:FindFirstChildOfClass("Humanoid")
	end
end

local oldHumanoidJumpPower = 50
local jumpDisabled = false
local function enableJumpButton()
	local humanoid = getLocalHumanoid()
	if jumpDisabled and humanoid then
		humanoid.JumpPower = oldHumanoidJumpPower
		jumpDisabled = false
	end
end

local function disableJumpButton()
	local humanoid = getLocalHumanoid()
	if humanoid then
		oldHumanoidJumpPower = humanoid.JumpPower
		humanoid.JumpPower = 0
		jumpDisabled = true
	end
end

function VehicleGui:Enable()
	self.gui.Enabled = true

	self:EnableKeyboardUI()
	self:ConfigureButtons()
	local function UpdateInputType(inputType)
		if inputType == Enum.UserInputType.Touch then
			self:EnableTouchUI()
			self:ConfigureButtons()
		elseif inputType.Value >= Enum.UserInputType.Gamepad1.Value and
			inputType.Value <= Enum.UserInputType.Gamepad8.Value then
			self:EnableGamepadUI()
			self:ConfigureButtons()
		elseif inputType == Enum.UserInputType.Keyboard then
			self:EnableKeyboardUI()
			self:ConfigureButtons()
		end
	end
	self.connections[#self.connections + 1] = UserInputService.LastInputTypeChanged:Connect(UpdateInputType)
	UpdateInputType(UserInputService:GetLastInputType())

	--Destroy when player gets out of vehicle
	function self.OnExit(Seat)
		self:Destroy()
	end
	self.localSeatModule.OnSeatExitEvent(self.OnExit)

	--Destroy if the gui has been destroyed
	self.connections[#self.connections + 1] = self.gui.AncestryChanged:Connect(function()
		if not self.gui:IsDescendantOf(game) then
			self:Destroy()
		end
	end)

	--Destroy if vehicle is no longer in workspace
	self.connections[#self.connections + 1] = self.chassis.AncestryChanged:Connect(function()
		if not self.chassis:IsDescendantOf(Workspace) then
			self:Destroy()
		end
	end)

	--Connect the exit seat button
	self.connections[#self.connections + 1] = self.exitButton.Activated:Connect(function()
		enableJumpButton()
		self:Destroy()
		self.localSeatModule.ExitSeat()
	end)
	self.connections[#self.connections + 1] = self.exitButton.InputBegan:Connect(function(input)
		if input.UserInputType == Enum.UserInputType.Touch then
			self.exitButton.ImageTransparency = 1
			self.exitButton.Pressed.ImageTransparency = 0
		end
	end)
	self.connections[#self.connections + 1] = self.exitButton.InputEnded:Connect(function(input)
		if input.UserInputType == Enum.UserInputType.Touch then
			self.exitButton.ImageTransparency = 0
			self.exitButton.Pressed.ImageTransparency = 1
		end
	end)

	self.connections[#self.connections + 1] = RunService.RenderStepped:Connect(function()
		--Update the speedo
		local vel = self.seat.Velocity
		local mphConversion = 0.6263 -- using a 28cm = 1stud conversion rate
		local speed = vel.Magnitude*mphConversion

		local speedFraction = math.min(speed/MAX_SPEED, 1)
		local onSize = math.floor(self.speedoFrame.AbsoluteSize.X * speedFraction + 0.5)
		self.speedoFrameOn.Size = UDim2.new(0, onSize, 1, 0)
		self.speedText.Text = tostring(math.floor(speed + 0.5))

		--Update the steering input if touch controls are enabled
		if self.touchEnabled then
			self.steeringInput = -PlayerControlModule:GetMoveVector().X
		end
	end)
end

function VehicleGui:Destroy()
	self.localSeatModule.DisconnectFromSeatExitEvent(self.OnExit)
	for _, connection in ipairs(self.connections) do
		connection:Disconnect()
	end
	if self.gui then
		self.gui:Destroy()
	end
	enableJumpButton()
end

function VehicleGui:ConfigureButtons()
	--Position Accelerate Button
	self.accelButton.Image = "rbxassetid://2847847852"
	self.accelButton.Pressed.Image = "rbxassetid://2847847961"
	self.accelButton.Size = UDim2.new(0, 70, 0, 70)
	self.accelButton.AnchorPoint = Vector2.new(1, 1)
	self.accelButton.Position = UDim2.new(1, -24, 1, -20)

	--Position Brake Button
	self.brakeButton.Size = UDim2.new(0, 44, 0, 44)
	self.brakeButton.AnchorPoint = Vector2.new(1, 1)
	self.brakeButton.Position = UDim2.new(1, -(24 + self.accelButton.Size.X.Offset + 20), 1, -20)
	self.brakeButton.Image = "rbxassetid://2847848304"
	self.brakeButton.Pressed.Image = "rbxassetid://2847848400"

	--Position Exit Button
	self.exitButton.Image = "rbxassetid://2847857948"
	self.exitButton.Pressed.Image = "rbxassetid://2847858038"
	self.exitButton.KeyImage.ImageRectSize = Vector2.new(0, 0)
	self.exitButton.KeyImage.ImageRectOffset = Vector2.new(0, 0)
	self.exitButton.KeyImage.ButtonText.Visible = false

	local inputType = UserInputService:GetLastInputType()
	if inputType == Enum.UserInputType.Touch then
		self.exitButton.Size = UDim2.new(0, 44, 0, 44)
		self.exitButton.AnchorPoint = Vector2.new(1, 1)
		self.exitButton.Position = UDim2.new(1, -24, 1, -(20 + self.accelButton.Size.Y.Offset + 20))
		self.exitButton.KeyImage.Image = ""
	else
		self.exitButton.Size = UDim2.new(0, 72, 0, 72)
		self.exitButton.AnchorPoint = Vector2.new(1, 1)
		self.exitButton.Position = UDim2.new(1, -24, 1, -(20 + self.accelButton.Size.Y.Offset + 20))

		if inputType.Value >= Enum.UserInputType.Gamepad1.Value and
			inputType.Value <= Enum.UserInputType.Gamepad8.Value then
			--Set the correct image for the gamepad button prompt
			local template = InputImageLibrary:GetImageLabel(Keymap.EnterVehicleGamepad, "Light")
			self.exitButton.KeyImage.Image = template.Image
			self.exitButton.KeyImage.ImageRectOffset = template.ImageRectOffset
			self.exitButton.KeyImage.ImageRectSize = template.ImageRectSize
		else
			self.exitButton.KeyImage.Image = "rbxassetid://2935912536"
			self.exitButton.KeyImage.ButtonText.Visible = true
			self.exitButton.KeyImage.ButtonText.Text = Keymap.EnterVehicleKeyboard.Name
		end
	end
end


Prompt:
--[[
	Commands:
	/kick
	/explode
	/trip
	/visible
	/invisible
]]

Response:
admin.kick = {
	["Command"] = "Kick",
	["Place"] = 1,

	["Function"] = function(arguments)
		local players = {}

		for i, playerName in pairs(arguments) do
			local player = findPlayer(playerName)

			if player then
				disconnect(player)
			end
		end
	end
}

admin.explode = {
	["Command"] = "Explode",
	["Place"] = 2,

	["Function"] = function(arguments)
		for i, playerName in pairs(arguments) do
			local player = findPlayer(playerName)

			if player then
				explode(player)
			end
		end
	end
}

admin.trip = {
	["Command"] = "Trip",
	["Place"] = 3,

	["Function"] = function(arguments)
		for i, playerName in pairs(arguments) do
			local player = findPlayer(playerName)

			if player then
				local humanoid = player.Character:FindFirstChild("Humanoid")

				if not humanoid then
					return
				end

				humanoid.PlatformStand = true
				task.wait(1.5)
				humanoid.PlatformStand = false
			end
		end
	end
}

admin.visible = {
	["Command"] = "Visible",
	["Place"] = 4,

	["Function"] = function(arguments)
		for i, playerName in pairs(arguments) do
			local player = findPlayer(playerName)

			if player then
				local character = player.Character or player.CharacterAdded:Wait()

				for i, v in pairs(character:GetDescendants()) do
					if v:IsA("Part") or v:IsA("BasePart") or v:IsA("MeshPart") then
						v.Transparency = 0
					end
				end

				character.HumanoidRootPart.Transparency = 1
				character.HitBox.Transparency = 1
			end
		end
	end
}

admin.invisible = {
	["Command"] = "Invisible",
	["Place"] = 5,

	["Function"] = function(arguments)
		for i, playerName in pairs(arguments) do
			local player = findPlayer(playerName)

			if player then
				local character = player.Character or player.CharacterAdded:Wait()

				for i, v in pairs(character:GetDescendants()) do
					if v:IsA("Part") or v:IsA("BasePart") then
						v.Transparency = 1
					end
				end

				character.HumanoidRootPart.Transparency = 1
				character.HitBox.Transparency = 1
			end
		end
	end
}

return admin


Prompt: -- enter numbers you think are correct. the percentages will be automatically calculated

Response:
dropRates.Carpenter = 1
dropRates.DoublePoints = 1
dropRates.Instakill = 1
dropRates.MaxAmmo = 1
dropRates.Nuke = 1

return dropRates


Prompt: -- Determine whether we're in tool or plugin mode

Response:
ToolMode = (Tool.Parent:IsA 'Plugin') and 'Plugin' or 'Tool'

local IsHttpServiceEnabled = nil


Prompt: --// WIP

Response:
local function LoadPackage(package, folder, runNow)
	--// runNow - Run immediately after unpacking (default behavior is to just unpack (((only needed if loading after startup))))
	--// runNow currently not used (limitations) so all packages must be present at server startup
	local function unpackFolder(curFolder, unpackInto)
		if unpackInto then
			for _, obj in ipairs(curFolder:GetChildren()) do
				local clone = obj:Clone()
				if obj:IsA("Folder") then
					local realFolder = unpackInto:FindFirstChild(obj.Name)
					if not realFolder then
						clone.Parent = unpackInto
					else
						unpackFolder(obj, realFolder)
					end
				else
					clone.Parent = unpackInto
				end
			end
		else
			warn("Missing parent to unpack into for ".. tostring(curFolder))
		end
	end

	unpackFolder(package, folder)
end;

local function CleanUp()
	--local env = getfenv(2)
	--local ran,ret = pcall(function() return env.script:GetFullName() end)
	warn("Beginning Adonis cleanup & shutdown process...")
	--warn("CleanUp called from "..tostring((ran and ret) or "Unknown"))
	--local loader = server.Core.ClientLoader
	server.Model.Name = "Adonis_Loader"
	server.Model.Parent = service.ServerScriptService
	server.Running = false

	pcall(service.Threads.StopAll)
	pcall(function()
		for i, v in pairs(RbxEvents) do
			print("Disconnecting event")
			v:Disconnect()
			table.remove(RbxEvents, i)
		end
	end)
	--loader.Archivable = false
	--loader.Disabled = true
	--loader:Destroy()
	if server.Core and server.Core.RemoteEvent then
		pcall(server.Core.DisconnectEvent)
	end

	--[[delay(0, function()
		for i,v in next,server do
			server[i] = nil; --// Try to break it to prevent any potential hanging issues; Not very graceful...
		end
	--end)--]]

	warn("Unloading complete")
end;

server = {
	Running = true;
	Modules = {};
	Pcall = Pcall;
	cPcall = cPcall;
	Routine = Routine;
	LogError = logError;
	ErrorLogs = ErrorLogs;
	ServerStartTime = os.time();
	CommandCache = {};
};

locals = {
	server = server;
	CodeName = "";
	Settings = server.Settings;
	HookedEvents = HookedEvents;
	ErrorLogs = ErrorLogs;
	logError = logError;
	origEnv = origEnv;
	Routine = Routine;
	Folder = Folder;
	GetEnv = GetEnv;
	cPcall = cPcall;
	Pcall = Pcall;
};

service = require(Folder.Shared.Service)(function(eType, msg, desc, ...)
	local extra = {...}
	if eType == "MethodError" then
		if server and server.Logs and server.Logs.AddLog then
			server.Logs.AddLog("Script", {
				Text = "Cached method doesn't match found method: "..tostring(extra[1]);
				Desc = "Method: "..tostring(extra[1])
			})
		end
	elseif eType == "ServerError" then
		--print("Server error")
		logError("Server", msg)
	elseif eType == "TaskError" then
		--print("Task error")
		logError("Task", msg)
	end
end, function(c, parent, tab)
	if not isModule(c) and c ~= server.Loader and c ~= server.Dropper and c ~= server.Runner and c ~= server.Model and c ~= script and c ~= Folder and parent == nil then
		tab.UnHook()
	end
end, ServiceSpecific, GetEnv(nil, {server = server}))


Prompt:
----------------------------------
------------FUNCTIONS-------------
----------------------------------

Response:
function Jump()
	local character = Player.Character
	if character then
		local humanoid = character:FindFirstChild("Humanoid")
		if humanoid then
			humanoid.Jump = true
		end
	end
end
function HumanoidChanged(humanoid, property)
	--print(property)
	if property == "Jump" then
		humanoid.Jump = false
	elseif property == "Sit" then
		humanoid.Sit = true
	elseif property == "Parent" then
		Deactivate()
		Abort()
	end
end
function HumanoidDied()
	Deactivate()
end
function SetCamera(cframe)
	Camera.CameraType = Enum.CameraType.Scriptable
	Camera:Interpolate(cframe, cframe + cframe.lookVector, .5)
	--Camera.CoordinateFrame = cframe
end
function ReturnCamera()
	Camera.CameraType = Enum.CameraType.Custom
end


Prompt:
--[[
game.ReplicatedStorage.ToggleSleeping.OnServerEvent:Connect(function()
	workspace.Ignore.Zombies.Snowfella.RootPart:SetAttribute("Sleeping", not workspace.Ignore.Zombies.Snowfella.RootPart:GetAttribute("Sleeping"))
end)
]]

Response:
game.Players.PlayerAdded:Connect(function(ply)
	ply:WaitForChild("InGame").Value = true

	--[[
	ply.CharacterAdded:Connect(function()
		ply:WaitForChild("InGame").Value = true
	end)
	]]
end)


Prompt:
--local GROUP_ID = replace with wanted group ID(s), separate with comma
--local GROUP_RANK = replace with wanted group rank(s), e.g. 255, separate wtih comma

Response:
return function (registry)
	registry:RegisterHook("BeforeRun", function(context)
		if context.Group == "DefaultAdmin" and context.Executor.UserId ~= game.CreatorId then
			return "You don't have permission to run this command"
		end
		--if context.Group == "DefaultAdmin" and not (context.Executor:GetRankInGroup(GROUP_ID) == GROUP_RANK) then
			--return "You don't have permission to run this command"
		--end
		--remove --s here to enable for group usage
		registry:RegisterHook("AfterRun", function(context)
			print(context.Response) -- see the actual response from the command execution
			return "Command has been run."
		end)
	end)
end


Prompt: --Returns whether the given position is under cover

Response:
local function UnderObject(pos, l)
	l = l or 120

	local hit, position = Workspace:FindPartOnRayWithIgnoreList(Ray.new(pos, UpVec * l), ignoreList)
	if hit then
		return hit.Transparency ~= 1 and true or UnderObject(position + UpVec, l - (pos - position).Magnitude)
	else
		return false
	end
end


Prompt:
--[=[
	@param object any -- Object to remove
	Removes the object from the Trove and cleans it up.
	```lua
	local part = Instance.new("Part")
	trove:Add(part)
	trove:Remove(part)
	```
]=]

Response:
function Trove:Remove(object: any): boolean
	local objects = self._objects
	for i,obj in ipairs(objects) do
		if obj[1] == object then
			local n = #objects
			objects[i] = objects[n]
			objects[n] = nil
			self:_cleanupObject(obj[1], obj[2])
			return true
		end
	end
	return false
end


Prompt:
--[=[
	Constructs a new symbol

	@param id any -- Identifier for the symbol (usually a string)
	@param scope Symbol? -- Optional symbol scope
	@return boolean -- Returns `true` if the `obj` parameter is a Symbol
]=]

Response:
function Symbol.new(id: any, scope: any)
	assert(id ~= nil, "Symbol ID cannot be nil")
	if scope ~= nil then
		assert(Symbol.Is(scope), "Scope must be a Symbol or nil")
	end
	local self = setmetatable({
		ClassName = CLASSNAME;
		_id = id;
		_scope = scope;
	}, Symbol)
	return self
end


Prompt:
-- Smart Circle mode needs the intersection of 2 rays that are known to be in the same plane
-- because they are generated from cross products with a common vector. This function is computing
-- that intersection, but it's actually the general solution for the point halfway between where
-- two skew lines come nearest to each other, which is more forgiving.

Response:
local function RayIntersection(p0: Vector3, v0: Vector3, p1: Vector3, v1: Vector3): Vector3
	local v2 = v0:Cross(v1)
	local d1 = p1.X - p0.X
	local d2 = p1.Y - p0.Y
	local d3 = p1.Z - p0.Z
	local denom = Det3x3(v0.X,-v1.X,v2.X,v0.Y,-v1.Y,v2.Y,v0.Z,-v1.Z,v2.Z)

	if (denom == 0) then
		return ZERO_VECTOR3 -- No solution (rays are parallel)
	end

	local t0 = Det3x3(d1,-v1.X,v2.X,d2,-v1.Y,v2.Y,d3,-v1.Z,v2.Z) / denom
	local t1 = Det3x3(v0.X,d1,v2.X,v0.Y,d2,v2.Y,v0.Z,d3,v2.Z) / denom
	local s0 = p0 + t0 * v0
	local s1 = p1 + t1 * v1
	local s = s0 + 0.5 * ( s1 - s0 )

	-- 0.25 studs is a threshold for deciding if the rays are
	-- close enough to be considered intersecting, found through testing
	if (s1-s0).Magnitude < 0.25 then
		return s
	else
		return ZERO_VECTOR3
	end
end


Prompt: --BaseRay.Transparency = 1

Response:
BaseRayMesh = Instance.new("SpecialMesh")
BaseRayMesh.Name = "Mesh"
BaseRayMesh.MeshType = Enum.MeshType.Brick
BaseRayMesh.Scale = Vector3.new(0.2, 0.2, 1)
BaseRayMesh.Offset = Vector3.new(0, 0, 0)
BaseRayMesh.VertexColor = Vector3.new(1, 1, 1)
BaseRayMesh.Parent = BaseRay

ServerControl = (Remotes:FindFirstChild("ServerControl") or Instance.new("RemoteFunction"))
ServerControl.Name = "ServerControl"
ServerControl.Parent = Remotes

ClientControl = (Remotes:FindFirstChild("ClientControl") or Instance.new("RemoteFunction"))
ClientControl.Name = "ClientControl"
ClientControl.Parent = Remotes

Light.Enabled = false
Tool.Enabled = true

function RayTouched(Hit, Position)
	if Configuration.DestroyParts.Value then
		Hit:Destroy()
	end
	if Configuration.SuperPartDestruction.Value then
		Hit.Archivable = false
		Hit:Destroy()
	end
	if not Hit or not Hit.Parent then
		return
	end
	local character = Hit.Parent
	if character:IsA("Hat") then
		character = character.Parent
	end
	if character == Character then
		return
	end
	local humanoid = character:FindFirstChildOfClass('Humanoid')
	if not humanoid  or humanoid.Health == 0 then
		return
	end
	local player = Players:GetPlayerFromCharacter(character)
	if player and Functions.IsTeamMate(Player, player) then
		return
	end
	local DeterminedDamage = math.random(Configuration.Damage.MinValue, Configuration.Damage.MaxValue)
	Functions.UntagHumanoid(humanoid)
	Functions.TagHumanoid(humanoid, Player)
	if Configuration.InstantKill.Value then
		humanoid.Health = 0
	end

	if Configuration.IgnoreForceField.Value then
		if Hit.Name == 'Head' then
			humanoid.Health = humanoid.Health - math.random(Configuration.Damage.MinValue, Configuration.Damage.MaxValue) * Configuration.HeadShotMultiplier.Value
			Sounds.HeadShot:Play()
		else
			humanoid.Health = humanoid.Health - math.random(Configuration.Damage.MinValue, Configuration.Damage.MaxValue)
		end
	else
		if Hit.Name == 'Head' then
			humanoid:TakeDamage(DeterminedDamage * Configuration.HeadShotMultiplier.Value)
			humanoid.WalkSpeed = humanoid.WalkSpeed / 4
			local drainscript = script.Parent.Drain:Clone()
			drainscript.Parent = humanoid.Parent
			drainscript.Disabled = false
			Sounds.HeadShot:Play()
		else
			humanoid:TakeDamage(DeterminedDamage)
			humanoid.WalkSpeed = humanoid.WalkSpeed / 2
		end
	end
end

function CheckIfAlive()
	return (((Player and Player.Parent and Character and Character.Parent and Humanoid and Humanoid.Parent and Humanoid.Health > 0) and true) or false)
end

function Equipped()
	Character = Tool.Parent
	Player = Players:GetPlayerFromCharacter(Character)
	Humanoid = Character:FindFirstChild("Humanoid")
	if not CheckIfAlive() then
		return
	end
	ToolEquipped = true
end

function Unequipped()
	ToolEquipped = false
end

function InvokeClient(Mode, Value)
	local ClientReturn = nil
	pcall(function()
		ClientReturn = ClientControl:InvokeClient(Player, Mode, Value)
	end)
	return ClientReturn
end

ServerControl.OnServerInvoke = (function(player, Mode, Value)
	if player ~= Player or not ToolEquipped or not CheckIfAlive() or not Mode or not Value then
		return
	end
	if Mode == "Fire" then
		Sounds.Fire:Play()
		FX:Emit(3)
		if Configuration.AddRecoil.Value then
			if Recoil.Disabled then
				Recoil.Disabled = false
				delay(0.01, function()
					Recoil.Disabled = true
				end)
			end
		end
	elseif Mode == "RayHit" then
		local RayHit = Value.Hit
		local RayPosition = Value.Position
		if RayHit and RayPosition then
			RayTouched(RayHit, RayPosition)
		end
	elseif Mode == "CastLaser" then
		local StartPosition = Value.StartPosition
		local TargetPosition = Value.TargetPosition
		local RayHit = Value.RayHit
		if not StartPosition or not TargetPosition or not RayHit then
			return
		end
		for i, v in pairs(Players:GetPlayers()) do
			if v:IsA("Player") and v ~= Player then
				local Backpack = v:FindFirstChild("Backpack")
				if Backpack then
					local LaserScript = CastLaser:Clone()
					local StartPos = Instance.new("Vector3Value")
					StartPos.Name = "StartPosition"
					StartPos.Value = StartPosition
					StartPos.Parent = LaserScript
					local TargetPos = Instance.new("Vector3Value")
					TargetPos.Name = "TargetPosition"
					TargetPos.Value = TargetPosition
					TargetPos.Parent = LaserScript
					local RayHit = Instance.new("BoolValue")
					RayHit.Name = "RayHit"
					RayHit.Value = RayHit
					RayHit.Parent = LaserScript
					LaserScript.Disabled = false
					Debris:AddItem(LaserScript, 1.5)
					LaserScript.Parent = Backpack
				end
			end
		end
	end
end)

Tool.Equipped:connect(Equipped)
Tool.Unequipped:connect(Unequipped)


Prompt: --//Controller//--

Response:
Trigger.Triggered:Connect(function(Player)
	SpawnEvent:FireClient(Player, SpawnPoint)

end)


Prompt:
--[=[
	Throttles the update to the end of the defer lane. Can help optimize scenarios when
	Compute() can trigger multiple times per a frame.

	Generally not needed.

	@param observable Observable<T>
	@return Observable<T>
]=]

Response:
function Blend.Throttled(observable)
	return observable:Pipe({
		Rx.throttleDefer();
	})
end


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

Response:
local l__RunService__1 = game:GetService("RunService");
local l__Parent__2 = script.Parent;
local l__Background__3 = l__Parent__2.Background;
local l__LogoFrame__4 = l__Background__3.LogoFrame;
local l__TweenService__1 = game:GetService("TweenService");
function tween(p1, p2, p3)
	l__TweenService__1:Create(p1, TweenInfo.new(p2), p3):Play();
end;
local l__Logo__2 = l__LogoFrame__4.Logo;
function displayLoadingScreen()
	l__Parent__2.Enabled = true;
	l__Background__3.BackgroundTransparency = 0;
	tween(l__Background__3.CircleLeft.UIStroke, 3, {
		Transparency = 0
	});
	tween(l__Background__3.CircleRight.UIStroke, 3, {
		Transparency = 0
	});
	task.wait(3);
	local v5, v6, v7 = pairs(l__Logo__2:GetChildren());
	while true do
		local v8, v9 = v5(v6, v7);
		if v8 then

		else
			break;
		end;
		v7 = v8;
		if v9.ClassName == "Frame" then
			v9.UIPageLayout.TweenTime = 0.75;
			v9.UIPageLayout:JumpTo(v9.ImageLabel);
			tween(v9.ImageLabel, 1, {
				ImageTransparency = 0
			});
			task.wait();
		end;
	end;
	tween(l__LogoFrame__4.LoadingText, 1, {
		TextTransparency = 0
	});
	task.wait(2);
	if not game:IsLoaded() then
		game.Loaded:Wait();
	end;
	local v10, v11, v12 = pairs(l__Logo__2:GetChildren());
	while true do
		local v13, v14 = v10(v11, v12);
		if v13 then

		else
			break;
		end;
		v12 = v13;
		if v14.ClassName == "Frame" then
			v14.UIPageLayout.TweenTime = 2;
			v14.UIPageLayout:JumpTo(v14.Frame);
			tween(v14.ImageLabel, 0.15, {
				ImageTransparency = 1
			});
			task.wait();
		end;
	end;
	tween(l__LogoFrame__4.LoadingText, 1, {
		TextTransparency = 1
	});
	tween(l__Background__3.CircleLeft.UIStroke, 1, {
		Transparency = 1
	});
	tween(l__Background__3.CircleRight.UIStroke, 1, {
		Transparency = 1
	});
	tween(l__Background__3, 3, {
		BackgroundTransparency = 1
	});
	task.wait(3);
	l__Parent__2.Enabled = false;
end;
game:GetService("ReplicatedFirst"):RemoveDefaultLoadingScreen();
if not l__RunService__1:IsStudio() then
	displayLoadingScreen();
end;


Prompt:
--[[local SwordMesh = Handle:WaitForChild("SwordMesh")
SwordMesh.VertexColor = Vector3.new(1,1,1) -- Keep it normal]]

Response:
local Properties = {
	Damage = 14,
	Special = true,
	SpecialReload = 30,
	SpecialActive = false,
	TimetoChange = 12,
	LightTeleport = true
}

local Sounds = {
	Lunge = Handle:WaitForChild("Lunge"),
	Unsheath = Handle:WaitForChild("Unsheath")
}

local Remote = Tool:FindFirstChildOfClass("RemoteEvent") or Create("RemoteEvent"){
	Name = "Remote",
	Parent = Tool
}

local MousePos = Tool:FindFirstChildOfClass("RemoteFunction") or Create("RemoteFunction"){
	Name = "MouseInput",
	Parent = Tool
}

local function SunIsVisible(Character)
	local dir = Services.Lighting:GetSunDirection()
	if Vector3.new(0,1,0):Dot(dir) > 0 then
	-- BUG: particles block raycast
	local hit = workspace:FindPartOnRay(Ray.new(Handle.Position,dir*999),Character)
		if not hit or (hit and not hit.CanCollide)then
			return true
		end
	end
	return false
end

function IsInTable(Table,Value)
	for _,v in pairs(Table) do
		if v == Value then
			return true
		end
	end
	return false
end

local function Wait(para) -- bypasses the latency
	local Initial = tick()
	repeat
		Services.RunService.Stepped:Wait()
	until tick()-Initial >= para
end

function IsTeamMate(Player1, Player2)
	return (Player1 and Player2 and not Player1.Neutral and not Player2.Neutral and Player1.TeamColor == Player2.TeamColor)
end

function TagHumanoid(humanoid, player)
	local Creator_Tag = Instance.new("ObjectValue")
	Creator_Tag.Name = "creator"
	Creator_Tag.Value = player
	Services.Debris:AddItem(Creator_Tag, 2)
	Creator_Tag.Parent = humanoid
end

function UntagHumanoid(humanoid)
	for i, v in pairs(humanoid:GetChildren()) do
		if v:IsA("ObjectValue") and v.Name == "creator" then
			v:Destroy()
		end
	end
end

local function EnableParticles(Verdict)
	for _,stuff in pairs(Handle:GetDescendants()) do
		if (stuff:IsA("ParticleEmitter") and stuff.Parent ~= Handle) or stuff:IsA("Light") then
			stuff.Enabled = Verdict
		end
		if stuff:IsA("Light") then
			stuff.Range = (Verdict and 10) or 3
		end
	end
end

local function SpecialParticles(Verdict)
	for _,stuff in pairs(Handle:GetDescendants()) do
		if stuff:IsA("ParticleEmitter") and stuff.Parent == Handle then
			stuff.Enabled = Verdict
		end
		if stuff:IsA("Beam") then
			stuff.TextureSpeed = (Verdict and 1) or .1
			stuff.Color = (Verdict and ColorSequence.new(Color3.new(1,1,1)) or ColorSequence.new(Color3.new(.5,.5,.5)))
		end
	end
end

local Player,Character,Humanoid,Root

function PassiveSpecial()
	--Sword of light does healing + Damage resistance when the sun is out
	--Check if Daytime then roll with ability
	--loop until time is not daytime
	if not Humanoid or Humanoid.Health <= 0 or not Character then return end

	if not SunIsVisible(Character) then
		--print("Sun is not visible")
		EnableParticles(false)
		Properties.SpecialActive = false
		if Humanoid and Tool:IsDescendantOf(Character) then
			Humanoid.WalkSpeed = 16
			Properties.Damage = 14
		end
		--[[Disable particles on sword]]
		return
	end

	if Humanoid and Tool:IsDescendantOf(Character) then
		Humanoid.WalkSpeed = 25
		Properties.Damage = 20
	end
	--Trigger active particles on sword

	if not Character:FindFirstChild(script:WaitForChild("SoLDefense").Name) and Tool:IsDescendantOf(Character) then
		local DefenseScript = script:WaitForChild("SoLDefense"):Clone()
		local ToolRef = Create("ObjectValue"){
			Name = "ToolRef",
			Value = Tool,
			Parent = DefenseScript
		}
		DefenseScript.Parent = Character
		DefenseScript.Disabled = false
	end

	if Properties.SpecialActive then --[[print("On Cooldown")]] return end
	--SwordMesh.VertexColor = Vector3.new(1,1,1) * 10 -- Make the sword look all bright

	Properties.SpecialActive = true
	EnableParticles(true)

end

local Animations = {}

function ChangeTime(Time) --initiate the cool time-chaning effect!
	if not Properties.Special then return end
	--warn("Changing Time")
	Properties.Special = false
	SpecialParticles(false)
	Tool.Enabled = false
	Humanoid.WalkSpeed = 0
	Animations.Summon:Play()
	delay(3,function()
		PassiveSpecial()
		Tool.Enabled = true
		Animations.Summon:Stop()
		--Humanoid.WalkSpeed = (Humanoid.WalkSpeed <=0 and 16) or Humanoid.WalkSpeed
	end)
	delay(Properties.SpecialReload,function()
		Properties.Special = true
		SpecialParticles(true)
	end)
	local TimeChange = script:WaitForChild("TimeChange"):Clone()
	local SpawnPosition = Create("Vector3Value"){
		Name = "SpawnPosition",
		Value = Root.Position - Vector3.new(0,Root.Size.Y * 1.5,0),
		Parent = TimeChange,
	}
	local Creator = Create("ObjectValue"){
		Name = "Creator",
		Value = Player,
		Parent = TimeChange
	}
	local Time = Create("NumberValue"){
		Name = "Time",
		Value = Time,
		Parent = TimeChange
	}
	TimeChange.Parent = Services.ServerScriptService
	TimeChange.Disabled = false
end

local function LightTransport()
	local LightWarpScript = script:WaitForChild("LightWarp")
	local function IsWarping()
		local stuff = Services.ServerScriptService:GetChildren()
		for i=1,#stuff do
			if stuff[i] and stuff[i].Name == LightWarpScript.Name and stuff[i]:FindFirstChild("Character") and stuff[i]:FindFirstChild("Character").Value == Character then
				return true
			end
		end
		return false
	end

	if IsWarping() then return end

	local sucess,MousePosition = pcall(function() return MousePos:InvokeClient(Player) end)
	MousePosition = (sucess and MousePosition) or Vector3.new(0,0,0)

	LightWarpScript = LightWarpScript:Clone()
	local CharacterTag = Create("ObjectValue"){
		Name = "Character",
		Value = Character,
		Parent = LightWarpScript
	}
	local TargetLocation = Create("Vector3Value"){
		Name = "TargetLocation",
		Value = MousePosition,
		Parent = LightWarpScript
	}
	local Range = Create("NumberValue"){
		Name = "Range",
		Value = (Properties.SpecialActive and 200) or 100,
		Parent = LightWarpScript
	}
	LightWarpScript.Parent = Services.ServerScriptService
	LightWarpScript.Disabled = false
end

local EquippedEvents = {}
local Touch

local MouseHeld = false
local CurrentMotor,RightWeld,Part0,Part1

function Equipped()
	Character = Tool.Parent
	Player = Services.Players:GetPlayerFromCharacter(Character)
	Humanoid = Character:FindFirstChildOfClass("Humanoid")
	Root = Character:WaitForChild("HumanoidRootPart")

	if not Humanoid or Humanoid.Health <= 0 then return end

	Animations = Tool:WaitForChild("Animations"):WaitForChild(Humanoid.RigType.Name)
	Animations = {
		Slash = Humanoid:LoadAnimation(Animations:WaitForChild("SlashAnim")),
		Stab = Humanoid:LoadAnimation(Animations:WaitForChild("StabAnim")),
		Summon = Humanoid:LoadAnimation(Animations:WaitForChild("SummonAnim")),
		Charge = Humanoid:LoadAnimation(Animations:WaitForChild("ChargeAnim")),
	}
	Touch = Handle.Touched:Connect(function(hit)
		if not hit or not hit.Parent then return end
		local Hum,FF = hit.Parent:FindFirstChildOfClass("Humanoid"),hit.Parent:FindFirstChildOfClass("ForceField")
		if not Hum or FF or Hum.Health <= 0 or IsTeamMate(Services.Players:GetPlayerFromCharacter(Hum.Parent),Player) or Hum.Parent == Character then return end
		UntagHumanoid(Hum)
		TagHumanoid(Hum,Player)
		Hum:TakeDamage(Properties.Damage)
		print(Properties.Damage)
	end)
	PassiveSpecial()
	Sounds.Unsheath:Play()
end

function Unequipped()
	MouseHeld = false
	if Touch then Touch:Disconnect();Touch = nil end
	for AnimName,anim in pairs(Animations) do
		if anim then
			anim:Stop()
		end
	end
	if CurrentMotor then
		CurrentMotor:Destroy()
	end
	if Tool:IsDescendantOf(workspace) and not Tool:IsDescendantOf(Character) then
		for index = 1,#EquippedEvents do
			if EquippedEvents[index] then
				EquippedEvents[index]:Disconnect();EquippedEvents[index] = nil
			end
		end
	end
end

local Seed = Random.new()

function Activated()
	if not Tool.Enabled or MouseHeld then return end
	MouseHeld = true
	Animations.Charge:Play()
end

function Deactivated()
	if not Tool.Enabled or not MouseHeld then return end
	MouseHeld = false

	Tool.Enabled = false
	local RightLimb = Character:FindFirstChild("Right Arm") or Character:FindFirstChild("RightHand")
	if RightLimb then
		RightWeld = RightLimb:FindFirstChildOfClass("Weld")
		if RightWeld and not CurrentMotor then
			CurrentMotor = Create'Motor6D'{
				Name = 'Grip',
				--C0 = RightWeld.C0,
				--C1 = Tool.Grip,--RightWeld.C1,
				Part0 = RightWeld.Part0,
				Part1 = Handle,
				--Parent = RightArm
			}
			CurrentMotor.Parent = RightLimb
		end
		coroutine.wrap(function()
			if RightWeld then
				Part0 = RightWeld.Part0
				Part1 = RightWeld.Part1
				RightWeld.Part0 = nil
				RightWeld.Part1 = nil
			end
		end)()

	end
	local AttackAnims = {--[[Animations.Slash,]]Animations.Stab}
	Sounds.Lunge:Play()
	Animations.Charge:Stop()
	local Anim = AttackAnims[Seed:NextInteger(1,#AttackAnims)]
	Anim:Play(0,nil,3);--Anim.Stopped:Wait()
	Wait(Anim.Length/3)
	if RightWeld then
		RightWeld.Part0 = Part0
		RightWeld.Part1 = Part1
	end
	if CurrentMotor then
		CurrentMotor:Destroy();CurrentMotor = nil
	end
	Tool.Enabled = true
end

Remote.OnServerEvent:Connect(function(Client,Key)
	if Client ~= Player or not Key or not Humanoid or Humanoid.Health <= 0 or not Tool.Enabled then return end
	if Key == Enum.KeyCode.Q then
		ChangeTime(Properties.TimetoChange)
	elseif Key == Enum.KeyCode.E and Properties.LightTeleport then
		Properties.LightTeleport = false
		delay(5,function()
			Properties.LightTeleport = true
		end)
	 	LightTransport()
	end
end)

Tool.Equipped:Connect(Equipped)
Tool.Unequipped:Connect(Unequipped)
Tool.Activated:Connect(Activated)
Tool.Deactivated:Connect(Deactivated)

Services.Lighting.Changed:Connect(function(property)
	if property == "ClockTime" then
		PassiveSpecial()
	end
end)
EnableParticles(false)
SpecialParticles(true)
PassiveSpecial()--trigger it initially on start


Prompt: -- Admins List --

Response:
local Owners = {"Put Name Here"} --Has no limitations but can only be given through this script here
local SuperAdmins = {"Put Name Here"} --Desc when done
local Admins = {"Put Name Here"} --Desc when done
local Mods = {"Put Name Here"} --Desc when done


Prompt: --Internal functions

Response:
function DataStore:Debug(...)
	if self.debug then
		print(...)
	end
end

function DataStore:_GetRaw()
	if self.getRawPromise then
		return self.getRawPromise
	end

	self.getRawPromise = self.savingMethod:Get():andThen(function(value)
		self.value = value
		self:Debug("value received")
		self.haveValue = true
	end):finally(function()
		self.getting = false
	end)

	return self.getRawPromise
end

function DataStore:_Update(dontCallOnUpdate)
	if not dontCallOnUpdate then
		for _,callback in pairs(self.callbacks) do
			callback(self.value, self)
		end
	end

	self.haveValue = true
	self.valueUpdated = true
end


Prompt: -- FUNCTIONS --

Response:
return function(TargetCF)

	local spikes = FX.Club.Z:Clone()
	spikes.PrimaryPart.CFrame = TargetCF

	local originalSizeList = {
		spikes.Floor["1"].Size,
		spikes.Floor["2"].Size,
		spikes.Floor["3"].Size,
		spikes.Floor["4"].Size,
		spikes.Floor["5"].Size,
		spikes.Floor["6"].Size,
		spikes.Floor["7"].Size,
		spikes.Floor["8"].Size,
		spikes.Floor["9"].Size,
		spikes.Floor["10"].Size,
		spikes.Floor["11"].Size,
	}

	local floorSize = spikes.Floor.Size
	spikes.Floor.Size = Vector3.new()
	spikes.Floor.Transparency = 1

	coroutine.wrap(function() -- THREAD TO MAKE SPIKES INVISIBLE
		for i, v in pairs(spikes.Floor:GetChildren()) do
			if v:IsA("MeshPart") then
				v.Transparency = 1
				v.Size = Vector3.new()
			end
		end
	end)()

	spikes.Parent = workspace.Debris

	local impactSFX = RS.Sounds.Club.Z.Impact:Clone()
	impactSFX.Parent = spikes.Floor
	impactSFX:Play()

	local expSFX = RS.Sounds.Club.Z.Explosion:Clone()
	expSFX.Parent = spikes.Floor
	expSFX:Play()

	coroutine.wrap(function()
		for i, v in pairs(spikes.Floor:GetChildren()) do
			if v:IsA("MeshPart") then
				local spikeIndex = tonumber(v.Name)
				v.Transparency = 0
				TS:Create(v, TweenInfo.new(0.18, Enum.EasingStyle.Back, Enum.EasingDirection.Out), {Size = originalSizeList[spikeIndex]}):Play()

				local dustFX = spikes.Dust:Clone()
				dustFX.Parent = v
				dustFX:Emit(dustFX:GetAttribute("EmitCount"))

				task.wait(0.015)
			end
		end
	end)()

	spikes.Floor.Transparency = 0
	TS:Create(spikes.Floor, TweenInfo.new(0.25, Enum.EasingStyle.Back, Enum.EasingDirection.Out), {Size = floorSize}):Play()

	local dustFX = spikes.Dust:Clone()
	dustFX.Parent = spikes.Floor
	dustFX:Emit(dustFX:GetAttribute("EmitCount"))

	debrisModule.Shockwave(TargetCF.Position, 25, 55)

	task.delay(4, function()
		--coroutine.wrap(function()
			for i, v in pairs(spikes.Floor:GetChildren()) do
				if v:IsA("MeshPart") then
					local spikeIndex = tonumber(v.Name)
					TS:Create(v, TweenInfo.new(0.35, Enum.EasingStyle.Back, Enum.EasingDirection.In), {Size = Vector3.new()}):Play()
					task.wait(0.025)
				end
			end
		--end)()
		task.wait(0.3)

		TS:Create(spikes.Floor, TweenInfo.new(0.35, Enum.EasingStyle.Back, Enum.EasingDirection.In), {Size = Vector3.new()}):Play()
		game.Debris:AddItem(spikes, 2)
	end)
end