Advertisement
SigmaBoy456

Roblox catalog heaven Script Kill all v1 WORKING

May 27th, 2024
547
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 2.23 KB | None | 0 0
  1. local DrRayLibrary = loadstring(game:HttpGet("https://raw.githubusercontent.com/AZYsGithub/DrRay-UI-Library/main/DrRay.lua"))()
  2. local window = DrRayLibrary:Load("Catalog Heaven GUI v1", "Default")
  3. local tab = DrRayLibrary.newTab("Catalog Heaven Script", "ImageIdHere")
  4. tab.newButton("Rocket kill all", "MUST EQUIP ROCKET TO WORK", function()
  5.     local function main()
  6.     local player = game.Players.LocalPlayer
  7.  
  8.     -- Function to generate a random position near the target position
  9.     local function getRandomPositionNear(targetPos)
  10.         local range = 10 -- Define the range around the target position
  11.         local randomOffset = Vector3.new(
  12.             math.random(-range, range),
  13.             math.random(-range, range),
  14.             math.random(-range, range)
  15.         )
  16.         return targetPos + randomOffset
  17.     end
  18.  
  19.     for _, otherPlayer in ipairs(game.Players:GetPlayers()) do
  20.         if otherPlayer ~= player then
  21.             local character = otherPlayer.Character
  22.             local myCharacter = player.Character
  23.            
  24.             -- Ensure both characters exist and have a HumanoidRootPart
  25.             if character and character:FindFirstChild("HumanoidRootPart") and myCharacter and myCharacter:FindFirstChild("HumanoidRootPart") then
  26.                 local otherPos = character.HumanoidRootPart.Position
  27.                 local myPos = myCharacter.HumanoidRootPart.Position
  28.                
  29.                 -- Generate two random positions around the other player's position
  30.                 local randomPos1 = getRandomPositionNear(otherPos)
  31.                 local randomPos2 = getRandomPositionNear(otherPos)
  32.                
  33.                 local args = {
  34.                     [1] = randomPos1,
  35.                     [2] = randomPos2
  36.                 }
  37.  
  38.                 -- Fire the rocket
  39.                 myCharacter.RocketJumper.FireRocket:FireServer(unpack(args))
  40.             end
  41.         end
  42.     end
  43. end
  44.  
  45. while true do
  46. main()
  47.     wait(0.5)
  48.     end
  49.    
  50. end)
  51. tab.newButton("Get the Rocket Here", "Get Rocket to kill all", function()
  52.     local args = {
  53.     [1] = 169602103
  54. }
  55.  
  56. game:GetService("ReplicatedStorage"):WaitForChild("Remotes"):WaitForChild("ToggleAsset"):InvokeServer(unpack(args))
  57.    
  58. end)
  59.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement