Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Save the entire Lua script as a string
- local scriptSource = [[
- -- Whitelist Usernames
- local whitelistedUsers = {
- "RavyyFrm", -- Add any usernames you want to allow here
- "iiu9017", -- Example of another whitelisted user
- }
- local player = game.Players.LocalPlayer
- local username = player.Name
- -- Function to check if user is whitelisted
- local function isWhitelisted(userName)
- for _, whitelistedName in ipairs(whitelistedUsers) do
- if userName == whitelistedName then
- return true
- end
- end
- return false
- end
- -- Check if the player is whitelisted
- if isWhitelisted(username) then
- -- If whitelisted, load the UI library
- local library = loadstring(game:HttpGet("https://raw.githubusercontent.com/Consistt/Ui/main/UnLeaked"))()
- library.rank = "developer"
- local Wm = library:Watermark("xsx example | v" .. library.version .. " | " .. library:GetUsername() .. " | rank: " .. library.rank)
- local FpsWm = Wm:AddWatermark("fps: " .. library.fps)
- coroutine.wrap(function()
- while wait(.75) do
- FpsWm:Text("fps: " .. library.fps)
- end
- end)()
- local Notif = library:InitNotifications()
- local LoadingXSX = Notif:Notify("Loading xsx lib v2, please be patient.", 5, "information")
- library.title = "Vigil"
- library:Introduction()
- wait(1)
- local Init = library:Init()
- -- Fly Tab
- local Tab1 = Init:NewTab("Flying Tab")
- local Section1 = Tab1:NewSection("Fly Components")
- -- Fly script (Modified)
- local function initializeFlying(character)
- local humanoid = character:WaitForChild("Humanoid")
- local userInputService = game:GetService("UserInputService")
- local camera = game.Workspace.CurrentCamera -- Reference to the camera
- local flying = false -- Track flying status
- local flyingSpeed = 500 -- Set flying speed
- local bodyGyro, bodyVelocity -- Objects for smooth flight
- local drag = 2 -- Drag for smoother flight
- -- Function to start or stop flying
- local function toggleFly()
- flying = not flying -- Toggle flying status
- if flying then
- -- Create BodyGyro for smooth turning
- bodyGyro = Instance.new("BodyGyro")
- bodyGyro.MaxTorque = Vector3.new(400000, 400000, 400000) -- Max torque for smooth turning
- bodyGyro.CFrame = character.HumanoidRootPart.CFrame
- bodyGyro.Parent = character.HumanoidRootPart
- -- Create BodyVelocity for controlled flight
- bodyVelocity = Instance.new("BodyVelocity")
- bodyVelocity.MaxForce = Vector3.new(400000, 400000, 400000)
- bodyVelocity.Velocity = Vector3.new(0, 0, 0) -- Initial velocity is 0
- bodyVelocity.P = 10000 -- High power for responsive movement
- bodyVelocity.Parent = character.HumanoidRootPart
- -- Disable gravity and auto-rotation while flying
- humanoid.PlatformStand = true
- humanoid.AutoRotate = false
- -- Fly movement loop
- game:GetService("RunService").Heartbeat:Connect(function()
- if flying then
- -- Calculate forward movement direction based on the camera's facing direction
- local moveDirection = camera.CFrame.LookVector
- local rightDirection = camera.CFrame.RightVector
- local upDirection = Vector3.new(0, 1, 0)
- -- Start by setting velocity to zero
- local velocity = Vector3.new(0, 0, 0)
- -- Horizontal movement (WASD)
- if userInputService:IsKeyDown(Enum.KeyCode.W) then
- velocity = velocity + moveDirection * flyingSpeed
- end
- if userInputService:IsKeyDown(Enum.KeyCode.S) then
- velocity = velocity - moveDirection * flyingSpeed
- end
- if userInputService:IsKeyDown(Enum.KeyCode.A) then
- velocity = velocity - rightDirection * flyingSpeed
- end
- if userInputService:IsKeyDown(Enum.KeyCode.D) then
- velocity = velocity + rightDirection * flyingSpeed
- end
- -- Vertical movement (Spacebar and Shift)
- if userInputService:IsKeyDown(Enum.KeyCode.Space) then
- velocity = velocity + upDirection * flyingSpeed
- end
- if userInputService:IsKeyDown(Enum.KeyCode.LeftShift) then
- velocity = velocity - upDirection * flyingSpeed
- end
- -- Smooth out the movement by applying drag (slows the movement for smoother flying)
- bodyVelocity.Velocity = velocity - bodyVelocity.Velocity * drag * game:GetService("RunService").Heartbeat:Wait()
- -- Smooth rotation towards the camera's facing direction
- bodyGyro.CFrame = CFrame.new(character.HumanoidRootPart.Position, character.HumanoidRootPart.Position + camera.CFrame.LookVector)
- else
- -- Reset and stop flying
- bodyVelocity:Destroy()
- bodyGyro:Destroy()
- humanoid.PlatformStand = false
- humanoid.AutoRotate = true
- end
- end)
- else
- -- Reset and stop flying
- bodyVelocity:Destroy()
- bodyGyro:Destroy()
- humanoid.PlatformStand = false
- humanoid.AutoRotate = true
- end
- end
- -- Create Fly button to toggle flying
- local Button1 = Tab1:NewButton("Fly", function()
- toggleFly() -- Trigger flying when the button is pressed
- end)
- end
- -- Reinitialize flying system after player respawns
- player.CharacterAdded:Connect(function(character)
- initializeFlying(character)
- end)
- -- Buttons for other features (Esp, Inf Jump, etc.)
- local scriptLoaded = false -- Variable to check if the script is loaded
- local Button2 = Tab1:NewButton("Esp", function()
- if not scriptLoaded then
- -- Load and execute the script
- loadstring(game:HttpGet("https://pastebin.com/raw/UAvMUgPK"))() -- Replace with your desired script URL
- scriptLoaded = true -- Mark the script as loaded
- else
- -- If needed, add functionality to "unload" the script here
- -- For example, reset the state or stop the effects of the loaded script
- scriptLoaded = false -- Mark the script as unloaded
- end
- end)
- local Button4 = Tab1:NewButton("Inf Jump", function()
- if not scriptLoaded then
- -- Load and execute the script
- loadstring(game:HttpGet("https://pastebin.com/raw/1erE1nrB"))() -- Replace with your desired script URL
- scriptLoaded = true -- Mark the script as loaded
- else
- -- If needed, add functionality to "unload" the script here
- -- For example, reset the state or stop the effects of the loaded script
- scriptLoaded = false -- Mark the script as unloaded
- end
- end)
- local Button5 = Tab1:NewButton("Instant Prompts", function()
- if not scriptLoaded then
- -- Load and execute the script
- loadstring(game:HttpGet("https://pastebin.com/raw/bgg6xuVd"))() -- Replace with your desired script URL
- scriptLoaded = true -- Mark the script as loaded
- else
- -- If needed, add functionality to "unload" the script here
- -- For example, reset the state or stop the effects of the loaded script
- scriptLoaded = false -- Mark the script as unloaded
- end
- end)
- -- Create the new tab
- local Tab2 = Init:NewTab("By Pass")
- -- Create "No FallDamage" button in the new tab
- local Button3 = Tab2:NewButton("No FallDamage", function()
- if not scriptLoaded then
- -- Load and execute the script
- loadstring(game:HttpGet("https://pastebin.com/raw/R1j7qrKF"))() -- Replace with your desired script URL
- scriptLoaded = true -- Mark the script as loaded
- else
- -- If needed, add functionality to "unload" the script here
- -- For example, reset the state or stop the effects of the loaded script
- scriptLoaded = false -- Mark the script as unloaded
- end
- end)
- -- Create "Eat Bypass" button in the new tab
- local Button3 = Tab2:NewButton("Eat Bypass", function()
- if not scriptLoaded then
- -- Load and execute the script
- loadstring(game:HttpGet("https://pastebin.com/raw/5d6JgAPy"))() -- Replace with your desired script URL
- scriptLoaded = true -- Mark the script as loaded
- else
- -- If needed, add functionality to "unload" the script here
- -- For example, reset the state or stop the effects of the loaded script
- scriptLoaded = false -- Mark the script as unloaded
- end
- end)
- else
- -- If the player is not whitelisted, show a notification
- local NotificationHolder = loadstring(game:HttpGet("https://raw.githubusercontent.com/BocusLuke/UI/main/STX/Module.Lua"))()
- local Notification = loadstring(game:HttpGet("https://raw.githubusercontent.com/BocusLuke/UI/main/STX/Client.Lua"))()
- Notification:Notify(
- {Title = "You are not whitelisted!", Description = "Get whitelisted at https://discord.gg/CcB32rDc9c"},
- {OutlineColor = Color3.fromRGB(255, 0, 0), Time = 5, Type = "option"},
- {Image = "http://www.roblox.com/asset/?id=6023426923", ImageColor = Color3.fromRGB(255, 84, 84)}
- )
- end
- ]]
- -- Restart the entire script upon respawn
- game.Players.LocalPlayer.CharacterAdded:Connect(function()
- loadstring(scriptSource)() -- Execute the entire script again
- end)
- -- Initial execution of the script
- loadstring(scriptSource)() -- Run the script the first time
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement