Advertisement
Guest User

Aimbot by Phoenix

a guest
Jun 18th, 2019
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 9.76 KB | None | 0 0
  1. local TS = require(game.ReplicatedStorage.Tortoiseshell)
  2. TS.Console:Log("--|_Phoenix Initialized_|--", Color3.fromRGB(255,10,255))
  3.  
  4.  
  5. function run()
  6. spawn(function()
  7. local function epic_esp(model)
  8. local human = Instance.new("Humanoid",model);
  9. if human and model.Name ~= game.Players.LocalPlayer.Name then
  10. human.HealthDisplayDistance = math.huge;
  11. human.HealthDisplayType = Enum.HumanoidHealthDisplayType.AlwaysOn;
  12. human.NameDisplayDistance = math.huge;
  13. human.NameOcclusion = Enum.NameOcclusion.NoOcclusion;
  14. end;
  15. end;
  16.  
  17. for _,p in next,workspace.Characters:children'' do
  18. epic_esp(p)
  19. end;
  20.  
  21. workspace.Characters.ChildAdded:Connect(function(c)
  22. epic_esp(c)
  23. end)
  24. end)
  25.  
  26.  
  27.  
  28.  
  29.  
  30. -----------------------------------// aimbot script
  31.  
  32.  
  33. local cam = workspace.Camera
  34. local camera = workspace.Camera
  35. local plr = game:service'Players'.LocalPlayer
  36. local t
  37. local mouse = plr:GetMouse()
  38. local aimbot = true
  39. local whitelisted = {
  40. plr.Name;
  41. }
  42.  
  43. local ray = Ray.new
  44. local ray_start
  45.  
  46.  
  47.  
  48.  
  49. local checkifwhitelisted = function(nam)
  50. local asd = false
  51.  
  52. for _, a in pairs(whitelisted) do
  53. if nam == a then
  54. asd = true
  55. end
  56. end
  57.  
  58. return asd
  59. end
  60.  
  61. _G.gofor = "Head"
  62. local lPlayerTeam = nil
  63.  
  64. function checkteam(name)
  65. local teams = game.Teams
  66. local plr_team = nil
  67. for i,v in pairs(teams:GetDescendants()) do
  68. if plr_team == nil then
  69. if v.Name == name then
  70. plr_team = v.Parent
  71. return plr_team
  72. end
  73. end
  74. end
  75. end
  76. lPlayerTeam = checkteam(plr.Name)
  77.  
  78. function CheckIf(name)
  79. for i,v in pairs(workspace.Characters:children()) do
  80. if checkteam(name) ~= lPlayerTeam then
  81. return true
  82. end
  83. end
  84. return false
  85. end
  86.  
  87. local function getcloseplayer()
  88. --pcall(function()
  89. local ignorelist = workspace.Characters[plr.Name].Hitbox:children''
  90. for i,v in pairs(workspace:children'') do
  91. if v:IsA("Model") then
  92. table.insert(ignorelist,v)
  93. end
  94. end
  95. local closestDist = 2e9
  96. local player
  97.  
  98. for _, a in pairs(workspace.Characters:children()) do
  99. if a:IsA'Model' and game:service'Players':FindFirstChild(a.Name) and a.Name ~= plr.Name and checkifwhitelisted(a.Name) == false and CheckIf(a.Name) and a ~= nil then
  100.  
  101. local dist = (workspace.Characters[plr.Name].Root.Position - a.Root.Position).magnitude
  102.  
  103. if dist < closestDist then
  104. if a ~= nil and a:FindFirstChild'Hitbox' then
  105. if a.Hitbox:FindFirstChild'Head' then
  106. pcall(function()
  107. ray_start = workspace.Characters[plr.Name].Hitbox.Head.Position
  108. local vector = ( a.Hitbox.Head.Position - ray_start)
  109. local new_ray = ray(ray_start, vector.unit * 1000)
  110. local hit, position = workspace:FindPartOnRayWithIgnoreList(new_ray, ignorelist)
  111.  
  112. if (hit and hit:isDescendantOf(a.Hitbox)) then
  113. closestDist = dist
  114. player = a.Hitbox
  115. end
  116. end)
  117. end
  118. end
  119. end
  120.  
  121.  
  122. end
  123. end
  124.  
  125. return player
  126. --end)
  127. end
  128.  
  129. mouse.KeyDown:connect(function(key)
  130. if key == "[" then
  131. if aimbot then
  132. aimbot = false
  133. else
  134. aimbot = true
  135. end
  136. end
  137. end)
  138.  
  139. local closesthead = nil
  140.  
  141.  
  142. --------------------------------------------------------------------------////////////////////////// Cam Scripto
  143.  
  144. game.Players.LocalPlayer.PlayerScripts.CameraScript.Disabled = true
  145. local UserInputService = game:GetService("UserInputService")
  146. local ReplicatedStorage = game:GetService("ReplicatedStorage")
  147. local Workspace = game:GetService("Workspace")
  148. local Players = game:GetService("Players")
  149. local TS = require(ReplicatedStorage:WaitForChild("Tortoiseshell"))
  150. local PLAYER = Players.LocalPlayer
  151. local CAMERA = Workspace.CurrentCamera
  152. local OFFSET = Vector3.new(0, 1.6, 0)
  153. local SPRINT_FOV_SCALE = 0.9
  154. local LEAN_DISTANCE = 2
  155. local LEAN_TILT = 0.15
  156. local MIN_Y, MAX_Y = -1.5, 1.5
  157. local SENSITIVITY = Vector2.new(0.004, 0.004)
  158. local recoilSpring = TS.Math.Spring:Create(1, 200, 30, 1)
  159. TS.Camera.FirstPerson.RecoilSpring = recoilSpring
  160. local character, root, state, sprinting, lean, vaulting, grounded, climbing, aiming, look, sliding, backpack, items, equipped, item, config
  161. local x, y = 0, 0
  162. local leanOffset = CFrame.new()
  163. local lastUpdate = 0
  164. local actionSpring = TS.Math.Spring:Create(1, 100, 10, 1)
  165. local slideFOV = 0
  166. local spectateChar
  167. local function Equipped(newItem)
  168. pcall(function()
  169. config = nil
  170. item = nil
  171. if newItem then
  172. config = TS.Items:GetConfig(newItem)
  173. item = newItem
  174. end
  175. end)
  176. end
  177. local function HandleCharacter(newCharacter)
  178. if newCharacter then
  179. character = nil
  180. spectateChar = nil
  181. root = newCharacter:WaitForChild("Root")
  182. state = newCharacter:WaitForChild("State")
  183. sprinting = state:WaitForChild("Sprinting")
  184. lean = state:WaitForChild("Lean")
  185. vaulting = state:WaitForChild("Vaulting")
  186. grounded = state:WaitForChild("Grounded")
  187. climbing = state:WaitForChild("Climbing")
  188. aiming = state:WaitForChild("Aiming")
  189. look = state:WaitForChild("Look")
  190. sliding = state:WaitForChild("Sliding")
  191. backpack = newCharacter:WaitForChild("Backpack")
  192. equipped = backpack:WaitForChild("Equipped")
  193. items = backpack:WaitForChild("Items")
  194. equipped.Changed:Connect(function()
  195. Equipped(equipped.Value)
  196. end)
  197. vaulting.Changed:Connect(function()
  198. if vaulting.Value then
  199. actionSpring:Shove(Vector3.new(sprinting.Value and -3 or -2, 0, 0))
  200. end
  201. end)
  202. climbing.Changed:Connect(function()
  203. if climbing.Value then
  204. actionSpring:Shove(Vector3.new(-10, 0, 0))
  205. end
  206. end)
  207. grounded.Changed:Connect(function()
  208. if not vaulting.Value and root.Velocity.Y < -60 then
  209. actionSpring:Shove(Vector3.new(root.Velocity.Y / 20, 0, 0))
  210. end
  211. end)
  212. newCharacter.DescendantAdded:Connect(function(obj)
  213. if obj:IsA("BasePart") then
  214. obj.LocalTransparencyModifier = 1
  215. end
  216. end)
  217. for _, v in pairs(newCharacter:GetDescendants()) do
  218. if v:IsA("BasePart") then
  219. v.LocalTransparencyModifier = 1
  220. end
  221. end
  222. Equipped(equipped.Value)
  223. character = newCharacter
  224. end
  225. end
  226. TS.Damage.CharacterKilled:Connect(function(char, _, player)
  227. if char == character and player then
  228. spectateChar = TS.Characters:GetCharacter(player)
  229. end
  230. end)
  231. TS.Characters.CharacterAdded:Connect(function(player, character)
  232. if player == PLAYER then
  233. HandleCharacter(character)
  234. end
  235. end)
  236. UserInputService.InputChanged:connect(function(inputObject, processed)
  237. if inputObject.UserInputType == Enum.UserInputType.MouseMovement then
  238. local fovSens = math.clamp((CAMERA.FieldOfView / TS.Camera.FieldOfView) ^ 1.5, 0, 1)
  239. x = (x - inputObject.Delta.X * SENSITIVITY.X * fovSens * TS.Camera.Sensitivity) % (math.pi * 2)
  240. y = math.clamp(y - inputObject.Delta.Y * SENSITIVITY.Y * fovSens * TS.Camera.Sensitivity, MIN_Y, MAX_Y)
  241. end
  242. end)
  243. CAMERA.FieldOfView = 1
  244. CAMERA.CameraType = Enum.CameraType.Scriptable
  245. HandleCharacter(TS.Characters:GetCharacter(PLAYER))
  246.  
  247.  
  248. TS.Timer:BindToRenderStep("Camera", 1, function(deltaTime)
  249. if spectateChar then
  250. local center = spectateChar.PrimaryPart.Position + Vector3.new(0, 0.5, 0)
  251. CAMERA.FieldOfView = 50
  252. CAMERA.CFrame = CFrame.new(center) * CFrame.Angles(0, x, 0) * CFrame.Angles(y, 0, 0) * CFrame.new(0, 0, 15)
  253. CAMERA.Focus = CAMERA.CFrame * CFrame.new(0, 0, -20)
  254. elseif character and character.Parent then
  255. look.Value = y
  256. if sliding.Value then
  257. local speed = Vector2.new(root.Velocity.X, root.Velocity.Z).Magnitude
  258. slideFOV = TS.Math:Lerp(slideFOV, speed / 3 * (TS.Camera.FieldOfView / 90), math.min(deltaTime * 10, 1))
  259. else
  260. slideFOV = TS.Math:Lerp(slideFOV, 0, math.min(deltaTime * 10, 1))
  261. end
  262. local newFOV = TS.Camera.FieldOfView
  263. local center = root.CFrame:PointToWorldSpace(OFFSET)
  264. local player = getcloseplayer()
  265. if sprinting.Value then
  266. newFOV = newFOV * SPRINT_FOV_SCALE
  267. elseif aiming.Value then
  268. if aimbot then
  269. if player ~= nil then
  270. CAMERA.CoordinateFrame = CFrame.new(center, player.Head.Position)
  271. end
  272. end
  273. if item then
  274. newFOV = newFOV * config.Stats.AimFOV
  275. else
  276. newFOV = newFOV * 0.9
  277. end
  278. end
  279. CAMERA.FieldOfView = TS.Math:Lerp(CAMERA.FieldOfView, math.min(newFOV + slideFOV, 120), math.min(deltaTime * 10, 1))
  280. local leanAmount = lean.Value
  281. if math.abs(leanAmount) > 0.1 then
  282. local hit, position = TS.Raycast:CastGeometry(center + Vector3.new(0, -1, 0), root.CFrame:VectorToWorldSpace(Vector3.new(leanAmount * LEAN_DISTANCE * 2, 0, 0)))
  283. if hit then
  284. local distance = (position - center).Magnitude
  285. leanAmount = math.sin(lean.Value) * distance / (LEAN_DISTANCE * 2)
  286. end
  287. end
  288. local heightOffset = math.cos(leanAmount * math.pi / 2) - 1
  289. leanOffset = leanOffset:Lerp(CFrame.new(leanAmount * LEAN_DISTANCE, heightOffset * LEAN_DISTANCE / 4, 0) * CFrame.Angles(0, 0, -leanAmount * LEAN_TILT), math.min(deltaTime * 10, 1))
  290. actionSpring:Update(deltaTime)
  291. local actionOffset = CFrame.Angles(actionSpring.Position.X, actionSpring.Position.Y, actionSpring.Position.Z)
  292. local recoilOffset = CFrame.Angles(recoilSpring.Position.Y * 0, recoilSpring.Position.X * 0, 0)
  293. if aiming.Value == false or player == nil then
  294. CAMERA.CFrame = CFrame.new(center) * CFrame.Angles(0, x, 0) * CFrame.Angles(y, 0, 0) * leanOffset * actionOffset * recoilOffset
  295. end
  296. CAMERA.Focus = CAMERA.CFrame * CFrame.new(0, 0, -20)
  297. if 0.1 <= tick() - lastUpdate then
  298. lastUpdate = tick()
  299. TS.Network:Fire("Character", "State", "Look", y)
  300. end
  301. end
  302. end)
  303. end
  304.  
  305. run()
  306.  
  307. workspace.Characters.ChildAdded:Connect(function(v)
  308. if v.Name == game.Players.LocalPlayer.Name then
  309. wait(.2)
  310. run()
  311. end
  312. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement