Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local Library = loadstring(game:HttpGet("https://raw.githubusercontent.com/xHeptc/Kavo-UI-Library/main/source.lua"))()
- local Window = Library.CreateLib("Seiko Scripts", "Synapse")
- local Tab = Window:NewTab("Game Name")
- local Section = Tab:NewSection("Sub and like")
- Section:NewButton("ButtonText", "ButtonInfo", function()-- Create ScreenGui
- local screenGui = Instance.new("ScreenGui")
- screenGui.Parent = game.Players.LocalPlayer:WaitForChild("PlayerGui")
- screenGui.ResetOnSpawn = false
- -- Create Frame (Stylized with Neon)
- local frame = Instance.new("Frame")
- frame.Parent = screenGui
- frame.BackgroundColor3 = Color3.fromRGB(10, 10, 10)
- frame.Size = UDim2.new(0, 250, 0, 150)
- frame.Position = UDim2.new(0.5, -125, 0.5, -75)
- frame.Active = true
- frame.Draggable = true
- frame.BorderSizePixel = 0
- frame.BackgroundTransparency = 0.3
- -- Add Neon Outline Effect
- local neonOutline = Instance.new("UIStroke")
- neonOutline.Parent = frame
- neonOutline.Thickness = 5
- neonOutline.ApplyStrokeMode = Enum.ApplyStrokeMode.Border
- neonOutline.Color = Color3.fromRGB(0, 255, 255)
- neonOutline.Transparency = 0.5
- -- Add Background Gradient
- local gradient = Instance.new("UIGradient")
- gradient.Parent = frame
- gradient.Color = ColorSequence.new{
- ColorSequenceKeypoint.new(0, Color3.fromRGB(30, 30, 30)),
- ColorSequenceKeypoint.new(1, Color3.fromRGB(50, 50, 50))
- }
- gradient.Rotation = 45
- -- Create On Button
- local onButton = Instance.new("TextButton")
- onButton.Parent = frame
- onButton.BackgroundColor3 = Color3.fromRGB(0, 255, 0)
- onButton.Size = UDim2.new(0, 80, 0, 40)
- onButton.Position = UDim2.new(0, 20, 0, 20)
- onButton.Text = "ON"
- onButton.TextScaled = true
- onButton.TextColor3 = Color3.fromRGB(0, 0, 0)
- onButton.BorderSizePixel = 0
- -- Neon Effect for On Button
- local onNeon = Instance.new("UIStroke")
- onNeon.Parent = onButton
- onNeon.Thickness = 4
- onNeon.ApplyStrokeMode = Enum.ApplyStrokeMode.Border
- onNeon.Color = Color3.fromRGB(0, 255, 255)
- onNeon.Transparency = 0.5
- -- Create Off Button
- local offButton = Instance.new("TextButton")
- offButton.Parent = frame
- offButton.BackgroundColor3 = Color3.fromRGB(255, 0, 0)
- offButton.Size = UDim2.new(0, 80, 0, 40)
- offButton.Position = UDim2.new(0, 140, 0, 20)
- offButton.Text = "OFF"
- offButton.TextScaled = true
- offButton.TextColor3 = Color3.fromRGB(0, 0, 0)
- offButton.BorderSizePixel = 0
- -- Neon Effect for Off Button
- local offNeon = Instance.new("UIStroke")
- offNeon.Parent = offButton
- offNeon.Thickness = 4
- offNeon.ApplyStrokeMode = Enum.ApplyStrokeMode.Border
- offNeon.Color = Color3.fromRGB(0, 255, 255)
- offNeon.Transparency = 0.5
- -- Create Destroy Button
- local destroyButton = Instance.new("TextButton")
- destroyButton.Parent = frame
- destroyButton.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
- destroyButton.Size = UDim2.new(0, 200, 0, 40)
- destroyButton.Position = UDim2.new(0, 20, 0, 100)
- destroyButton.Text = "Destroy GUI"
- destroyButton.TextScaled = true
- destroyButton.TextColor3 = Color3.fromRGB(0, 0, 0)
- destroyButton.BorderSizePixel = 0
- -- Create Status Indicator
- local statusLabel = Instance.new("TextLabel")
- statusLabel.Parent = frame
- statusLabel.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
- statusLabel.Size = UDim2.new(0, 250, 0, 30)
- statusLabel.Position = UDim2.new(0, 0, 0, -30)
- statusLabel.Text = "WallHop By Luffy: OFF"
- statusLabel.TextColor3 = Color3.fromRGB(255, 0, 0)
- statusLabel.TextScaled = true
- statusLabel.TextStrokeTransparency = 0.5
- -- Variables for Wallhop Functionality
- local toggle = false
- local InfiniteJumpEnabled = true -- Acts as debounce
- local UserInputService = game:GetService("UserInputService")
- local Players = game:GetService("Players")
- local Workspace = game:GetService("Workspace")
- local RunService = game:GetService("RunService")
- local raycastParams = RaycastParams.new()
- raycastParams.FilterType = Enum.RaycastFilterType.Blacklist
- -- Filter list will be updated dynamically
- -- Precise wall detection function - Returns RaycastResult
- local function getWallRaycastResult()
- local player = Players.LocalPlayer
- local character = player.Character
- if not character then return nil end
- local humanoidRootPart = character:FindFirstChild("HumanoidRootPart")
- if not humanoidRootPart then return nil end
- raycastParams.FilterDescendantsInstances = {character}
- local directions = {
- humanoidRootPart.CFrame.LookVector,
- -humanoidRootPart.CFrame.LookVector,
- humanoidRootPart.CFrame.RightVector,
- -humanoidRootPart.CFrame.RightVector
- }
- local detectionDistance = 2
- local closestHit = nil
- local minDistance = detectionDistance + 1
- for _, direction in pairs(directions) do
- local ray = Workspace:Raycast(
- humanoidRootPart.Position,
- direction * detectionDistance,
- raycastParams
- )
- if ray and ray.Instance then
- if ray.Distance < minDistance then
- minDistance = ray.Distance
- closestHit = ray
- end
- end
- end
- return closestHit
- end
- -- Button Functions
- onButton.MouseButton1Click:Connect(function()
- statusLabel.Text = "WallHop By Luffy: ON"
- statusLabel.TextColor3 = Color3.fromRGB(0, 255, 0)
- toggle = true
- end)
- offButton.MouseButton1Click:Connect(function()
- statusLabel.Text = "WallHop By Luffy: OFF"
- statusLabel.TextColor3 = Color3.fromRGB(255, 0, 0)
- toggle = false
- end)
- destroyButton.MouseButton1Click:Connect(function()
- screenGui:Destroy()
- end)
- -- Wallhop Function - ADDED ROTATION BACK TOWARDS WALL
- UserInputService.JumpRequest:Connect(function()
- if not toggle or not InfiniteJumpEnabled then return end
- local player = Players.LocalPlayer
- local character = player.Character
- local humanoid = character and character:FindFirstChildOfClass("Humanoid")
- local rootPart = character and character:FindFirstChild("HumanoidRootPart")
- local camera = Workspace.CurrentCamera
- if not (humanoid and rootPart and camera) then return end
- local wallRayResult = getWallRaycastResult()
- if wallRayResult then
- InfiniteJumpEnabled = false -- Start debounce immediately
- -- 1. Calculate Base Direction Away from Wall
- local wallNormal = wallRayResult.Normal
- local horizontalWallNormal = Vector3.new(wallNormal.X, 0, wallNormal.Z).Unit
- if horizontalWallNormal.Magnitude < 0.1 then
- horizontalWallNormal = (rootPart.CFrame.LookVector * Vector3.new(1,0,1)).Unit
- if horizontalWallNormal.Magnitude < 0.1 then horizontalWallNormal = Vector3.new(0,0,-1) end
- end
- local baseDirectionAwayFromWall = horizontalWallNormal -- Store this original direction
- -- 2. Get Camera's Horizontal Look Direction
- local cameraLook = camera.CFrame.LookVector
- local horizontalCameraLook = Vector3.new(cameraLook.X, 0, cameraLook.Z).Unit
- if horizontalCameraLook.Magnitude < 0.1 then horizontalCameraLook = baseDirectionAwayFromWall end
- -- 3. Calculate Initial Rotation (Away from Wall, Camera Influenced)
- local maxInfluenceAngle = math.rad(40)
- local dot = math.clamp(baseDirectionAwayFromWall:Dot(horizontalCameraLook), -1, 1)
- local angleBetween = math.acos(dot)
- local cross = baseDirectionAwayFromWall:Cross(horizontalCameraLook)
- local rotationSign = math.sign(cross.Y)
- if rotationSign == 0 then angleBetween = 0 end
- local actualInfluenceAngle = math.min(angleBetween, maxInfluenceAngle)
- local adjustmentRotation = CFrame.Angles(0, actualInfluenceAngle * rotationSign, 0)
- local initialTargetLookDirection = adjustmentRotation * baseDirectionAwayFromWall
- -- 4. Apply Initial Rotation FIRST
- rootPart.CFrame = CFrame.lookAt(rootPart.Position, rootPart.Position + initialTargetLookDirection)
- -- 5. Wait a very short moment (one frame)
- RunService.Heartbeat:Wait()
- -- 6. Apply Jump
- local didJump = false
- if humanoid and humanoid:GetState() ~= Enum.HumanoidStateType.Dead then
- humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
- didJump = true -- Track if the jump actually happened
- end
- -- 7. Apply Rotation BACK towards the wall IF the jump occurred
- if didJump then
- local directionTowardsWall = -baseDirectionAwayFromWall -- Reverse the original away direction
- -- Use the root part's current position as the origin for lookAt
- rootPart.CFrame = CFrame.lookAt(rootPart.Position, rootPart.Position + directionTowardsWall)
- end
- -- Post-jump cooldown
- task.wait(0.15)
- InfiniteJumpEnabled = true -- End debounce
- end
- end)
- -- Your script here remove this text
- print("Clicked")
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement