Candy Farm Toggleable Button
Key Required

Candy Farm Toggleable Button

[UPDATE] Ability Warsdavidisnotafurrydavidisnotafurry 4.8K views 609 executesUpdated Oct 31, 2025
2.1/ 5(7 votes)
3443% Positive
Lua Script•123 lines (3524 chars)
--// Candy Bowl + Candy Corn Instant Magnet GUI
-- Brings ALL candies (entire models) to player torso instantly
-- Offset 0.1 studs above torso

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

-- GUI Setup
local ScreenGui = Instance.new("ScreenGui")
ScreenGui.Name = "CandyMagnetGUI"
ScreenGui.ResetOnSpawn = false
ScreenGui.Parent = LocalPlayer:WaitForChild("PlayerGui")

-- Toggle Button
local ToggleButton = Instance.new("TextButton")
ToggleButton.Size = UDim2.new(0, 150, 0, 40)
ToggleButton.Position = UDim2.new(0.5, -75, 0.5, -20)
ToggleButton.BackgroundColor3 = Color3.fromRGB(255, 170, 0)
ToggleButton.Text = "Candy Magnet: OFF"
ToggleButton.TextColor3 = Color3.new(0, 0, 0)
ToggleButton.Font = Enum.Font.SourceSansBold
ToggleButton.TextScaled = true
ToggleButton.Draggable = true
ToggleButton.Active = true
ToggleButton.Selectable = true
ToggleButton.Parent = ScreenGui

-- Count Display
local CountBox = Instance.new("TextBox")
CountBox.Size = UDim2.new(1, 0, 0, 25)
CountBox.Position = UDim2.new(0, 0, 1, 0)
CountBox.BackgroundColor3 = Color3.fromRGB(255, 220, 150)
CountBox.Text = "Candies: 0"
CountBox.TextEditable = false
CountBox.TextScaled = true
CountBox.Font = Enum.Font.SourceSansBold
CountBox.Parent = ToggleButton

-- getNil function
local getNil = function(name, class)
	for _, v in next, getnilinstances() do
		if v.ClassName == class and v.Name == name then
			return v
		end
	end
end

-- Find all candies
local function FindCandies()
	local all = {}
	local count = 0
	for _, v in ipairs(workspace:GetChildren()) do
		if v and (v.Name == "Candy Bowl" or v.Name == "Candy Corn") then
			table.insert(all, v)
			count += 1
		end
	end

	-- Optional nil-instance search
	local nilBowl = getNil("Candy Bowl", "Model")
	local nilCorn = getNil("Candy Corn", "Model")
	if nilBowl then table.insert(all, nilBowl) count += 1 end
	if nilCorn then table.insert(all, nilCorn) count += 1 end

	return all, count
end

-- Main loop
local running = false

task.spawn(function()
	while true do
		if running then
			local char = LocalPlayer.Character
			local hrp = char and char:FindFirstChild("HumanoidRootPart")
			if hrp then
				local candies, count = FindCandies()
				CountBox.Text = "Candies: " .. count

				for _, candy in ipairs(candies) do
					if candy and candy:IsDescendantOf(workspace) then
						-- Move entire model if possible
						if candy:IsA("Model") then
							local primary = candy.PrimaryPart or candy:FindFirstChildWhichIsA("BasePart")
							if primary then
								local offset = hrp.CFrame.Position + Vector3.new(0, 0.1, 0)
								local delta = offset - primary.Position
								for _, part in ipairs(candy:GetDescendants()) do
									if part:IsA("BasePart") then
										part.CFrame = part.CFrame + delta
									end
								end
							end
						elseif candy:IsA("BasePart") then
							candy.CFrame = hrp.CFrame + Vector3.new(0, 0.1, 0)
						end
					end
				end
			end
		else
			local _, count = FindCandies()
			CountBox.Text = "Candies: " .. count
		end
		task.wait(0.01)
	end
end)

-- Toggle button
ToggleButton.MouseButton1Click:Connect(function()
	running = not running
	if running then
		ToggleButton.Text = "Candy Magnet: ON"
		ToggleButton.BackgroundColor3 = Color3.fromRGB(0, 255, 0)
	else
		ToggleButton.Text = "Candy Magnet: OFF"
		ToggleButton.BackgroundColor3 = Color3.fromRGB(255, 170, 0)
	end
end)

-- Respawn handling
LocalPlayer.CharacterAdded:Connect(function(char)
	local hrp = char:WaitForChild("HumanoidRootPart", 5)
end)

Features & Information

It just brings ALL candy to Ur torso. Thats all! Stays after respawnibg and when u respawn It keeps values (If It was on and i respawn It Will Spawn on If It was off off when u spawn)
#ABILITY WARS#Ability Wars

Community Comments (7)

davidisnotafurrydavidisnotafurryNov 1, 2025

No need to use lemon again. Script works perfectly. It brings candies Instead of going to them. No more lag.

animosityanimosityNov 2, 2025

works great. used gingerbread to hide while farming

Replying to @animosity
animosityanimosityNov 2, 2025(edited)

script's collect counter doesnt work, though. stuck on 2-3 (edit: does work, the counter was a candy collected per second, edit 2: wrong wgain ot was the candy in the map)

stopbeingnotsigmastopbeingnotsigmaNov 26, 2025

Bad script doesn't work anymore (this script is very bad and this Logs you)

Replying to @stopbeingnotsigma
davidisnotafurrydavidisnotafurryDec 20, 2025

@stopbeingnotsigma sir halloween is over 🥀

DuckhubDuckhubNov 26, 2025

I agree this doesn't work for me to This has hacked my Roblox account and Logged where I live

Replying to @Duckhub
davidisnotafurrydavidisnotafurryDec 20, 2025

@Moonsec sir i do NOT think you have an actual brain to think that i make viruses 🥀

More Scripts for [UPDATE] Ability Wars