Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local Settings = {
- Aimbot = false,
- Smoothness = 50,
- TeamCheck = false,
- FovUsed = false,
- Fov = 100,
- Boxes = false,
- Names = false,
- Walkspeed = 16,
- Jumppower = 50,
- CtrlClickTP = false
- }
- local RunService = game:GetService("RunService")
- local UserInputService = game:GetService("UserInputService")
- local Camera = game:GetService("Workspace").CurrentCamera
- local Players = game:GetService("Players")
- local Player = Players.LocalPlayer
- local Mouse = Player:GetMouse()
- local Library = loadstring(game:HttpGet("https://raw.githubusercontent.com/xHeptc/Kavo-UI-Library/main/source.lua"))()
- local Window = Library.CreateLib("Bye mohamed", "Ocean")
- local Main = Window:NewTab('Main')
- local MainSection = Main:NewSection("Main")
- local Circle = Drawing.new("Circle")
- Circle.Color = Color3.new(1, 1, 1)
- Circle.Thickness = 1
- Circle.Radius = Settings.Fov
- Circle.Visible = Settings.FovUsed
- Circle.NumSides = 1000
- Circle.Filled = false
- Circle.Transparency = 1
- MainSection:NewToggle('Use Fov', "fov", function(Bool)
- Settings.FovUsed = Bool
- Circle.Visible = Bool
- end)
- MainSection:NewToggle('Aimbot', "aim player at the head", function(Bool)
- Settings.Aimbot = Bool
- end)
- MainSection:NewSlider('Smoothness', "smoothnees", 1, 250, function(Number)
- Settings.Smoothness = Number
- end)
- MainSection:NewSlider('Fov', "hmm", 1, 1000, function(Number)
- Settings.Fov = Number
- Circle.Radius = Number
- end)
- MainSection:NewToggle('Box Esp', "box around players", function(Bool)
- Settings.Boxes = Bool
- end)
- MainSection:NewToggle('Name Esp', "gives name of the players", function(Bool)
- Settings.Names = Bool
- end)
- local Char = Window:NewTab('Character')
- local CharSection = Char:NewSection("Char")
- CharSection:NewLabel("Warning! Some features may be detected depending on the game.")
- CharSection:NewSlider('Walk Speed', "walk speed", 16, 100, function(Number)
- Settings.Walkspeed = Number
- if Player.Character ~= nil and Player.Character:FindFirstChild("Humanoid") then
- Player.Character.Humanoid.WalkSpeed = Number
- end
- end)
- CharSection:NewSlider('Jump Power', "hmm", 50, 250, function(Number)
- Settings.Jumppower = Number
- if Player.Character ~= nil and Player.Character:FindFirstChild("Humanoid") then
- Player.Character.Humanoid.JumpPower = Number
- end
- end)
- CharSection:NewKeybind("Keybind", "KeybindInfo", Enum.KeyCode.P, function()
- Library:ToggleUI()
- end)
- CharSection:NewButton("Fly", "bird mode", function()
- loadstring(game:HttpGet("https://cdn.wearedevs.net/scripts/Fly.txt"))()
- end)
- CharSection:NewButton("Rejoin", "Rejoins you to the same server", function()
- game:GetService("TeleportService"):Teleport(game.PlaceId, game:GetService("Players").LocalPlayer)
- end)
- CharSection:NewToggle('Ctrl Click TP', "hold ctrl to tp somewhere", function(Bool)
- Settings.CtrlClickTP = Bool
- end)
- function DrawText()
- local Text = Drawing.new("Text")
- Text.Color = Color3.fromRGB(190, 190, 0)
- Text.Size = 20
- Text.Outline = true
- Text.Center = true
- return Text
- end
- function DrawSquare()
- local Box = Drawing.new("Square")
- Box.Color = Color3.fromRGB(190, 190, 0)
- Box.Thickness = 0.5
- Box.Filled = false
- Box.Transparency = 1
- return Box
- end
- function IsPlayerAlive(player)
- if player.Character ~= nil and player.Character:FindFirstChild("HumanoidRootPart") then
- return true
- end
- return false
- end
- function GetOffset(part, pos)
- local FarPosition = Camera:WorldToViewportPoint(Vector3.new(part.Position.X, part.Position.Y + (part.Size.Y / 2), part.Position.Z))
- return FarPosition.Y - pos.Y
- end
- function GetCorners(player)
- local TopY = math.huge
- local BottomY = -math.huge
- local RightX = -math.huge
- local LeftX = math.huge
- local Offsets
- local Positions = {}
- for i, v in next, player.Character:GetChildren() do
- if v.ClassName == "MeshPart" or v.Name == "Head" then
- local Position, OnScreen = Camera:WorldToViewportPoint(v.Position)
- Positions[v.Name] = Position
- Offsets = GetOffset(v, Position)
- if OnScreen then
- if Position.Y < TopY then
- TopY = Position.Y
- end
- if Position.Y > BottomY then
- BottomY = Position.Y
- end
- if Position.X < LeftX then
- LeftX = Position.X
- end
- if Position.X > RightX then
- RightX = Position.X
- end
- end
- end
- end
- return {TopLeft = Vector2.new(LeftX + Offsets, TopY + Offsets), TopRight = Vector2.new(RightX - Offsets, TopY + Offsets), BottomLeft = Vector2.new(LeftX + Offsets, BottomY - Offsets), BottomRight = Vector2.new(RightX - Offsets, BottomY - Offsets), Positions = Positions}
- end
- function GetClosest()
- local Closest = nil
- local Magnitude = math.huge
- for i, v in next, Players:GetPlayers() do
- if v ~= Player and IsPlayerAlive(v) then
- if not Settings.TeamCheck or Settings.TeamCheck and v.Team ~= LocalPlayer.Team then
- local Position, Visible = Camera:WorldToScreenPoint(v.Character["HumanoidRootPart"].Position)
- if Visible then
- local Mouse = Player:GetMouse()
- local Distance = (Vector2.new(Mouse.X, Mouse.Y) - Vector2.new(Position.X, Position.Y)).Magnitude
- if not Settings.FovUsed and Distance < Magnitude or Settings.FovUsed and Distance < Magnitude and Distance < Settings.Fov then
- Closest = v
- Magnitude = Distance
- end
- end
- end
- end
- end
- return Closest
- end
- function AddEsp(player)
- local Box = DrawSquare()
- local Name = DrawText()
- RunService.Stepped:Connect(function()
- IsAlive = IsPlayerAlive(player)
- if IsAlive and player.Character:FindFirstChild("HumanoidRootPart") then
- local Corners = GetCorners(player)
- local Positions = Corners.Positions
- local xDist = Corners.BottomRight.X - Corners.TopLeft.X
- local yDist = Corners.BottomRight.Y - Corners.TopLeft.Y
- local RootPosition, OnScreen = Camera:WorldToViewportPoint(player.Character.HumanoidRootPart.Position)
- if Settings.Boxes then
- Box.Visible = OnScreen
- Box.Size = Vector2.new(xDist, yDist)
- Box.Position = Corners.TopLeft
- else
- Box.Visible = false
- end
- if Settings.Names then
- Name.Visible = OnScreen
- Name.Position = Vector2.new(Corners.BottomRight.X - (xDist / 2), Corners.TopLeft.Y - 45)
- Name.Text = player.Name
- else
- Name.Visible = false
- end
- else
- Box.Visible = false
- Name.Visible = false
- end
- end)
- end
- for i, v in pairs(Players:GetPlayers()) do
- if v ~= Player then
- AddEsp(v)
- end
- end
- Players.PlayerAdded:Connect(function(player)
- if v ~= Player then
- AddEsp(player)
- end
- end)
- Mouse.Button1Down:Connect(function()
- if Settings.CtrlClickTP and Player.Character ~= nil then
- if UserInputService:IsKeyDown(Enum.KeyCode.LeftControl) or UserInputService:IsKeyDown(Enum.KeyCode.RightControl) then
- Player.Character:MoveTo(Mouse.Hit.Position)
- end
- end
- end)
- RunService.RenderStepped:Connect(function()
- local Mouse = UserInputService:GetMouseLocation()
- Circle.Position = Vector2.new(Mouse.X, Mouse.Y)
- end)
- while wait(0.05) do
- if Settings.Aimbot and UserInputService:IsMouseButtonPressed(Enum.UserInputType.MouseButton2) then
- local Target = GetClosest()
- if Target ~= nil then
- local Position = Camera:WorldToViewportPoint(Target.Character.Head.Position)
- local Mouse = UserInputService:GetMouseLocation()
- mousemoverel((Position.X - Mouse.X) / (Settings.Smoothness / 10), (Position.Y - Mouse.Y) / (Settings.Smoothness / 10))
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement