Roblox/luau_corpus huggingface dataset:
--Change the value \/
local flinginess = 50 --CHANGE THIS VALUE TO AFFECT FLING

local flng = flinginess
local negflng = flinginess * -1
--[[
	Create a promise that represents the immediately rejected value.
]]
function Promise.reject(...)
	local length, values = pack(...)
	return Promise._new(debug.traceback(nil, 2), function(_, reject)
		reject(unpack(values, 1, length))
	end)
end
Promise.Reject = Promise.reject
--// Module LoadOrder List; Core modules need to be loaded in a specific order; If you create new "Core" modules make sure you add them here or they won't load
local LoadingOrder = {
	--// Nearly all modules rely on these to function
	"Logs";
	"Variables";
	"Functions";
a
	--// Core functionality
	"Core";
	"Remote";
	"Process";

	--// Misc
	"Admin";
	"HTTP";
	"Anti";
	"Commands";
}
--[=[
	This function returns a table with the values of the passed dictionary.
	
	```lua
	local Dictionary = {
		A = 1,
		B = 2,
		C = 3,
	}
	
	print(TableKit.Values(Dictionary)) -- prints {1, 2, 3}
	```

	@within TableKit
	@param dictionary table
	@return table
]=]
function TableKit.Values<T>(dictionary: { [unknown]: T }): { T }
	local valueArray = {}

	for _, value in dictionary do
		table.insert(valueArray, value)
	end

	return valueArray
end
--local eat = Humanoid:LoadAnimation(AnimF.open)
--local Idle = Humanoid:LoadAnimation(AnimF.idle)
local Debounce = false

tool.Equipped:Connect(function()
--[[
		___      _______                _     
	   / _ |____/ ___/ /  ___ ____ ___ (_)__ 
	  / __ /___/ /__/ _ \/ _ `(_-<(_-</ (_-<
	 /_/ |_|   \___/_//_/\_,_/___/___/_/___/
 						SecondLogic @ Inspare
]]
local FE = workspace.FilteringEnabled
local car = script.Parent.Car.Value
local handler = car:WaitForChild("AC6_FE_Sounds")
local _Tune = require(car["A-Chassis Tune"])
local on = 0
local throt=0
local redline=0

script:WaitForChild("Rev")

for _,v in ipairs(car.DriveSeat:GetChildren()) do
	for _,a in ipairs(script:GetChildren()) do
		if v.Name==a.Name then v:Stop() wait() v:Destroy() end
	end
end

handler:FireServer("newSound","Rev",car.DriveSeat,script.Rev.SoundId,0,script.Rev.Volume,true)
handler:FireServer("playSound","Rev")
car.DriveSeat:WaitForChild("Rev")

game:GetService("RunService").Heartbeat:Connect(function() -- to-do: linear interpolate on all clients at 10/s to avoid bogging down network
	local _RPM = script.Parent.Values.RPM.Value
	
	if script.Parent.Values.Throttle.Value <= _Tune.IdleThrottle/100 then
		throt = math.max(.3,throt-.2)	
	else
		throt = math.min(1,throt+.1)	
	end	
	if script.Parent.Values.RPM.Value > _Tune.Redline-_Tune.RevBounce/4 and script.Parent.Values.Throttle.Value > _Tune.IdleThrottle/100 then
		redline=.5
	else
		redline=1
	end
	if not script.Parent.IsOn.Value then on=math.max(on-.015,0) else on=1 end
	local Pitch = math.max((((script.Rev.SetPitch.Value + script.Rev.SetRev.Value*_RPM/_Tune.Redline))*on^2),script.Rev.SetPitch.Value)
	if FE then
		handler:FireServer("updateSound","Rev",script.Rev.SoundId,Pitch,script.Rev.Volume)
	else
		car.DriveSeat.Rev.Pitch = Pitch
	end
end)
-- VisualComponents by Travis, modified for native visuals. 

local module = {}

module.panels = {}

local MapConstant = 40000
local VideoControl = require(script.VideoControl.Value)

local function mapScreen(center,screen)
	local dif = Instance.new("Attachment",center)
	dif.WorldPosition = screen.Position

	for i,v in pairs(screen.VisualScreen.Main:GetChildren()) do
		if v:IsA("ImageLabel") then
			v.Position = UDim2.new(0.5, dif.Position.X * MapConstant, 0.5, (dif.Position.Y - dif.Position.Z) * MapConstant )
		end
	end
	for i,v in pairs(screen.VisualScreen.SpriteVisual:GetChildren()) do
		if v:IsA("ImageLabel") then
			v.Position = UDim2.new(0.5, dif.Position.X * MapConstant, 0.5, (dif.Position.Y - dif.Position.Z) * MapConstant )
		end
	end


	screen.VisualScreen.CanvasSize = Vector2.new((screen.Size.X*MapConstant),(screen.Size.Y*MapConstant))
	dif:Destroy()
end

function module.Start(screensFolder)
	local center = screensFolder.CenterPart
	if screensFolder:FindFirstChild("Panels") then
		for i,v in pairs(screensFolder.Panels:GetChildren()) do
			local cloneFrame = script.Main:Clone()
			local cloneFrame1 = script.SpriteVisual:Clone()
			cloneFrame.Parent = v.VisualScreen
			cloneFrame1.Parent = v.VisualScreen
			mapScreen(center,v)
			table.insert(module.panels,v)
			v.Debug:Destroy()
		end
	end
	VideoControl.SpriteStart()
end


return module
--------|    Variables    |--------
local cashLabel = _L.GUI.Bottom.MainBottomBar.CenterContainer.Cash.Title
--!strict
return function(value)
	return typeof(value) == "number" and value == value and value ~= math.huge and value ~= -math.huge
end
--[=[
	Utility to build a localization table from json, intended to be used with rojo. Can also handle Rojo json
	objects turned into tables!

	@class JsonToLocalizationTable
]=]

local LocalizationService = game:GetService("LocalizationService")
local HttpService = game:GetService("HttpService")
local RunService = game:GetService("RunService")

local JsonToLocalizationTable = {}

local LOCALIZATION_TABLE_NAME = "GeneratedJSONTable"
-- ================================================================================
-- LOCAL FUNCTIONS
-- ================================================================================
local function setModelAnchored(parent, anchored)
	for _, child in ipairs(parent:GetChildren()) do
		if (child:IsA("BasePart")) or (child:IsA("MeshPart")) then
			child.Anchored = anchored
		end
		setModelAnchored(child, anchored)
	end
end -- setModelAnchored()

local function setModelCanCollide(parent, canCollide)
	for _, child in ipairs(parent:GetChildren()) do
		if (child:IsA("BasePart")) or (child:IsA("MeshPart")) then
			child.CanCollide = canCollide
		end
		setModelAnchored(child, canCollide)
	end
end -- setModelCanCollide()

local function setModelTransparency(parent, transparency)
	for _, child in ipairs(parent:GetChildren()) do
		if (child:IsA("BasePart")) or (child:IsA("MeshPart")) then
			child.Transparency = transparency
		end
		setModelTransparency(child, transparency)
	end
end -- setModelTransparency()

local function removeLimbsAndThings(character)
	for _, child in ipairs(character:GetChildren()) do
		removeLimbsAndThings(child)
		if (not child:IsA("Humanoid")) and (not child:IsA("Motor6D")) 
			and (child.Name ~= "Head") and (child.Name ~= "UpperTorso") then
				child:Destroy()
		end
	end
end -- removeLimbsAndThings()

local function insertModelIntoCharacter(character, model)
	for _, child in ipairs(model:GetChildren()) do
		child.Parent = character
		insertModelIntoCharacter(child, child)
	end
end -- insertModelIntoCharacter()

local function setCollisionGroup(parent, group)
	for _,part in pairs(parent:GetChildren()) do
		if (part:IsA("BasePart") or (part:IsA("MeshPart"))) then
			PhysicsService:SetPartCollisionGroup(part, group)
		end
	end
end -- SetCollisionGroup()
--[[Engine]]
	--Torque Curve
	Tune.Horsepower		= 75
	Tune.IdleRPM		= 500
	Tune.PeakRPM		= 5600
	Tune.Redline		= 6300
	Tune.EqPoint		= 6300
	Tune.PeakSharpness	= 2.2
	Tune.CurveMult		= 0.01
	
	--Incline Compensation
	Tune.InclineComp	= 1.35			-- Torque compensation multiplier for inclines (applies gradient from 0-90 degrees)
	
	--Misc
	Tune.RevAccel		= 0		-- RPM acceleration when clutch is off
	Tune.RevDecay		= 75		-- RPM decay when clutch is off
	Tune.RevBounce		= 500		-- RPM kickback from redline
	Tune.IdleThrottle	= 0			-- Percent throttle at idle
	Tune.ClutchTol		= 450		-- Clutch engagement threshold (higher = faster response)
-- Function to handle the button click
local function onClick()
	-- Destroy the parent GUI (the ScreenGui containing the TextButton)
	button.Parent:Destroy()
end

button.MouseButton1Click:Connect(onClick)
--[[ Local Variables ]]--
local MasterControl = {}

local Players = game:GetService('Players')
local RunService = game:GetService('RunService')

while not Players.LocalPlayer do
	wait()
end
local LocalPlayer = Players.LocalPlayer
local CachedHumanoid = nil
local RenderSteppedCon = nil
local SeatedCn = nil
local moveFunc = LocalPlayer.Move

local isJumping = false
local isSeated = false
local myVehicleSeat = nil
local moveValue = Vector3.new(0,0,0)
--if SignalValues.Signal1.Value == 2 then
	SignalValues.Signal1.Value = 3
-- functions

function stopAllAnimations()
	local oldAnim = currentAnim

	-- return to idle if finishing an emote
	if (emoteNames[oldAnim] ~= nil and emoteNames[oldAnim] == false) then
		oldAnim = "idle"
	end

	currentAnim = ""
	if (currentAnimKeyframeHandler ~= nil) then
		currentAnimKeyframeHandler:Disconnect()
	end

	if (oldAnimTrack ~= nil) then
		oldAnimTrack:Stop()
		oldAnimTrack:Destroy()
		oldAnimTrack = nil
	end
	if (currentAnimTrack ~= nil) then
		currentAnimTrack:Stop()
		currentAnimTrack:Destroy()
		currentAnimTrack = nil
	end
	return oldAnim
end

function setAnimationSpeed(speed)
	if speed ~= currentAnimSpeed then
		currentAnimSpeed = speed
		currentAnimTrack:AdjustSpeed(currentAnimSpeed)
	end
end

function keyFrameReachedFunc(frameName)
	if (frameName == "End") then
-- Display result window for active players
function PlayerManager:DisplayRoundResult(resultString, resultTime)
	for _, player in ipairs(PlayerManager.ActivePlayers) do
		DisplayRoundResult:FireClient(player, resultString, resultTime)
	end
end
-- UI Profile
local usernameprofile = gui.Parent.Parent.User.Username
local displaynameprofile = gui.Parent.Parent.User.DisplayName
local pfpprofile = gui.Parent.Parent.User.ProfilePicture
local shutterpfp = script.Parent.Parent.Parent.ShutterFrame.ProfilePicture

local Players = game:GetService("Players")

local player = Players.LocalPlayer
-- [ FUNCTIONS ] --

repeat wait() until cam.CameraSubject ~= nil

cam.CameraType = Enum.CameraType.Scriptable
-- Instances have a "Name" field.  Sort 
-- by that name,
function CommonUtil.SortByName(items)	
	local function compareInstanceNames(i1, i2) 
		return (i1.Name < i2.Name)
	end
	table.sort(items, compareInstanceNames)
	return items
end
--//ENGINE//--
Horsepower = 430  --{This is how much power your engine block makes ALONE, this does not represent to total horsepower output [IF you have a turbo/SC]}
EngineDisplacement = 3000 --{Engine size in CC's}
EngineType =  "Diesel" --{Petrol, Diesel, Electric]
EngineLocation = "Front" --{Front, Mid, Rear}
ForcedInduction = "Single" --{Natural, Single, Twin, Supercharger} 
InductionPartSize = 1.5 --{0-5, 1 being small, 5 being large (Decimals accepted, e.g 2.64 turbo size, this is the size of the turbo}
ElectronicallyLimited = false --{Electronically Limit the top speed of your vehicle}
LimitSpeedValue = 100 --{Limits top speed of the vehicle [In MPH]}
-- Returns the current active view model
-- @return Model
function FirstPersonRigAssembly.GetActiveRig()
	return activeRig
end
--[[
	Returns the current value of this ForPairs object.
	The object will be registered as a dependency unless `asDependency` is false.
]]
function class:get(asDependency: boolean?): any
	if asDependency ~= false then
		Dependencies.useDependency(self)
	end
	return self._outputTable
end
--------LEFT DOOR --------
game.Workspace.doorleft.l11.BrickColor = BrickColor.new(133)
game.Workspace.doorleft.l12.BrickColor = BrickColor.new(133)
game.Workspace.doorleft.l13.BrickColor = BrickColor.new(133)
game.Workspace.doorleft.l41.BrickColor = BrickColor.new(133)
game.Workspace.doorleft.l42.BrickColor = BrickColor.new(133)
game.Workspace.doorleft.l43.BrickColor = BrickColor.new(133)
game.Workspace.doorleft.l71.BrickColor = BrickColor.new(133)
game.Workspace.doorleft.l72.BrickColor = BrickColor.new(133)
game.Workspace.doorleft.l73.BrickColor = BrickColor.new(133)

game.Workspace.doorleft.l21.BrickColor = BrickColor.new(106)
game.Workspace.doorleft.l22.BrickColor = BrickColor.new(106)
game.Workspace.doorleft.l23.BrickColor = BrickColor.new(106)
game.Workspace.doorleft.l51.BrickColor = BrickColor.new(106)
game.Workspace.doorleft.l52.BrickColor = BrickColor.new(106)
game.Workspace.doorleft.l53.BrickColor = BrickColor.new(106)

game.Workspace.doorleft.l31.BrickColor = BrickColor.new(21)
game.Workspace.doorleft.l32.BrickColor = BrickColor.new(21)
game.Workspace.doorleft.l33.BrickColor = BrickColor.new(21)
game.Workspace.doorleft.l61.BrickColor = BrickColor.new(21)
game.Workspace.doorleft.l62.BrickColor = BrickColor.new(21)
game.Workspace.doorleft.l63.BrickColor = BrickColor.new(21)

game.Workspace.doorleft.pillar.BrickColor = BrickColor.new(106)
--Function of the repair button
repair.MouseButton1Down:connect(function()
	if repairtwo == true then
		repairtwo = false
		local ff = Instance.new ("ForceField")
		ff.Parent = sp
		sp.Temporary:ClearAllChildren()
		menudisappear()
		disappearall()
		click.MaxActivationDistance = 10
		coverup()
		wait(1)
		ready = true
		ff:Destroy()
		
		for _,force in pairs(sp:GetChildren()) do
				if force:IsA("ForceField") then
					force:Destroy()
				end
		end
		
		script.Fixer.Disabled = true
		wait(5)
		repairtwo = true
	end
	
end)
--Main
local CacheManager: any = {}
CacheManager.__index = CacheManager

function CacheManager.new()
    local self = setmetatable({}, CacheManager)
    self.Cache = {}
    self.CacheLimit = math.huge
    self.Locked = false
    self.CacheParent = workspace

    return self
end

function CacheManager:SetCacheLimit(limit: number)
    self.CacheLimit = math.max(limit, 1)

    for _, cacheEntry: {[string]: any} in pairs(self.Cache) do
        local cacheToPurge: number = math.max(0, self.CacheLimit - #cacheEntry.Cache)

        if cacheToPurge > 0 then
            for _ = 1, cacheToPurge do
                cacheEntry.Cache[#cacheEntry.Cache]:Destroy()
                cacheEntry.Cache[#cacheEntry.Cache] = nil
            end
        end
    end
end

function CacheManager:Return(id: string, obj: Instance)
    if self.Locked then
        obj:Destroy()
        return    
    end

    if self.Cache[id] then
        if #self.Cache[id].Cache < self.CacheLimit then
            if obj:IsA("BasePart") then
                obj.Anchored = true
            elseif obj:IsA("Model") and obj.PrimaryPart then
                obj.PrimaryPart.Anchored = true
            end

            --? Maybe i should use bulkmoveto instead of this
            if obj:IsA("PVInstance") then
                obj:PivotTo(farawayCFrame)
            end
        
            table.insert(self.Cache[id].Cache, obj)
        else
            obj:Destroy()
        end
    end
end

function CacheManager:Take(id: string)
    if self.Locked then return end 

    if self.Cache[id] then
        local storedNum: number = #self.Cache[id].Cache

        if storedNum == 0 then
            local obj: Instance = self.Cache[id].Original:Clone()
            obj.Parent = self.CacheParent

            return obj
        else
            local obj: Instance = self.Cache[id].Cache[storedNum]
            
            self.Cache[id].Cache[storedNum] = nil

            if obj:IsA("BasePart") then
                obj.Anchored = false
            elseif obj:IsA("Model") and obj.PrimaryPart then
                obj.PrimaryPart.Anchored = false
            end

            return obj
        end
    end
end

function CacheManager:Register(id: string, obj: Instance)
    if self.Locked then 
        obj:Destroy()
        return 
    end

    if not self.Cache[id] then
        self.Cache[id] = {
            Cache = {},
            Original = obj
        }
    end
end

function CacheManager:Destroy(): ()
    self.Locked = true
    
    local _, cacheEntry: {[string]: Instance | {Instance}} = next(self.Cache)

    repeat
        cacheEntry.Original:Destroy()

        repeat
            cacheEntry.Cache[#cacheEntry.Cache]:Destroy()
            cacheEntry.Cache[#cacheEntry.Cache] = nil
        until #cacheEntry.Cache == 0

        _, cacheEntry = next(self.Cache)
    until cacheEntry == nil

    self.Cache = nil
    self = nil
end

return CacheManager
-------------------------------------------
local weld2 = Instance.new("Weld")
weld2.Part0 = torso
weld2.Parent = torso
weld2.Part1 = arms[2]
weld2.C1 = CFrame.new(0.5,0.495,1.25) * CFrame.fromEulerAnglesXYZ(math.rad(90),0,0)
arms[2].Name = "RDave"
arms[2].CanCollide = true
welds[2] = weld2
--[[
	Package link auto-generated by Rotriever
]]
local PackageIndex = script.Parent.Parent.Parent._Index

local Package = require(PackageIndex["JestFakeTimers"]["JestFakeTimers"])

export type FakeTimers = Package.FakeTimers


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

	Tune.FBrakeForce	= 3000		-- Front brake force
	Tune.RBrakeForce	= 2500		-- Rear brake force
	Tune.PBrakeForce	= 100000		-- 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]
--[[
	[Whether the whole character turns to face the mouse.]
	[If set to true, MseGuide will be set to true and both HeadHorFactor and BodyHorFactor will be set to 0]
--]]
local TurnCharacterToMouse = True
--[[
	-- Time functions
	-- @author Narrev
	
	This module can be called like so:
	
	timeModule = require(331894616) 	
	
	timeModule.Date() 			--> returns (year, month, days) @ timestamp tick()
	timeModule.Date(seconds) 	--> returns (year, month, days) @ seconds after epoch time
	
	timeModule.Time()			--> returns (hours, minutes, seconds) @ timestamp tick()
	timeModule.Time(seconds)	--> returns (hours, minutes, seconds) @ seconds after epoch time
	
--]]

local floor, ceil = math.floor, math.ceil

local function isLeapYear(year)
    return year % 4 == 0 and (year % 25 ~= 0 or year % 16 == 0)
end

local function GetLeaps(year)
	return floor(year/4) - floor(year/100) + floor(year/400)
end

local function CountDays(year)
	return 365*year + GetLeaps(year)
end

local function CountDays2(year)
	return 365*year + GetLeaps(year - 1)	
end

local function overflow(array, seed)
	for i = 1, #array do
		if seed - array[i] <= 0 then
			return i, seed
		end
		seed = seed - array[i]
	end
end

local function GetYMDFromSeconds(seconds)
	local seconds = seconds or tick()
    local days = ceil((seconds + 1) / 86400) + CountDays(1970)
    
    local _400Years = 400*floor(days / CountDays(400))
    local _100Years = 100*floor(days % CountDays(400) / CountDays(100))
    local _4Years = 4*floor(days % CountDays(400) % CountDays(100) / CountDays(4))
    
    local _1Years, month
    _1Years, days = overflow({366,365,365,365}, days - CountDays2(_4Years + _100Years + _400Years))
	_1Years	= _1Years - 1
    
    local year = _1Years + _4Years + _100Years + _400Years
    month, days = overflow({31,isLeapYear(year) and 29 or 28,31,30,31,30,31,31,30,31,30,31}, days)
        
	return year, month, days
end

local function GetTimeFromSeconds(seconds)
	local hours	= floor(seconds / 3600 % 24)
	local minutes	= floor(seconds / 60 % 60)
	local seconds	= floor(seconds % 60)
	
	return hours, minutes, seconds
end

return {Date = GetYMDFromSeconds, Time = GetTimeFromSeconds}
--[=[
	Observes a link value that is not nil.

	@param linkName string
	@param parent Instance
	@return Brio<Instance>
]=]
function RxLinkUtils.observeLinkValueBrio(linkName, parent)
	assert(type(linkName) == "string", "linkName should be 'string'")
	assert(typeof(parent) == "Instance", "parent should be 'Instance'")

	return RxInstanceUtils.observeChildrenOfNameBrio(parent, "ObjectValue", linkName)
		:Pipe({
			RxBrioUtils.flatMapBrio(function(instance)
				return RxInstanceUtils.observePropertyBrio(instance, "Value", function(value)
					return value ~= nil
				end)
			end)
		})
end
--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 plrData = require(game.ReplicatedStorage.Source.Modules.Util):GetPlayerData(player)
	return plrData.Money.Gold.Value < 30
end
--!native
local CameraModule = {}
local Mouse = game.Players.LocalPlayer:GetMouse()
local UserInput = game:GetService("UserInputService")
--viridian 6
if k == "v" and ibo.Value==true then
	bin.Blade.BrickColor = BrickColor.new("Pastel green")
	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=true colorbin.viridian.Value = true
	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=false colorbin.cyan.Value = false
    end
-- Initialize
StarterGui.ResetPlayerGuiOnSpawn = false
local MapPurgeProof = workspace:FindFirstChild('MapPurgeProof')
if not MapPurgeProof then
	MapPurgeProof = Instance.new('Folder')
	MapPurgeProof.Parent = workspace
	MapPurgeProof.Name = 'MapPurgeProof'
end
--[[
	A utility used to create a function spy that can be used to robustly test
	that functions are invoked the correct number of times and with the correct
	number of arguments.

	This should only be used in tests.
]]

local assertDeepEqual = require(script.Parent.assertDeepEqual)

local function createSpy(inner)
	local self = {}
	self.callCount = 0
	self.values = {}
	self.valuesLength = 0
	self.value = function(...)
		self.callCount = self.callCount + 1
		self.values = { ... }
		self.valuesLength = select("#", ...)

		if inner ~= nil then
			return inner(...)
		end
		return nil
	end

	self.assertCalledWith = function(_, ...)
		local len = select("#", ...)

		if self.valuesLength ~= len then
			error(("Expected %d arguments, but was called with %d arguments"):format(self.valuesLength, len), 2)
		end

		for i = 1, len do
			local expected = select(i, ...)

			assert(self.values[i] == expected, "value differs")
		end
	end

	self.assertCalledWithDeepEqual = function(_, ...)
		local len = select("#", ...)

		if self.valuesLength ~= len then
			error(("Expected %d arguments, but was called with %d arguments"):format(self.valuesLength, len), 2)
		end

		for i = 1, len do
			local expected = select(i, ...)

			assertDeepEqual(self.values[i], expected)
		end
	end

	self.captureValues = function(_, ...)
		local len = select("#", ...)
		local result = {}

		assert(self.valuesLength == len, "length of expected values differs from stored values")

		for i = 1, len do
			local key = select(i, ...)
			result[key] = self.values[i]
		end

		return result
	end

	setmetatable(self, {
		__index = function(_, key)
			error(("%q is not a valid member of spy"):format(key))
		end,
	})

	return self
end

return createSpy
--// Recoil Settings	
	gunrecoil = -0.75; -- How much the gun recoils backwards when not aiming
	camrecoil = 1.1; -- How much the camera flicks when not aiming
	AimGunRecoil = -0.6; -- How much the gun recoils backwards when aiming
	AimCamRecoil = 1; -- How much the camera flicks when aiming
	
	CamShake = 1; -- THIS IS NEW!!!! CONTROLS CAMERA SHAKE WHEN FIRING
	AimCamShake = 1; -- THIS IS ALSO NEW!!!!
	
	Kickback = 6; -- Upward gun rotation when not aiming
	AimKickback = 2; -- Upward gun rotation when aiming
-- these accept or return opcodes in the form of string names
function luaP:GET_OPCODE(i) return self.ROpCode[i.OP] end
function luaP:SET_OPCODE(i, o) i.OP = self.OpCode[o] end

function luaP:GETARG_A(i) return i.A end
function luaP:SETARG_A(i, u) i.A = u end

function luaP:GETARG_B(i) return i.B end
function luaP:SETARG_B(i, b) i.B = b end

function luaP:GETARG_C(i) return i.C end
function luaP:SETARG_C(i, b) i.C = b end

function luaP:GETARG_Bx(i) return i.Bx end
function luaP:SETARG_Bx(i, b) i.Bx = b end

function luaP:GETARG_sBx(i) return i.Bx - self.MAXARG_sBx end
function luaP:SETARG_sBx(i, b) i.Bx = b + self.MAXARG_sBx end

function luaP:CREATE_ABC(o,a,b,c)
  return {OP = self.OpCode[o], A = a, B = b, C = c}
end

function luaP:CREATE_ABx(o,a,bc)
  return {OP = self.OpCode[o], A = a, Bx = bc}
end