0% found this document useful (0 votes)
94 views2 pages

Main Lua

Uploaded by

Ferid Qalayev
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
94 views2 pages

Main Lua

Uploaded by

Ferid Qalayev
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 2

local OrionLib =

loadstring(game:HttpGet(('https://raw.githubusercontent.com/shlexware/Orion/main/
source')))()
local Window = OrionLib:MakeWindow({Name = "LuckyPotion - Made by yelpsupreme",
HidePremium = false, SaveConfig = true, ConfigFolder = "OrionTest"})

local Tab = Window:MakeTab({


Name = nil,
Icon = "rbxassetid://4483345998",
PremiumOnly = false
})

Tab:AddButton({
Name = "AutoFarm",
Callback = function()
-- Function to teleport the player to all Hitbox parts sequentially
local function teleportToHitboxes()
local player = game.Players.LocalPlayer
local character = player.Character or player.CharacterAdded:Wait()
local humanoidRootPart = character:WaitForChild("HumanoidRootPart")

while true do
-- Find all Hitbox parts in the Workspace
local hitboxes = {}
for _, part in pairs(game:GetService("Workspace"):GetDescendants()) do
if part:IsA("Part") and part.Name == "Hitbox" then
table.insert(hitboxes, part)
end
end

-- Teleport to each Hitbox part in sequence


for _, hitbox in ipairs(hitboxes) do
humanoidRootPart.CFrame = hitbox.CFrame
wait(1) -- Wait 1 second before moving to the next Hitbox
end
end
end

-- Execute the function


teleportToHitboxes()

end
})

OrionLib:MakeNotification({
Name = "AutoFarm Warning",
Content = "Restart to stop autofarm",
Image = "rbxassetid://4483345998",
Time = 5
})

Tab:AddButton({
Name = "Reset",
Callback = function()
-- Function to reset the player's character
local function resetCharacter()
local player = game.Players.LocalPlayer
if player and player.Character then
-- Option 1: Reset the player's character by setting the Humanoid's Health
to 0
local humanoid = player.Character:FindFirstChildOfClass("Humanoid")
if humanoid then
humanoid.Health = 0
end

-- Option 2: Alternatively, you could use the player's CharacterAdded event


to reset
-- player:LoadCharacter()
end
end

-- Execute the function to reset the character


resetCharacter()

end
})

You might also like