Pinkstack/roblox-luau-corpus-text huggingface dataset:
-------- OMG HAX



r = game:service("RunService")


local damage = 0


local slash_damage = 3
local lunge_damage = 5

sword = script.Parent.Center
Tool = script.Parent


local SlashSound = Instance.new("Sound")
SlashSound.SoundId = "rbxasset://sounds\\swordslash.wav"
SlashSound.Parent = sword
SlashSound.Volume = .7

local LungeSound = Instance.new("Sound")
LungeSound.SoundId = "rbxasset://sounds\\swordlunge.wav"
LungeSound.Parent = sword
LungeSound.Volume = .6

local UnsheathSound = Instance.new("Sound")
UnsheathSound.SoundId = "rbxasset://sounds\\unsheath.wav"
UnsheathSound.Parent = sword
UnsheathSound.Volume = 1



function blow(hit)
	local humanoid = hit.Parent:findFirstChild("Humanoid")
	local vCharacter = Tool.Parent
	local vPlayer = game.Players:playerFromCharacter(vCharacter)
	local hum = vCharacter:findFirstChild("Humanoid") -- non-nil if tool held by a character
	if humanoid~=nil and humanoid ~= hum and hum ~= nil then
		print("SWORD HIT")
		tagHumanoid(humanoid, vPlayer)
		humanoid:TakeDamage(damage)
		wait(1)
		untagHumanoid(humanoid)
	end
end


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

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


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

function lunge()
	damage = lunge_damage

	LungeSound:play()

	local anim = Instance.new("StringValue")
	anim.Name = "toolanim"
	anim.Value = "Lunge"
	anim.Parent = Tool
	
	
	force = Instance.new("BodyVelocity")
	force.velocity = Vector3.new(0,10,0) --Tool.Parent.Torso.CFrame.lookVector * 80
	force.Parent = Tool.Parent.Torso
	wait(.25)
	swordOut()
	wait(.25)
	force.Parent = nil
	wait(.5)
	swordUp()

	damage = slash_damage
end

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

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

function swordAcross()
	-- parry
end


Tool.Enabled = true
local last_attack = 0
function onActivated()

	if not Tool.Enabled then
		return
	end

	Tool.Enabled = false

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

	t = r.Stepped:wait()

	if (t - last_attack < 0) then
		lunge()
	else
		attack()
	end

	last_attack = t

	wait(.75)

	Tool.Enabled = true
end


function onEquipped()
	UnsheathSound:play()
end


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


connection = sword.Touched:connect(blow)
--Feel free to poke around and see how this works.  It's not very complex



local car = script.Parent.Car.Value
local Values = script.Parent:WaitForChild("Values") --This bit of code is still in 90% of A-Chassis plugins lol
local _Tune = require(car["A-Chassis Tune"])
local Handler = car:WaitForChild("ExhaustHandler")
local IsFlaming = false --Exhaust flame debounce.  Debounces are important so code block doesn't run too quickly

Values.Throttle.Changed:Connect(function() -- This is where all the magic happens.  Flames are determined by when you release the throttle
	
	local RPMRatio = Values.RPM.Value / _Tune.Redline
	
	print(RPMRatio)
	
	if RPMRatio > 0.8 and not IsFlaming and car.DriveSeat.Throttle < 1 then
		
		IsFlaming = true
		Handler:FireServer("Flames",true)
		wait(0.1)
		Handler:FireServer("Flames",false)
		Handler:FireServer("FlamesSmall",true)
		wait(1)
		Handler:FireServer("FlamesSmall",false)
		IsFlaming = false
	elseif Values.Throttle.Value < 0.5 then
		
		Handler:FireServer("FlamesSmall",false)
		
		
	end
	
end)
--updated 10/09/2022



npc= nil
hum= nil
health_gui= script.Parent
health_text= script.Parent:WaitForChild("TextLabel")


if (health_gui.Parent~= nil and health_gui.Parent.ClassName== "Model" and health_gui.Parent:FindFirstChildOfClass("Humanoid")) then
	npc= health_gui.Parent
	hum= health_gui.Parent:FindFirstChildOfClass("Humanoid")
	
elseif (health_gui.Parent.Parent~= nil and health_gui.Parent.Parent.ClassName== "Model" and health_gui.Parent.Parent:FindFirstChildOfClass("Humanoid")) then
	npc= health_gui.Parent.Parent
	hum= health_gui.Parent.Parent:FindFirstChildOfClass("Humanoid")
	
elseif (health_gui.Parent.Parent.Parent~= nil and health_gui.Parent.Parent.Parent.ClassName== "Model" and health_gui.Parent.Parent.Parent:FindFirstChildOfClass("Humanoid")) then
	npc= health_gui.Parent.Parent.Parent
	hum= health_gui.Parent.Parent.Parent:FindFirstChildOfClass("Humanoid")
end


if not npc then
	health_gui:Remove()
end

if not hum then
	health_text.Text= "humanoid not found"
	health_text.TextColor3= Color3.fromRGB(255, 255, 127)
end

hum.DisplayDistanceType= Enum.HumanoidDisplayDistanceType.None
hum.HealthDisplayType= Enum.HumanoidHealthDisplayType.AlwaysOff


game["Run Service"].Heartbeat:Connect(function()
	
	--for text health
	health_text.Text= npc.Name.. " | ".. hum.Health.. " / ".. hum.MaxHealth
	
	--for color
	local GoodColor= Color3.fromRGB(85, 255, 127)
	local MediumColor= Color3.fromRGB(255, 255, 127)
	local BadColor= Color3.fromRGB(255, 140, 142)

	if hum.Health >= hum.MaxHealth * 0.6 then
		health_text.TextColor3= GoodColor
	end
	
	if hum.Health <= hum.MaxHealth * 0.6 then
		health_text.TextColor3= MediumColor
	end
	
	if hum.Health <= hum.MaxHealth * 0.25 then
		health_text.TextColor3= BadColor
	end
	
end)
--cyan 4


if k == "c" and ibo.Value==true then
	bin.Blade.BrickColor = BrickColor.new("Cyan")
	bin.Blade2.BrickColor = BrickColor.new("Institutional white")
	bin.Blade.White.Enabled=false colorbin.white.Value = false
	bin.Blade.Blue.Enabled=false colorbin.blue.Value = false
	bin.Blade.Green.Enabled=false colorbin.green.Value = false
	bin.Blade.Magenta.Enabled=false colorbin.magenta.Value = false
	bin.Blade.Orange.Enabled=false colorbin.orange.Value = false
	bin.Blade.Viridian.Enabled=false colorbin.viridian.Value = false
	bin.Blade.Violet.Enabled=false colorbin.violet.Value = false
	bin.Blade.Red.Enabled=false colorbin.red.Value = false
	bin.Blade.Silver.Enabled=false colorbin.silver.Value = false
	bin.Blade.Black.Enabled=false colorbin.black.Value = false
	bin.Blade.NavyBlue.Enabled=false colorbin.navyblue.Value = false
	bin.Blade.Yellow.Enabled=false colorbin.yellow.Value = false
	bin.Blade.Cyan.Enabled=true colorbin.cyan.Value = true
    end
--[[Engine]]


	--Torque Curve
	Tune.Horsepower		= 175		--	[TORQUE CURVE VISUAL]
	Tune.IdleRPM		= 700		--		https://www.desmos.com/calculator/2uo3hqwdhf
	Tune.PeakRPM		= 6200		--		Use sliders to manipulate values
	Tune.Redline		= 7600		--		Copy and paste slider values into the respective tune values
	Tune.EqPoint		= 5500
	Tune.PeakSharpness	= 7.5
	Tune.CurveMult		= 0.16
	
	--Incline Compensation
	Tune.InclineComp	= 1.7			-- Torque compensation multiplier for inclines (applies gradient from 0-90 degrees)
	
	--Misc
	Tune.RevAccel		= 150		-- RPM acceleration when clutch is off
	Tune.RevDecay		= 75		-- RPM decay when clutch is off
	Tune.RevBounce		= 500		-- RPM kickback from redline
	Tune.IdleThrottle	= 3			-- Percent throttle at idle
	Tune.ClutchTol		= 1		-- Clutch engagement threshold (higher = faster response)
--[[Transmission]]


	Tune.TransModes		= {"Auto","Manual"}												--[[
	[Modes]
		"Auto"		: Automatic shifting
		"Semi"		: Clutchless manual shifting, dual clutch transmission
		"Manual"	: Manual shifting with clutch
		
		>Include within brackets
			eg: {"Semi"} or {"Auto", "Manual"}								
		>First mode is default mode													]]
	
	--Automatic Settings
	Tune.AutoShiftMode	= "RPM"												--[[
	[Modes]
		"Speed"		: Shifts based on wheel speed
		"RPM"		: Shifts based on RPM											]]	
	Tune.AutoUpThresh	= 480		-- Automatic upshift point 	(relative to peak RPM, positive = Over-rev)
	Tune.AutoDownThresh = 50		-- Automatic downshift point (relative to peak RPM, positive = Under-rev)
	
	--Gear Ratios
	
	--Gear Ratios
	Tune.FinalDrive		= 3.65			-- Gearing determines top speed and wheel torque
	Tune.Ratios			= {				-- Higher ratio = more torque, Lower ratio = higher top speed
		--[[Reverse]]	3.45			,	-- Copy and paste a ratio to add a gear
		--[[Neutral]]	0			,	-- Ratios can also be deleted
		--[[ 1 ]]		4.40			,	-- Reverse, Neutral, and 1st gear are required
		--[[ 2 ]]		2.75			,
		--[[ 3 ]]		1.85			,
		--[[ 4 ]]		1.40			,
		--[[ 5 ]]		1.00 ,
		--[[ 6 ]]		0.75	,
	}
	Tune.FDMult			= 1.1			-- Ratio multiplier (keep this at 1 if car is not struggling with torque)
--[[
	The entry point for the Fusion library.
]]



local PubTypes = require(script.PubTypes)
local restrictRead = require(script.Utility.restrictRead)

export type StateObject<T> = PubTypes.StateObject<T>
export type CanBeState<T> = PubTypes.CanBeState<T>
export type Symbol = PubTypes.Symbol
export type Value<T> = PubTypes.Value<T>
export type Computed<T> = PubTypes.Computed<T>
export type ComputedPairs<K, V> = PubTypes.ComputedPairs<K, V>
export type Observer = PubTypes.Observer
export type Tween<T> = PubTypes.Tween<T>
export type Spring<T> = PubTypes.Spring<T>

type Fusion = {
	New: (className: string) -> ((propertyTable: PubTypes.PropertyTable) -> Instance),
	Children: PubTypes.ChildrenKey,
	OnEvent: (eventName: string) -> PubTypes.OnEventKey,
	OnChange: (propertyName: string) -> PubTypes.OnChangeKey,

	Value: <T>(initialValue: T) -> Value<T>,
	Computed: <T>(callback: () -> T) -> Computed<T>,
	ComputedPairs: <K, VI, VO>(inputTable: CanBeState<{[K]: VI}>, processor: (K, VI) -> VO, destructor: (VO) -> ()?) -> ComputedPairs<K, VO>,
	Observer: (watchedState: StateObject<any>) -> Observer,

	Tween: <T>(goalState: StateObject<T>, tweenInfo: TweenInfo?) -> Tween<T>,
	Spring: <T>(goalState: StateObject<T>, speed: number?, damping: number?) -> Spring<T>
}

return restrictRead("Fusion", {
	New = require(script.Instances.New),
	Children = require(script.Instances.Children),
	OnEvent = require(script.Instances.OnEvent),
	OnChange = require(script.Instances.OnChange),

	Value = require(script.State.Value),
	Computed = require(script.State.Computed),
	ComputedPairs = require(script.State.ComputedPairs),
	Observer = require(script.State.Observer),

	Tween = require(script.Animation.Tween),
	Spring = require(script.Animation.Spring)
}) :: Fusion
--[[Steering]]


Tune.SteerInner		= 32		-- Inner wheel steering angle (in degrees)
Tune.SteerOuter		= 33		-- Outer wheel steering angle (in degrees)
Tune.SteerSpeed		= .02		-- Steering increment per tick (in degrees)
Tune.ReturnSpeed	= .04		-- Steering increment per tick (in degrees)
Tune.SteerDecay		= 320		-- Speed of gradient cutoff (in SPS)
Tune.MinSteer		= 10		-- Minimum steering at max steer decay (in percent)
Tune.MSteerExp		= 1			-- Mouse steering exponential degree
--Put this in StarterPlayer, StarterCharacterScripts




local human = script.Parent:WaitForChild("Humanoid")

local AttackArm = true 

local canattack = true 

game:GetService("UserInputService").InputBegan:connect(function(input, gamepor)
	if (input.KeyCode == Enum.KeyCode.X or input.KeyCode == Enum.KeyCode.ButtonY) and canattack then 
		canattack = false 
		script.RemoteEvent:FireServer(AttackArm) 
		human:LoadAnimation(AttackArm and script.R or script.L):Play()
		wait(0.6) 
		AttackArm = not AttackArm 
		canattack = true 
	end	
end)
--NOTE: We create the rocket once and then clone it when the player fires


local Rocket = Instance.new('Part') do
	-- Set up the rocket part
	Rocket.Name = 'Rocket'
	Rocket.FormFactor = Enum.FormFactor.Custom --NOTE: This must be done before changing Size
	Rocket.Size = ROCKET_PART_SIZE
	Rocket.CanCollide = false
	Rocket.Anchored = true	
	
	-- Add the mesh
	local mesh = Instance.new('SpecialMesh', Rocket)
	mesh.MeshId = MISSILE_MESH_ID
	mesh.Scale = MISSILE_MESH_SCALE

	-- Add fire
	local fire = Instance.new('Fire', Rocket)
	fire.Heat = 5
	fire.Size = 2
	
	-- Clone the sounds and set Boom to PlayOnRemove
	local swooshSoundClone = SwooshSound:Clone()
	swooshSoundClone.Parent = Rocket
	local boomSoundClone = BoomSound:Clone()
	boomSoundClone.PlayOnRemove = true
	boomSoundClone.Parent = Rocket

	-- Attach creator tags to the rocket early on
	local creatorTag = Instance.new('ObjectValue', Rocket)
	creatorTag.Value = MyPlayer
	creatorTag.Name = 'creator' --NOTE: Must be called 'creator' for website stats
	local iconTag = Instance.new('StringValue', creatorTag)
	iconTag.Value = Tool.TextureId
	iconTag.Name = 'icon'

	-- Finally, clone the rocket script and enable it
	local rocketScriptClone = RocketScript:Clone()
	rocketScriptClone.Parent = Rocket
	rocketScriptClone.Disabled = false
end
--- RUNTIME ---



local Tool = {}

Tool.MouseButton1 = function(Character)
	if Character:GetAttribute("Cooldown") == true then return end
	Character:SetAttribute("Cooldown", true)

	Character.Humanoid:LoadAnimation(script.Animation):Play()

	Character[script.Name].Handle.Swing:Play()

	local MousePosition = MousePosition:InvokeClient(Players:GetPlayerFromCharacter(Character))
	-- Character.PrimaryPart.CFrame = CFrame.new(Character.PrimaryPart.Position, MousePosition) -- Points character at mouse, at extreme angles it trips so I'm disabling for now

	task.wait(0.33)

	Character[script.Name].Handle.Shoot:Play()
	
	Projectile(Character, MousePosition)

	task.wait(2)

	Character:SetAttribute("Cooldown", false)
end

return Tool
--[[
	Server-side manager that listens to events to advance the FTUE stage in a player's data and
	trigger server-side world changes according to the current stage
--]]



local ReplicatedStorage = game:GetService("ReplicatedStorage")
local ServerStorage = game:GetService("ServerStorage")

local PlayerDataServer = require(ServerStorage.Source.PlayerData.Server)
local FtueStage = require(ReplicatedStorage.Source.SharedConstants.FtueStage)
local InFarmFtueStage = require(script.StageHandlers.InFarmFtueStage)
local SellingPlantFtueStage = require(script.StageHandlers.SellingPlantFtueStage)
local PurchasingSeedFtueStage = require(script.StageHandlers.PurchasingSeedFtueStage)
local PurchasingPotFtueStage = require(script.StageHandlers.PurchasingPotFtueStage)
local ReturningToFarmFtueStage = require(script.StageHandlers.ReturningToFarmFtueStage)
local PlayerDataKey = require(ReplicatedStorage.Source.SharedConstants.PlayerDataKey)

type FtueStage = {
	handleAsync: (Player) -> FtueStage.EnumType?,
}

local handlerByStage: { [string]: FtueStage } = {
	[FtueStage.InFarm] = InFarmFtueStage,
	[FtueStage.SellingPlant] = SellingPlantFtueStage,
	[FtueStage.PurchasingSeed] = PurchasingSeedFtueStage,
	[FtueStage.PurchasingPot] = PurchasingPotFtueStage,
	[FtueStage.ReturningToFarm] = ReturningToFarmFtueStage,
}

local FtueManagerServer = {}

function FtueManagerServer.onPlayerAdded(player: Player)
	local ftueStage = PlayerDataServer.getValue(player, PlayerDataKey.FtueStage)
	FtueManagerServer._updateFtueStage(player, ftueStage)
end

function FtueManagerServer._updateFtueStage(player: Player, ftueStage: FtueStage.EnumType?)
	PlayerDataServer.setValue(player, PlayerDataKey.FtueStage, ftueStage)

	if not ftueStage then
		return
	end

	task.spawn(function()
		local stageHandler = handlerByStage[ftueStage :: FtueStage.EnumType]
		local nextStage: FtueStage.EnumType? = stageHandler.handleAsync(player)
		FtueManagerServer._updateFtueStage(player, nextStage)
	end)
end

return FtueManagerServer
--[[
	--Instructions--
	-For every material you want, you must add a new elseif statement, set "Enum.Materal" to the material you want. For example "Enum.Material.Glass"
	-Then just change the properties of the sound within that elseif statement to what you want.
	-Don't forget to edit the "Running" Script!
--]]
--CREDITS FOR BUILDING THIS SCRIPT:
--Spathi
--edit the function below to return true when you want this response/prompt to be valid
--player is the player speaking to the dialogue, and dialogueFolder is the object containing the dialogue data


return function(player, dialogueFolder)
	local ClassInformationTable = require(game.ReplicatedStorage.Source.Modules.CharacterScripts.Classes.ClassInformation)
	return (not ClassInformationTable:GetClassFolder(player,"Brawler").GuardBreak.Value)
end
--[[Engine]]


	--Torque Curve
	Tune.Horsepower		= 100		--	[TORQUE CURVE VISUAL]
	Tune.IdleRPM		= 700		--		https://www.desmos.com/calculator/2uo3hqwdhf
	Tune.PeakRPM		= 6000		--		Use sliders to manipulate values
	Tune.Redline		= 6700		--		Copy and paste slider values into the respective tune values
	Tune.EqPoint		= 5500
	Tune.PeakSharpness	= 7.5
	Tune.CurveMult		= 0.16
	
	--Incline Compensation
	Tune.InclineComp	= 4.7			-- Torque compensation multiplier for inclines (applies gradient from 0-90 degrees)
	
	--Misc
	Tune.RevAccel		= 150		-- RPM acceleration when clutch is off
	Tune.RevDecay		= 75		-- RPM decay when clutch is off
	Tune.RevBounce		= 500		-- RPM kickback from redline
	Tune.IdleThrottle	= 3			-- Percent throttle at idle
	Tune.ClutchTol		= 500		-- Clutch engagement threshold (higher = faster response)
--[[
	Calculate the actual spot Frame position in studs by making use of adornee position.

	Parameters:
	- surfaceGui (SurfaceGui): SurfaceGui instance that the spot belongs to
	- spot (Frame): Frame instance representing a Spot

	Returns:
	- (Vector3): World position of the spot
]]


function CameraModule:getSpotPosition(surfaceGui, spot)
	local adornee = surfaceGui.Adornee
	local face = surfaceGui.Face

	-- Find offset of the spot's Frame from the center of the SurfaceGui (in studs)
	local spotCenter = spot.AbsolutePosition + (Vector2.new(0.5, 0.5) - spot.AnchorPoint) * spot.AbsoluteSize
	local guiOffset = (spotCenter - surfaceGui.AbsoluteSize / 2) / surfaceGui.PixelsPerStud

	-- Calculate the actual position of the center of spot (in studs)
	local spotPosition = adornee.CFrame:PointToWorldSpace(self:_getPointByFace(guiOffset, adornee, face))

	return spotPosition
end

function CameraModule:_tweenCamera(target)
	-- Animate to the spot
	local tweenTime = constants.CameraTweenTime
	local tweenInfo = TweenInfo.new(tweenTime, Enum.EasingStyle.Quad, Enum.EasingDirection.InOut)
	local tween = self.tweenService:Create(self.camera, tweenInfo, { CFrame = target })

	tween:Play()

	task.wait(tweenTime)
end
--[[
	3/19/20
	newwil
	DataStore/Leaderstats
--]]



local DataStoreService = game:GetService("DataStoreService")

local playerData = DataStoreService:GetDataStore("playerData")

game.Players.PlayerAdded:Connect(function(player)
	local leaderstats = Instance.new("Folder")
	leaderstats.Name = "leaderstats"
	leaderstats.Parent = player
	
	local cash = Instance.new("IntValue")
	cash.Name = "Cash"
	cash.Parent = leaderstats
	
	local data 
	local success, errormessage = pcall(function()
		data = playerData:GetAsync(player.UserId.."-cash") 
	end)
	
	if success then 
		cash.Value = data
	else
		print("Error while getting your data")
		warn(errormessage)
	end
end)

game.Players.PlayerRemoving:Connect(function(player)
	
	local success, errormessage = pcall(function()
		playerData:SetAsync(player.UserId.."-cash", player.leaderstats.Cash.Value)
	end)
	
	if success then
		print("Data successfully saved!")
	else
		print("There was an error while saving the data")
		warn(errormessage)
	end
	
end)
-- BaseCamera mod



local BaseCamera = require(baseCameraModule)

BaseCamera.UpCFrame = IDENTITYCF

function BaseCamera:UpdateUpCFrame(cf)
	self.UpCFrame = cf
end

function BaseCamera:CalculateNewLookCFrame(suppliedLookVector)
	local currLookVector = suppliedLookVector or self:GetCameraLookVector()
	currLookVector = self.UpCFrame:VectorToObjectSpace(currLookVector)
	
	local currPitchAngle = math.asin(currLookVector.y)
	local yTheta = math.clamp(self.rotateInput.y, -MAX_Y + currPitchAngle, -MIN_Y + currPitchAngle)
	local constrainedRotateInput = Vector2.new(self.rotateInput.x, yTheta)
	local startCFrame = CFrame.new(ZERO, currLookVector)
	local newLookCFrame = CFrame.Angles(0, -constrainedRotateInput.x, 0) * startCFrame * CFrame.Angles(-constrainedRotateInput.y,0,0)
	
	return newLookCFrame
end
-----------------
--| Variables |--
-----------------



local DebrisService = Game:GetService('Debris')
local PlayersService = Game:GetService('Players')

local Rocket = script.Parent

local CreatorTag = Rocket:WaitForChild('creator')
local Tank = Rocket:WaitForChild('Tank').Value
local SwooshSound = Rocket:WaitForChild('Swoosh')
local Target = Rocket:WaitForChild('Target')
--[[Run]]



	--Print Version
	local ver=require(car["A-Chassis Tune"].README)
	print("Novena: AC6T Loaded - Build "..ver)
	
	--Runtime Loops
	
	-- ~60 c/s
	game["Run Service"].Stepped:connect(function()
		--Steering
		Steering()
		
		--RPM
		RPM()
		
		--Suspension
		if not workspace:PGSIsEnabled() and _Tune.SusEnabled then
			Suspension()
		end
		
		--Power
		Engine()
		
		--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.Boost.Value = (_Boost/2)*_TPsi
		script.Parent.Values.Horsepower.Value = _HP
		script.Parent.Values.HpNatural.Value = _NH
		script.Parent.Values.HpBoosted.Value = _BH*(_Boost/2)
		script.Parent.Values.Torque.Value = _HP * _Tune.EqPoint / _RPM
		script.Parent.Values.TqNatural.Value = _NT
		script.Parent.Values.TqBoosted.Value = _BT*(_Boost/2)
		script.Parent.Values.TransmissionMode.Value = _TMode
		script.Parent.Values.Throttle.Value = _GThrot*_GThrotShift
		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.TCSAmt.Value = 1-_TCSAmt
		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)
	
	--	car.DriveSeat.CC.Changed:connect(function()
------------------------------------------------------------------------
-- initial parsing for statements, calls a lot of functions
-- * returns boolean instead of 0|1
-- * used in chunk()
------------------------------------------------------------------------


function luaY:statement(ls)
  local line = ls.linenumber  -- may be needed for error messages
  local c = ls.t.token
  if c == "TK_IF" then  -- stat -> ifstat
    self:ifstat(ls, line)
    return false
  elseif c == "TK_WHILE" then  -- stat -> whilestat
    self:whilestat(ls, line)
    return false
  elseif c == "TK_DO" then  -- stat -> DO block END
    luaX:next(ls)  -- skip DO
    self:block(ls)
    self:check_match(ls, "TK_END", "TK_DO", line)
    return false
  elseif c == "TK_FOR" then  -- stat -> forstat
    self:forstat(ls, line)
    return false
  elseif c == "TK_REPEAT" then  -- stat -> repeatstat
    self:repeatstat(ls, line)
    return false
  elseif c == "TK_FUNCTION" then  -- stat -> funcstat
    self:funcstat(ls, line)
    return false
  elseif c == "TK_LOCAL" then  -- stat -> localstat
    luaX:next(ls)  -- skip LOCAL
    if self:testnext(ls, "TK_FUNCTION") then  -- local function?
      self:localfunc(ls)
    else
      self:localstat(ls)
    end
    return false
  elseif c == "TK_RETURN" then  -- stat -> retstat
    self:retstat(ls)
    return true  -- must be last statement
  elseif c == "TK_BREAK" then  -- stat -> breakstat
    luaX:next(ls)  -- skip BREAK
    self:breakstat(ls)
    return true  -- must be last statement
  else
    self:exprstat(ls)
    return false  -- to avoid warnings
  end--if c
end