Roblox/luau_corpus huggingface dataset:
------------------------------------------------------------------------------------------------------------------------------------------------------
--  Events
------------------------------------------------------------------------------------------------------------------------------------------------------

UserInputService.InputBegan:connect(function(Input)
	if Input.KeyCode == Enum.KeyCode.S then
		CurrentPath = nil
		MouseHolding = false
		if PathingThread then coroutine.yield(PathingThread) end 
		
		LocalCharacter:WaitForChild('Humanoid'):MoveTo(LocalCharacter.HumanoidRootPart.Position)
	end
end)

LocalMouse.Button2Down:connect(function()
	MouseHolding = true

	repeat --wait(0.05)
		if PathingThread then coroutine.yield(PathingThread) end 

		PathingThread = coroutine.resume(coroutine.create(function()
			CreatePath()
		end))
		
		print(1)
		wait(0.05)
	until MouseHolding == false or CurrentPath == nil
end)

LocalMouse.Button2Up:connect(function()
  MouseHolding = false
end)
--// Ammo Settings			
	Ammo = 0;
	StoredAmmo = 0;
	MagCount = 0; --  If you want infinate ammo, set to math.huge EX. MagCount = math.huge;
	ExplosiveAmmo = math.huge;
-- Initialize the tool
local MoveTool = {
	Name = 'Move Tool';
	Color = BrickColor.new 'Deep orange';

	-- Default options
	Increment = 1;
	Axes = 'Global';

	-- Selection state
	InitialState = nil;
	InitialFocusCFrame = nil;
	InitialExtentsSize = nil;
	InitialExtentsCFrame = nil;

	-- Snapping state
	SnappedPoint = nil;
	PointSnapped = Signal.new();

	-- Resource maid
	Maid = Maid.new();

	-- Signals
	DragChanged = Signal.new();
	AxesChanged = Signal.new();
}

MoveTool.ManualText = [[<font face="GothamBlack" size="16">Move Tool  🛠</font>
Allows you to move parts.<font size="12"><br /></font>
<font size="12" color="rgb(150, 150, 150)"><b>Axes</b></font>
This option lets you choose in which direction to move each part.<font size="6"><br /></font>
 <font color="rgb(150, 150, 150)">•</font>  <b>GLOBAL</b> <font color="rgb(150, 150, 150)">—</font> Relative to the <b>world</b>
 <font color="rgb(150, 150, 150)">•</font>  <b>LOCAL</b> <font color="rgb(150, 150, 150)">—</font> Relative to each <b>individual part</b>
 <font color="rgb(150, 150, 150)">•</font>  <b>LAST</b> <font color="rgb(150, 150, 150)">—</font> Relative to the <b>last part clicked</b><font size="6"><br /></font>

<b>TIP:</b> Click on any part to focus the handles on it.<font size="6"><br /></font>
<b>TIP: </b>Hit the <b>Enter</b> key to switch between Axes modes quickly.<font size="12"><br /></font>

<font size="12" color="rgb(150, 150, 150)"><b>Increment</b></font>
Lets you choose how many studs to move parts by.<font size="6"><br /></font>

<b>TIP: </b>Hit the – key to quickly type increments.<font size="6"><br /></font>

<b>TIP: </b>Use your number pad to move exactly by the current increment. Holding <b>Shift</b> reverses the increment.<font size="4"><br /></font>
   <font color="rgb(150, 150, 150)">•</font>  8 & 2 — up & down
   <font color="rgb(150, 150, 150)">•</font>  1 & 9 — back & forth
   <font color="rgb(150, 150, 150)">•</font>  4 & 6 — left & right<font size="12"><br /></font>

<font size="12" color="rgb(150, 150, 150)"><b>Snapping</b></font>
You can place parts perfectly together by holding the <b><i>R</i></b> key, and dragging parts by their <b>snap points</b>.<font size="12"><br /></font>

<font size="12" color="rgb(150, 150, 150)"><b>Alignment</b></font>
Press <b><i>T</i></b> while dragging to <b>align</b> the bottom surface of your base part to the current target surface.
]]
--Runtime Loop
-- ~60 c/s
game["Run Service"].Stepped:connect(function()
	--Steering
	Steering()

	--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)
-------------------------
function onClicked()
R.Function1.Disabled = false
R.loop.Disabled = true
R.BrickColor = BrickColor.new("CGA brown")
R.Function2.Disabled = true

end
script.Parent.ClickDetector.MouseClick:connect(onClicked)
-- declarations
local Figure = script.Parent
local Head = Figure:WaitForChild("Head")
local Humanoid;
for _,Child in pairs(Figure:GetChildren())do
if Child and Child.ClassName=="Humanoid"then
Humanoid=Child;
end;
end;
local regening = false
--Light off
	src.left.Value.Value = 0
	light.Value = false
	else
	src.left.Value.Value = 1
	light.Value = true
	return
	end
end
end)
src.Parent.ChildRemoved:connect(function(child)
	if child.Name=="SeatWeld" then 
		src:Stop()
		script.Parent:Destroy()
	end
end)
-- Libraries
Security = require(Tool.Core.Security);
RegionModule = require(Tool.Libraries.Region);
Support = require(Tool.Libraries.SupportLibrary);
Serialization = require(Tool.Libraries.SerializationV3);
--local HighLight = char:WaitForChild("PLayerHighLight")
function deathCheck(health)
	if health <= 0 and dead == false then
		dead = true
		char.HumanoidRootPart.Anchored = true
		deathAnim:Play()
		wait(2.5)
		hum.BreakJointsOnDeath = true
		wait(0.5)
		char.HumanoidRootPart.Anchored = false
	
		script:Destroy()
	end
end

hum.HealthChanged:Connect(deathCheck)
-- MUSIC/SOUNDS
if Configuration.PrintingEnabled == false then

else
	print("DOORS 👁️ Sound Pack: Installing Musics/Ambiences Sounds...")
end

if Configuration.SoundsInSoundService == true then
	Folder = game.SoundService
end

if Configuration.MusicLobbyEnabled == false then
	Folder.Music.Lobby:Destroy()
end

if Configuration.GuidingLightMusicEnabled == false then
	Folder.Music["Guiding Light"]:Destroy()
end

if Configuration.EndingMusicEnabled == false then
	Folder.Music.Ending:Destroy()
end

if Configuration.ElevatorJamMusicEnabled == false then
	Folder.Music["Elevator Jam"]:Destroy()
end

if Configuration.UnhingedMusicEnabled == false then
	Folder.Music.Unhinged:Destroy()
end

if Configuration.AmbienceSoundEnabled == false then
	Folder.Ambience.Ambience:Destroy()
end
--------SETTINGS--------
local ITEM_NAME = "Pistol"
local ITEM_PRICE = 10
local CURRENCY_NAME = "Cash"
--Check if new player is admin		
	for v,numberObject in pairs(Administrators:GetChildren()) do
		if numberObject.Value == player.userId then
wait()
-- Decompiled with the Synapse X Luau decompiler.

local v1 = require(game.ReplicatedStorage:WaitForChild("Resources"));
while not v1.Loaded do
	game:GetService("RunService").Heartbeat:Wait();
end;
local l__StarterPlayer__2 = v1.StarterPlayer;
local l__CollectionService__3 = v1.CollectionService;
local l__Hoverboards__1 = v1.Directory.Hoverboards;
local u2 = nil;
function Create(p1)
	local l____HOVERBOARD__4 = v1.PlayerModule.Get("Character", p1):FindFirstChild("__HOVERBOARD");
	if l____HOVERBOARD__4 then
		l____HOVERBOARD__4:Destroy();
	end;
	local v5 = v1.StatService.Get(p1);
	if v5 then
		if not v5.Hoverboard then
			return;
		end;
	else
		return;
	end;
	local v6 = l__Hoverboards__1[v5.Hoverboard];
	if not v6 then
		return;
	end;
	local v7 = v1.PlayerModule.Get("Humanoid");
	local v8 = v1.PlayerModule.Get("RootPart");
	if v7 then
		if v8 then
			u2 = v7.HipHeight;
			v8.CFrame = v8.CFrame + Vector3.new(0, v7.HipHeight - v6.HipHeight, 0);
			v7.HipHeight = v6.HipHeight;
			v7.AutoJumpEnabled = false;
		end;
	end;
end;
local l__LocalPlayer__3 = v1.LocalPlayer;
function Remove(p2)
	local v9 = v1.PlayerModule.Get("Humanoid");
	local v10 = v1.PlayerModule.Get("RootPart");
	if v9 then
		if v10 then
			if p2 == l__LocalPlayer__3 then
				v10.Velocity = Vector3.new();
			end;
			if u2 then
				v9.HipHeight = u2;
				u2 = nil;
			end;
			v9.AutoJumpEnabled = true;
		end;
	end;
end;
function UpdatePlayer(p3, p4)
	local v11 = v1.PlayerModule.Get("Character", p3);
	if p4 then
		if not v11:FindFirstChild("__HOVERBOARD") then
			return Create(p3);
		end;
	end;
	if not p4 then
		if v11:FindFirstChild("__HOVERBOARD") then
			Remove(p3);
		end;
	end;
end;
function Toggle()
	v1.Variables.UsingHoverboard = not v1.Variables.UsingHoverboard;
	if not v1.Variables.UsingHoverboard then
		Remove(l__LocalPlayer__3);
	else
		Create(l__LocalPlayer__3);
	end;
	v1.Network.Fire("Update Hoverboard State", v1.Variables.UsingHoverboard);
end;
l__CollectionService__3:GetInstanceAddedSignal("UsingHoverboard"):Connect(function(p5)
	UpdatePlayer(p5, true);
end);
l__CollectionService__3:GetInstanceRemovedSignal("UsingHoverboard"):Connect(function(p6)
	UpdatePlayer(p6, false);
end);
task.defer(function()
	while v1.Variables.LoadingWorld do
		v1.Heartbeat();	
	end;
	for v12, v13 in ipairs((l__CollectionService__3:GetTagged("UsingHoverboard"))) do
		coroutine.wrap(UpdatePlayer)(v13, true);	
	end;
end);
v1.Signal.Fired("Stat Changed"):Connect(function(p7)

end);
v1.Signal.Fired("Changed Platform"):Connect(function()

end);
v1.Signal.Fired("World Changed"):Connect(function()
	if v1.Variables.UsingHoverboard then
		Toggle();
	end;
end);
--

local GJK = require(script:WaitForChild("GJK"))
local Supports = require(script:WaitForChild("Supports"))
local Vertices = require(script:WaitForChild("Vertices"))
-- declarations

local sGettingUp = newSound("rbxasset://sounds/action_get_up.mp3")
local sDied = newSound("rbxasset://sounds/uuhhh.mp3") 
local sFreeFalling = newSound("rbxasset://sounds/action_falling.mp3")
local sJumping = newSound("rbxasset://sounds/action_jump.mp3")
local sLanding = newSound("rbxasset://sounds/action_jump_land.mp3")
local sSplash = newSound("rbxasset://sounds/impact_water.mp3")
local sRunning = newSound("rbxasset://sounds/action_footsteps_plastic.mp3")
sRunning.Looped = true
local sSwimming = newSound("rbxasset://sounds/action_swim.mp3")
sSwimming.Looped = true
local sClimbing = newSound("rbxasset://sounds/action_footsteps_plastic.mp3")
sClimbing.Looped = true

local Figure = script.Parent
local Head = waitForChild(Figure, "Head")
local Humanoid = waitForChild(Figure, "Humanoid")

local prevState = "None"
--[[Wheel Configuration]]	
	
	--Store Reference Orientation Function
	function getParts(model,t,a)
		for i,v in pairs(model:GetChildren()) do
			if v:IsA("BasePart") then table.insert(t,{v,a.CFrame:toObjectSpace(v.CFrame)})
			elseif v:IsA("Model") then getParts(v,t,a)
			end
		end
	end
	
	--PGS/Legacy
	local fDensity = _Tune.FWheelDensity
	local rDensity = _Tune.RWheelDensity
	if not PGS_ON then
		fDensity = _Tune.FWLgcyDensity
		rDensity = _Tune.RWLgcyDensity
	end
	
	for _,v in pairs(Drive) do
		--Apply Wheel Density
		if v.Name=="FL" or v.Name=="FR" or v.Name=="F" then
			if v:IsA("BasePart") then
				if v.CustomPhysicalProperties == nil then v.CustomPhysicalProperties = PhysicalProperties.new(v.Material) end
				v.CustomPhysicalProperties = PhysicalProperties.new(
					fDensity,
					v.CustomPhysicalProperties.Friction,
					v.CustomPhysicalProperties.Elasticity,
					v.CustomPhysicalProperties.FrictionWeight,
					v.CustomPhysicalProperties.ElasticityWeight
				)
			end
		else
			if v:IsA("BasePart") then
				if v.CustomPhysicalProperties == nil then v.CustomPhysicalProperties = PhysicalProperties.new(v.Material) end
				v.CustomPhysicalProperties = PhysicalProperties.new(
					rDensity,
					v.CustomPhysicalProperties.Friction,
					v.CustomPhysicalProperties.Elasticity,
					v.CustomPhysicalProperties.FrictionWeight,
					v.CustomPhysicalProperties.ElasticityWeight
				)
			end		
		end
		
		--Resurface Wheels
		for _,a in pairs({"Top","Bottom","Left","Right","Front","Back"}) do
			v[a.."Surface"]=Enum.SurfaceType.SmoothNoOutlines
		end
		
		--Store Axle-Anchored/Suspension-Anchored Part Orientation
		local WParts = {}
		
		local tPos = v.Position-car.DriveSeat.Position
		if v.Name=="FL" or v.Name=="RL" then
			v.CFrame = car.DriveSeat.CFrame*CFrame.Angles(math.rad(90),0,math.rad(90))
		else
			v.CFrame = car.DriveSeat.CFrame*CFrame.Angles(math.rad(90),0,math.rad(-90))
		end
		v.CFrame = v.CFrame+tPos
		
		if v:FindFirstChild("Parts")~=nil then
			getParts(v.Parts,WParts,v)
		end
		if v:FindFirstChild("Fixed")~=nil then
			getParts(v.Fixed,WParts,v)
		end
		
		--Align Wheels
		if v.Name=="FL" or v.Name=="FR" then
			v.CFrame = v.CFrame*CFrame.Angles(math.rad(_Tune.FCamber),0,0)
			if v.Name=="FL" then
				v.CFrame = v.CFrame*CFrame.Angles(0,0,math.rad(_Tune.FToe))
			else
				v.CFrame = v.CFrame*CFrame.Angles(0,0,math.rad(-_Tune.FToe))
			end
		elseif v.Name=="RL" or v.Name=="RR" then
			v.CFrame = v.CFrame*CFrame.Angles(math.rad(_Tune.RCamber),0,0)
			if v.Name=="RL" then
				v.CFrame = v.CFrame*CFrame.Angles(0,0,math.rad(_Tune.RToe))
			else
				v.CFrame = v.CFrame*CFrame.Angles(0,0,math.rad(-_Tune.RToe))
			end
		end
		
		--Re-orient Axle-Anchored/Suspension-Anchored Parts
		for _,a in pairs(WParts) do
			a[1].CFrame=v.CFrame:toWorldSpace(a[2])
		end
--[[**
	ensures Roblox BrickColor type

	@param value The value to check against

	@returns True iff the condition is satisfied, false otherwise
**--]]
t.BrickColor = t.typeof("BrickColor")
--------------------------CHARACTER CONTROL-------------------------------
local CurrentIgnoreList
local CurrentIgnoreTag = nil

local TaggedInstanceAddedConnection = nil
local TaggedInstanceRemovedConnection = nil

local function GetCharacter()
	return Player and Player.Character
end

local function UpdateIgnoreTag(newIgnoreTag)
	if newIgnoreTag == CurrentIgnoreTag then
		return
	end
	if TaggedInstanceAddedConnection then
		TaggedInstanceAddedConnection:Disconnect()
		TaggedInstanceAddedConnection = nil
	end
	if TaggedInstanceRemovedConnection then
		TaggedInstanceRemovedConnection:Disconnect()
		TaggedInstanceRemovedConnection = nil
	end
	CurrentIgnoreTag = newIgnoreTag
	CurrentIgnoreList = {GetCharacter()}
	if CurrentIgnoreTag ~= nil then
		local ignoreParts = CollectionService:GetTagged(CurrentIgnoreTag)
		for _, ignorePart in ipairs(ignoreParts) do
			table.insert(CurrentIgnoreList, ignorePart)
		end
		TaggedInstanceAddedConnection = CollectionService:GetInstanceAddedSignal(
			CurrentIgnoreTag):Connect(function(ignorePart)
			table.insert(CurrentIgnoreList, ignorePart)
		end)
		TaggedInstanceRemovedConnection = CollectionService:GetInstanceRemovedSignal(
			CurrentIgnoreTag):Connect(function(ignorePart)
			for i = 1, #CurrentIgnoreList do
				if CurrentIgnoreList[i] == ignorePart then
					CurrentIgnoreList[i] = CurrentIgnoreList[#CurrentIgnoreList]
					table.remove(CurrentIgnoreList)
					break
				end
			end
		end)
	end
end

local function getIgnoreList()
	if CurrentIgnoreList then
		return CurrentIgnoreList
	end
	CurrentIgnoreList = {}
	table.insert(CurrentIgnoreList, GetCharacter())
	return CurrentIgnoreList
end

local function minV(a, b)
	return Vector3.new(math.min(a.X, b.X), math.min(a.Y, b.Y), math.min(a.Z, b.Z))
end
local function maxV(a, b)
	return Vector3.new(math.max(a.X, b.X), math.max(a.Y, b.Y), math.max(a.Z, b.Z))
end
local function getCollidableExtentsSize(character)
	if character == nil or character.PrimaryPart == nil then return end
	local toLocalCFrame = character.PrimaryPart.CFrame:inverse()
	local min = Vector3.new(math.huge, math.huge, math.huge)
	local max = Vector3.new(-math.huge, -math.huge, -math.huge)
	for _,descendant in pairs(character:GetDescendants()) do
		if descendant:IsA('BasePart') and descendant.CanCollide then
			local localCFrame = toLocalCFrame * descendant.CFrame
			local size = Vector3.new(descendant.Size.X / 2, descendant.Size.Y / 2, descendant.Size.Z / 2)
			local vertices = {
				Vector3.new( size.X,  size.Y,  size.Z),
				Vector3.new( size.X,  size.Y, -size.Z),
				Vector3.new( size.X, -size.Y,  size.Z),
				Vector3.new( size.X, -size.Y, -size.Z),
				Vector3.new(-size.X,  size.Y,  size.Z),
				Vector3.new(-size.X,  size.Y, -size.Z),
				Vector3.new(-size.X, -size.Y,  size.Z),
				Vector3.new(-size.X, -size.Y, -size.Z)
			}
			for _,vertex in ipairs(vertices) do
				local v = localCFrame * vertex
				min = minV(min, v)
				max = maxV(max, v)
			end
		end
	end
	local r = max - min
	if r.X < 0 or r.Y < 0 or r.Z < 0 then return nil end
	return r
end
--[[*
 * This class is a perf optimization for sorting the list of currently
 * running tests. It tries to keep tests in the same positions without
 * shifting the whole list.
 ]]
type CurrentTestList = {
	add: (self: CurrentTestList, testPath: Config_Path, config: Config_ProjectConfig) -> (),
	delete: (self: CurrentTestList, testPath: Config_Path) -> (),
	get: (self: CurrentTestList) -> Array<{
		testPath: Config_Path,
		config: Config_ProjectConfig,
	}>,
}

local CurrentTestList = {}
CurrentTestList.__index = CurrentTestList

function CurrentTestList.new(): CurrentTestList
	local self = setmetatable({}, CurrentTestList)
	self._array = {}
	return (self :: any) :: CurrentTestList
end

function CurrentTestList:add(testPath: Config_Path, config: Config_ProjectConfig): ()
	local index = Array.indexOf(self._array, nil)
	local record = { config = config, testPath = testPath }
	if index ~= -1 then
		self._array[index] = record
	else
		table.insert(self._array, record)
	end
end

function CurrentTestList:delete(testPath: Config_Path): ()
	local record = Array.find(self._array, function(record)
		return record ~= nil and record.testPath == testPath
	end)
	self._array[Array.indexOf(self._array, Boolean.toJSBoolean(record) and record or nil)] = nil
end

function CurrentTestList:get(): Array<{
	testPath: Config_Path,
	config: Config_ProjectConfig,
}>
	return self._array
end

type Cache = {
	content: string,
	clear: string,
}
--[[
    A utility script that generates readable dates
]]
local ReadableDate = {}

local DEFAULT_FORMAT = "$hour:$sec $day/$month/$year"
-- float rd_flt_be(string src, int s)
-- @src - Source binary string
-- @s - Start index of big endian float
local function rd_flt_be(src, s)
	local f1, f2, f3, f4 = string.byte(src, s, s + 3)
	return rd_flt_basic(f4, f3, f2, f1)
end
--samy22
d = false
function onTouched(hit)
if d == false then
h = hit.Parent:findFirstChild("Torso")
if (h~=nil) then 
d = true
gg = math.random(1,20)
if gg == 4 then
h.CFrame = h.CFrame * CFrame.Angles(0,0,math.rad(100))
end
if script.dmg.Value == true then
hum = h.Parent:findFirstChild("Humanoid")
if hum then
hum.Health = hum.Health - 25
end
end
wait(1.5)
d = false
end
end 
end
script.Parent.Parent.Touched:connect(onTouched)

while true do
bt = script.Parent
ppp = bt.Parent:GetMass()
wait(.25)
bt.force = Vector3.new(0,0,500*ppp*script.mag.Value)
wait(.25)
bt.force = Vector3.new(0,0,-500*ppp*script.mag.Value)
end
--]]


function getHumanoid(model)
	for _, v in pairs(model:GetChildren()) do
		if v:IsA'Humanoid' then
			return v
		end
	end
end


local ai = script.Parent
local human = getHumanoid(ai)
local hroot = ai.HumanoidRootPart
local zspeed = hroot.Velocity.magnitude


local pfs = game:GetService("PathfindingService")

function GetPlayerNames()
	local players = game:GetService('Players'):GetChildren()
	local name = nil
	for _, v in pairs(players) do
		if v:IsA'Player' then
			name = tostring(v.Name)
		end
	end
	return name
end

spawn(function()
	while wait() do
		
	end
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

function GetTorso(part)
	local chars = game.Workspace:GetChildren()
	local torso = nil
	for _, v in pairs(chars) do
		if v:IsA'Model' and v ~= script.Parent and v.Name == GetPlayerNames() then
			local charRoot = v:FindFirstChild'HumanoidRootPart'
			if (charRoot.Position - part).magnitude < SearchDistance then
				torso = charRoot
			end
		end
	end
	return torso
end

for _, zambieparts in pairs(ai:GetChildren()) do
	if zambieparts:IsA'Part' then
		zambieparts.Touched:connect(function(p)
			if p.Parent.Name == GetPlayerNames() and p.Parent.Name ~= ai.Name then -- damage
				local enemy = p.Parent
				local enemyhuman = getHumanoid(enemy)
				enemyhuman:TakeDamage(aiDamage)
			end
		end)
	end
end
-- Ammo
plr.Character.ChildAdded:connect(function(oc)
	if (oc:IsA("Tool") or oc:IsA("HopperBin")) and oc:FindFirstChild("Ammo") and oc:FindFirstChild("AmmoLeft") then 
		--gui.Ammo.Text = oc.Ammo.Value.."/"..oc.AmmoLeft.Value
		oc.Ammo.Changed:connect(function(v)
			--gui.Ammo.Text = oc.Ammo.Value.."/"..oc.AmmoLeft.Value
			gui.Ammo.Text = ""
		end)
		oc.AmmoLeft.Changed:connect(function(v)
			--gui.Ammo.Text = oc.Ammo.Value.."/"..oc.AmmoLeft.Value
			gui.Ammo.Text = ""
		end)
	end
end)

plr.Character.ChildRemoved:connect(function(oc)
	if (oc:IsA("Tool") or oc:IsA("HopperBin")) and oc:FindFirstChild("Ammo") and oc:FindFirstChild("AmmoLeft") then 
		gui.Ammo.Text = ""
	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)
	if plrData.Money.Gold.Value > 1 then
		return true
	end
	return false
end
--[=[
	Use to test that the given GuiObject or Rect is to the right of the other GuiObject or Rect.

	The last argument is optional. If nil, the matcher will pass only if the difference **left** edge of the given GuiObject or Rect and the **right** edge of the other GuiObject or Rect is zero or positive.

	Usage:

	```lua
	expect(a).toBeRightOf(b) -- Jest
	expect(a).to.be.rightOf(b) -- TestEZ
	```

	![Example of rightOf(a, b)](/rightOf(a,%20b).png)

	```lua
	expect(a).toBeRightOf(b, 5) -- Jest
	expect(a).to.be.rightOf(b, 5) -- TestEZ
	```

	![Example of rightOf(a, b, 5)](/rightOf(a,%20b,%205).png)

	```lua
	expect(a).toBeRightOf(b, NumberRange.new(0, 5)) -- Jest
	expect(a).to.be.rightOf(b, NumberRange.new(0, 5)) -- TestEZ
	```

	![Example of rightOf(a, b, NumberRange.new(0, 5))](/rightOf(a,%20b,%20NumberRange.new(0,%205)).png)

	@tag outside
	@within CollisionMatchers2D
]=]
local function rightOf(a: GuiObject | Rect, b: GuiObject | Rect, distance: number | NumberRange)
	local aRect = toRect(a)
	local bRect = toRect(b)

	local distanceFromSide = aRect.Min - bRect.Max
	if distance then
		if typeof(distance) == "number" then
			distance = NumberRange.new(distance)
		end

		return returnValue(
			distance.Min <= distanceFromSide.X and distance.Max >= distanceFromSide.X,
			"Was within range",
			"Was not within range ( " .. tostring(distance) .. ")"
		)
	else
		return returnValue(distanceFromSide.X >= 0, "Was not left of the element", "Was to the left of the element")
	end
end

return rightOf
--[=[
	@return boolean
	Returns `true` if the option has a value.
]=]
function Option:IsSome()
	return self._s
end
--[[
	Spawns a thread with predictable timing.
]]
function Promise.spawn(callback, ...)
	local args = { ... }
	local length = select("#", ...)

	local connection
	connection = RunService.Heartbeat:Connect(function()
		connection:Disconnect()
		callback(unpack(args, 1, length))
	end)
end
--[=[
	Returns if a string starts with a postfix
	@param str string
	@param prefix string
	@return boolean
]=]
function String.startsWith(str: string, prefix: string): boolean
	return str:sub(1, #prefix) == prefix
end