Roblox/luau_corpus huggingface dataset:
--		if EnabledCamera and EnabledCamera:GetShiftLock() and not EnabledCamera:IsInFirstPerson() then
--			if EnabledCamera:GetCameraActualZoom() < 1 then
--				local subjectPosition = EnabledCamera.lastSubjectPosition 
--				if subjectPosition then
--					Camera.Focus = CFrame_new(subjectPosition)
--					Camera.CFrame = CFrame_new(subjectPosition - MIN_CAMERA_ZOOM*EnabledCamera:GetCameraLook(), subjectPosition)
--				end
--			end
--		end
		return newCameraCFrame, desiredCameraFocus
	end
	
	-- Return unchanged values
	return desiredCameraCFrame, desiredCameraFocus
end

function Poppercam:OnCameraSubjectChanged(newSubject)
	self.vehicleParts = {}

	self.lastPopAmount = 0

	if newSubject then
		-- Determine if we should be popping at all
		self.popperEnabled = false
		for _, subjectType in pairs(VALID_SUBJECTS) do
			if newSubject:IsA(subjectType) then
				self.popperEnabled = true
				break
			end
		end

		-- Get all parts of the vehicle the player is controlling
		if newSubject:IsA('VehicleSeat') then
			self.vehicleParts = newSubject:GetConnectedParts(true)
		end
	
		if FFlagUserPortraitPopperFix then
			if newSubject:IsA("BasePart") then
				self.subjectPart = newSubject
			elseif newSubject:IsA("Model") then
				if newSubject.PrimaryPart then
					self.subjectPart = newSubject.PrimaryPart
				else
					-- Model has no PrimaryPart set, just use first BasePart
					-- we can find as better-than-nothing solution (can still fail)
					for _, child in pairs(newSubject:GetChildren()) do
						if child:IsA("BasePart") then
							self.subjectPart = child
							break
						end
					end	
				end
			elseif newSubject:IsA("Humanoid") then
				self.subjectPart = newSubject.RootPart
  			end
  		end
  	end
end

return Poppercam
--[=[
	Constructs a new Brio.

	```lua
	local brio = Brio.new("a", "b")
	print(brio:GetValue()) --> a b
	```

	@param ... any -- Brio values
	@return Brio
]=]
function Brio.new(...) -- Wrap
	return setmetatable({
		_values = table.pack(...);
	}, Brio)
end
-- check if camera is zoomed into first person
local function checkfirstperson()
	if isfirstperson == false then -- not in first person
		if ((camera.focus.p - camera.CFrame.p).magnitude <= 1) and (not character:GetAttribute("Ragdoll")) then
			enableviewmodel()
		end
	elseif ((camera.focus.p - camera.CFrame.p).magnitude > 1.1) or character:GetAttribute("Ragdoll") then
		disableviewmodel()
	end
end
--Kills users even if they have a shield

function module:ExecuteBehaviour(brickTouched, character)
	if character:FindFirstChild("Humanoid") ~= nil then
		if character.Humanoid.Health > 0 then
			character.Humanoid.Health = 0
			character:BreakJoints()
		end
	end
end

return module
--------------------
--| Script Logic |--
--------------------

Tool.Equipped:connect(OnEquipped)
Tool.Changed:connect(OnChanged)
Tool.Unequipped:connect(OnUnequipped)
--// All global vars will be wiped/replaced except script
--// All guis are autonamed client.Variables.CodeName..gui.Name

return function(data)
	local gui = script.Parent.Parent
	local playergui = service.PlayerGui
	local str = data.Message
	local time = data.Time or 15
	
	local log  = {
		Type = "Hint";
		Title = "Hint";
		Message = str;
		Icon = "rbxassetid://7501175708";
		Time = os.date("%X");
		Function = nil;
	}

	table.insert(client.Variables.CommunicationsHistory, log) 
	service.Events.CommsPanel:Fire(log)
	
	--client.UI.Make("HintHolder")
	local container = client.UI.Get("HintHolder",nil,true)
	if not container then 
		local holder = service.New("ScreenGui")
		local hTable = client.UI.Register(holder)
		local frame = service.New("ScrollingFrame", holder)
		client.UI.Prepare(holder)
		hTable.Name = "HintHolder"
		frame.Name = "Frame"
		frame.BackgroundTransparency = 1
		frame.Size = UDim2.new(1, 0, 0,150)
		frame.CanvasSize = UDim2.new(0, 0, 0, 0)
		frame.ChildAdded:Connect(function(c)
			if #frame:GetChildren() == 0 then
				frame.Visible = false
			else
				frame.Visible = true
			end
		end)
		
		frame.ChildRemoved:Connect(function(c)
			if #frame:GetChildren() == 0 then
				frame.Visible = false
			else
				frame.Visible = true
			end
		end)
		
		container = hTable
		hTable:Ready()
	end
	container = container.Object.Frame
	
	--// First things first account for notif :)
	local notif = client.UI.Get("Notif")
	local topbar = client.UI.Get("TopBar")
	
	container.Position = UDim2.new(0,0,0,((notif and 30) or 0) + ((topbar and 40) or 0) - 35)
	
	local children = container:GetChildren()
	
	gui.Position = UDim2.new(0,0,0,-100)
	gui.Frame.msg.Text = str
	local bounds = gui.Frame.msg.TextBounds.X
	
	local function moveGuis(m,ignore)
		m = m or 0
		local max = #container:GetChildren()
		for i,v in pairs(container:GetChildren()) do
			if v~=ignore then
				local y = (i+m)*28
				v.Position = UDim2.new(0,0,0,y)
				if i~=max then v.Size = UDim2.new(1,0,0,28) end
			end
		end
	end
	
	local lom = -1
	moveGuis(-1)
	gui.Parent = container
	if #container:GetChildren()>5 then lom = -2 end
	UDim2.new(0,0,0,(#container:GetChildren()+lom)*28)
	moveGuis(-1)
	--gui:TweenPosition(UDim2.new(0,0,0,(#container:GetChildren()+lom)*28),nil,nil,0.3,true,function() if gui and gui.Parent then moveGuis(-1) end end)
	
	if #container:GetChildren()>5 then
		local gui = container:GetChildren()[1]
		moveGuis(-2,gui)
		gui:Destroy()
		--gui:TweenPosition(UDim2.new(0,0,0,-100),nil,nil,0.2,true,function() if gui and gui.Parent then gui:Destroy() end end)
	end
	
	wait(data.Time or 5)
	
	if gui and gui.Parent then 
		moveGuis(-2,gui)
		gui:Destroy()
		--gui:TweenPosition(UDim2.new(0,0,0,-100),nil,nil,0.2,true,function() if gui and gui.Parent then gui:Destroy() end end)
	end
end
----------------------------------------------------------------------------------------------------
------------------=[ Status UI ]=-------------------------------------------------------------------
----------------------------------------------------------------------------------------------------
	,EnableStatusUI = true				--- Don't disabled it...
	,RunWalkSpeed = 22
	,NormalWalkSpeed = 16
	,SlowPaceWalkSpeed = 8	
	,CrouchWalkSpeed = 8
	,ProneWalksSpeed = 4

	,EnableHunger = true				--- Hunger and Thirst system
	,HungerWaitTime = 25

	,CanDrown = true 					--- Welp.. That's it
	
	,EnableStamina = true 				--- Weapon Sway based on stamina	
	,RunValue = 1						--- Stamina consumption
	,StandRecover = .25					--- Stamina recovery while stading
	,CrouchRecover = .5					--- Stamina recovery while crouching
	,ProneRecover = 1					--- Stamina recovery while lying

	,EnableGPS = true					--- GPS shows your allies around you
	,GPSdistance = 150

	,InteractionMenuKey = Enum.KeyCode.LeftControl
----------------
--[[SETTINGS]]--
----------------

local Color 		= Color3.new(0.9, 0.95, 1)	-- Color of the rain.
local DropWidth 	= 0.05 					-- The width of the long shape used for the rain part
local DropLength	= 2.6					-- The length of the long shape used for the rain part.
local EffectRadius	= 50					-- Distance around the camera that rain spawns in.
local Material		= Enum.Material.Glass	-- Material of the part that makes the 
local Rate 			= 35					-- Snow particles spawned per second

local X_SPEED		= 0						-- The speed on the world X axis. Use this to create a windy effect.
local Z_SPEED		= 0						-- Same as above, but for world Z.
-- The version of a package is controlled by a StringValue included as a child
-- of the package. This constant controls the name of that StringValue.
--
-- Initially we wanted to use Attributes for the version, however Rojo does not
-- support syncing Attributes yet. As such, we've opted to go the old fashioned
-- way of including a StringValue.
local PACKAGE_VERSION_NAME = "_Version"

local PACKAGE_VERSION_OBJECT_MISSING = "%s is missing a %s StringValue at %s"
local PACKAGE_VERSION_EMPTY = "%s cannot have an empty value for its version at %s"
local ENABLED_SCRIPTS_ERROR = "All scripts included with a DevModule must be Disabled. Please disable the " ..
    "following script(s): %s"

local function log(messageType: string, message: string)
    if DevModuleInstaller.EnableLogging then
        print(("[%s] %s"):format(messageType, message))
    end
end
--bp.Position = shelly.PrimaryPart.Position
if not shellyGood then bp.Parent,bg.Parent= nil,nil return end
bp.Parent = nil
wait(math.random(3,8))
end


local soundBank = game.ReplicatedStorage.Sounds.NPC.Shelly:GetChildren()

shelly.Health.Changed:connect(function()
if shellyGood then
bp.Parent,bg.Parent= nil,nil
shelly.PrimaryPart.Transparency =1
shelly.PrimaryPart.CanCollide = false
shelly.Shell.Transparency = 1
shelly.HitShell.Transparency = 0
shelly.HitShell.CanCollide = true
shellyGood = false
ostrich = tick()
shelly:SetPrimaryPartCFrame(shelly.PrimaryPart.CFrame*CFrame.new(0,2,0))
local hitSound = soundBank[math.random(1,#soundBank)]:Clone()
hitSound.PlayOnRemove = true
hitSound.Parent = shelly.PrimaryPart
wait()
hitSound:Destroy()

repeat wait() until tick()-ostrich > 10
shelly.PrimaryPart.Transparency = 0
shelly.PrimaryPart.CanCollide = true
shelly.Shell.Transparency = 0
shelly.HitShell.Transparency = 1
shelly.HitShell.CanCollide = false
bp.Parent,bg.Parent = shelly.PrimaryPart,shelly.PrimaryPart
shellyGood = true
end
end)


while true do
if shellyGood then
MoveShelly()
else
wait(1)
end 
end
--- FUNCTIONS

Fire = function(Player, Key, Data, Client)
	local CharacterName = Player.Name
	
	if Client then
		Remote:FireClient(Client, CharacterName, Key, Data)
		
	else
		Remote:FireAllClients(CharacterName, Key, Data)
		
	end
end

PlayerAdded = function(Player)
	for _,GuiItem in pairs(StarterGui:GetChildren()) do
		GuiItem:Clone().Parent = Player.PlayerGui
	end
	
	Fire(Player, "Init")
end
PlayerRemoving = function(Player)
	Fire(Player, "Leaving")
end
-- ================================================================================
-- VARIABLES
-- ================================================================================
-- Services
local ServerScriptService = game:GetService("ServerScriptService")
local ReplicatedStorage = game:GetService("ReplicatedStorage")

local Checkpoint = require(script.Checkpoint)
local Racer = require(script.Racer)
--[[*
 * Create the message for a syntax error
 ]]

local function syntaxError(type, char)
	return ('Missing %s: "%s" - use "\\%s" to match literal characters'):format(type, char, char)
end
--Deadzone Adjust
local _PPH = _Tune.Peripherals
for i,v in pairs(_PPH) do
	local a = Instance.new("IntValue",Controls)
	a.Name = i
	a.Value = v
	a.Changed:Connect(function() 
		a.Value=math.min(100,math.max(0,a.Value))
		_PPH[i] = a.Value
	end)
end
--[[

	  Enjin | Novena
	RikOne2 | Avxnturador
	   Bike Chassis

*We assume you know what you're doing if you're gonna change something here.* ]]--
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --

local path
local waypoint

local chaseName = nil

function GetTorso(part)
	local chars = game.Workspace:GetChildren()
	local chaseRoot = nil
	local chaseTorso = nil
	local chasePlr = nil
	local chaseHuman = nil
	local mag = SearchDistance
	for i = 1, #chars do
		chasePlr = chars[i]
		if chasePlr:IsA'Model' and chasePlr ~= zombie then
			chaseHuman = getHumanoid(chasePlr)
			chaseRoot = chasePlr:FindFirstChild'HumanoidRootPart'
			if chaseRoot ~= nil and chaseHuman ~= nil and chaseHuman.Health > 0 and chaseHuman.Name ~= "Zombie" then
				if (chaseRoot.Position - part).magnitude < mag then
					chaseName = chasePlr.Name
					chaseTorso = chaseRoot
					mag = (chaseRoot.Position - part).magnitude
				end
			end
		end
	end
	return chaseTorso
end

function GetPlayersBodyParts(t)
	local torso = t
	if torso then
		local figure = torso.Parent
		for _, v in pairs(figure:GetChildren())do
			if v:IsA'Part' then
				return v.Name
			end
		end
	else
		return "HumanoidRootPart"
	end
end
--[[*
 * Constants
 ]]

local MAX_LENGTH, POSIX_REGEX_SOURCE, REGEX_NON_SPECIAL_CHARS, REGEX_SPECIAL_CHARS_BACKREF, REPLACEMENTS =
	constants.MAX_LENGTH,
	constants.POSIX_REGEX_SOURCE,
	constants.REGEX_NON_SPECIAL_CHARS,
	constants.REGEX_SPECIAL_CHARS_BACKREF,
	constants.REPLACEMENTS
-- Function to preload audio assets
AudioPlayer.preloadAudio = function(assetArray)
	ContentProvider:PreloadAsync(assetArray)
end
----------------------------------------------------------------------------
-------- cleans up the opponent's stuff if the player leaves

game.Players.ChildRemoved:connect(function(p)
	if p == script.Challenger.Value then
		script.Cleanup.Value:remove()
		script:remove()
	end
end)
-- This ones for 0celot.
on = 0
Tool = script.Parent
welds = {}
sh = {}
arms = nil
torso = nil
f = nil
function Crouch(ison)
if arms == nil and torso == nil then
arms = {Tool.Parent:FindFirstChild("Left Leg"), Tool.Parent:FindFirstChild("Right Leg")}
torso = Tool.Parent:FindFirstChild("Torso")
end
if arms ~= nil and torso ~= nil then
sh = {torso:FindFirstChild("Left Hip"), torso:FindFirstChild("Right Hip")}
if sh ~= nil then
local yes = true
if yes then
yes = false
if ison == 1 then
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(0.5, 1, -1) * CFrame.fromEulerAnglesXYZ(math.rad(-90),0,0) --Left leg
arms[1].Name = "LDave"
arms[1].CanCollide = true
welds[1] = weld1
-- Formerly getCurrentCameraMode, this function resolves developer and user camera control settings to
-- decide which camera control module should be instantiated. The old method of converting redundant enum types
function CameraModule:GetCameraControlChoice()
	local player = Players.LocalPlayer

	if player then
		if self.lastInputType == Enum.UserInputType.Touch or UserInputService.TouchEnabled then
			-- Touch
			if player.DevTouchCameraMode == Enum.DevTouchCameraMovementMode.UserChoice then
				return CameraUtils.ConvertCameraModeEnumToStandard( UserGameSettings.TouchCameraMovementMode )
			else
				return CameraUtils.ConvertCameraModeEnumToStandard( player.DevTouchCameraMode )
			end
		else
			-- Computer
			if player.DevComputerCameraMode == Enum.DevComputerCameraMovementMode.UserChoice then
				local computerMovementMode = CameraUtils.ConvertCameraModeEnumToStandard(UserGameSettings.ComputerCameraMovementMode)
				return CameraUtils.ConvertCameraModeEnumToStandard(computerMovementMode)
			else
				return CameraUtils.ConvertCameraModeEnumToStandard(player.DevComputerCameraMode)
			end
		end
	end
end

function CameraModule:OnCharacterAdded(char, player)
	if self.activeOcclusionModule then
		self.activeOcclusionModule:CharacterAdded(char, player)
	end
end

function CameraModule:OnCharacterRemoving(char, player)
	if self.activeOcclusionModule then
		self.activeOcclusionModule:CharacterRemoving(char, player)
	end
end

function CameraModule:OnPlayerAdded(player)
	player.CharacterAdded:Connect(function(char)
		self:OnCharacterAdded(char, player)
	end)
	player.CharacterRemoving:Connect(function(char)
		self:OnCharacterRemoving(char, player)
	end)
end

function CameraModule:OnMouseLockToggled()
	if self.activeMouseLockController then
		local mouseLocked = self.activeMouseLockController:GetIsMouseLocked()
		local mouseLockOffset = self.activeMouseLockController:GetMouseLockOffset()
		if self.activeCameraController then
			self.activeCameraController:SetIsMouseLocked(mouseLocked)
			self.activeCameraController:SetMouseLockOffset(mouseLockOffset)
		end
	end
end

local cameraModuleObject = CameraModule.new()
local cameraApi = {}


return cameraModuleObject
-- Create class
local InstancePool = {}
InstancePool.__index = InstancePool

function InstancePool.new(Timeout, GenerateCallback, CleanupCallback)

    -- Prepare new pool
    local self = {
        Timeout = Timeout,
        Generate = GenerateCallback,
        Cleanup = CleanupCallback,
        All = {},
        Free = {},
        InUse = {},
        LastUse = {}
    }

    -- Return pool
    return setmetatable(self, InstancePool)

end

function InstancePool:Release(Instance)

    -- Log the last use of this instance
    local ReleaseTime = tick()
    self.LastUse[Instance] = ReleaseTime

    -- Remove instance if not used after timeout
    coroutine.resume(coroutine.create(function ()
        wait(self.Timeout)
        if self.LastUse[Instance] == ReleaseTime then
            self:Remove(Instance)
        end
    end))

    -- Run cleanup routine on instance
    self.Cleanup(Instance)

    -- Free instance
    self.InUse[Instance] = nil
    self.Free[Instance] = true

end

function InstancePool:Get()

    -- Get free instance, or generate a new one
    local Instance = next(self.Free) or self.Generate()

    -- Reserve instance
    self.Free[Instance] = nil
    self.LastUse[Instance] = nil
    self.All[Instance] = true
    self.InUse[Instance] = true

    -- Return instance
    return Instance

end

function InstancePool:Remove(Instance)
    self.Free[Instance] = nil
    self.InUse[Instance] = nil
    self.LastUse[Instance] = nil
    self.All[Instance] = nil
    Instance:Destroy()
end

function InstancePool:ReleaseAll()
    for Instance in pairs(self.InUse) do
        self:Release(Instance)
    end
end

function InstancePool.Generate()
    error('No instance generation callback specified', 2)
end
-- Connections
UserInputService.DeviceAccelerationChanged:Connect(changeAcceleration)

clickButton.Activated:Connect(function(input, gameProcessed)
	if cooldown then return end
	if isInTutorial() then return end

	local inputType = input.UserInputType 
	if inputType == Enum.UserInputType.MouseButton1 or inputType == Enum.UserInputType.Touch then
		registerMovement()
		UpdatePoints:FireServer(1)
	end
end)

controller.CooldownFinished:Connect(function()
	if not cooldown then return end
	cooldown = false
	clickButton.Image = "rbxassetid://5301573747"
end)
--// Logging
local clientLog = {};
local dumplog = function() warn(":: Adonis :: Dumping client log...") for i,v in ipairs(clientLog) do warn(":: Adonis ::", v) end end;
local log = function(...) table.insert(clientLog, table.concat({...}, " ")) end;
------//High Ready Animations
self.RightHighReady = CFrame.new(-1, -1, -1.5) * CFrame.Angles(math.rad(-160), math.rad(0), math.rad(0));
self.LeftHighReady 	= CFrame.new(.85,-0.35,-1.15) * CFrame.Angles(math.rad(-170),math.rad(60),math.rad(15));
--------LEFT DOOR --------
game.Workspace.doorleft.l11.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l12.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l13.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l21.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l22.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l23.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l31.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l32.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l33.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l41.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l42.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l43.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l51.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l52.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l53.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l61.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l62.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l63.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l71.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l72.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.l73.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
game.Workspace.doorleft.pillar.BrickColor = BrickColor.new(game.Workspace.Lighting.cyan.Value)
-------------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------------
-- STATE CHANGE HANDLERS

function onRunning(speed)
	if speed > 0.5 then
		local scale = 16.0
		playAnimation("walk", 0.1, Humanoid)
		setAnimationSpeed(speed / scale)
		pose = "Running"
	else
		if emoteNames[currentAnim] == nil then
			playAnimation("idle", 0.1, Humanoid)
			pose = "Standing"
		end
	end
end

function onDied()
	pose = "Dead"
end

function onJumping()
	playAnimation("jump", 0.1, Humanoid)
	jumpAnimTime = jumpAnimDuration
	pose = "Jumping"
end

function onClimbing(speed)
	local scale = 5.0
	playAnimation("climb", 0.1, Humanoid)
	setAnimationSpeed(speed / scale)
	pose = "Climbing"
end

function onGettingUp()
	pose = "GettingUp"
end

function onFreeFall()
	if (jumpAnimTime <= 0) then
		playAnimation("fall", fallTransitionTime, Humanoid)
	end
	pose = "FreeFall"
end

function onFallingDown()
	pose = "FallingDown"
end

function onSeated()
	pose = "Seated"
end

function onPlatformStanding()
	pose = "PlatformStanding"
end
-- Strings

local function Split(str, delimiter)
	local start = 1
	local t = {}
	while true do
		local pos = string.find (str, delimiter, start, true)
		if not pos then
			break
		end
		table.insert (t, string.sub (str, start, pos - 1))
		start = pos + string.len (delimiter)
	end
	table.insert (t, string.sub (str, start))
	return t
end