Zum Inhalt springen
Funktioniert

Cool Gym Game autofarm Xeno supported

CLclarkdevlinorg1 AufrufeUniversal26. Juli 2026
Teilen
Cool Gym Game autofarm Xeno supported

Script-Code

Lua
-- Cool gym autofarm - Walking System + Auto Clean

local player = game.Players.LocalPlayer
local character = player.Character or player.CharacterAdded:Wait()
local humanoid = character:WaitForChild("Humanoid")
local root = character:WaitForChild("HumanoidRootPart")

local autoFarm = false

local ScreenGui = Instance.new("ScreenGui")
ScreenGui.ResetOnSpawn = false
ScreenGui.Parent = player:WaitForChild("PlayerGui")

local Frame = Instance.new("Frame")
Frame.Size = UDim2.new(0, 290, 0, 180)
Frame.Position = UDim2.new(0.76, 0, 0.1, 0)
Frame.BackgroundColor3 = Color3.fromRGB(20, 20, 20)
Frame.BorderSizePixel = 0
Frame.Parent = ScreenGui

local Title = Instance.new("TextLabel")
Title.Size = UDim2.new(1, 0, 0, 40)
Title.BackgroundColor3 = Color3.fromRGB(30, 30, 30)
Title.Text = "Cool Gym Auto Farm v10"
Title.TextColor3 = Color3.new(1,1,1)
Title.Font = Enum.Font.GothamBold
Title.TextSize = 16
Title.Parent = Frame

local ToggleBtn = Instance.new("TextButton")
ToggleBtn.Size = UDim2.new(0.85, 0, 0, 55)
ToggleBtn.Position = UDim2.new(0.075, 0, 0.32, 0)
ToggleBtn.BackgroundColor3 = Color3.fromRGB(170, 0, 0)
ToggleBtn.Text = "START AUTO FARM"
ToggleBtn.TextColor3 = Color3.new(1,1,1)
ToggleBtn.Font = Enum.Font.GothamBold
ToggleBtn.TextSize = 16
ToggleBtn.Parent = Frame

local Status = Instance.new("TextLabel")
Status.Size = UDim2.new(1, 0, 0, 40)
Status.Position = UDim2.new(0, 0, 0.7, 0)
Status.BackgroundTransparency = 1
Status.Text = "Status: OFF"
Status.TextColor3 = Color3.fromRGB(255, 80, 80)
Status.Font = Enum.Font.Gotham
Status.TextSize = 14
Status.Parent = Frame

local function updateButton()
	if autoFarm then
		ToggleBtn.Text = "STOP AUTO FARM"
		ToggleBtn.BackgroundColor3 = Color3.fromRGB(0, 170, 0)
		Status.Text = "Searching for mess..."
		Status.TextColor3 = Color3.fromRGB(0, 255, 100)
	else
		ToggleBtn.Text = "START AUTO FARM"
		ToggleBtn.BackgroundColor3 = Color3.fromRGB(170, 0, 0)
		Status.Text = "Status: OFF"
		Status.TextColor3 = Color3.fromRGB(255, 80, 80)
	end
end

local function refreshCharacter()
	character = player.Character or player.CharacterAdded:Wait()
	humanoid = character:WaitForChild("Humanoid")
	root = character:WaitForChild("HumanoidRootPart")
end

local function isMessObject(obj)
	if not obj:IsA("BasePart") then return false end

	local name = obj.Name:lower()

	return name == "mess1"
		or name:find("water")
		or name:find("bottle")
		or name:find("puddle")
		or name:find("spill")
		or name:find("liquid")
end

local function findClosestMess()
	local closest = nil
	local shortest = math.huge

	for _, obj in ipairs(workspace:GetDescendants()) do
		if isMessObject(obj) then
			local dist = (root.Position - obj.Position).Magnitude

			if dist < shortest and dist < 150 then
				shortest = dist
				closest = obj
			end
		end
	end

	return closest
end

local function walkToPart(part)
	if not part or not part:IsDescendantOf(workspace) then
		return false
	end

	local reached = false
	local finished = false

	humanoid:MoveTo(part.Position)

	local conn
	conn = humanoid.MoveToFinished:Connect(function(success)
		reached = success
		finished = true
	end)

	local startTime = tick()

	while autoFarm and humanoid.Health > 0 and not finished do
		if not part:IsDescendantOf(workspace) then
			break
		end

		if tick() - startTime > 8 then
			break
		end

		task.wait(0.1)
	end

	if conn then
		conn:Disconnect()
	end

	return reached
end

local function cleanMess(mess)
	if not mess or not mess:IsDescendantOf(workspace) then return end

	root.CFrame = CFrame.lookAt(root.Position, mess.Position)

	local prompt = mess:FindFirstChildOfClass("ProximityPrompt")

	if not prompt and mess.Parent then
		prompt = mess.Parent:FindFirstChildOfClass("ProximityPrompt")
	end

	if prompt then
		fireproximityprompt(prompt, 2.5)
	end
end

ToggleBtn.MouseButton1Click:Connect(function()
	autoFarm = not autoFarm
	updateButton()

	if autoFarm then
		refreshCharacter()

		while autoFarm and humanoid.Health > 0 do
			local closest = findClosestMess()

			if closest then
				Status.Text = "Walking to: " .. closest.Name

				local reached = walkToPart(closest)

				if reached and autoFarm then
					Status.Text = "Cleaning: " .. closest.Name
					cleanMess(closest)
					task.wait(0.6)
				else
					Status.Text = "Could not reach mess"
					task.wait(0.5)
				end
			else
				humanoid:Move(Vector3.new(0, 0, 0), false)
				Status.Text = "No mess found..."
				task.wait(1)
			end
		end
	else
		if humanoid then
			humanoid:Move(Vector3.new(0, 0, 0), false)
		end
	end
end)

Beschreibung

you need to zoom out to make this script work

Kommentare (0)

Melde an, um an der Unterhaltung teilzunehmen

  • Sei der Erste, der kommentiert.

Häufig gestellte Fragen

Wie verwende ich den Cool Gym Game autofarm Xeno supported-Script?
Kopiere den obigen Code, öffne deinen Roblox-Executor, füge den Code ein und drücke Ausführen, während du im Spiel bist. Die Funktionen werden sofort aktiviert, sobald der Script läuft.
Ist der Cool Gym Game autofarm Xeno supported-Script kostenlos?
Ja. Dieser Script ist völlig kostenlos zu kopieren und zu verwenden. Wenn er ein Schlüsselsystem nutzt, folge dem Link "Schlüssel erhalten", um ihn kostenlos freizuschalten.
Ist der Cool Gym Game autofarm Xeno supported-Script sicher zu verwenden?
Der vollständige Quellcode wird auf dieser Seite angezeigt, damit du genau lesen kannst, was er tut, bevor du ihn ausführst. Verwende immer einen vertrauenswürdigen Executor, und denke daran, dass die Verwendung von Scripts gegen die Nutzungsbedingungen von Roblox verstößt — verwende sie auf eigene Gefahr.
Welcher Executor funktioniert mit Cool Gym Game autofarm Xeno supported?
Dieser Script funktioniert mit den meisten beliebten Roblox-Executoren. Besuche unsere Executor-Seite, um einen vertrauenswürdigen kostenlosen oder kostenpflichtigen Executor für dein Gerät zu finden.
Cool Gym Game autofarm Xeno supported | BloxScripter