Advertisement
Guest User

Roblox universal script

a guest
Nov 12th, 2024
1,020
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 21.67 KB | None | 0 0
  1. -
  2. Download Here --> https://tinyurl.com/589dan33 (Copy and Paste Link)
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9. Name already in use
  10. A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
  11. Aimbot-V2 / Resources / Scripts / Main.lua
  12. This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
  13. 1 contributor
  14. Users who have contributed to this file
  15.  
  16. Open with Desktop
  17. View raw
  18. Copy raw contents Copy raw contents Copy raw contents
  19. This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
  20. -- // Preventing Multiple Processes pcall ( function () getgenv (). Aimbot . Functions : Exit () end ) -- // Environment getgenv (). Aimbot = local Environment = getgenv (). Aimbot -- // Services local RunService = game: GetService ( " RunService " ) local UserInputService = game: GetService ( " UserInputService " ) local HttpService = game: GetService ( " HttpService " ) local TweenService = game: GetService ( " TweenService " ) local StarterGui = game: GetService ( " StarterGui " ) local Players = game: GetService ( " Players " ) local Camera = game: GetService ( " Workspace " ). CurrentCamera -- // Variables local LocalPlayer = Players. LocalPlayer local Title = " Exunys Developer " local FileNames = local Typing, Running, Animation, RequiredDistance, ServiceConnections = false , false , nil , 2000 , -- // Support Functions local mousemoverel = mousemoverel or (Input and Input. MouseMove ) local queueonteleport = queue_on_teleport or syn. queue_on_teleport -- // Script Settings Environment. Settings = SendNotifications = true , SaveSettings = true , -- Re-execute upon changing ReloadOnTeleport = true , Enabled = true , TeamCheck = false , AliveCheck = true , WallCheck = false , -- Laggy Sensitivity = 0 , -- Animation length (in seconds) before fully locking onto target ThirdPerson = false , -- Uses mousemoverel instead of CFrame to support locking in third person (could be choppy) ThirdPersonSensitivity = 3 , -- Boundary: 0.1 - 5 TriggerKey = " MouseButton2 " , Toggle = false , LockPart = " Head " -- Body part to lock on > Environment. FOVSettings = Enabled = true , Visible = true , Amount = 90 , Color = " 255, 255, 255 " , LockedColor = " 255, 70, 70 " , Transparency = 0.5 , Sides = 60 , Thickness = 1 , Filled = false > Environment. FOVCircle = Drawing. new ( " Circle " ) Environment. Locked = nil -- // Core Functions local function Encode ( Table ) if Table and type (Table) == " table " then local EncodedTable = HttpService: JSONEncode (Table) return EncodedTable end end local function Decode ( String ) if String and type (String) == " string " then local DecodedTable = HttpService: JSONDecode (String) return DecodedTable end end local function GetColor ( Color ) local R = tonumber ( string.match (Color, " ([%d]+)[%s]*,[%s]*[%d]+[%s]*,[%s]*[%d]+ " )) local G = tonumber ( string.match (Color, " [%d]+[%s]*,[%s]*([%d]+)[%s]*,[%s]*[%d]+ " )) local B = tonumber ( string.match (Color, " [%d]+[%s]*,[%s]*[%d]+[%s]*,[%s]*([%d]+) " )) return Color3. fromRGB (R, G, B) end local function SendNotification ( TitleArg , DescriptionArg , DurationArg ) if Environment. Settings . SendNotifications then StarterGui: SetCore ( " SendNotification " , Title = TitleArg, Text = DescriptionArg, Duration = DurationArg >) end end -- // Functions local function SaveSettings () if Environment. Settings . SaveSettings then if isfile (Title .. " / " .. FileNames[ 1 ] .. " / " .. FileNames[ 2 ]) then writefile (Title .. " / " .. FileNames[ 1 ] .. " / " .. FileNames[ 2 ], Encode (Environment. Settings )) end if isfile (Title .. " / " .. FileNames[ 1 ] .. " / " .. FileNames[ 3 ]) then writefile (Title .. " / " .. FileNames[ 1 ] .. " / " .. FileNames[ 3 ], Encode (Environment. FOVSettings )) end end end local function GetClosestPlayer () if not Environment. Locked then if Environment. FOVSettings . Enabled then RequiredDistance = Environment. FOVSettings . Amount else RequiredDistance = 2000 end for _, v in next, Players: GetPlayers () do if v ~= LocalPlayer then if v. Character and v. Character : FindFirstChild (Environment. Settings . LockPart ) and v. Character : FindFirstChildOfClass ( " Humanoid " ) then if Environment. Settings . TeamCheck and v. Team == LocalPlayer. Team then continue end if Environment. Settings . AliveCheck and v. Character : FindFirstChildOfClass ( " Humanoid " ). Health if Environment. Settings . WallCheck and # (Camera: GetPartsObscuringTarget (, v. Character : GetDescendants ())) > 0 then continue end local Vector, OnScreen = Camera: WorldToViewportPoint (v. Character [Environment. Settings . LockPart ]. Position ) local Distance = (Vector2. new (UserInputService: GetMouseLocation (). X , UserInputService: GetMouseLocation (). Y ) - Vector2. new (Vector. X , Vector. Y )). Magnitude if Distance RequiredDistance = Distance Environment. Locked = v end end end end elseif (Vector2. new (UserInputService: GetMouseLocation (). X , UserInputService: GetMouseLocation (). Y ) - Vector2. new (Camera: WorldToViewportPoint (Environment. Locked . Character [Environment. Settings . LockPart ]. Position ). X , Camera: WorldToViewportPoint (Environment. Locked . Character [Environment. Settings . LockPart ]. Position ). Y )). Magnitude > RequiredDistance then Environment. Locked = nil Animation: Cancel () Environment. FOVCircle . Color = GetColor (Environment. FOVSettings . Color ) end end -- // Typing Check ServiceConnections. TypingStartedConnection = UserInputService. TextBoxFocused : Connect ( function () Typing = true end ) ServiceConnections. TypingEndedConnection = UserInputService. TextBoxFocusReleased : Connect ( function () Typing = false end ) -- // Create, Save & Load Settings if Environment. Settings . SaveSettings then if not isfolder (Title) then makefolder (Title) end if not isfolder (Title .. " / " .. FileNames[ 1 ]) then makefolder (Title .. " / " .. FileNames[ 1 ]) end if not isfile (Title .. " / " .. FileNames[ 1 ] .. " / " .. FileNames[ 2 ]) then writefile (Title .. " / " .. FileNames[ 1 ] .. " / " .. FileNames[ 2 ], Encode (Environment. Settings )) else Environment. Settings = Decode ( readfile (Title .. " / " .. FileNames[ 1 ] .. " / " .. FileNames[ 2 ])) end if not isfile (Title .. " / " .. FileNames[ 1 ] .. " / " .. FileNames[ 3 ]) then writefile (Title .. " / " .. FileNames[ 1 ] .. " / " .. FileNames[ 3 ], Encode (Environment. FOVSettings )) else Environment. Visuals = Decode ( readfile (Title .. " / " .. FileNames[ 1 ] .. " / " .. FileNames[ 3 ])) end coroutine.wrap ( function () while wait ( 10 ) and Environment. Settings . SaveSettings do SaveSettings () end end )() else if isfolder (Title) then delfolder (Title) end end local function Load () ServiceConnections. RenderSteppedConnection = RunService. RenderStepped : Connect ( function () if Environment. FOVSettings . Enabled and Environment. Settings . Enabled then Environment. FOVCircle . Radius = Environment. FOVSettings . Amount Environment. FOVCircle . Thickness = Environment. FOVSettings . Thickness Environment. FOVCircle . Filled = Environment. FOVSettings . Filled Environment. FOVCircle . NumSides = Environment. FOVSettings . Sides Environment. FOVCircle . Color = GetColor (Environment. FOVSettings . Color ) Environment. FOVCircle . Transparency = Environment. FOVSettings . Transparency Environment. FOVCircle . Visible = Environment. FOVSettings . Visible Environment. FOVCircle . Position = Vector2. new (UserInputService: GetMouseLocation (). X , UserInputService: GetMouseLocation (). Y ) else Environment. FOVCircle . Visible = false end if Running and Environment. Settings . Enabled then GetClosestPlayer () if Environment. Settings . ThirdPerson then Environment. Settings . ThirdPersonSensitivity = math. clamp (Environment. Settings . ThirdPersonSensitivity , 0.1 , 5 ) local Vector = Camera: WorldToViewportPoint (Environment. Locked . Character [Environment. Settings . LockPart ]. Position ) mousemoverel ((Vector. X - UserInputService: GetMouseLocation (). X ) * Environment. Settings . ThirdPersonSensitivity , (Vector. Y - UserInputService: GetMouseLocation (). Y ) * Environment. Settings . ThirdPersonSensitivity ) else if Environment. Settings . Sensitivity > 0 then Animation = TweenService: Create (Camera, TweenInfo. new (Environment. Settings . Sensitivity , Enum. EasingStyle . Sine , Enum. EasingDirection . Out ), ) Animation: Play () else Camera. CFrame = CFrame. new (Camera. CFrame . Position , Environment. Locked . Character [Environment. Settings . LockPart ]. Position ) end end Environment. FOVCircle . Color = GetColor (Environment. FOVSettings . LockedColor ) end end ) ServiceConnections. InputBeganConnection = UserInputService. InputBegan : Connect ( function ( Input ) if not Typing then pcall ( function () if Input. KeyCode == Enum. KeyCode [Environment. Settings . TriggerKey ] then if Environment. Settings . Toggle then Running = not Running if not Running then Environment. Locked = nil Animation: Cancel () Environment. FOVCircle . Color = GetColor (Environment. FOVSettings . Color ) end else Running = true end end end ) pcall ( function () if Input. UserInputType == Enum. UserInputType [Environment. Settings . TriggerKey ] then if Environment. Settings . Toggle then Running = not Running if not Running then Environment. Locked = nil Animation: Cancel () Environment. FOVCircle . Color = GetColor (Environment. FOVSettings . Color ) end else Running = true end end end ) end end ) ServiceConnections. InputEndedConnection = UserInputService. InputEnded : Connect ( function ( Input ) if not Typing then pcall ( function () if Input. KeyCode == Enum. KeyCode [Environment. Settings . TriggerKey ] then if not Environment. Settings . Toggle then Running = false Environment. Locked = nil Animation: Cancel () Environment. FOVCircle . Color = GetColor (Environment. FOVSettings . Color ) end end end ) pcall ( function () if Input. UserInputType == Enum. UserInputType [Environment. Settings . TriggerKey ] then if not Environment. Settings . Toggle then Running = false Environment. Locked = nil Animation: Cancel () Environment. FOVCircle . Color = GetColor (Environment. FOVSettings . Color ) end end end ) end end ) end -- // Functions Environment. Functions = function Environment. Functions : Exit () SaveSettings () for _, v in next, ServiceConnections do v: Disconnect () end if Environment. FOVCircle . Remove then Environment. FOVCircle : Remove () end getgenv (). Aimbot . Functions = nil getgenv (). Aimbot = nil end function Environment. Functions : Restart () SaveSettings () for _, v in next, ServiceConnections do v: Disconnect () end Load () end function Environment. Functions : ResetSettings () Environment. Settings = SendNotifications = true , SaveSettings = true , -- Re-execute upon changing ReloadOnTeleport = true , Enabled = true , TeamCheck = false , AliveCheck = true , WallCheck = false , Sensitivity = 0 , -- Animation length (in seconds) before fully locking onto target ThirdPerson = false , ThirdPersonSensitivity = 3 , TriggerKey = " MouseButton2 " , Toggle = false , LockPart = " Head " -- Body part to lock on > Environment. FOVSettings = Enabled = true , Visible = true , Amount = 90 , Color = " 255, 255, 255 " , LockedColor = " 255, 70, 70 " , Transparency = 0.5 , Sides = 60 , Thickness = 1 , Filled = false > end -- // Support Check if not Drawing or not getgenv then SendNotification (Title, " Your exploit does not support this script " , 3 ); return end -- // Reload On Teleport if Environment. Settings . ReloadOnTeleport then if queueonteleport then queueonteleport (game: HttpGet ( " https://raw.githubusercontent.com/Exunys/Aimbot-V2/main/Resources/Scripts/Main.lua " )) else SendNotification (Title, " Your exploit does not support \" syn.queue_on_teleport() \" " ) end end -- // Load Load (); SendNotification (Title, " Aimbot script successfully loaded! Check the GitHub page on how to configure the script. " , 5 )
  21. Exunys/Aimbot-V2
  22. This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
  23. Name already in use
  24. A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
  25. Sign In Required
  26. Please sign in to use Codespaces.
  27. Launching GitHub Desktop
  28. If nothing happens, download GitHub Desktop and try again.
  29. Launching GitHub Desktop
  30. If nothing happens, download GitHub Desktop and try again.
  31. Launching Xcode
  32. If nothing happens, download Xcode and try again.
  33. Launching Visual Studio Code
  34. Your codespace will open once ready.
  35. There was a problem preparing your codespace, please try again.
  36. Latest commit
  37. Git stats
  38. Files
  39. Failed to load latest commit information.
  40. README.md
  41. ℹ️ This repository is discontinued. Use the new script AirHub.
  42. This script is a universal aim-locking script. Works on all games which use the default character. This specific version has lots of crucial improvements such as:
  43.  
  44. More Functions / Features & Settings
  45. Security / Decreased Detection Risk
  46. Optimized & Organized Code
  47. Speed / Faster Execution & Functionality
  48. Configurable Settings
  49. Storing
  50. Execution / Precise & Efficient
  51. Third Person Support
  52.  
  53. This project is completely free and open sourced. But, that does not mean you own rights to it. Read this document for more information. You can re-use / stitch this script or any system of this project into any of your repositories, as long as you credit the developer Exunys.
  54.  
  55. [23/10/2022] - Added Third Person Support (Read Script Examples)
  56. [08/01/2023] - Bug fixes, optimizations & new script - Aimbot V2 GUI (Read Aimbot V2 GUI)
  57.  
  58.  
  59. The script will not function properly unless your exploit fully supports / includes these following functions & libraries:
  60. isfolder() , makefolder() & delfolder()
  61. isfile() , writefile() & delfile()
  62. getgenv()
  63. syn.queue_on_teleport() / queue_on_teleport()
  64. Drawing
  65.  
  66. getgenv().Aimbot.Settings.SaveSettings = false
  67.  
  68. This script is indeed universal, but it might not run on games with specific character constructions (custom characters).
  69. A recommended exploit to run this script on is Synapse X.
  70.  
  71. The script's environment is stored as:
  72. More on how to configure the aimbot below this part.
  73. This script includes settings which can be easily configured to your preference.
  74. getgenv().Aimbot.Settings = = true, SaveSettings = true, -- Re-execute upon changing ReloadOnTeleport = true, Enabled = true, TeamCheck = false, AliveCheck = true, WallCheck = false, -- Laggy Sensitivity = 0, -- Animation length (in seconds) before fully locking onto target ThirdPerson = false, -- Uses mousemoverel instead of CFrame to support locking in third person (could be choppy) ThirdPersonSensitivity = 3, -- Boundary: 0.1 - 5 TriggerKey = "MouseButton2", Toggle = false, LockPart = "Head" -- Body part to lock on (Character part's name) > getgenv().Aimbot.FOVSettings = = true, Visible = true, Amount = 90, Color = "255, 255, 255", LockedColor = "255, 70, 70", Transparency = 0.5, Sides = 60, Thickness = 1, Filled = false >
  75. Graphic View (Horizontal Tree Diagram)
  76. ⚠️ WARNING ⚠️ - The WallCheck function is very laggy, it is recommended you have it set as false at all times!
  77.  
  78. You can also find the JSON format (which is the way they get stored) here.
  79. The Lua format of the settings / the factory reset script can be found here.
  80.  
  81. By reading the visual representation of the configuration part of the environment table, it should be pretty easy to configure the script afterwards. Here are some examples:
  82. The following script will disable the aimbot temporarily:
  83. getgenv().Aimbot.Settings.Enabled = false
  84. You can also change the color of the FOV Circle:
  85. getgenv().Aimbot.FOVSettings.Color = "50, 255, 70" -- The colors must be fed as strings in RGB format. [(R)ed (0 - 255); (G)reen (0 - 255); (B)lue (0 - 255)]
  86. The script only accepts RGB configurations in strings as colors, if you input anything else, the script will break and not execute. Read below on how to fix this.
  87. You can also disable FOV Checking incase you don't find it useful / don't need it:
  88. getgenv().Aimbot.FOVSettings.Enabled = false
  89. If you want the script to work in third person, you can enable the ThirdPerson setting:
  90. getgenv().Aimbot.Settings.ThirdPerson = true
  91. If you want to edit the sensitivity for the third person mode:
  92. -- The locking animation becomes faster as you increase the value (meaning 5 = fastest). The script becomes choppy if you increase the value. getgenv().Aimbot.Settings.ThirdPersonSensitivity = 3 -- Boundary: 0.1 - 5
  93. The options are endless, you can configure the script in any way you desire.
  94. Read about the input types and more information about the drawing library in use for the FOV Circle (to learn how to configure it) here.
  95. If you want to disable the script saving the settings & delete the saved settings, you can do that automatically by executing the code below:
  96. getgenv().Aimbot.Settings.SaveSettings = false loadstring(game:HttpGet("https://raw.githubusercontent.com/Exunys/Aimbot-V2/main/Resources/Scripts/Delete%20Settings%20-%20Fix%20Script.lua"))()
  97. If the script is not running upon execution, try a few of the solutions below:
  98.  
  99. There is possibly a configuration that is unacceptable at most cases. Execute this script and restart your game for changes to take effect.
  100. Open your exploit's root folder, find a folder named workspace and look for a folder named Exunys Developer , inside there should be another folder named Aimbot . Once you find it, delete this folder and restart your game.
  101.  
  102. If none of these solutions work, check if your exploit is supported (read the Notices part). If the script still doesn't work, contact Exunys & report the problem you are experiencing in detail.
  103. Check if your exploit is supported here.
  104. If you want to change the key you want to press to trigger the Aimbot, configure the TriggerKey setting.
  105. getgenv().Aimbot.Settings.TriggerKey = "E" -- E is the key's name (This is equivalent to Enum.KeyCode.E, except, the script only handles strings)
  106. getgenv().Aimbot.Settings.TriggerKey = "MouseButton1" -- MouseButton1 is the key's name [LMB] (This is equivalent to Enum.UserInputType.MouseButton1, except, the script only handles strings)
  107. This script will work if the input type selected is either a KeyCode or UserInputType so all you have to input is the last part / the key's name.
  108. This script includes built-in functions to control the Aimbot. The functions can be accessed by indexing Functions in the Environment. Example:
  109.  
  110. Functions:Exit()
  111. Exits (unexecutes) the script and leaves no traces back.
  112.  
  113. Restarts the script, good for incase the script starts lagging.
  114.  
  115. Factory resets the settings and wipes the previous ones that were saved to the workspace.
  116.  
  117. Exit
  118.  
  119. getgenv().Aimbot.Functions:Exit()
  120. getgenv().Aimbot.Functions:Restart()
  121. getgenv().Aimbot.Functions:ResetSettings()
  122. Settings used in the video above:
  123. getgenv().Aimbot.Settings.Sensitivity = 0.5 getgenv().Aimbot.FOVSettings.Amount = 300 getgenv().Aimbot.FOVSettings.Sides = 18 getgenv().Aimbot.FOVSettings.Transparency = 1 getgenv().Aimbot.FOVSettings.Thickness = 2 getgenv().Aimbot.FOVSettings.Color = "25, 70, 200"
  124. The video above presents the Environment.Functions:ResetSettings() function. Read the Functions part for more.
  125. getgenv().Aimbot.Functions:ResetSettings()
  126. The video above presents the Environment.Functions:Exit() function. Read the Functions part for more.
  127. getgenv().Aimbot.Functions:Exit()
  128. The video above shows how the script functions when the Environment.Settings.ThirdPerson value is set to true .
  129. getgenv().Aimbot.Settings.ThirdPerson = true
  130. The video above shows the Aimbot V2 GUI.
  131.  
  132. This source does not include any Exunys Developer systems like storing the settings, sending notifications, using colors as strings, reloading the script on teleport etc.
  133. This source is more optimized and relatively smaller to allow the user to modify the code and freely put it into their own script. But of course, do not forget that this script has a license.
  134. The raw source can be found here.
  135.  
  136. This script can be found here. The script is powered by Pepsi's UI Library and it uses the Raw Aimbot V2 Source.
  137. This script is the same as the raw source but implemented into a UI Library which can be used as an independent script rather then an embeddable script for other developers.
  138. Load the script by copying it from here or by executing the code below.
  139. loadstring(game:HttpGet("https://raw.githubusercontent.com/Exunys/Aimbot-V2/main/Resources/Scripts/Aimbot%20V2%20GUI.lua"))()
  140. Default (With Exunys Developer Systems)
  141. Load the script by copying it from here or by executing the code below.
  142. loadstring(game:HttpGet("https://raw.githubusercontent.com/Exunys/Aimbot-V2/main/Resources/Scripts/Main.lua"))()
  143. Raw (Without Exunys Developer Systems)
  144. Load the script by copying it from here or by executing the code below.
  145. loadstring(game:HttpGet("https://raw.githubusercontent.com/Exunys/Aimbot-V2/main/Resources/Scripts/Raw%20Main.lua"))()
  146. Developer Contact Information
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement