Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- if any "hub owners" decide to use this in their gui, please put me in the credits somewhere kthx!
- local EliminatedSpeed = 150
- local MaxTimeAttempt = 10
- local SpinSpeed = 2500
- local NetworkCompensation = 5
- local Running = true
- local Gui = Instance.new("ScreenGui",game:GetService("CoreGui"))
- local StopButton = Instance.new("TextButton")
- StopButton.Size = UDim2.fromOffset(50,50)
- StopButton.Text = "Stop"
- StopButton.Position = UDim2.fromScale(0.5,0.8)
- StopButton.AnchorPoint = Vector2.new(0.5,0.5)
- StopButton.BorderSizePixel = 5
- StopButton.BorderColor3 = Color3.new(1,1,1)
- StopButton.BackgroundColor3 = Color3.new(0,0,0)
- StopButton.TextColor3 = Color3.new(1,1,1)
- StopButton.Parent = Gui
- StopButton.MouseButton1Click:Connect(function()
- Running = false
- Gui:Destroy()
- end)
- local function MakeChat(message,color)
- game:GetService("StarterGui"):SetCore("ChatMakeSystemMessage",{
- Text = message,
- Color = color
- })
- end
- MakeChat("Made by Zeezy/XYZ/Heioni",Color3.new(1,0,0))
- local TotalKills = 0
- local RunService = game:GetService("RunService")
- local Players = game:GetService("Players")
- local Player = Players.LocalPlayer
- local Camera = workspace.CurrentCamera
- workspace.Changed:Connect(function()
- Camera = workspace.CurrentCamera
- end)
- while Running do
- RunService.RenderStepped:Wait()
- local Character = Player.Character
- if Character then
- for i,v in ipairs(Character:GetDescendants()) do
- if v:IsA("BasePart") then
- v.CanCollide = false
- v.Velocity = Vector3.new(0,0,0)
- end
- end
- local Root = Character.PrimaryPart
- if Root then
- Camera.CameraType = Enum.CameraType.Scriptable
- local Target = Players:GetPlayers()[math.random(1,#Players:GetPlayers())]
- if Target ~= Player and Target.Character then
- local TargetRoot = Target.Character.PrimaryPart
- local EliminationStart = time() + MaxTimeAttempt
- if TargetRoot then
- while Running do
- if TargetRoot.Velocity.Magnitude > EliminatedSpeed then
- TotalKills = TotalKills + 1
- warn("Target killed! Finding new target")
- MakeChat("Target #" .. TotalKills.. " killed! Finding new target",Color3.new(0,1,0))
- break
- end
- if time() > EliminationStart then
- warn("Elapsed time went over max time per attempt, finding new target")
- MakeChat("Elapsed time went over max time per attempt, finding new target",Color3.new(1,1,0))
- break
- end
- local delta = RunService.RenderStepped:Wait()
- Camera.CFrame = CFrame.new(
- TargetRoot.Position + Vector3.new(10,10,10),
- TargetRoot.Position
- )
- Root.CFrame = TargetRoot.CFrame * CFrame.Angles(
- math.pi,
- math.random()*10,
- 0
- ) + Vector3.new(0,-1,0) + ((TargetRoot.Velocity*delta)*NetworkCompensation)
- Root.Velocity = Vector3.new(0,0,0)
- Root.RotVelocity = Vector3.new(0,SpinSpeed,0)
- end
- end
- end
- else
- Character:GetPropertyChangedSignal("PrimaryPart"):Wait()
- end
- else
- Player.CharacterAdded:Wait()
- end
- end
- workspace.CurrentCamera.CameraType = Enum.CameraType.Custom
- workspace.CurrentCamera.CameraSubject = Player.Character.Humanoid
- Player.Character.PrimaryPart.RotVelocity = Vector3.new()
- Player.Character.PrimaryPart.Velocity = Vector3.new() -- :3
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement