suramraja1

ggggg

Jun 17th, 2025 (edited)
50
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 10.91 KB | None | 0 0
  1. -- 💰 STEAL A BRAINROT - AUTO COLLECT v11.0
  2. -- Using smooth tween movement instead of teleport!
  3.  
  4. -- Services
  5. local Players = game:GetService("Players")
  6. local ReplicatedStorage = game:GetService("ReplicatedStorage")
  7. local TweenService = game:GetService("TweenService")
  8.  
  9. -- Player
  10. local player = Players.LocalPlayer
  11.  
  12. -- Tween variables
  13. local isTweening = false
  14.  
  15. -- Get Net system and ClaimCoins RemoteEvent
  16. local Net = require(ReplicatedStorage.Packages.Net)
  17. local ClaimCoinsRemote = Net:RemoteEvent("PlotService/ClaimCoins")
  18.  
  19. -- Use the game's PlotController
  20. local Controllers = ReplicatedStorage:WaitForChild("Controllers")
  21. local PlotController = require(Controllers.PlotController)
  22.  
  23. -- 📊 Visual Flow Diagram:
  24. --┌─ auto_collect_money() ─┐
  25. --│                        │
  26. --├─ Get Plot via Game API │
  27. --├─ Tween to Collection ───┼─ Smooth Movement → Fire RemoteEvent
  28. --├─ Fire ClaimCoins       │
  29. --│                        │
  30. --└─ Continue Loop         │
  31.  
  32.  
  33. local isFlyModeActive = false
  34. local flyModeThread = nil
  35.  
  36. local function toggleFlyMode()
  37.     isFlyModeActive = not isFlyModeActive
  38.    
  39.     if isFlyModeActive then
  40.         flyModeThread = spawn(function()
  41.             while isFlyModeActive do
  42.                 pcall(function()
  43.                     local player = game:GetService("Players").LocalPlayer
  44.                     local character = player.Character
  45.                     if not character then return end
  46.                    
  47.                     local humanoid = character:FindFirstChild("Humanoid")
  48.                     local rootPart = character:FindFirstChild("HumanoidRootPart")
  49.                     if not humanoid or not rootPart then return end
  50.                    
  51.                     local camera = workspace.CurrentCamera
  52.                     local UIS = game:GetService("UserInputService")
  53.                     local flySpeed = humanoid.WalkSpeed * 0.9
  54.                    
  55.                     -- Check if Gyro exists in rootPart, create if not
  56.                     local Gyro = rootPart:FindFirstChild("Gyro")
  57.                     if not Gyro then
  58.                         Gyro = Instance.new("BodyGyro")
  59.                         Gyro.Name = "Gyro"
  60.                         Gyro.P = 9e4
  61.                         Gyro.MaxTorque = Vector3.new(9e9, 9e9, 9e9)
  62.                         Gyro.Parent = rootPart
  63.                     end
  64.                    
  65.                     -- Check if BodyVelocity exists in rootPart, create if not
  66.                     local Velocity = rootPart:FindFirstChild("BodyVelocity")
  67.                     if not Velocity then
  68.                         Velocity = Instance.new("BodyVelocity")
  69.                         Velocity.Name = "BodyVelocity"
  70.                         Velocity.MaxForce = Vector3.new(9e9, 9e9, 9e9)
  71.                         Velocity.Velocity = Vector3.zero
  72.                         Velocity.Parent = rootPart
  73.                     end
  74.                    
  75.                     -- Set platform stand
  76.                     humanoid.PlatformStand = true
  77.                    
  78.                     -- Update Gyro CFrame
  79.                     Gyro.CFrame = CFrame.new(rootPart.Position, rootPart.Position + camera.CFrame.LookVector)
  80.                    
  81.                     -- Calculate movement direction based on key presses
  82.                     local moveDir = Vector3.new(0,0,0)
  83.                     if UIS:IsKeyDown(Enum.KeyCode.W) then moveDir = moveDir + camera.CFrame.LookVector end
  84.                     if UIS:IsKeyDown(Enum.KeyCode.S) then moveDir = moveDir - camera.CFrame.LookVector end
  85.                     if UIS:IsKeyDown(Enum.KeyCode.A) then moveDir = moveDir - camera.CFrame.RightVector end
  86.                     if UIS:IsKeyDown(Enum.KeyCode.D) then moveDir = moveDir + camera.CFrame.RightVector end
  87.                    
  88.                     -- Apply speed
  89.                     if moveDir.Magnitude > 0 then moveDir = moveDir.Unit * flySpeed end
  90.                     Velocity.Velocity = moveDir
  91.                 end)
  92.                
  93.                 task.wait(0.1)
  94.             end
  95.         end)
  96.     else
  97.         -- Clean up when toggled off
  98.         pcall(function()
  99.             local player = game:GetService("Players").LocalPlayer
  100.             local character = player.Character
  101.             if character then
  102.                 local humanoid = character:FindFirstChild("Humanoid")
  103.                 local rootPart = character:FindFirstChild("HumanoidRootPart")
  104.                
  105.                 if humanoid then humanoid.PlatformStand = false end
  106.                
  107.                 if rootPart then
  108.                     local Gyro = rootPart:FindFirstChild("Gyro")
  109.                     local Velocity = rootPart:FindFirstChild("BodyVelocity")
  110.                    
  111.                     if Gyro then Gyro:Destroy() end
  112.                     if Velocity then Velocity:Destroy() end
  113.                 end
  114.             end
  115.         end)
  116.     end
  117.    
  118.     return isFlyModeActive
  119. end
  120.  
  121. local isNoClipActive = false
  122. local noClipThread = nil
  123.  
  124. local function toggleNoClip()
  125.     isNoClipActive = not isNoClipActive
  126.    
  127.     if isNoClipActive then
  128.         noClipThread = spawn(function()
  129.             while isNoClipActive do
  130.                 pcall(function()
  131.                     local character = game.Players.LocalPlayer.Character
  132.                     if character then
  133.                         for _, v in pairs(character:GetDescendants()) do
  134.                             if v:IsA("BasePart") and v.CanCollide == true then
  135.                                 v.CanCollide = false
  136.                             end
  137.                         end
  138.                     end
  139.                 end)
  140.                 game:GetService("Players").LocalPlayer.CameraMaxZoomDistance = 20
  141.                 -- Set minimum zoom distance
  142.                 game:GetService("Players").LocalPlayer.CameraMinZoomDistance = 10
  143.                 -- Set current zoom distance
  144.                 camera.CFrame = camera.CFrame * CFrame.new(0, 0, 20)
  145.                 game:GetService("RunService").Stepped:Wait()
  146.             end
  147.         end)
  148.     else
  149.         -- Clean up when toggled off
  150.         pcall(function()
  151.             local character = game.Players.LocalPlayer.Character
  152.             if character then
  153.                 for _, v in pairs(character:GetDescendants()) do
  154.                     if v:IsA("BasePart") then
  155.                         v.CanCollide = true
  156.                     end
  157.                 end
  158.             end
  159.         end)
  160.     end
  161.    
  162.     return isNoClipActive
  163. end
  164.  
  165. function TweenCharacterToTarget(targetPart)
  166.     -- If already tweening, don't start a new tween
  167.     if isTweening then
  168.         return false
  169.     end
  170.    
  171.     -- Parameter validation
  172.     if not targetPart then
  173.         warn("Target part not provided!")
  174.         return false
  175.     end
  176.    
  177.     -- Mark as tweening
  178.     isTweening = true
  179.    
  180.     -- Fixed speed setting
  181.     local speed = 16
  182.    
  183.     -- Get Player and Character
  184.     local player = Players.LocalPlayer
  185.     local character = player.Character or player.CharacterAdded:Wait()
  186.     local humanoidRootPart = character:WaitForChild("HumanoidRootPart")
  187.    
  188.     -- Calculate direct target position
  189.     local startPosition = humanoidRootPart.Position
  190.     local targetPosition = targetPart.Position + Vector3.new(0, 0, 0) --  0 3 0 for Slightly above target
  191.     local targetCFrame = CFrame.new(targetPosition, targetPosition + humanoidRootPart.CFrame.LookVector)
  192.    
  193.     -- Calculate distance and time based on speed
  194.     local distance = (targetPosition - startPosition).Magnitude
  195.     local tweenTime = distance / speed
  196.    
  197.     -- Create single direct tween with calculated time
  198.     local tweenInfo = TweenInfo.new(tweenTime, Enum.EasingStyle.Linear, Enum.EasingDirection.Out)
  199.     local directTween = TweenService:Create(humanoidRootPart, tweenInfo, { CFrame = targetCFrame })
  200.    
  201.     -- Reset tweening flag when tween completes
  202.     directTween.Completed:Connect(function()
  203.         isTweening = false
  204.     end)
  205.    
  206.     -- Start the tween
  207.     directTween:Play()
  208.    
  209.     -- Return tween
  210.     return directTween
  211. end
  212.  
  213. local function auto_collect_money()
  214.     -- Get our plot using game's method
  215.     local myPlot = PlotController:GetMyPlot()
  216.     if not myPlot then return 0 end
  217.    
  218.     -- Get player character
  219.     local character = player.Character
  220.     if not character then return 0 end
  221.    
  222.     local rootPart = character:FindFirstChild("HumanoidRootPart")
  223.     if not rootPart then return 0 end
  224.    
  225.     local collected = 0
  226.    
  227.     -- Get AnimalPodiums
  228.     local animalPodiums = myPlot.PlotModel:FindFirstChild("AnimalPodiums")
  229.     if not animalPodiums then return 0 end
  230.    
  231.     -- Check each slot for money to collect
  232.     for slotNumber = 1, 10 do
  233.         local podium = animalPodiums:FindFirstChild(tostring(slotNumber))
  234.         if podium then
  235.             local claim = podium:FindFirstChild("Claim")
  236.             if claim then
  237.                 local main = claim:FindFirstChild("Main")
  238.                 if main then
  239.                     local collectButton = main:FindFirstChild("Collect")
  240.                     if collectButton and collectButton.Enabled then
  241.                         -- Tween to collection area using your function
  242.                         local hitbox = claim:FindFirstChild("Hitbox")
  243.                         if hitbox then
  244.                             print("💫 Tweening to collect from slot", slotNumber)
  245.                            
  246.                             local horizontalTween, verticalTween, downwardTween = TweenCharacterToTarget(hitbox)
  247.                            
  248.                             -- Wait for tween to complete
  249.                             if verticalTween then
  250.                                 verticalTween.Completed:Wait()
  251.                             end
  252.                                
  253.                             -- Small delay then fire RemoteEvent
  254.                             task.wait(0.3)
  255.                             ClaimCoinsRemote:FireServer(slotNumber)
  256.                             collected = collected + 1
  257.                            
  258.                             print("💰 Collected from slot", slotNumber)
  259.                             task.wait(0.5) -- Prevent spam
  260.                         end
  261.                     end
  262.                 end
  263.             end
  264.         end
  265.     end
  266.    
  267.     return collected
  268. end
  269.  
  270. print("🚀 Auto-Collect Money Started! (SMOOTH TWEEN VERSION)")
  271.  
  272. -- Wait for game to load
  273. task.wait(3)
  274.  
  275. -- Main loop
  276. while true do
  277.  
  278.     if not isFlyModeActive then
  279.         toggleFlyMode()
  280.     end
  281.  
  282.     if not isNoClipActive then
  283.         toggleNoClip()
  284.     end
  285.  
  286.  
  287.     if not isTweening then -- Only collect when not already tweening
  288.         local collected = auto_collect_money()
  289.        
  290.         if collected > 0 then
  291.             print("✅ Successfully collected from", collected, "animals using smooth tweens!")
  292.         end
  293.     end
  294.    
  295.     task.wait(2) -- Check every 2 seconds
  296. end
Add Comment
Please, Sign In to add comment