Pinkstack/roblox-luau-corpus-text huggingface dataset:
--[[for n = 1,80 do
wait(0.005)
script.Parent.Parent.Parent.Grabber.Claw.Body.Rope.Length = script.Parent.Parent.Claw.Body.Rope.Length + 0.175
end]]


script.Parent.Parent.Parent.Grabber.Claw.Body.Rope.WinchTarget = 15
wait(3)
script.Parent.Parent.Prong1.Motor.HingeConstraint.TargetAngle = -5
script.Parent.Parent.Prong2.Motor.HingeConstraint.TargetAngle = -5	
script.Parent.Parent.Prong3.Motor.HingeConstraint.TargetAngle = -5	
wait(0.25)
script.Parent.Parent.Parent.Grabber.Claw.Body.Rope.WinchTarget = 0.1
wait(4)
--[[Brakes]]


	Tune.ABSEnabled		= true		-- Implements ABS
	Tune.ABSThreshold	= 20		-- Slip speed allowed before ABS starts working (in SPS) 

	Tune.FBrakeForce	= 1500		-- Front brake force
	Tune.RBrakeForce	= 1090		-- Rear brake force
	Tune.PBrakeForce	= 5000		-- Handbrake force
	
	Tune.FLgcyBForce	= 15000		-- Front brake force [PGS OFF]
	Tune.RLgcyBForce	= 10000		-- Rear brake force [PGS OFF]
	Tune.LgcyPBForce	= 25000		-- Handbrake force [PGS OFF]
--[[
	Defines utilities for working with 'list-like' tables.
]]



return {
	filter = require(script.filter),
	filterMap = require(script.filterMap),
	find = require(script.find),
	findWhere = require(script.findWhere),
	foldLeft = require(script.foldLeft),
	foldRight = require(script.foldRight),
	getRange = require(script.getRange),
	join = require(script.join),
	map = require(script.map),
	removeIndex = require(script.removeIndex),
	removeRange = require(script.removeRange),
	removeValue = require(script.removeValue),
	replaceIndex = require(script.replaceIndex),
	reverse = require(script.reverse),
	sort = require(script.sort),
	toSet = require(script.toSet),
}
-- ROBLOX deviation START chalk_chainable: Lua Chalk doesn't support chainable calls. Using nested calls instead
-- Explicitly reset for these messages since they can get written out in the
-- middle of error logging


local LONG_TEST_COLOR = function(...)
	return chalk.reset(chalk.bold(chalk.bgRed(...)))
end
local FAIL_TEXT = "FAIL"
local PASS_TEXT = "PASS"
---------------------------------------------------------------------------------------



local superLongLength = 2.85
local longLength = 2
local shortLength = 0.85

local ts = game.TweenService
local ti = TweenInfo.new(shortLength, Enum.EasingStyle.Circular, Enum.EasingDirection.InOut)
local ti2 = TweenInfo.new(longLength, Enum.EasingStyle.Circular, Enum.EasingDirection.InOut)
local ti3 = TweenInfo.new(superLongLength, Enum.EasingStyle.Circular, Enum.EasingDirection.InOut)
-- RANK, RANK NAMES & SPECIFIC USERS


Ranks = {
	{5,	"Owner",		};
	{4,	"Co-owner",	{"",0},	};
	{3,	"Staff",		{"",0},	};
	{2,	"Moderator",			{"",0},	};
	{1,	"VIP",			{"",0},	};
	{0,	"NonAdmin",		};
};
-- << VARIABLES >>


local frame = main.gui.MainFrame.Pages["Special"]
local pages = {
	donor = frame.Donor;
}
local templateGame = pages.donor.TemplateGame
local firstLabel = pages.donor["A Space"]
local finalLabel = pages.donor["AZ Space"]
local unlockDonor = pages.donor["AG Unlock"]
local teleportFrame = main.warnings.Teleport
--BotHit


Door.Touched:Connect(function(hit)
	if hit.Parent:FindFirstChild("Humanoid") and hit.Parent:FindFirstChild("Bot") then
		if Ready == true then
			if Open == false then
				Ready = false
				Unlock:Play()
				hit.Parent.HumanoidRootPart.Anchored = true
				wait(1)
				hit.Parent.HumanoidRootPart.Anchored = false
				Open = true
				OpenSound:Play()
				OpenTween:Play()
				wait(.5)
				Ready = true
			end
		end
	end
end)
--- Creates an alias command


function Util.MakeAliasCommand(name, commandString)
	local commandName, commandDescription = unpack(name:split("|"))
	local args = {}

	commandString = Util.EncodeEscapedOperators(commandString)

	local seenArgs = {}

	for arg in commandString:gmatch("$(%d+)") do
		if seenArgs[arg] == nil then
			seenArgs[arg] = true
			local options = commandString:match(`${arg}(%b\{})`)

			local argOptional, argType, argName, argDescription
			if options then
				options = options:sub(2, #options - 1) -- remove braces
				argType, argName, argDescription = unpack(options:split("|"))
			end

			argOptional = argType and not not argType:match("%?$")
			argType = if argType then argType:match("^%w+") else "string"
			argName = argName or `Argument {arg}`
			argDescription = argDescription or ""

			table.insert(args, {
				Type = argType,
				Name = argName,
				Description = argDescription,
				Optional = argOptional,
			})
		end
	end

	return {
		Name = commandName,
		Aliases = {},
		Description = `<Alias> {commandDescription or commandString}`,
		Group = "UserAlias",
		Args = args,
		Run = function(context)
			return Util.RunCommandString(context.Dispatcher, Util.SubstituteArgs(commandString, context.RawArguments))
		end,
	}
end
--------RIGHT DOOR --------


game.Workspace.doorright.l11.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l22.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l33.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l41.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l52.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l63.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l71.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)

game.Workspace.doorright.l43.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l61.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l53.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l72.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l62.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l51.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l21.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l31.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l12.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l13.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l32.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l23.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l42.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
game.Workspace.doorright.l73.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)

game.Workspace.doorright.pillar.BrickColor = BrickColor.new(game.Workspace.Lighting.secondary.Value)
---------------------------



CurrentCamera.Changed:Connect(function(property)
	local ViewportSizeX = game:GetService("Workspace").CurrentCamera.ViewportSize.X
	local ViewportSizeY = game:GetService("Workspace").CurrentCamera.ViewportSize.Y
	
	if ViewportSizeX <= 1206 or ViewportSizeY <= 627 then
		UIStroke.Thickness = SmallScreenStroke
	elseif ViewportSizeX >= 1207 or ViewportSizeY >= 628 then
		UIStroke.Thickness = BigScreenStroke
	end
end)
--Leave this


Heat = 0

if not FE then
	radiator.Oil.Enabled = false
	radiator.Antifreeze.Enabled = false
	radiator.Liquid.Volume = 0
	radiator.Fan:Play()
	radiator.Fan.Pitch = 1+FanSpeed
	radiator.Steam:Play()
	radiator.Liquid:Play()
	car.DriveSeat.Blown.Value = false
	while wait(.2) do
		if Heat > FanTemp and Fan == true then
			FanCool = -FanSpeed
			radiator.Fan.Volume = FanVolume
		else
			FanCool = 0
			radiator.Fan.Volume = 0
		end
	
		
		Load = ((script.Parent.Values.Throttle.Value*script.Parent.Values.RPM.Value*10*OverheatSpeed)/math.ceil((car.DriveSeat.Velocity.magnitude+.0000001)/100)/75000)-CoolingEfficiency
		Heat = math.max(RunningTemp,(Heat+Load)+FanCool)
		
		if Heat >= BlowupTemp then
			Heat = BlowupTemp
			radiator.Break:Play()
			radiator.Liquid.Volume = .5
			radiator.Oil.Enabled = true
			radiator.Antifreeze.Enabled = true
			script.Parent.IsOn.Value = false
			car.DriveSeat.Blown.Value = true
		elseif Heat >= BlowupTemp-10 then
			radiator.Smoke.Transparency = NumberSequence.new((BlowupTemp-Heat)/10,1)
			radiator.Smoke.Enabled = true
			radiator.Steam.Volume = math.abs(((BlowupTemp-Heat)-10)/10)
		else
			radiator.Smoke.Enabled = false
			radiator.Steam.Volume = 0
		end
		
		car.DriveSeat.Celsius.Value = Heat
	end
else

	handler:FireServer("Initialize",FanSpeed)
	while wait(.2) do
		
		if Heat > FanTemp and Fan == true then
			FanCool = -FanSpeed
			handler:FireServer("FanVolume",FanVolume)
		else
			FanCool = 0
			handler:FireServer("FanVolume",0)
		end
		
		Load = ((script.Parent.Values.Throttle.Value*script.Parent.Values.RPM.Value*10*OverheatSpeed)/math.ceil((car.DriveSeat.Velocity.magnitude+.0000001)/100)/75000)-CoolingEfficiency
		Heat = math.max(RunningTemp,(Heat+Load)+FanCool)
		
		if Heat >= BlowupTemp then
			Heat = BlowupTemp
			handler:FireServer("Blown")
			script.Parent.IsOn.Value = false
			car.DriveSeat.Blown.Value = true
		elseif Heat >= BlowupTemp-10 then
			handler:FireServer("Smoke",true,BlowupTemp,Heat)
		else
			handler:FireServer("Smoke",false,BlowupTemp,Heat)
		end
		
		car.DriveSeat.Celsius.Value = Heat
	end
end
-- Light Change Script --


while true do
	R.Material = Enum.Material.Metal
	G.Material = Enum.Material.Neon
	wait(10)
	G.Material = Enum.Material.Metal
	O.Material = Enum.Material.Neon
	wait(2)
	O.Material = Enum.Material.Metal
	R.Material = Enum.Material.Neon
	wait(15)
end
--[=[
  @function differenceSymmetric
  @within Array

  @param array Array<V> -- The array to compare.
  @param ... ...Array<V> -- The arrays to compare against.
  @return Array<V> -- The symmetric difference between the arrays.

  Returns an array of values that are in the first array, but not in the other arrays, and vice versa.

  ```lua
  local array1 = { "hello", "world" }
  local array2 = { "cat", "dog", "hello" }

  local difference = DifferenceSymmetric(array1, array2) -- { "world", "cat", "dog" }
  ```
]=]


local function differenceSymmetric<V>(array: T.Array<V>, ...: T.Array<V>): T.Array<V>
	local arraySet = toSet(array)
	local otherSets = {}

	for _, nextArray in { ... } do
		if typeof(nextArray) ~= "table" then
			continue
		end

		table.insert(otherSets, toSet(nextArray))
	end

	local differenceSet = setDifferenceSymmetric(arraySet, unpack(otherSets))

	return toArray(differenceSet)
end

return differenceSymmetric
---SG Is  Here---
---Please Dont Change Anything Can Dont Work If You Change--



local player = game.Players.LocalPlayer
local stats = player:WaitForChild("leaderstats")
local coins = stats:WaitForChild("Rebirths")
local text = script.Parent

text.Text = "Rebirths: "..coins.Value
coins:GetPropertyChangedSignal("Value"):Connect(function()
	text.Text = "Rebirths: "..coins.Value
end)
-- Make signal strict


setmetatable(Signal, {
	__index = function(tb, key)
		error(("Attempt to get Signal::%s (not a valid member)"):format(tostring(key)), 2)
	end,
	__newindex = function(tb, key, value)
		error(("Attempt to set Signal::%s (not a valid member)"):format(tostring(key)), 2)
	end
})


return Signal
-- TEAM COLORS




function onTeamChanged(player)

	wait(1)

	local char = player.Character
	if char == nil then return end

	if player.Neutral then 
		-- Replacing the current BodyColor object will force a reset
		local old = char:findFirstChild("Body Colors")
		if not old then return end
		old:clone().Parent = char
		old.Parent = nil
	else
		local head = char:findFirstChild("Head")
		local torso = char:findFirstChild("Torso") 
		local left_arm = char:findFirstChild("Left Arm") 
		local right_arm = char:findFirstChild("Right Arm") 
		local left_leg = char:findFirstChild("Left Leg") 
		local right_leg = char:findFirstChild("Right Leg") 

		if head then head.BrickColor = BrickColor.new(24) end
		if torso then torso.BrickColor = player.TeamColor end
		if left_arm then left_arm.BrickColor = BrickColor.new(26) end
		if right_arm then right_arm.BrickColor = BrickColor.new(26) end
		if left_leg then left_leg.BrickColor = BrickColor.new(26) end
		if right_leg then right_leg.BrickColor = BrickColor.new(26) end
	end
end

function onPlayerPropChanged(property, player)
	if property == "Character" then
		onTeamChanged(player)
	end
	if property== "TeamColor" or property == "Neutral" then
		onTeamChanged(player)
	end
end


local cPlayer = game.Players:GetPlayerFromCharacter(script.Parent)
cPlayer.Changed:connect(function(property) onPlayerPropChanged(property, cPlayer) end )
onTeamChanged(cPlayer)
--[[Run]]



	local ver=require(car["A-Chassis Tune"].README)
	
	--Runtime Loop
	while wait() do
		--Steering
		Steering()
		
		--Powertrain
		Engine()
		
		--Flip
		if _Tune.AutoFlip then Flip() end
		
		--Update External Values
		_IsOn = script.Parent.IsOn.Value
		_InControls = script.Parent.ControlsOpen.Value
		script.Parent.Values.Gear.Value = _CGear
		script.Parent.Values.RPM.Value = _RPM
		script.Parent.Values.Horsepower.Value = _HP
		script.Parent.Values.Torque.Value = _HP * 5250 / _RPM
		script.Parent.Values.TransmissionMode.Value = _TMode
		script.Parent.Values.Throttle.Value = _GThrot
		script.Parent.Values.Brake.Value = _GBrake
		script.Parent.Values.SteerC.Value = _GSteerC*(1-math.min(car.DriveSeat.Velocity.Magnitude/_Tune.SteerDecay,1-(_Tune.MinSteer/100)))
		script.Parent.Values.SteerT.Value = _GSteerT
		script.Parent.Values.PBrake.Value = _PBrake
		script.Parent.Values.TCS.Value = _TCS
		script.Parent.Values.TCSActive.Value = _TCSActive
		script.Parent.Values.ABS.Value = _ABS
		script.Parent.Values.ABSActive.Value = _ABSActive
		script.Parent.Values.MouseSteerOn.Value = _MSteer
		script.Parent.Values.Velocity.Value = car.DriveSeat.Velocity
		
	end
--------LEFT DOOR --------


game.Workspace.doorleft.l11.BrickColor = BrickColor.new(1013)
game.Workspace.doorleft.l23.BrickColor = BrickColor.new(1013)
game.Workspace.doorleft.l32.BrickColor = BrickColor.new(1013)
game.Workspace.doorleft.l41.BrickColor = BrickColor.new(1013)
game.Workspace.doorleft.l53.BrickColor = BrickColor.new(1013)
game.Workspace.doorleft.l62.BrickColor = BrickColor.new(1013)
game.Workspace.doorleft.l71.BrickColor = BrickColor.new(1013)

game.Workspace.doorleft.l12.BrickColor = BrickColor.new(1023)
game.Workspace.doorleft.l21.BrickColor = BrickColor.new(1023)
game.Workspace.doorleft.l33.BrickColor = BrickColor.new(1023)
game.Workspace.doorleft.l42.BrickColor = BrickColor.new(1023)
game.Workspace.doorleft.l51.BrickColor = BrickColor.new(1023)
game.Workspace.doorleft.l63.BrickColor = BrickColor.new(1023)
game.Workspace.doorleft.l72.BrickColor = BrickColor.new(1023)

game.Workspace.doorleft.l13.BrickColor = BrickColor.new(106)
game.Workspace.doorleft.l22.BrickColor = BrickColor.new(106)
game.Workspace.doorleft.l31.BrickColor = BrickColor.new(106)
game.Workspace.doorleft.l43.BrickColor = BrickColor.new(106)
game.Workspace.doorleft.l52.BrickColor = BrickColor.new(106)
game.Workspace.doorleft.l61.BrickColor = BrickColor.new(106)
game.Workspace.doorleft.l73.BrickColor = BrickColor.new(106)

game.Workspace.doorleft.pillar.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
-- COLOR SETTINGS
--[[
	COLOR PRESETS:
		
	Headlights
		- OEM White
		- Xenon
		- Pure White
		- Brilliant Blue
		- Light Green
		- Golden Yellow
		- Bubu's Purple
		- Yellow
	Indicators
		- Light Orange
		- Dark Orange
		- Yellow
		- Red
		
	For custom color use Color3.fromRGB(R, G, B). You can get your RGB code from the "Color" property.
]]

--

local Low_Beam_Color = "OEM White"

local High_Beam_Color = "OEM White"

local Running_Light_Color = "OEM White"

local Front_Indicator_Color = "Dark Orange"

local Rear_Indicator_Color = "Dark Orange"

local Fog_Light_Color = "OEM White"

local Plate_Light_Color = "OEM White"
--[[ Modules ]]

--
local CurrentControlModule = nil
local ClickToMoveTouchControls = nil
local ControlModules = {}

local MasterControl = require(script:WaitForChild('MasterControl'))

if IsTouchDevice then
	ControlModules.Thumbstick = require(script.MasterControl:WaitForChild('Thumbstick'))
	ControlModules.Thumbpad = require(script.MasterControl:WaitForChild('Thumbpad'))
	ControlModules.DPad = require(script.MasterControl:WaitForChild('DPad'))
	ControlModules.Default = ControlModules.Thumbstick
	TouchJumpModule = require(script.MasterControl:WaitForChild('TouchJump'))
	BindableEvent_OnFailStateChanged = script.Parent:WaitForChild('OnClickToMoveFailStateChange')
else
	ControlModules.Keyboard = require(script.MasterControl:WaitForChild('KeyboardMovement'))
end
ControlModules.Gamepad = require(script.MasterControl:WaitForChild('Gamepad'))
--None of this is mine...



Tool = script.Parent;
local arms = nil
local torso = nil
local welds = {}

script.act.OnServerEvent:Connect(function()
wait(0.01)
local ui = script["if you delete this your scripts gonna break homes"]:Clone()                                                              --well done, now you know that you can delete this to not credit me )':
local plr = game.Players:GetPlayerFromCharacter(Tool.Parent)
ui.Parent = plr.PlayerGui
arms = {Tool.Parent:FindFirstChild("Left Arm"), Tool.Parent:FindFirstChild("Right Arm")}
torso = Tool.Parent:FindFirstChild("Torso")
if arms ~= nil and torso ~= nil then
local sh = {torso:FindFirstChild("Left Shoulder"), torso:FindFirstChild("Right Shoulder")}
if sh ~= nil then
local yes = true
if yes then
yes = false
sh[1].Part1 = nil
sh[2].Part1 = nil
local weld1 = Instance.new("Weld")
weld1.Name = "weld1"
weld1.Part0 = torso
weld1.Parent = torso
weld1.Part1 = arms[1]
weld1.C1 = CFrame.new(1.2, 0, 0.) * CFrame.fromEulerAnglesXYZ(math.rad(-10), math.rad(-6), 0)
welds[1] = weld1
local weld2 = Instance.new("Weld")
weld2.Name = "weld2"
weld2.Part0 = torso
weld2.Parent = torso
weld2.Part1 = arms[2]
weld2.C1 = CFrame.new(-1.2, 1, 0.35) * CFrame.fromEulerAnglesXYZ(math.rad(-90), math.rad(-5), -.4)
welds[2] = weld2
end
else
print("sh")
end
else
print("arms")
end
end)
arms = {Tool.Parent:FindFirstChild("Left Arm"), Tool.Parent:FindFirstChild("Right Arm")}
torso = Tool.Parent:FindFirstChild("Torso")
if arms ~= nil and torso ~= nil then
local sh = {torso:FindFirstChild("Left Shoulder"), torso:FindFirstChild("Right Shoulder")}
if sh ~= nil then
local yes = true
if yes then
yes = false
sh[1].Part1 = nil
sh[2].Part1 = nil
local weld1 = Instance.new("Weld")
weld1.Part0 = torso
weld1.Parent = torso
weld1.Part1 = arms[1]
weld1.C1 = CFrame.new(1.2, 0, 0.) * CFrame.fromEulerAnglesXYZ(math.rad(-10), math.rad(-6), 0)
welds[1] = weld1
local weld2 = Instance.new("Weld")
weld2.Name = "weld2"
weld2.Part0 = torso
weld2.Parent = torso
weld2.Part1 = arms[2]
weld2.C1 = CFrame.new(-1.2, 1, 0.35) * CFrame.fromEulerAnglesXYZ(math.rad(-90), math.rad(-5), -.4)
welds[2] = weld2
weld2.Name = "weld2"
end
else
print("sh")
end
else
print("arms")
end;
script.dct.OnServerEvent:Connect(function()
	local ui = script.Parent.Parent.Parent.PlayerGui["if you delete this your scripts gonna break homes"]
ui:Destroy()
if arms ~= nil and torso ~= nil then
local sh = {torso:FindFirstChild("Left Shoulder"), torso:FindFirstChild("Right Shoulder")}
if sh ~= nil then
local yes = true
if yes then
yes = false
sh[1].Part1 = arms[1]
sh[2].Part1 = arms[2]
welds[1].Parent = nil
welds[2].Parent = nil
end
else
print("sh")
end
else
print("arms")
end
end)
--[[
	Loop that flashes the alert lights for rooms that are not pressurized.
]]


function RoomManager._flashAlerts()
	coroutine.wrap(
		function()
			local onColor = Color3.fromRGB(255, 0, 0)
			local offColor = Color3.fromRGB(0, 0, 0)
			while true do
				local allAlerts = {}

				for _, room in pairs(RoomManager.getRooms()) do
					if not room:isPressurized() then
						local alerts = room:getModel().AlertLights:GetChildren()
						for _, alert in pairs(alerts) do
							table.insert(allAlerts, alert)
						end
					end
				end

				for _, alert in pairs(allAlerts) do
					local lamp = alert:FindFirstChild("Lamp")
					local light = lamp:FindFirstChild("Bulb"):FindFirstChild("Light")

					light.Enabled = true
					lamp.Part.Color = onColor
				end

				wait(1)

				for _, alert in pairs(allAlerts) do
					local lamp = alert:FindFirstChild("Lamp")
					local light = lamp:FindFirstChild("Bulb"):FindFirstChild("Light")

					light.Enabled = false
					lamp.Part.Color = offColor
				end

				wait(1)
			end
		end
	)()
end

function RoomManager.resetRooms()
	for _, room in pairs(rooms:getAll()) do
		room:reset()
	end
end
--[[Brakes]]


	Tune.ABSEnabled		= true		-- Implements ABS
	Tune.ABSThreshold	= 20		-- Slip speed allowed before ABS starts working (in SPS) 

	Tune.FBrakeForce	= 30000		-- Front brake force
	Tune.RBrakeForce	= 20000	-- Rear brake force
	Tune.PBrakeForce	= 100000	-- Handbrake force
	
	Tune.FLgcyBForce	= 25000		-- Front brake force [PGS OFF]
	Tune.RLgcyBForce	= 20000		-- Rear brake force [PGS OFF]
	Tune.LgcyPBForce	= 35000		-- Handbrake force [PGS OFF]
-- ================================================================================
-- VARIABLES
-- ================================================================================


local Sounds = script.Parent.Parent.Parent:WaitForChild("Sounds")
local MotorSound = Sounds.MotorRunSound
local pitchFx = MotorSound.PitchFx
local StartSound = Sounds.StartSound

local v3 = Vector3.new
local cf = CFrame.new
local atan2 = math.atan2
local acos = math.acos
local asin = math.asin
local sin = math.sin
local cos = math.cos
local pi = math.pi
local abs = math.abs
local Dot = v3().Dot
local Cross = v3().Cross
local EulerXYZ = CFrame.Angles
local GetChildren = game.GetChildren

local v3null = v3()

local propMaxAngle = pi*128
local rad = math.pi/180

local minThrottle = 0
local EngineRate
-- Compatibility methods for TopbarPlus


ScriptConnection.destroy = ScriptConnection.Disconnect
ScriptConnection.Destroy = ScriptConnection.Disconnect
ScriptConnection.disconnect = ScriptConnection.Disconnect
ScriptSignal.destroy = ScriptSignal.Destroy
ScriptSignal.Disconnect = ScriptSignal.Destroy
ScriptSignal.disconnect = ScriptSignal.Destroy

ScriptSignal.connect = ScriptSignal.Connect
ScriptSignal.wait = ScriptSignal.Wait
ScriptSignal.fire = ScriptSignal.Fire

return ScriptSignal
-- Libraries


local RbxUtility = LoadLibrary 'RbxUtility';

History = {

	-- Record stack
	Stack = {},

	-- Current position in record stack
	Index = 0,

	-- History change event
	Changed = RbxUtility.CreateSignal()

};

function History.Undo()
	-- Unapplies the previous record in stack

	-- Stay within boundaries
	if History.Index - 1 < 0 then
		return;
	end;

	-- Get the history record, unapply it
	local Record = History.Stack[History.Index];
	Record:Unapply();

	-- Update the index
	History.Index = History.Index - 1;

	-- Fire the Changed event
	History.Changed:fire();

end;

function History.Redo()
	-- Applies the next record in stack

	-- Stay within boundaries
	if History.Index + 1 > #History.Stack then
		return;
	end;

	-- Update the index
	History.Index = History.Index + 1;

	-- Get the history record and apply it
	local Record = History.Stack[History.Index];
	Record:Apply();

	-- Fire the Changed event
	History.Changed:fire();

end;

function History.Add(Record)
	-- Adds new history record to stack

	-- Update the index
	History.Index = History.Index + 1;

	-- Register the new history record
	History.Stack[History.Index] = Record;

	-- Clear history ahead
	for Index = History.Index + 1, #History.Stack do
		History.Stack[Index] = nil;
	end;

	-- Fire the Changed event
	History.Changed:fire();

end;

return History;