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

r = game:service("RunService")


local damage = 5


local slash_damage = 8
local lunge_damage = 17

sword = script.Parent.Handle
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
		-- final check, make sure sword is in-hand

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


	end
end


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

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


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

function 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(.1)
	swordOut()
	wait(.1)
	force.Parent = nil
	wait(.2)
	swordUp()

	damage = slash_damage
end

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

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

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 < .2) then
		lunge()
	else
		attack()
	end

	last_attack = t

	--wait(.5)

	Tool.Enabled = true
end


function onEquipped()
	UnsheathSound:play()
end


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


connection = sword.Touched:connect(blow)
--Main body parts
local myRoot = script.Parent:WaitForChild("HumanoidRootPart")
local myHuman = script.Parent:WaitForChild("Humanoid")
local upperTorso = script.Parent:WaitForChild("UpperTorso")
--------------------------------------------

local Signal = {}
Signal.__index = Signal


function Signal.new()
	local self = setmetatable({
		_bindable = Instance.new("BindableEvent");
		_connections = {};
		_args = {};
		_threads = 0;
		_id = 0;
	}, Signal)
	return self
end


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


function Signal:Fire(...)
	local id = self._id
	self._id = self._id + 1
	self._args[id] = {#self._connections + self._threads, {n = select("#", ...), ...}}
	self._threads = 0
	self._bindable:Fire(id)
end


function Signal:Wait()
	self._threads = self._threads + 1
	local id = self._bindable.Event:Wait()
	local args = self._args[id]
	args[1] = args[1] - 1
	if (args[1] <= 0) then
		self._args[id] = nil
	end
	return table.unpack(args[2], 1, args[2].n)
end


function Signal:WaitPromise()
	return Promise.new(function(resolve)
		resolve(self:Wait())
	end)
end


function Signal:Connect(handler)
	local connection = Connection.new(self, self._bindable.Event:Connect(function(id)
		local args = self._args[id]
		args[1] = args[1] - 1
		if (args[1] <= 0) then
			self._args[id] = nil
		end
		handler(table.unpack(args[2], 1, args[2].n))
	end))
	table.insert(self._connections, connection)
	return connection
end


function Signal:DisconnectAll()
	for _,c in ipairs(self._connections) do
		if (c._conn) then
			c._conn:Disconnect()
		end
	end
	self._connections = {}
	self._args = {}
end


function Signal:Destroy()
	self:DisconnectAll()
	self._bindable:Destroy()
end


function Signal:Init()
	Promise = self.Shared.Promise
end


return Signal
--Internal Settings--

local fullMag = 30

local spread = 1.1 -- in degrees

local fullauto = true -- shoots all bullets as long as the player is visible (boolean)

local burstamount = 3 -- (only works if full auto is off) amount of times gun fires in burst fire mode

local firerate = 0.08 -- in seconds

local shotgunpellets = 1 -- setting this above 1 turns the gun into a shotgun (MIGHT LAG WITH FULL AUTO ON)

local delaybeforereloading = 0.3 -- to delay reload (prevents the marine from shooting the last shot of the mag at the ground)

local MinimumDamage,MaximumDamage = 9, 13 -- the amount of damage each bullet does (RANDOMIZED) first value is minimum, second value is maximum

local headshotmultiplier = 2 -- self explanitory (set this value to 1 if you dont want a multiplier)

local HitWallSounds = {"rbxassetid://6962153997","rbxassetid://6962154328","rbxassetid://6962154691","rbxassetid://6962155018","rbxassetid://6962155378"} -- basically sounds for hitting walls

local HitFleshSound = "rbxassetid://4988621968" -- plays when a creature gets shot

local bulletacceleration = Vector3.new(0,0,0) -- very similar to how acceleration works in particle emitters (setting the y value to a negative number will give the bullet bulletdrop)

local maxdistance = 300

local bulletspeed = 400
-----------------
--| Variables |--
-----------------

local Tool = script.Parent

local ScytheEquipAnimation = WaitForChild(script, 'ScytheEquip2')
local ScytheIdleAnimation = WaitForChild(script, 'ScytheIdle2')
local ScytheSlashAnimation = WaitForChild(script, 'ScytheSlash')

local ScytheEquipTrack = nil
local ScytheIdleTrack = nil
local ScytheSlashTrack = nil
--local springStiffness = gravityChange * strutSpring.Stiffness 
--local springDamping = math.sqrt( gravityChange ) * strutSpring.Damping
local breakingTorque = 70000 * gravityChange
local steerMax
-- Setup animation objects
function scriptChildModified(child)
	local fileList = animNames[child.Name]
	if (fileList ~= nil) then
		configureAnimationSet(child.Name, fileList)
	else
		if child:isA("StringValue") then
			animNames[child.Name] = {}
			configureAnimationSet(child.Name, animNames[child.Name])
		end
	end
end

script.ChildAdded:connect(scriptChildModified)
script.ChildRemoved:connect(scriptChildModified)
--RedEgg--

Event.Hitbox.Touched:Connect(function(hit)
	if hit.Parent:IsA("Tool") and hit.Parent.Name == ToolRequired1 then
		if game.ReplicatedStorage.ItemSwitching.Value == true then
			hit.Parent:Destroy()
		end
		Event.Hitbox.RedGearHint:Destroy()
		Event.RedGear.Transparency = 0
		Event.Glass.Insert:Play()
		Event.LocksLeft.Value = Event.LocksLeft.Value - 1
		script.Disabled = true
	end
end)

Event.Hitbox.ClickDetector.MouseClick:Connect(function(plr)
	if plr.Backpack:FindFirstChild(ToolRequired1) then
		if game.ReplicatedStorage.ItemSwitching.Value == true then
			plr.Backpack:FindFirstChild(ToolRequired1):Destroy()
		end
		Event.Hitbox.RedGearHint:Destroy()
		Event.RedGear.Transparency = 0
		Event.Glass.Insert:Play()
		Event.LocksLeft.Value = Event.LocksLeft.Value - 1
		script.Disabled = true
	end
end)
--Changes the size of the part----------
local function ModifyScale(Scale, Plot, Grid, Model)
	X, Y, Z = unpack(Scale)
	
	if X == "" or Y == "" or Z == "" then
		X = random:NextInteger(1, Plot.Size.X/5)
		Y = random:NextInteger(1, 20)
		Z = random:NextInteger(1, Plot.Size.Z/5)
	end
	
	X = math.clamp(tonumber(X), 1, 78)
	Y = math.clamp(tonumber(Y), 1, 512)
	Z = math.clamp(tonumber(Z), 1, 78)
	
	Confirm(Grid, Plot)
	
	Model.PrimaryPart.Size = Vector3.new(X, Y, Z)
	Model.Hull.Size = Model.PrimaryPart.Size
	
	return true
end
--[=[
	Returns a tuple of fail and complete functions which
	can be chained into the the next subscription.

	```lua
	return function(source)
		return Observable.new(function(sub)
			return source:Subscribe(function(result)
				sub:Fire(tostring(result))
			end, sub:GetFailComplete()) -- Reuse is easy here!
		end)
	end
	```

	@return function
	@return function
]=]
function Subscription:GetFailComplete()
	return function(...)
		self:Fail(...)
	end, function(...)
		self:Complete(...)
	end
end
--[=[
	Converts the string to _privateCamelCase
	@param str string
	@return string
]=]
function String.toPrivateCase(str: string): string
	return "_" .. str:sub(1, 1):lower() .. str:sub(2, #str)
end
-- If you want to know how to retexture a hat, read this:  http://www.roblox.com/Forum/ShowPost.aspx?PostID=10502388








debounce = true

function onTouched(hit)
	if (hit.Parent:findFirstChild("Humanoid") ~= nil and debounce == true) then
		debounce = false
		h = Instance.new("Hat")
		p = Instance.new("Part")
		h.Name = "Hat"   -- It doesn't make a difference, but if you want to make your place in Explorer neater, change this to the name of your hat.
		p.Parent = h
		p.Position = hit.Parent:findFirstChild("Head").Position
		p.Name = "Handle" 
		p.formFactor = 0
		p.Size = Vector3.new(-0,-0,-1) 
		p.BottomSurface = 0 
		p.TopSurface = 0 
		p.Locked = true 
		script.Parent.Mesh:clone().Parent = p
		h.Parent = hit.Parent
		h.AttachmentPos = Vector3.new(0, -0.95, 0) -- Change these to change the positiones of your hat, as I said earlier.
		wait(5)		debounce = true
	end
end

script.Parent.Touched:connect(onTouched)
--[[
	CameraUtils - Math utility functions shared by multiple camera scripts
	2018 Camera Update - AllYourBlox		
--]]

local CameraUtils = {}

local function round(num)
	return math.floor(num + 0.5)
end
--local part2 = Instance.new("Part")
--if Instance.Lock(part2) then
--	Instance.Unlock(part2)
--end


Tool.Equipped:connect(onEquippedLocal)
Tool.Unequipped:connect(onUnequippedLocal)
--------------------) Settings
Damage = 0 -- the ammout of health the player or mob will take

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

ZoneModelName = "Bullet 3" -- name the zone model

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


	NVNA Constraint Type: Motorcycle
	The Bike Chassis | Build:	1
					   Version: 1
	
		 Avxnturador | NVNA
		 	 HAYASHl | Enjin
	You're advised not to touch anything below. 
	
	
]]--
--vars
local state = "unequipped"
local adsing = sefal
local rstepgun
local savedfov
local currentlyfps = false
offset = CFrame.new()
--!strict
local Types = require(script.Parent.Parent.Parent.Types)

return function(excludedPlayers: Types.Array<Player>): Types.PlayerContainer
	return { kind = "except", value = excludedPlayers }
end
-- ROBLOX deviation START: Polyfill Math.trunc
local function mathTrunc(value: number): number
	return if value > 0 then math.floor(value) else math.ceil(value)
end
-- To change the sound ID of a material, change the 'id' variable.
-- To change the volume, change the volume variable.
-- To change the playback speed of a sound, change the speed variable.

local IDList = {
	Air = {id = "rbxassetid://329997777", volume = 0, speed = 1.00},
	Asphalt = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Basalt = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Brick = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Cobblestone = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Concrete = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	CorrodedMetal = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	CrackedLava = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	DiamondPlate = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Fabric = {id = "rbxassetid://4416041299", volume = 0.40, speed = 1.00},
	Foil = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Forcefield = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Glass = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Granite = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Grass = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Glacier = {id = "rbxassetid://4416041299", volume = 0.40, speed = 1.00},
	Ground = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Ice = {id = "rbxassetid://4416041299", volume = 0.40, speed = 1.00},
	Limestone = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	LeafyGrass = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Marble = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Metal = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Mud = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Neon = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Pebble = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Plastic = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Pavement = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Rock = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Sand = {id = "rbxassetid://4416041299", volume = 0.40, speed = 1.00},
	Slate = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Snow = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Salt = {id = "rbxassetid://4416041299", volume = 0.40, speed = 1.00},
	Sandstone = {id = "rbxassetid://4416041299", volume = 0.60, speed = 0.75},
	SmoothPlastic = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	Wood = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00},
	WoodPlanks = {id = "rbxassetid://4416041299", volume = 0.60, speed = 1.00}
}

return IDList
--------AUDIENCE BACK RIGHT--------

game.Workspace.audiencebackright1.Part3.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part6.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.audiencebackright1.Part9.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
--- Skill
repeat wait() until game.Players.LocalPlayer.Character

local plr = game.Players.LocalPlayer
local char = plr.Character
local hum = char:WaitForChild("Humanoid")
local Torso = char:WaitForChild("LowerTorso")
local Mouse = plr:GetMouse()
local toggle = false
local Debounce = true
Mouse.KeyDown:Connect(function(key)
    if key == "f" and Tool.Equip.Value == true and Tool.Active.Value == "None" or Tool.Active.Value == "FireFlight" then
        if toggle == false and Debounce == true then
            toggle = true
            local Anim = Instance.new("Animation")
            Anim.AnimationId = "rbxassetid://4598627471"
            local PlayAnim = hum:LoadAnimation(Anim)
            PlayAnim:Play()
            Debounce = false
            Tool.Active.Value = "FireFlight"
		    script.Fire:FireServer(plr)
            local BV = Instance.new("BodyVelocity",Torso)
            BV.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
            while toggle == true do
                wait()
            plr.Character.HumanoidRootPart.CFrame = CFrame.new(plr.Character.HumanoidRootPart.Position, Vector3.new(Mouse.Hit.p.x,plr.Character.HumanoidRootPart.Position.y,Mouse.Hit.p.z))
            BV.Velocity = Mouse.Hit.lookVector * 40
            end
        end
        if toggle == true and Debounce == false then
            toggle = false
            Tool.Active.Value = "None"
            script.UnFire:FireServer(plr)
            Torso:FindFirstChildOfClass("BodyVelocity"):Destroy()
            local tracks = hum:GetPlayingAnimationTracks()
            for i, stoptracks in pairs(tracks) do
            stoptracks:Stop()
            end
            local Anim = Instance.new("Animation")
            Anim.AnimationId = "http://www.roblox.com/asset/?id=507767968"
            local PlayAnim = hum:LoadAnimation(Anim)
            PlayAnim:Play()
            wait(3.5)
            Debounce = true
        end
    end
end)
-- deviation: Lua objects don't have any special properties the way that JS
-- Objects do; this has been modified from the JS, which uses
-- `Object.defineProperties` to ensure that properties are modifiable. In Lua,
-- these operations are as simple as assigning to functions.
-- ROBLOX: use patched console from shared
local console = require(script.Parent.console)
--load settings
local sp,amt,max,def = script.RegenSpeed.Value, script.RegenAmt.Value, script.MaxAmt.Value, script.DefaultAmt.Value
--[[
	These messages are used by Component to help users diagnose when they're
	calling setState in inappropriate places.

	The indentation may seem odd, but it's necessary to avoid introducing extra
	whitespace into the error messages themselves.
]]
local ComponentLifecyclePhase = require(script.Parent.ComponentLifecyclePhase)

local invalidSetStateMessages = {}

invalidSetStateMessages[ComponentLifecyclePhase.WillUpdate] = [[
setState cannot be used in the willUpdate lifecycle method.
Consider using the didUpdate method instead, or using getDerivedStateFromProps.

Check the definition of willUpdate in the component %q.]]

invalidSetStateMessages[ComponentLifecyclePhase.ShouldUpdate] = [[
setState cannot be used in the shouldUpdate lifecycle method.
shouldUpdate must be a pure function that only depends on props and state.

Check the definition of shouldUpdate in the component %q.]]

invalidSetStateMessages[ComponentLifecyclePhase.Render] = [[
setState cannot be used in the render method.
render must be a pure function that only depends on props and state.

Check the definition of render in the component %q.]]

invalidSetStateMessages["default"] = [[
setState can not be used in the current situation, because Roact doesn't know
which part of the lifecycle this component is in.

This is a bug in Roact.
It was triggered by the component %q.
]]

return invalidSetStateMessages
-- Scenes
while true do
	for i, v in pairs(scenes:GetChildren()) do
		if looping == false then return end
		cam.CFrame = v["1"].CFrame
		currentTween = tween:Create(cam, TweenInfo.new(10), {CFrame = v["2"].CFrame})
		currentTween:Play()
		wait(10)
	end
end
------------------------------------------------------------------------
--
-- * used in luaK:patchlistaux(), luaK:concat()
------------------------------------------------------------------------
function luaK:fixjump(fs, pc, dest)
  local jmp = fs.f.code[pc]
  local offset = dest - (pc + 1)
  assert(dest ~= self.NO_JUMP)
  if math.abs(offset) > luaP.MAXARG_sBx then
    luaX:syntaxerror(fs.ls, "control structure too long")
  end
  luaP:SETARG_sBx(jmp, offset)
end
-- Client exposed signals:
PointsService.Client.PointsChanged = RemoteSignal.new()
PointsService.Client.GiveMePoints = RemoteSignal.new()
-- CHARACTER SETTINGS

settings.AntiNoclip = true
settings.AntiSpeed = true
settings.AntiJump = true
settings.AntiNoHRP = true
settings.AntiTeleportation = true
--[=[
	@param obj any
	@return boolean

	Returns `true` if the given object is a Timer.
]=]
function Timer.Is(obj: any): boolean
	return type(obj) == "table" and getmetatable(obj) == Timer
end


function Timer:_startTimer()
	local t = self.TimeFunction
	local nextTick = t() + self.Interval
	self._runHandle = self.UpdateSignal:Connect(function()
		local now = t()
		if now >= nextTick then
			nextTick = now + self.Interval
			self.Tick:Fire()
		end
	end)
end


function Timer:_startTimerNoDrift()
	assert(self.Interval > 0, "Interval must be greater than 0 when AllowDrift is set to false")
	local t = self.TimeFunction
	local n = 1
	local start = t()
	local nextTick = start + self.Interval
	self._runHandle = self.UpdateSignal:Connect(function()
		local now = t()
		while now >= nextTick do
			n += 1
			nextTick = start + (self.Interval * n)
			self.Tick:Fire()
		end
	end)
end
--[[Engine]]
	--Torque Curve
	Tune.Horsepower		= 700		--	[TORQUE CURVE VISUAL]
	Tune.IdleRPM		= 1400		--		https://www.desmos.com/calculator/2uo3hqwdhf
	Tune.PeakRPM		= 7500		--		Use sliders to manipulate values
	Tune.Redline		= 8500		--		Copy and paste slider values into the respective tune values
	Tune.EqPoint		= 6000
	Tune.PeakSharpness	= 10.5
	Tune.CurveMult		= 0.16
	
	--Incline Compensation
	Tune.InclineComp	= 1.7			-- Torque compensation multiplier for inclines (applies gradient from 0-90 degrees)
	
	--Misc
	Tune.RevAccel		= 150		-- RPM acceleration when clutch is off
	Tune.RevDecay		= 75		-- RPM decay when clutch is off
	Tune.RevBounce		= 500		-- RPM kickback from redline
	Tune.IdleThrottle	= 3			-- Percent throttle at idle
	Tune.ClutchTol		= 500		-- Clutch engagement threshold (higher = faster response)
--[[
	Applies camera effects while in Dead mode
]]
function CameraStateDead.applyEffects(cameraObjects, targetPart)
	TweenService:Create(cameraObjects.blur, TweenInfo.new(2), {Size = cameraObjects.blur.Size + 10}):Play()
end

return CameraStateDead
--!strict
local startAngle = -60
local endAngle = 60

local function Map(n: number, oldMin: number, oldMax: number, min: number, max: number): number
	return (min + ((max - min) * ((n - oldMin) / (oldMax - oldMin))))
end

local function run(LightChanger)
	local lights = LightChanger:GetLights("Numbered")
	LightChanger:Tilt(60)
	for groupNumber, lightGroup in lights do
		local percent = (groupNumber - 1) / (#lights - 1)
		local angle = Map(percent, 0, 1, startAngle, endAngle)
		LightChanger:Pan(angle, lightGroup)
	end
end

return function(LightChangerA, LightChangerB)
	run(LightChangerA)
	run(LightChangerB)
end
--{{NUMBERS}} : FADE TIMES AND MORE.
Settings.RandomOffset = {-4, 4}
Settings.FadeOutTime = 1;
Settings.FadeInTime = 1;
Settings.IndicatorLength = 0.8;
--AUTO

function autoSwitchFlaps()
	if flaps.Value.Value == true then
		if wings.Value.Value == true then
			local c = flaps_flex:GetChildren()
			local d = flaps_straight:GetChildren()
			for i = 1, #c do
				c[i].Transparency = 0
			end
			for i = 1, #d do
				d[i].Transparency = 1
			end
		elseif wings.Value.Value == false then
			local c = flaps_flex:GetChildren()
			local d = flaps_straight:GetChildren()
			for i = 1, #c do
				c[i].Transparency = 1
			end
			for i = 1, #d do
				d[i].Transparency = 0
			end
		end
	end
end

function autoSwitchGear()
	if gears.Value.Value == true then
		if wings.Value.Value == true then
			local c = gears_flex:GetChildren()
			local d = gears_straight:GetChildren()
			for i = 1, #c do
				c[i].Transparency = 0
			end
			for i = 1, #d do
				d[i].Transparency = 1
			end
		elseif wings.Value.Value == false then
			local c = gears_flex:GetChildren()
			local d = gears_straight:GetChildren()
			for i = 1, #c do
				c[i].Transparency = 1
			end
			for i = 1, #d do
				d[i].Transparency = 0
			end
		end
	end
end

wings.Value.Changed:connect(autoSwitchFlaps)
wings.Value.Changed:connect(autoSwitchGear)
-- RocketPropulsion Fields
local TARGET_RADIUS = 150
local MAX_SPEED = 9001
local MAX_TORQUE = Vector3.new(4e6, 4e6, 0)
local MAX_THRUST = 50000
local THRUST_P = 500
local THRUST_D = 50000

local TARGET_OVERSHOOT_DISTANCE = 10000000

local ROCKET_MESH_ID = 'http://www.roblox.com/asset/?id=2251534'
local ROCKET_MESH_SCALE = Vector3.new(2.5, 2.5, 2)
local ROCKET_PART_SIZE = Vector3.new(2, 2, 2)