Pumpkin Hub - Slap Royale [EARLY RELEASE]
Key Required

Pumpkin Hub - Slap Royale [EARLY RELEASE]

[UPDATE🏴‍☠️] Slap Battles👏GosermanGoserman 420 views 350 executesUpdated Oct 3, 2026
2.5/ 5(2 votes)
1150% Positive
Lua Script•3118 lines (62454 chars)
-- Developer note!
-- This script is made for the mode Slap Royale in the game Slap Battles.
-- Low ping is recommended because delays can cause kicks so the recommended ping is 0 to 100 if your below this you should be fine.
-- This script has features that no other current script has (when writing this) and yes they work like anti acid and auto win.
-- This script has one of the best slap auras in slap royale so you will be able to kill exploiters easy as pie.
-- Huge thank you for choosing Pumpkin Hub!

local Players=game:GetService("Players")
local LocalPlayer=Players.LocalPlayer
local Char=LocalPlayer.Character or LocalPlayer.CharacterAdded:Wait()
local ReplicatedStorage=game:GetService("ReplicatedStorage")
local ItemRemote=ReplicatedStorage.Remotes.Item
local BusJumping=ReplicatedStorage.Remotes.BusJumping
local UIS=game:GetService("UserInputService")
local Camera=workspace.CurrentCamera
local CollectionService=game:GetService("CollectionService")

local RayParams=RaycastParams.new()
RayParams.FilterDescendantsInstances={Char}
RayParams.FilterType=Enum.RaycastFilterType.Exclude

for _,player in ipairs(Players:GetPlayers()) do
	local c=player.Character or player.CharacterAdded:Wait()
	if c:FindFirstChild("HumanoidRootPart") then
		CollectionService:AddTag(c,"PumpkinPlayer")
	end
end

Players.PlayerAdded:Connect(function(plr)
	plr.CharacterAdded:Connect(function(c)
		CollectionService:AddTag(c,"PumpkinPlayer")
	end)
end)

local function ClearLine(a,b)
	local r=workspace:Raycast(a,b-a,RayParams)
	return not r
end

local function ClearFromTool(toolPos,targetPos)
	local r=workspace:Raycast(toolPos,targetPos-toolPos,RayParams)
	return not r
end

local function AvoidTools(pos)
	local newPos=pos
	for _,obj in ipairs(workspace:GetDescendants()) do
		if obj:IsA("Tool") then
			local handle=obj:FindFirstChild("Handle")
			if handle then
				local flatPos=Vector3.new(newPos.X,handle.Position.Y,newPos.Z)
				if (flatPos-handle.Position).Magnitude<3 then
					newPos=newPos+Camera.CFrame.RightVector*6
				end
			end
		end
	end
	return newPos
end

local function Ground(pos)
	local r=workspace:Raycast(pos+Vector3.new(0,40,0),Vector3.new(0,-200,0),RayParams)
	if r then
		local p=r.Position+Vector3.new(0,3,0)
		return AvoidTools(p)
	else
		return AvoidTools(pos+Vector3.new(0,3,0))
	end
end

local AutoUseList={
	["Speed Potion"]=true,
	["Potion of Strength"]=true,
	["Bull's essence"]=true,
	["Frog Potion"]=true,
	["Speed Brew"]=true,
	["Frog Brew"]=true,
	["Strength Brew"]=true,
	["Boba"]=true
}

local function PickupTool(tool)
	local id=tool:GetAttribute("ItemId")
	if id then
		ItemRemote:FireServer(id)
		local gui=tool:FindFirstChild("ItemGui")
		if gui then gui.Enabled=false end
	end
end

local function EnsureNotOnTool(target,toolPos)
	local flatTarget=Vector3.new(target.X,toolPos.Y,target.Z)
	if (flatTarget-toolPos).Magnitude<2 then
		local alt=Ground(toolPos+Camera.CFrame.RightVector*5)
		if math.abs(alt.Y-toolPos.Y)<=6 and ClearFromTool(toolPos,alt) then
			return alt
		end
		local alt2=Ground(toolPos-Camera.CFrame.RightVector*5)
		if math.abs(alt2.Y-toolPos.Y)<=6 and ClearFromTool(toolPos,alt2) then
			return alt2
		end
	end
	return target
end

local function BestSide(toolPos)
	local hrp=Char:FindFirstChild("HumanoidRootPart")
	local baseY=toolPos.Y
	if not hrp then
		local g=Vector3.new(toolPos.X,baseY+3,toolPos.Z)
		return EnsureNotOnTool(AvoidTools(g),toolPos)
	end
	local sides={
		Vector3.new(toolPos.X,baseY,toolPos.Z)+Camera.CFrame.RightVector*5,
		Vector3.new(toolPos.X,baseY,toolPos.Z)-Camera.CFrame.RightVector*5,
		Vector3.new(toolPos.X,baseY,toolPos.Z)+Camera.CFrame.LookVector*5,
		Vector3.new(toolPos.X,baseY,toolPos.Z)-Camera.CFrame.LookVector*5
	}
	local best=nil
	local bestDist=math.huge
	for _,pos in ipairs(sides) do
		local g=AvoidTools(pos)
		if math.abs(g.Y-baseY)<=2 then
			if ClearFromTool(toolPos,g) then
				local d=(g-hrp.Position).Magnitude
				if d<bestDist then
					bestDist=d
					best=g
				end
			end
		end
	end
	if best then
		return EnsureNotOnTool(best,toolPos)
	end
	local fallback=Vector3.new(toolPos.X,baseY,toolPos.Z)
	return EnsureNotOnTool(AvoidTools(fallback),toolPos)
end

local function SafeTP(tool)
	local hrp=Char:FindFirstChild("HumanoidRootPart")
	local handle=tool:FindFirstChild("Handle")
	if not hrp or not handle then return end
	local target=BestSide(handle.Position)
	target=AvoidTools(target)
	hrp.CFrame=CFrame.new(target,hrp.Position+hrp.CFrame.LookVector)
end

local function TPAndPickup(tool)
	SafeTP(tool)
	task.wait(0.1)
	PickupTool(tool)
	task.wait(0.5)
end

local Player = game.Players.LocalPlayer
local Char = Player.Character or Player.CharacterAdded:Wait()

local teleportCount = 0
local lastTransparency = 1
local ILEnabled = false
local CanCount = false

local function Ground(pos)
	local ray = Ray.new(pos, Vector3.new(0, -500, 0))
	local part, hitPos = workspace:FindPartOnRay(ray)
	return hitPos or pos
end

local function InstantLand()
	if teleportCount >= 1 then return end

	local c = Player.Character
	if not c then return end

	local hrp = c:FindFirstChild("HumanoidRootPart")
	if not hrp then return end

	local crystal = workspace:FindFirstChild("CrystalBlue", true)
	if not crystal then return end

	local target = Ground(crystal.Position)
	hrp.CFrame = CFrame.new(target, hrp.Position + hrp.CFrame.LookVector)

	teleportCount += 1
	ILEnabled = false
	CanCount = false
end

Player.CharacterAdded:Connect(function(c)
	Char = c
	teleportCount = 0
	lastTransparency = 1
	CanCount = false
end)

task.spawn(function()
	while true do
		local c = Player.Character
		if ILEnabled and teleportCount < 1 and c then
			local head = c:FindFirstChild("Head")
			if head then
				local t = head.Transparency

				if t == 1 then
					CanCount = true
				end

				if t == 0 and lastTransparency ~= 0 and CanCount then
					InstantLand()
				end

				lastTransparency = t
			else
				lastTransparency = 1
			end
		else
			lastTransparency = 1
		end

		task.wait(0.05)
	end
end)

local EBJEnabled=false
local ILEnabled=false
local RemoveZoneEnabled=false
local DeleteSeatsEnabled=false
local AutoUseEnabled=false
local GetItemsEnabled=false
local AutoPickupEnabled=false
local BombPicked=false
local PlayerESPEnabled=false
local ItemESPEnabled=false
local globalHRPSize=1
local hrpGlobalSliderUsed=false

local function ApplyHighlight(adorn)
	if adorn and adorn.Parent and not adorn.Parent:FindFirstChild("PumpkinHighlight") then
		local h=Instance.new("Highlight")
		h.Name="PumpkinHighlight"
		h.Adornee=adorn
		h.FillColor=Color3.fromRGB(255,255,0)
		h.OutlineColor=Color3.fromRGB(0,0,0)
		h.FillTransparency=0.7
		h.OutlineTransparency=0
		h.Parent=adorn.Parent
	end
end

local function CreateNameTag(char)
	if char and not char:FindFirstChild("PumpkinNameTag") then
		local hrp=char:FindFirstChild("HumanoidRootPart")
		if hrp then
			local billboard=Instance.new("BillboardGui")
			billboard.Name="PumpkinNameTag"
			billboard.Size=UDim2.new(0,150,0,40)
			billboard.Adornee=hrp
			billboard.AlwaysOnTop=true
			billboard.Parent=char
			local label=Instance.new("TextLabel")
			label.Size=UDim2.new(1,0,1,0)
			label.BackgroundTransparency=1
			label.TextScaled=true
			label.Font=Enum.Font.GothamBold
			label.TextColor3=Color3.fromRGB(0,200,255)
			label.TextStrokeTransparency=0.3
			label.TextStrokeColor3=Color3.new(0,0,0)
			label.Text=char.Name
			label.Parent=billboard
		end
	end
end

local function CreateToolTag(tool)
	if tool and tool.Parent==workspace.Items and not tool:FindFirstChild("PumpkinItemTag") then
		local handle=tool:FindFirstChild("Handle")
		if handle then
			local billboard=Instance.new("BillboardGui")
			billboard.Name="PumpkinItemTag"
			billboard.Size=UDim2.new(0,150,0,40)
			billboard.Adornee=handle
			billboard.AlwaysOnTop=true
			billboard.Parent=tool
			local label=Instance.new("TextLabel")
			label.Size=UDim2.new(1,0,1,0)
			label.BackgroundTransparency=1
			label.TextScaled=true
			label.Font=Enum.Font.GothamBold
			label.TextColor3=Color3.fromRGB(255,200,0)
			label.TextStrokeTransparency=0.3
			label.TextStrokeColor3=Color3.new(0,0,0)
			label.Text=tool.Name
			label.Parent=billboard
			ApplyHighlight(handle)
		end
	end
end

workspace.DescendantAdded:Connect(function(obj)
	if obj:IsA("Tool") and obj.Parent==workspace.Items then
		CollectionService:AddTag(obj,"PumpkinItem")
	end
	if obj:IsA("Model") and obj:FindFirstChild("HumanoidRootPart") then
		CollectionService:AddTag(obj,"PumpkinPlayer")
	end
end)

for _,tool in ipairs(workspace.Items:GetChildren()) do
	if tool:IsA("Tool") then
		CollectionService:AddTag(tool,"PumpkinItem")
	end
end

CollectionService:GetInstanceAddedSignal("PumpkinItem"):Connect(function(tool)
	if ItemESPEnabled then
		CreateToolTag(tool)
	end
end)

CollectionService:GetInstanceAddedSignal("PumpkinPlayer"):Connect(function(char)
	if PlayerESPEnabled then
		local hrp=char:FindFirstChild("HumanoidRootPart")
		if hrp then
			ApplyHighlight(hrp)
			CreateNameTag(char)
		end
	end
end)

local Rayfield=loadstring(game:HttpGet('https://sirius.menu/rayfield'))()

local Window=Rayfield:CreateWindow({
	Name="Pumpkin Hub [EARLY RELEASE]",
	LoadingTitle="Pumpkin Hub",
	LoadingSubtitle="Slap Royale",
	ConfigurationSaving={Enabled=false}
})

Rayfield:Notify({
	Title = "IMPORTANT!",
	Content = "USING THIS SCRIPT CAN RESULT IN A PERMANENT BAN USE ON OWN RISK",
	Duration = 7,
})

local CombatTab=Window:CreateTab("Combat",4483345998)
local ItemsTab=Window:CreateTab("Items",4483345998)
local ESPTab=Window:CreateTab("ESP",4483345998)
local OtherTab=Window:CreateTab("Other",4483345998)

CombatTab:CreateSlider({
	Name="Hitbox Size (Others + NPCs)",
	Range={1,20},
	Increment=1,
	CurrentValue=1,
	Callback=function(v)
		globalHRPSize=v
		hrpGlobalSliderUsed=true
	end
})

CombatTab:CreateToggle({
	Name="Slap Aura",
	CurrentValue=false,
	Callback=function(v)
		_G.SlapAura=v
	end
})

UIS.InputBegan:Connect(function(input, gp)
	if gp then return end
	if input.KeyCode == SlapAuraKey then
		SlapAuraToggle = not SlapAuraToggle
		SlapAuraButton:Set(SlapAuraToggle)
	end
end)

CombatTab:CreateToggle({
	Name="Auto Win",
	CurrentValue=false,
	Callback=function(v)
		_G.AutoWin=v
	end
})

local hitCount = 0

local function IsRagdolled(char)
	local hum = char:FindFirstChild("Humanoid")
	if not hum then return true end
	if hum.Health <= 0 then return true end
	if hum.PlatformStand then return true end
	return false
end

task.spawn(function()
	while task.wait(5) do
		if not _G.AutoWin then
			continue
		end

		if hitCount >= 5 then
			hitCount = 0
			task.wait(10)
		end

		local hrp = Char and Char:FindFirstChild("HumanoidRootPart")
		if not hrp then
			continue
		end

		local closest, closestDist = nil, math.huge

		for _, plr in ipairs(Players:GetPlayers()) do
			if plr ~= LocalPlayer then
				local char = plr.Character
				local targetHrp = char and char:FindFirstChild("HumanoidRootPart")

				if targetHrp and not IsRagdolled(char) then
					local dist = (hrp.Position - targetHrp.Position).Magnitude

					if dist < closestDist then
						closestDist = dist
						closest = targetHrp
					end
				end
			end
		end

		if closest then
			hrp.CFrame = closest.CFrame
			hitCount += 1
		end
	end
end)

ItemsTab:CreateToggle({
	Name="Use Items",
	CurrentValue=false,
	Callback=function(v)
		AutoUseEnabled=v
	end
})

ItemsTab:CreateToggle({
	Name = "Get Items",
	CurrentValue = false,
	Callback = function(v)
		GetItemsEnabled = v

		if v then
			-- Disable Get All Items
			GetAllItemsEnabled = false
			SetGetAllItemsNoclip(false)
		end
	end
})

ItemsTab:CreateToggle({
	Name="Auto Pickup",
	CurrentValue=false,
	Callback=function(v)
		AutoPickupEnabled=v
	end
})

local AutoBombBusEnabled=false

ItemsTab:CreateToggle({
	Name="Auto Bomb Bus",
	CurrentValue=false,
	Callback=function(v)
		AutoBombBusEnabled=v
	end
})

local Players = game:GetService("Players")

local LocalPlayer = Players.LocalPlayer
local AutoGetCrates = false

local function GetRoot()
	local character = LocalPlayer.Character
	if not character then
		return nil
	end

	return character:FindFirstChild("HumanoidRootPart")
end

local function ProcessCrate(crate)
	if not AutoGetCrates then
		return
	end

	if not crate:IsA("Model") or crate.Name ~= "Crate" then
		return
	end

	local rootPart = GetRoot()
	if not rootPart then
		return
	end

	-- Get the crate's position
	local crateCFrame

	if crate.PrimaryPart then
		crateCFrame = crate.PrimaryPart.CFrame
	else
		crateCFrame = crate:GetPivot()
	end

	-- Teleport 10 studs underneath the crate
	local targetPosition =
		crateCFrame.Position - Vector3.new(0, 10, 0)

	rootPart.CFrame =
		CFrame.new(targetPosition) *
		(rootPart.CFrame - rootPart.CFrame.Position)

	-- Find Effects.Basic Flame Wisp
	local effects = crate:FindFirstChild("Effects", true)
	local basic = effects and effects:FindFirstChild("Basic")
	local flameWisp = basic and basic:FindFirstChild("Flame Wisp")

	-- Wait until Flame Wisp is disabled
	if flameWisp and flameWisp:IsA("ParticleEmitter") then
		while AutoGetCrates
			and crate.Parent
			and flameWisp.Enabled do

			task.wait(0.1)
		end
	end

	if not AutoGetCrates or not crate.Parent then
		return
	end

	-- Find GetItemFromCrate
	local remote = crate:FindFirstChild("GetItemFromCrate", true)

	if not remote then
		warn("GetItemFromCrate not found in crate:", crate:GetFullName())
		return
	end

	if remote:IsA("RemoteEvent") then
		remote:FireServer()

	elseif remote:IsA("RemoteFunction") then
		remote:InvokeServer()
	end
end

ItemsTab:CreateToggle({
	Name = "Auto Get Crates [NOT FINSIHED]",
	CurrentValue = false,

	Callback = function(Value)

		AutoGetCrates = Value

		if not Value then
			return
		end

		local shipments = workspace:FindFirstChild("Shipments")
		local cratesFolder = shipments and shipments:FindFirstChild("Crates")

		if not cratesFolder then
			Rayfield:Notify({
				Title = "Auto Get Crates",
				Content = "Workspace.Shipments.Crates not found.",
				Duration = 5
			})
			return
		end

		-- Process crates that already exist
		for _, crate in ipairs(cratesFolder:GetChildren()) do
			task.spawn(function()
				ProcessCrate(crate)
			end)
		end

		-- Process newly spawned crates
		task.spawn(function()

			while AutoGetCrates and cratesFolder.Parent do

				local connection

				connection = cratesFolder.ChildAdded:Connect(function(crate)
					if AutoGetCrates
						and crate:IsA("Model")
						and crate.Name == "Crate" then

						task.spawn(function()
							ProcessCrate(crate)
						end)
					end
				end)

				repeat
					task.wait(1)
				until not AutoGetCrates or not cratesFolder.Parent

				if connection then
					connection:Disconnect()
				end
			end
		end)
	end
})

local Players = game:GetService("Players")
local CollectionService = game:GetService("CollectionService")

local PlayerESPEnabled = false

local function CreateNameTag(char)
	local head = char:FindFirstChild("Head")
	if not head then
		return
	end

	local oldTag = head:FindFirstChild("PlayerESP")
	if oldTag then
		oldTag:Destroy()
	end

	local billboard = Instance.new("BillboardGui")
	billboard.Name = "PlayerESP"
	billboard.Adornee = head
	billboard.Size = UDim2.new(0, 200, 0, 35)
	billboard.StudsOffset = Vector3.new(0, 3, 0)
	billboard.AlwaysOnTop = true
	billboard.Parent = head

	local nameLabel = Instance.new("TextLabel")
	nameLabel.Name = "Name"
	nameLabel.BackgroundTransparency = 1
	nameLabel.Size = UDim2.new(1, 0, 1, 0)
	nameLabel.Text = char.Name
	nameLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
	nameLabel.TextStrokeTransparency = 0
	nameLabel.TextStrokeColor3 = Color3.fromRGB(0, 0, 0)
	nameLabel.TextScaled = true
	nameLabel.Font = Enum.Font.GothamBold
	nameLabel.Parent = billboard
end

local function RemoveNameTag(char)
	local head = char:FindFirstChild("Head")

	if head then
		local billboard = head:FindFirstChild("PlayerESP")

		if billboard then
			billboard:Destroy()
		end
	end
end

ESPTab:CreateToggle({
	Name = "Player ESP",
	CurrentValue = false,
	Callback = function(v)

		PlayerESPEnabled = v

		for _, char in ipairs(CollectionService:GetTagged("PumpkinPlayer")) do

			local hrp = char:FindFirstChild("HumanoidRootPart")

			if v then
				if hrp then
					ApplyHighlight(hrp)
				end

				CreateNameTag(char)
			else
				RemoveNameTag(char)
			end
		end
	end
})

ESPTab:CreateToggle({
	Name="Tool ESP",
	CurrentValue=false,
	Callback=function(v)
		ItemESPEnabled=v
		if v then
			for _,tool in ipairs(CollectionService:GetTagged("PumpkinItem")) do
				CreateToolTag(tool)
			end
		end
	end
})

local GloveESPEnabled = false

local function GetGloveValue(player)
	local glove = player:FindFirstChild("Glove")

	if not glove then
		return nil
	end

	-- Supports StringValue and similar Value objects
	local success, value = pcall(function()
		return glove.Value
	end)

	if success and value ~= nil then
		return tostring(value)
	end

	return nil
end

local function UpdateGloveTag(char)
	if not GloveESPEnabled then
		return
	end

	local head = char:FindFirstChild("Head")
	if not head then
		return
	end

	local player = Players:GetPlayerFromCharacter(char)
	if not player then
		return
	end

	local playerESP = head:FindFirstChild("PlayerESP")

	if not playerESP then
		return
	end

	local gloveLabel = playerESP:FindFirstChild("Glove")

	if not gloveLabel then
		gloveLabel = Instance.new("TextLabel")
		gloveLabel.Name = "Glove"
		gloveLabel.BackgroundTransparency = 1
		gloveLabel.Size = UDim2.new(1, 0, 0, 20)
		gloveLabel.Position = UDim2.new(0, 0, 0, 25)
		gloveLabel.TextColor3 = Color3.fromRGB(255, 220, 80)
		gloveLabel.TextStrokeTransparency = 0
		gloveLabel.TextStrokeColor3 = Color3.fromRGB(0, 0, 0)
		gloveLabel.TextScaled = true
		gloveLabel.Font = Enum.Font.GothamBold
		gloveLabel.Parent = playerESP
	end

	local gloveValue = GetGloveValue(player)

	if gloveValue then
		gloveLabel.Text = gloveValue
		gloveLabel.Visible = true
	else
		gloveLabel.Text = "Unknown"
		gloveLabel.Visible = true
	end
end

local function RemoveGloveTag(char)
	local head = char:FindFirstChild("Head")

	if not head then
		return
	end

	local playerESP = head:FindFirstChild("PlayerESP")

	if not playerESP then
		return
	end

	local gloveLabel = playerESP:FindFirstChild("Glove")

	if gloveLabel then
		gloveLabel:Destroy()
	end

	-- Restore normal Player ESP size
	playerESP.Size = UDim2.new(0, 200, 0, 35)
end

ESPTab:CreateToggle({
	Name = "Glove ESP (Need Player ESP on to work)",
	CurrentValue = false,
	Callback = function(v)

		GloveESPEnabled = v

		for _, char in ipairs(CollectionService:GetTagged("PumpkinPlayer")) do

			if v then
				UpdateGloveTag(char)
			else
				RemoveGloveTag(char)
			end
		end
	end
})

OtherTab:CreateToggle({
	Name="Early Bus Jump",
	CurrentValue=false,
	Callback=function(v)
		EBJEnabled=v
	end
})

OtherTab:CreateToggle({
	Name="Instant Landing",
	CurrentValue=false,
	Callback=function(v)
		ILEnabled=v
	end
})

OtherTab:CreateToggle({
	Name="Remove Zone Effect",
	CurrentValue=false,
	Callback=function(v)
		RemoveZoneEnabled=v
	end
})

OtherTab:CreateToggle({
	Name="Delete All Seats",
	CurrentValue=false,
	Callback=function(v)
		DeleteSeatsEnabled=v
	end
})

local SpeedBoostEnabled=false

OtherTab:CreateToggle({
	Name="Speed Boost",
	CurrentValue=false,
	Callback=function(v)
		SpeedBoostEnabled=v
	end
})

local InfJumpEnabled = false

OtherTab:CreateToggle({
	Name = "Infinite Jump",
	CurrentValue = false,
	Callback = function(v)
		InfJumpEnabled = v
	end
})

UIS.JumpRequest:Connect(function()
	if InfJumpEnabled then
		local hum = Char and Char:FindFirstChildOfClass("Humanoid")
		if hum then
			hum:ChangeState(Enum.HumanoidStateType.Jumping)
		end
	end
end)

OtherTab:CreateButton({
	Name = "Open Lab + Teleport",
	Callback = function()

		local Players = game:GetService("Players")
		local LocalPlayer = Players.LocalPlayer

		local codes = {
			["9648755440"] = "8",
			["9648765536"] = "2",
			["9648723237"] = "3",
			["9648718450"] = "6",
			["9648769161"] = "4",
			["9648730082"] = "6",
			["9648734698"] = "2",
			["9648712563"] = "2",
			["9648742013"] = "7",
			["9648745618"] = "3",
			["9648715920"] = "6",
			["9648752438"] = "2",
			["9648749145"] = "8",
			["9648759883"] = "9",
			["9648738553"] = "8"
		}

		-- Get Map
		local map = workspace:FindFirstChild("Map")

		if not map then
			Rayfield:Notify({
				Title = "Open Lab + Teleport",
				Content = "Map not found.",
				Duration = 5
			})
			return
		end

		-- Get code GUI
		local codeBrick = map:FindFirstChild("CodeBrick")
		local surfaceGui = codeBrick and codeBrick:FindFirstChild("SurfaceGui")

		if not surfaceGui then
			Rayfield:Notify({
				Title = "Open Lab + Teleport",
				Content = "CodeBrick/SurfaceGui not found.",
				Duration = 5
			})
			return
		end

		-- Find IMGTemplate objects
		local templates = {}

		for _, obj in ipairs(surfaceGui:GetChildren()) do
			if obj.Name == "IMGTemplate" then
				table.insert(templates, obj)
			end
		end

		if #templates ~= 4 then
			Rayfield:Notify({
				Title = "Open Lab + Teleport",
				Content = "Found " .. #templates .. " images instead of 4.",
				Duration = 5
			})
			return
		end

		-- Sort images left to right
		table.sort(templates, function(a, b)
			local ax = a.AbsolutePosition.X
			local bx = b.AbsolutePosition.X

			if math.abs(ax - bx) > 1 then
				return ax < bx
			end

			return a.AbsolutePosition.Y < b.AbsolutePosition.Y
		end)

		local result = {}

		-- Convert images to digits
		for i, imageObject in ipairs(templates) do

			local image = tostring(imageObject.Image)

			local assetId =
				image:match("[?&]id=(%d+)")
				or image:match("rbxassetid://(%d+)")
				or image:match("(%d+)$")

			local digit = assetId and codes[assetId]

			if not digit then
				Rayfield:Notify({
					Title = "Open Lab + Teleport",
					Content = "Unknown image at position "
						.. i .. ": " .. image,
					Duration = 5
				})
				return
			end

			result[i] = digit
		end

		local CodeEsp = table.concat(result)

		-- Get CodeDoor
		local originOffice = map:FindFirstChild("OriginOffice")

		if not originOffice then
			Rayfield:Notify({
				Title = "Open Lab + Teleport",
				Content = "OriginOffice not found.",
				Duration = 5
			})
			return
		end

		local codeDoor = originOffice:FindFirstChild("CodeDoor")
		local door = codeDoor and codeDoor:FindFirstChild("Door")

		if not door then
			Rayfield:Notify({
				Title = "Open Lab + Teleport",
				Content = "Door not found.",
				Duration = 5
			})
			return
		end

		-- Get Door BasePart
		local doorPart

		if door:IsA("BasePart") then
			doorPart = door
		else
			doorPart = door:FindFirstChildWhichIsA("BasePart", true)
		end

		if not doorPart then
			Rayfield:Notify({
				Title = "Open Lab + Teleport",
				Content = "No BasePart found inside Door.",
				Duration = 5
			})
			return
		end

		-- Get character
		local character = LocalPlayer.Character
			or LocalPlayer.CharacterAdded:Wait()

		local rootPart = character:FindFirstChild("HumanoidRootPart")

		if not rootPart then
			Rayfield:Notify({
				Title = "Open Lab + Teleport",
				Content = "HumanoidRootPart not found.",
				Duration = 5
			})
			return
		end

		-- ==========================================
		-- TELEPORT 20 STUDS TO THE LEFT OF THE DOOR
		-- ==========================================

		local leftOffset =
			-doorPart.CFrame.RightVector * 20

		local targetPosition =
			doorPart.Position + leftOffset

		-- Preserve player's current rotation
		local currentRotation =
			rootPart.CFrame - rootPart.CFrame.Position

		-- Teleport BEFORE entering the code
		rootPart.CFrame =
			CFrame.new(targetPosition) * currentRotation

		-- ==========================================
		-- GET KEYPAD
		-- ==========================================

		local keypad = door:FindFirstChild("Keypad")
		local buttonsFolder = keypad and keypad:FindFirstChild("Buttons")

		if not buttonsFolder then
			Rayfield:Notify({
				Title = "Open Lab + Teleport",
				Content = "Keypad Buttons not found.",
				Duration = 5
			})
			return
		end

		-- ==========================================
		-- RESET KEYPAD BEFORE ENTERING CODE
		-- ==========================================

		local resetButton = buttonsFolder:FindFirstChild("Reset")

		if not resetButton then
			Rayfield:Notify({
				Title = "Open Lab + Teleport",
				Content = "Reset button not found.",
				Duration = 5
			})
			return
		end

		local resetDetector =
			resetButton:FindFirstChildOfClass("ClickDetector")

		if not resetDetector then
			Rayfield:Notify({
				Title = "Open Lab + Teleport",
				Content = "ClickDetector missing from Reset.",
				Duration = 5
			})
			return
		end

		-- Clear anything already entered
		fireclickdetector(resetDetector)

		-- Small delay to let the keypad process Reset
		task.wait(0.2)

		-- ==========================================
		-- ENTER CODE
		-- ==========================================

		for i = 1, #CodeEsp do

			local digit = CodeEsp:sub(i, i)
			local button = buttonsFolder:FindFirstChild(digit)

			if not button then
				Rayfield:Notify({
					Title = "Open Lab + Teleport",
					Content = "Button " .. digit .. " not found.",
					Duration = 5
				})
				return
			end

			local clickDetector =
				button:FindFirstChildOfClass("ClickDetector")

			if not clickDetector then
				Rayfield:Notify({
					Title = "Open Lab + Teleport",
					Content = "ClickDetector missing from button "
						.. digit .. ".",
					Duration = 5
				})
				return
			end

			fireclickdetector(clickDetector)

			task.wait(0.15)
		end

		-- ==========================================
		-- PRESS ENTER
		-- ==========================================

		local enterButton =
			buttonsFolder:FindFirstChild("Enter")

		if not enterButton then
			Rayfield:Notify({
				Title = "Open Lab + Teleport",
				Content = "Enter button not found.",
				Duration = 5
			})
			return
		end

		local enterDetector =
			enterButton:FindFirstChildOfClass("ClickDetector")

		if not enterDetector then
			Rayfield:Notify({
				Title = "Open Lab + Teleport",
				Content = "ClickDetector missing from Enter.",
				Duration = 5
			})
			return
		end

		fireclickdetector(enterDetector)

		Rayfield:Notify({
			Title = "Code Entered [ " .. CodeEsp .. " ]",
			Content = "Reset keypad, teleported left of door, and entered code.",
			Duration = 5
		})
	end
})

OtherTab:CreateButton({
	Name = "Show Lab Code",
	Callback = function()

		local codes = {
			["9648755440"] = "8",
			["9648765536"] = "2",
			["9648723237"] = "3",
			["9648718450"] = "6",
			["9648769161"] = "4",
			["9648730082"] = "6",
			["9648734698"] = "2",
			["9648712563"] = "2",
			["9648742013"] = "7",
			["9648745618"] = "3",
			["9648715920"] = "6",
			["9648752438"] = "2",
			["9648749145"] = "8",
			["9648759883"] = "9",
			["9648738553"] = "8"
		}

		-- Get Map
		local map = workspace:FindFirstChild("Map")

		if not map then
			Rayfield:Notify({
				Title = "Show Lab Code",
				Content = "Map not found.",
				Duration = 5
			})
			return
		end

		-- Get code GUI
		local codeBrick = map:FindFirstChild("CodeBrick")
		local surfaceGui = codeBrick and codeBrick:FindFirstChild("SurfaceGui")

		if not surfaceGui then
			Rayfield:Notify({
				Title = "Show Lab Code",
				Content = "CodeBrick/SurfaceGui not found.",
				Duration = 5
			})
			return
		end

		-- Find IMGTemplate objects
		local templates = {}

		for _, obj in ipairs(surfaceGui:GetChildren()) do
			if obj.Name == "IMGTemplate" then
				table.insert(templates, obj)
			end
		end

		if #templates ~= 4 then
			Rayfield:Notify({
				Title = "Show Lab Code",
				Content = "Found " .. #templates .. " images instead of 4.",
				Duration = 5
			})
			return
		end

		-- Sort images left to right
		table.sort(templates, function(a, b)
			local ax = a.AbsolutePosition.X
			local bx = b.AbsolutePosition.X

			if math.abs(ax - bx) > 1 then
				return ax < bx
			end

			return a.AbsolutePosition.Y < b.AbsolutePosition.Y
		end)

		local result = {}

		-- Convert images to digits
		for i, imageObject in ipairs(templates) do

			local image = tostring(imageObject.Image)

			local assetId =
				image:match("[?&]id=(%d+)")
				or image:match("rbxassetid://(%d+)")
				or image:match("(%d+)$")

			local digit = assetId and codes[assetId]

			if not digit then
				Rayfield:Notify({
					Title = "Show Lab Code",
					Content = "Unknown image at position "
						.. i .. ": " .. image,
					Duration = 5
				})
				return
			end

			result[i] = digit
		end

		local CodeEsp = table.concat(result)

		-- Show code for 10 seconds
		Rayfield:Notify({
			Title = "Lab Code: " .. CodeEsp,
			Content = "Code will disappear in 10 seconds.",
			Duration = 10
		})
	end
})

OtherTab:CreateButton({
	Name="Lobby Hider",
	Callback=function()
		local hrp=Char:FindFirstChild("HumanoidRootPart")
		local lobby=workspace:FindFirstChild("Lobby")
		local ceiling=lobby and lobby:FindFirstChild("Ceiling")
		if hrp and ceiling then
			local base=ceiling.Position
			local top=Ground(base+Vector3.new(0,50,0))
			hrp.CFrame=CFrame.new(top,hrp.Position+hrp.CFrame.LookVector)
		end
	end
})

local SafetyTab = Window:CreateTab("Safety", 4483345998)

SafetyTab:CreateToggle({
	Name = "Anti Acid",
	CurrentValue = false,
	Callback = function(v)
		_G.AntiAcid = v
	end
})

SafetyTab:CreateToggle({
	Name = "Anti Lava",
	CurrentValue = false,
	Callback = function(v)
		_G.AntiLava = v
	end
})

local AntiCubeOfDeathEnabled = false

SafetyTab:CreateToggle({
	Name = "Anti Cube of Death",
	CurrentValue = false,
	Callback = function(v)
		AntiCubeOfDeathEnabled = v
	end
})

task.spawn(function()
	while true do
		if AntiCubeOfDeathEnabled then
			local rubble = workspace:FindFirstChild("Rubbled Remains")

			if rubble then
				for _, obj in ipairs(rubble:GetDescendants()) do
					if obj.Name == "Cube of Death"
						or obj.Name == "Death"
						or obj.Name == "■" then
						obj:Destroy()
					end
				end
			end
		end

		task.wait(0.1)
	end
end)

SafetyTab:CreateToggle({
	Name = "Anti Knockback",
	CurrentValue = false,
	Callback = function(v)
		_G.AntiKnockback = v
	end
})

SafetyTab:CreateToggle({
	Name = "Go Under Map (Use Anti Acid with this for it to not get you killed)",
	CurrentValue = false,
	Callback = function(Value)

		local Players = game:GetService("Players")
		local LocalPlayer = Players.LocalPlayer

		-- 2 second cooldown
		if _G.GoUnderMapCooldown then
			Rayfield:Notify({
				Title = "Go Under Map",
				Content = "Teleport is on cooldown.",
				Duration = 2
			})
			return
		end

		local character = LocalPlayer.Character
			or LocalPlayer.CharacterAdded:Wait()

		local rootPart = character:FindFirstChild("HumanoidRootPart")
		local humanoid = character:FindFirstChildOfClass("Humanoid")

		if not rootPart or not humanoid then
			Rayfield:Notify({
				Title = "Go Under Map",
				Content = "Character not ready.",
				Duration = 5
			})
			return
		end

		_G.GoUnderMapCooldown = true

		if Value then
			-- ==========================================
			-- ON: TELEPORT 30 STUDS DOWN
			-- ==========================================

			rootPart.CFrame =
				rootPart.CFrame + Vector3.new(0, -30, 0)

			Rayfield:Notify({
				Title = "Go Under Map",
				Content = "Teleported 30 studs down.",
				Duration = 3
			})

		else
			-- ==========================================
			-- OFF: FIND TOP OF TERRAIN
			-- ==========================================

			local terrain = workspace:FindFirstChildOfClass("Terrain")

			if not terrain then
				_G.GoUnderMapCooldown = false

				Rayfield:Notify({
					Title = "Go Under Map",
					Content = "Terrain not found.",
					Duration = 5
				})
				return
			end

			-- Start high above the player and raycast DOWN.
			-- This finds the TOP surface of the terrain.
			local rayOrigin =
				rootPart.Position + Vector3.new(0, 1000, 0)

			local rayDirection =
				Vector3.new(0, -2000, 0)

			local rayParams = RaycastParams.new()
			rayParams.FilterType = Enum.RaycastFilterType.Include
			rayParams.FilterDescendantsInstances = {
				terrain
			}
			rayParams.IgnoreWater = true

			local rayResult = workspace:Raycast(
				rayOrigin,
				rayDirection,
				rayParams
			)

			if not rayResult then
				_G.GoUnderMapCooldown = false

				Rayfield:Notify({
					Title = "Go Under Map",
					Content = "Could not find the top of the terrain.",
					Duration = 5
				})
				return
			end

			-- Character height
			local halfHeight = rootPart.Size.Y / 2

			-- Put the HumanoidRootPart above the terrain.
			local targetPosition =
				rayResult.Position
				+ Vector3.new(0, halfHeight + 2, 0)

			-- Preserve rotation
			local currentRotation =
				rootPart.CFrame - rootPart.CFrame.Position

			rootPart.CFrame =
				CFrame.new(targetPosition) * currentRotation

			Rayfield:Notify({
				Title = "Go Under Map",
				Content = "Teleported on top of the terrain.",
				Duration = 3
			})
		end

		-- ==========================================
		-- 2 SECOND COOLDOWN
		-- ==========================================

		task.delay(2, function()
			_G.GoUnderMapCooldown = false
		end)
	end
})

BusJumping.OnClientEvent:Connect(function()
	if ILEnabled then
		InstantLand()
	end
end)

task.spawn(function()
	while true do
		if EBJEnabled then
			local head=Char:FindFirstChild("Head")
			if head and head.Transparency==1 then
				BusJumping:FireServer()
			end
		end
		task.wait(0.05)
	end
end)

task.spawn(function()
	while true do
		if RemoveZoneEnabled then
			for _,obj in ipairs(game:GetDescendants()) do
				if obj.Name=="ZoneEffects" then
					obj:Destroy()
				end
			end
		end
		task.wait(1)
	end
end)

task.spawn(function()
	while true do
		if DeleteSeatsEnabled then
			for _,obj in ipairs(game:GetDescendants()) do
				if obj:IsA("Seat") or obj:IsA("VehicleSeat") then
					obj:Destroy()
				end
			end
		end
		task.wait(1)
	end
end)

task.spawn(function()
	while true do
		if hrpGlobalSliderUsed then
			for _,player in ipairs(Players:GetPlayers()) do
				if player~=LocalPlayer then
					local c=player.Character
					local hrp=c and c:FindFirstChild("HumanoidRootPart")
					if hrp then
						hrp.Size=Vector3.new(globalHRPSize,globalHRPSize,globalHRPSize)
						hrp.Transparency=0.8
						hrp.CanCollide=false
					end
				end
			end
			for _,npc in ipairs(workspace:GetDescendants()) do
				if npc:IsA("Model") and npc:FindFirstChild("Humanoid") and npc~=Char then
					local hrp=npc:FindFirstChild("HumanoidRootPart")
					if hrp then
						hrp.Size=Vector3.new(globalHRPSize,globalHRPSize,globalHRPSize)
						hrp.Transparency=0.8
						hrp.CanCollide=false
					end
				end
			end
		end
		task.wait(0.3)
	end
end)

task.spawn(function()
	while true do
		if AutoUseEnabled then
			for _,tool in ipairs(LocalPlayer.Backpack:GetChildren()) do
				if AutoUseList[tool.Name] then
					tool.Parent=Char
					task.wait(0.5)
					pcall(function()tool:Activate()end)
				end
			end
		end
		task.wait(0.1)
	end
end)

--==================================================
-- GET ITEMS
--==================================================

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

local lp = Players.LocalPlayer
local char = lp.Character or lp.CharacterAdded:Wait()

local Items = workspace:WaitForChild("Items")
local ItemRemote = ReplicatedStorage.Remotes.Item
local BusJumping = ReplicatedStorage.Remotes.BusJumping

--==================================================
-- STATE
--==================================================

local blocked = false
local recoveryRunning = false
local lastPicked = nil

local BombPickedThisRound = false
local BombTeleportedThisRound = false

local ContinueAfterBusEnabled = false
local ContinueAfterBusRunning = false

local CollectionRunning = false
local CollectionCooldown = false

-- First collection = 4
-- Every collection after = 7
local CollectionCycle = 0

--==================================================
-- ALLOWED ITEMS
--==================================================

local AllowedTools = {
	["Bomb"] = true,
	["Potion of Strength"] = true,
	["Bull's essence"] = true,
	["Boba"] = true,
	["Speed Potion"] = true,
	["Frog Potion"] = true
}

--==================================================
-- CHARACTER
--==================================================

local function UpdateCharacter(c)
	char = c

	blocked = false
	recoveryRunning = false
	lastPicked = nil

	BombPickedThisRound = false
	BombTeleportedThisRound = false

	CollectionRunning = false
	CollectionCooldown = false
	ContinueAfterBusRunning = false

	CollectionCycle = 0
end

lp.CharacterAdded:Connect(UpdateCharacter)

--==================================================
-- COUNTDOWN
--==================================================

local function GetCountdownObject()
	local countdown = lp.PlayerGui:FindFirstChild("Countdown")
	local container = countdown and countdown:FindFirstChild("Countdown")

	return container and container:FindFirstChild("TimeLeft")
end

local function GetCountdown()
	local obj = GetCountdownObject()

	if not obj then
		return nil
	end

	return tonumber(obj.Text)
end

local function CountdownAllowed()
	local value = GetCountdown()

	return value ~= nil
		and value >= 1
		and value <= 3
end

--==================================================
-- BODY PARTS
--==================================================

local function GetRightLeg(c)
	if not c then
		return nil
	end

	return c:FindFirstChild("RightUpperLeg")
		or c:FindFirstChild("RightLowerLeg")
		or c:FindFirstChild("RightFoot")
		or c:FindFirstChild("Right Leg")
end

local function GetTorso(c)
	c = c or lp.Character

	if not c then
		return nil
	end

	return c:FindFirstChild("UpperTorso")
		or c:FindFirstChild("Torso")
end

--==================================================
-- FIND ALLOWED TOOL
--==================================================

local function FindAllowedTool(maxDistance)
	local currentChar = lp.Character
	local hrp = currentChar and currentChar:FindFirstChild("HumanoidRootPart")

	if not hrp then
		return nil
	end

	local closest = nil
	local closestDistance = maxDistance or math.huge

	for _, tool in ipairs(Items:GetChildren()) do

		if tool:IsA("Tool")
			and AllowedTools[tool.Name] then

			local handle = tool:FindFirstChild("Handle")

			if handle then

				local distance =
					(handle.Position - hrp.Position).Magnitude

				if distance < closestDistance then
					closestDistance = distance
					closest = tool
				end
			end
		end
	end

	return closest
end

--==================================================
-- PICKUP
--==================================================

local function Pickup(handle)

	if not GetItemsEnabled then
		return false
	end

	if blocked or recoveryRunning then
		return false
	end

	if not CountdownAllowed() then
		return false
	end

	if not handle or not handle.Parent then
		return false
	end

	local id = handle:GetAttribute("ItemId")

	if not id then
		return false
	end

	ItemRemote:FireServer(id)

	local gui = handle:FindFirstChild("ItemGui")

	if gui then
		gui.Enabled = false
	end

	return true
end

--==================================================
-- TELEPORT TO TOOL WITHOUT PICKUP
--==================================================

local function TPToToolWithoutPickup(tool)

	if not tool or not tool.Parent then
		return false
	end

	local currentChar = lp.Character

	local hrp =
		currentChar
		and currentChar:FindFirstChild("HumanoidRootPart")

	local handle = tool:FindFirstChild("Handle")

	if not hrp or not handle then
		return false
	end

	local toolPos = handle.Position

	local sideDirs = {
		Vector3.new(3, 0, 0),
		Vector3.new(-3, 0, 0),
		Vector3.new(0, 0, 3),
		Vector3.new(0, 0, -3)
	}

	local chosenSide = nil

	for _, dir in ipairs(sideDirs) do

		local ray = workspace:Raycast(
			toolPos,
			dir,
			RayParams
		)

		if not ray then
			chosenSide = dir
			break
		end
	end

	if chosenSide then

		hrp.CFrame = CFrame.new(
			toolPos + chosenSide,
			toolPos
		)

	else

		local rightVector

		if Camera then
			rightVector = Camera.CFrame.RightVector
		else
			rightVector = Vector3.new(1, 0, 0)
		end

		local sidePos =
			toolPos + rightVector * 4

		hrp.CFrame = CFrame.new(
			sidePos,
			toolPos
		)
	end

	return true
end

--==================================================
-- TELEPORT + PICKUP
--==================================================

local function TPWaitLookPickup(tool)

	if not tool or not tool.Parent then
		return false
	end

	if lastPicked == tool then
		return false
	end

	if not GetItemsEnabled then
		return false
	end

	if blocked or recoveryRunning then
		return false
	end

	if not CountdownAllowed() then
		return false
	end

	local currentChar = lp.Character

	local hrp =
		currentChar
		and currentChar:FindFirstChild("HumanoidRootPart")

	local handle = tool:FindFirstChild("Handle")

	if not hrp or not handle then
		return false
	end

	lastPicked = tool

	local toolPos = handle.Position

	local sideDirs = {
		Vector3.new(2, 0, 0),
		Vector3.new(-2, 0, 0),
		Vector3.new(0, 0, 2),
		Vector3.new(0, 0, -2)
	}

	local chosenSide = nil

	for _, dir in ipairs(sideDirs) do

		local ray = workspace:Raycast(
			toolPos,
			dir,
			RayParams
		)

		if not ray then
			chosenSide = dir
			break
		end
	end

	if chosenSide then

		hrp.CFrame = CFrame.new(
			toolPos + chosenSide,
			toolPos
		)

	else

		local rightVector

		if Camera then
			rightVector = Camera.CFrame.RightVector
		else
			rightVector = Vector3.new(1, 0, 0)
		end

		local sidePos =
			toolPos + rightVector * 4

		hrp.CFrame = CFrame.new(
			sidePos,
			toolPos
		)
	end

	task.wait(0.25)

	if not GetItemsEnabled then
		return false
	end

	if blocked or recoveryRunning then
		return false
	end

	if not CountdownAllowed() then
		return false
	end

	if not handle or not handle.Parent then
		return false
	end

	hrp.CFrame = CFrame.new(
		hrp.Position,
		toolPos
	)

	local success = Pickup(handle)

	task.wait(0.25)

	return success
end

--==================================================
-- GET ITEMS IN ORDER
--==================================================

local function GetOrderedItems()

	local bomb = nil

	local strengthList = {}
	local bullList = {}
	local bobaList = {}
	local speedList = {}
	local frogList = {}

	for _, obj in ipairs(Items:GetChildren()) do

		if obj:IsA("Tool") then

			local handle = obj:FindFirstChild("Handle")

			if handle then

				if obj.Name == "Bomb"
					and not BombPickedThisRound
					and not BombTeleportedThisRound
					and not bomb then

					bomb = obj

				elseif obj.Name == "Potion of Strength" then

					table.insert(
						strengthList,
						obj
					)

				elseif obj.Name == "Bull's essence" then

					table.insert(
						bullList,
						obj
					)

				elseif obj.Name == "Boba" then

					table.insert(
						bobaList,
						obj
					)

				elseif obj.Name == "Speed Potion" then

					table.insert(
						speedList,
						obj
					)

				elseif obj.Name == "Frog Potion" then

					table.insert(
						frogList,
						obj
					)
				end
			end
		end
	end

	return {
		{bomb},
		strengthList,
		bullList,
		bobaList,
		speedList,
		frogList
	}
end

--==================================================
-- COLLECT EXACT NUMBER
--==================================================

local function CollectItems(amount)

	if CollectionRunning then
		return 0
	end

	if not GetItemsEnabled then
		return 0
	end

	if blocked or recoveryRunning then
		return 0
	end

	if not CountdownAllowed() then
		return 0
	end

	CollectionRunning = true

	local picked = 0

	local order = GetOrderedItems()

	for _, group in ipairs(order) do

		for _, tool in ipairs(group) do

			if picked >= amount then
				break
			end

			if not GetItemsEnabled then
				break
			end

			if blocked or recoveryRunning then
				break
			end

			if not CountdownAllowed() then
				break
			end

			if tool and tool.Parent then

				-- Bomb may only be teleported to once.
				if tool.Name == "Bomb"
					and BombTeleportedThisRound then

					continue
				end

				local success =
					TPWaitLookPickup(tool)

				if success then

					picked += 1

					if tool.Name == "Bomb" then

						BombPickedThisRound = true
						BombTeleportedThisRound = true
					end
				end
			end
		end

		if picked >= amount then
			break
		end
	end

	CollectionRunning = false

	return picked
end

--==================================================
-- CONTINUE ITEM COLLECTION AFTER BUS
--==================================================

ItemsTab:CreateToggle({
	Name = "Continue Item Collection after bus",
	CurrentValue = false,

	Callback = function(v)

		ContinueAfterBusEnabled = v

		if not v then

			-- Disabled:
			-- stay in the bus
			-- do not jump
			-- do not teleport after bus
			-- do not collect after bus

			GetItemsEnabled = false

			ContinueAfterBusRunning = false
			CollectionRunning = false
			CollectionCooldown = false

			lastPicked = nil
		end
	end
})

--==================================================
-- START BUS COLLECTION
--==================================================

local function StartBusCollection()

	if not ContinueAfterBusEnabled then
		return
	end

	if ContinueAfterBusRunning then
		return
	end

	ContinueAfterBusRunning = true

	-- Stop normal item collection while inside bus.
	GetItemsEnabled = false
	CollectionRunning = false
	CollectionCooldown = false
	lastPicked = nil

	task.wait(0.5)

	-- Check toggle before jumping.
	if not ContinueAfterBusEnabled then

		GetItemsEnabled = false
		ContinueAfterBusRunning = false

		return
	end

	--==================================================
	-- JUMP OUT, THEN TELEPORT TO TOOL
	--==================================================

	if ContinueAfterBusEnabled then

		-- Jump out first
		pcall(function()
			BusJumping:FireServer()
		end)

		-- Wait 0.1 seconds after jumping
		task.wait(0.1)

		if not ContinueAfterBusEnabled then
			return
		end

		-- Look for a tool after the jump.
		-- Retry briefly in case the items have not loaded yet.
		local tool = nil

		for i = 1, 20 do

			if not ContinueAfterBusEnabled then
				break
			end

			tool = FindAllowedTool(1000)

			if tool and tool.Parent then
				break
			end

			task.wait(0.05)
		end

		-- Teleport after the tool is found
		if ContinueAfterBusEnabled and tool and tool.Parent then
			TPToToolWithoutPickup(tool)
		end
	end

	--==================================================
	-- WAIT AFTER JUMP
	--==================================================

	task.wait(0.2)

	if not ContinueAfterBusEnabled then

		GetItemsEnabled = false
		ContinueAfterBusRunning = false

		return
	end

	--==================================================
	-- CONFIRM PLAYER IS OUT OF BUS
	--==================================================

	local startTime = tick()
	local exitedBus = false

	while tick() - startTime < 10 do

		if not ContinueAfterBusEnabled then

			GetItemsEnabled = false
			ContinueAfterBusRunning = false

			return
		end

		local currentChar = lp.Character
		local torso = GetTorso(currentChar)

		if torso and torso.Transparency < 1 then

			exitedBus = true
			break
		end

		task.wait(0.05)
	end

	if not exitedBus then

		GetItemsEnabled = false
		ContinueAfterBusRunning = false

		return
	end

	--==================================================
	-- WAIT 10 SECONDS AFTER JUMPING OUT
	--==================================================

	task.wait(10)

	if not ContinueAfterBusEnabled then

		GetItemsEnabled = false
		ContinueAfterBusRunning = false

		return
	end

	--==================================================
	-- DELETE GLIDERS WHILE GET ITEMS IS ENABLED
	--==================================================

	task.spawn(function()
		while true do
			if GetItemsEnabled then
				for _, obj in ipairs(workspace:GetDescendants()) do
					if obj.Name == "Glider" then
						pcall(function()
							obj:Destroy()
						end)
					end
				end
			end

			task.wait(0.1)
		end
	end)

	--==================================================
	-- NOW TELEPORT TO BOMB
	--==================================================

	GetItemsEnabled = true

	if not BombTeleportedThisRound
		and ContinueAfterBusEnabled then

		local bomb = nil

		for _, tool in ipairs(Items:GetChildren()) do

			if tool:IsA("Tool")
				and tool.Name == "Bomb"
				and tool.Parent then

				bomb = tool
				break
			end
		end

		if bomb then

			TPToToolWithoutPickup(bomb)

			BombTeleportedThisRound = true
		end
	end

	--==================================================
	-- COLLECT ITEMS
	--==================================================

	if ContinueAfterBusEnabled
		and GetItemsEnabled then

		local amount

		if CollectionCycle == 0 then
			amount = 4
		else
			amount = 7
		end

		local picked =
			CollectItems(amount)

		if picked > 0 then

			CollectionCycle += 1

			-- Always wait 5 seconds after
			-- the collection finishes.
			CollectionCooldown = true

			task.wait(5)

			CollectionCooldown = false
		end
	end

	ContinueAfterBusRunning = false
end

--==================================================
-- BUS LEG MONITOR
--==================================================

local function SetupBusMonitor(c)

	local leg = GetRightLeg(c)

	if not leg then
		return
	end

	local previousTransparency =
		leg.Transparency

	leg:GetPropertyChangedSignal(
		"Transparency"
	):Connect(function()

		local currentTransparency =
			leg.Transparency

		local becameInvisible =
			previousTransparency < 1
			and currentTransparency >= 1

		previousTransparency =
			currentTransparency

		if not becameInvisible then
			return
		end

		--==================================================
		-- CONTINUE OFF
		--==================================================

		if not ContinueAfterBusEnabled then

			-- Stay in bus.
			GetItemsEnabled = false

			return
		end

		--==================================================
		-- CONTINUE ON
		--==================================================

		if ContinueAfterBusRunning then
			return
		end

		task.spawn(function()
			StartBusCollection()
		end)

	end)
end

SetupBusMonitor(char)

--==================================================
-- CHARACTER ADDED
--==================================================

lp.CharacterAdded:Connect(function(c)

	task.wait(0.2)

	char = c

	BombPickedThisRound = false
	BombTeleportedThisRound = false

	lastPicked = nil

	ContinueAfterBusRunning = false
	CollectionRunning = false
	CollectionCooldown = false

	CollectionCycle = 0

	SetupBusMonitor(c)
end)

--==================================================
-- MAIN COLLECTION LOOP
--
-- 4 ITEMS
-- WAIT 5 SEC
-- 7 ITEMS
-- WAIT 5 SEC
-- 7 ITEMS
-- WAIT 5 SEC
-- REPEAT
--==================================================

task.spawn(function()

	while true do

		if GetItemsEnabled
			and not blocked
			and not recoveryRunning
			and not ContinueAfterBusRunning
			and not CollectionCooldown
			and not CollectionRunning
			and CountdownAllowed() then

			local amount

			if CollectionCycle == 0 then
				amount = 4
			else
				amount = 7
			end

			local picked =
				CollectItems(amount)

			if picked > 0 then

				CollectionCycle += 1

				-- 5 second cooldown after every collection.
				CollectionCooldown = true

				task.wait(5)

				CollectionCooldown = false
			end
		end

		task.wait(0.1)
	end
end)

--==================================================
-- INSTANT LANDING
--==================================================

task.spawn(function()

	while true do

		local timeLeftObj =
			GetCountdownObject()

		if timeLeftObj
			and timeLeftObj.Text == "1" then

			task.wait(1.2)

			if ILEnabled then
				InstantLand()
			end
		end

		task.wait(0.2)
	end
end)

--==================================================
-- ROUND RESET
--==================================================

task.spawn(function()

	local wasHigh = false

	while true do

		local value =
			GetCountdown()

		if value and value > 3 then

			if not wasHigh then

				BombPickedThisRound = false
				BombTeleportedThisRound = false

				lastPicked = nil

				CollectionCycle = 0

				CollectionRunning = false
				CollectionCooldown = false
			end

			wasHigh = true

		else

			wasHigh = false
		end

		task.wait(0.5)
	end
end)

local lastSlap = 0

local function NotRagdolled(char)
	local hum = char:FindFirstChild("Humanoid")
	if not hum then return false end
	if hum.Health <= 0 then return false end
	if hum.PlatformStand == true then return false end
	return true
end

task.spawn(function()
	while true do
		if _G.SlapAura then
			local now = tick()
			if now - lastSlap >= 0.25 then
				local hrp = Char:FindFirstChild("HumanoidRootPart")
				local toolEquipped = Char:FindFirstChildWhichIsA("Tool")

				if hrp and toolEquipped then
					for _,player in ipairs(Players:GetPlayers()) do
						if player ~= lp then
							local c = player.Character
							local chrp = c and c:FindFirstChild("HumanoidRootPart")

							if chrp and NotRagdolled(c) then
								local dist = (hrp.Position - chrp.Position).Magnitude
								if dist <= 20 then
									lastSlap = now
									pcall(function()
										ReplicatedStorage.Remotes.Slap:FireServer(chrp)
									end)
									break
								end
							end
						end
					end
				end
			end
		end
		task.wait(0.001)
	end
end)

task.spawn(function()
	while true do
		if SpeedBoostEnabled then
			local hum=Char:FindFirstChild("Humanoid")
			local hrp=Char:FindFirstChild("HumanoidRootPart")
			if hum and hrp then
				local dir=hum.MoveDirection
				if dir.Magnitude>0 then
					hrp.CFrame=hrp.CFrame+(dir*0.5)
				end
			end
		end
		task.wait(0.07)
	end
end)

task.spawn(function()
	while true do
		if AutoBombBusEnabled then
			local head=Char:FindFirstChild("Head")
			if head and head.Transparency==1 then
				task.wait(10.3)
				local bomb=Char:FindFirstChild("Bomb") or lp.Backpack:FindFirstChild("Bomb")
				if bomb then
					bomb.Parent=Char
					pcall(function()
						bomb:Activate()
					end)
				end
			end
		end
		task.wait(0.05)
	end
end)

task.spawn(function()
	while true do

		if _G.AntiAcid then
			local whitelist = {
				["Colliders"] = true,
				["Effects"] = true,
				["IgnoreList"] = true,
				["InteractableEvents"] = true,
				["Items"] = true,
				["Map"] = true,
				["MapBounds"] = true,
				["Rubbled Remains"] = true,
				["Shipments"] = true,
				["Lobby"] = true,
				["SoundRegions"] = true
			}

			for _,obj in ipairs(workspace:GetChildren()) do
				if obj:IsA("Folder") and not whitelist[obj.Name] then
					for _,child in ipairs(obj:GetChildren()) do
						child:Destroy()
					end
					obj:Destroy()
				end
			end
		end

		if _G.AntiLava then
			for _,obj in ipairs(workspace:GetDescendants()) do
				if obj:IsA("BasePart") and obj.Name == "Lava" then
					obj:Destroy()
				end
			end
		end

		if _G.AntiKnockback then
			local char = Players.LocalPlayer.Character
			local hum = char and char:FindFirstChild("Humanoid")
			local hrp = char and char:FindFirstChild("HumanoidRootPart")

			if hum and hrp then
				if hum.PlatformStand == true then
					if not workspace:FindFirstChild("AntiKB_Cage_"..char.Name) then
						local cage = Instance.new("Folder")
						cage.Name = "AntiKB_Cage_"..char.Name
						cage.Parent = workspace

						local function makePart(name, size, offset)
							local p = Instance.new("Part")
							p.Name = name
							p.Size = size
							p.Anchored = true
							p.CanCollide = true
							p.Transparency = 1
							p.Position = hrp.Position + offset
							p.Parent = cage
						end

						makePart("Top", Vector3.new(6,1,6), Vector3.new(0,3,0))
						makePart("Bottom", Vector3.new(6,1,6), Vector3.new(0,-3,0))
						makePart("Front", Vector3.new(6,6,1), Vector3.new(0,0,-3))
						makePart("Back", Vector3.new(6,6,1), Vector3.new(0,0,3))
						makePart("Left", Vector3.new(1,6,6), Vector3.new(-3,0,0))
						makePart("Right", Vector3.new(1,6,6), Vector3.new(3,0,0))
					else
						local cage = workspace["AntiKB_Cage_"..char.Name]
						for _,p in ipairs(cage:GetChildren()) do
							if p:IsA("Part") then
								if p.Name == "Top" then p.Position = hrp.Position + Vector3.new(0,5,0) end
								if p.Name == "Bottom" then p.Position = hrp.Position + Vector3.new(0,-5,0) end
								if p.Name == "Front" then p.Position = hrp.Position + Vector3.new(0,0,-5) end
								if p.Name == "Back" then p.Position = hrp.Position + Vector3.new(0,0,5) end
								if p.Name == "Left" then p.Position = hrp.Position + Vector3.new(-5,0,0) end
								if p.Name == "Right" then p.Position = hrp.Position + Vector3.new(5,0,0) end
							end
						end
					end
				else
					local cage = workspace:FindFirstChild("AntiKB_Cage_"..char.Name)
					if cage then cage:Destroy() end
				end
			end
		end

		task.wait(0.1)
	end
end)

--==================================================
-- GET ALL ITEMS
--==================================================

local TweenService = game:GetService("TweenService")
local RunService = game:GetService("RunService")

local GetAllItemsEnabled = false
local GetAllItemsRunning = false
local GetAllItemsNoclipConnection

--==================================================
-- NOCLIP
--==================================================

local function SetGetAllItemsNoclip(enabled)

	if GetAllItemsNoclipConnection then
		GetAllItemsNoclipConnection:Disconnect()
		GetAllItemsNoclipConnection = nil
	end

	if not enabled then

		local currentChar = lp.Character

		if currentChar then
			for _, obj in ipairs(currentChar:GetDescendants()) do
				if obj:IsA("BasePart") then
					obj.CanCollide = true
				end
			end
		end

		return
	end

	GetAllItemsNoclipConnection =
		RunService.Stepped:Connect(function()

			if not GetAllItemsEnabled then
				return
			end

			local currentChar = lp.Character

			if not currentChar then
				return
			end

			for _, obj in ipairs(currentChar:GetDescendants()) do
				if obj:IsA("BasePart") then
					obj.CanCollide = false
				end
			end
		end)
end

--==================================================
-- FIND CLOSEST TOOL
-- ALL TOOLS IN workspace.Items
--==================================================

local function FindClosestGetAllTool()

	local currentChar = lp.Character

	local hrp =
		currentChar
		and currentChar:FindFirstChild("HumanoidRootPart")

	if not hrp then
		return nil
	end

	local closest = nil
	local closestDistance = math.huge

	for _, tool in ipairs(Items:GetChildren()) do

		-- Accept EVERY Tool in workspace.Items.
		if tool:IsA("Tool") then

			local handle =
				tool:FindFirstChild("Handle")

			if handle
				and handle:IsA("BasePart")
				and handle.Parent then

				local distance =
					(handle.Position - hrp.Position).Magnitude

				if distance < closestDistance then

					closestDistance = distance
					closest = tool

				end
			end
		end
	end

	return closest
end

--==================================================
-- TWEEN TO TOOL
--==================================================

local function TweenToGetAllTool(tool)

	if not tool or not tool.Parent then
		return false
	end

	local currentChar = lp.Character

	local hrp =
		currentChar
		and currentChar:FindFirstChild("HumanoidRootPart")

	local handle =
		tool:FindFirstChild("Handle")

	if not hrp or not handle then
		return false
	end

	local targetPosition =
		handle.Position + Vector3.new(2, 0, 0)

	local targetCFrame =
		CFrame.new(
			targetPosition,
			handle.Position
		)

	local tweenInfo =
		TweenInfo.new(
			0.1,
			Enum.EasingStyle.Linear,
			Enum.EasingDirection.Out
		)

	local tween =
		TweenService:Create(
			hrp,
			tweenInfo,
			{
				CFrame = targetCFrame
			}
		)

	local finished = false

	local connection =
		tween.Completed:Connect(function()
			finished = true
		end)

	tween:Play()

	while not finished do

		if not GetAllItemsEnabled then

			tween:Cancel()

			if connection then
				connection:Disconnect()
			end

			return false
		end

		if not tool.Parent then

			tween:Cancel()

			if connection then
				connection:Disconnect()
			end

			return false
		end

		task.wait()
	end

	if connection then
		connection:Disconnect()
	end

	return true
end

--==================================================
-- PICK UP TOOL
--==================================================

local function GetAllPickup(tool)

	if not GetAllItemsEnabled then
		return false
	end

	if not tool or not tool.Parent then
		return false
	end

	local handle =
		tool:FindFirstChild("Handle")

	if not handle then
		return false
	end

	local id =
		handle:GetAttribute("ItemId")

	if not id then
		return false
	end

	ItemRemote:FireServer(id)

	local gui =
		handle:FindFirstChild("ItemGui")

	if gui then
		gui.Enabled = false
	end

	return true
end

--==================================================
-- GET ALL ITEMS LOOP
--==================================================

local function StartGetAllItems()

	if GetAllItemsRunning then
		return
	end

	GetAllItemsRunning = true

	while GetAllItemsEnabled do

		-- Use the same countdown requirement.
		if CountdownAllowed() then

			-- Always get the closest remaining Tool.
			local tool =
				FindClosestGetAllTool()

			if tool then

				-- Tween to tool for 0.4 seconds.
				local arrived =
					TweenToGetAllTool(tool)

				if arrived
					and GetAllItemsEnabled
					and tool.Parent then

					-- Wait 0.4 seconds after arriving.
					task.wait(0.4)

					if GetAllItemsEnabled
						and tool.Parent then

						-- Pick it up.
						GetAllPickup(tool)

						-- Wait 2 seconds before
						-- going to the next tool.
						task.wait(2)
					end

				else
					task.wait(0.1)
				end

			else

				-- No tools currently available.
				task.wait(0.1)

			end

		else

			-- Wait for the countdown.
			task.wait(0.1)

		end
	end

	GetAllItemsRunning = false
end

--==================================================
-- TOGGLE
--==================================================

ItemsTab:CreateToggle({
	Name = "Get all items",
	CurrentValue = false,

	Callback = function(v)
		GetAllItemsEnabled = v

		if v then
			-- Disable Get Items
			GetItemsEnabled = false
			CollectionRunning = false
			CollectionCooldown = false
			lastPicked = nil

			-- Enable Get All Items
			SetGetAllItemsNoclip(true)

			if not GetAllItemsRunning then
				task.spawn(StartGetAllItems)
			end
		else
			SetGetAllItemsNoclip(false)
		end
	end
})

--==================================================
-- CHARACTER RESPAWN
--==================================================

lp.CharacterAdded:Connect(function()

	task.wait(0.2)

	if GetAllItemsEnabled then
		SetGetAllItemsNoclip(true)
	end
end)

Features & Information

Script has Reach, Slap Aura, Auto win, Use Permanent items, Get Items, Auto Bomb Bus, Continue Get Items after bus, Player ESP, Item ESP, Early Bus Jump, Instant Landing, Remove zone effects, Delete all seats, Speed Boost, Lobby Hider, Get Lab Code, Anti Acid, Anti Lava, Anti Cubes of Deaths and Anti Ragdoll
#Slap Royale#Slap Battles#OP Slap Royale script#Keyless script#Slap

Community Comments (1)

GosermanGosermanOct 8, 2026

Comment here things I should improve and new features to add!

More Scripts for [UPDATE🏴‍☠️] Slap Battles👏