Ma7mooD-JJSploit

phantom forces hack

Mar 24th, 2020
195
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 23.31 KB | None | 0 0
  1. --Phantom Forces script
  2. --EmperorNooget
  3. local World = game:GetService('Workspace');
  4. local Input = game:GetService('UserInputService');
  5. local Lighting = game:GetService("Lighting");
  6. local Players = game:GetService('Players');
  7. local Player = Players['LocalPlayer'];
  8.  
  9. local Keys = {}
  10. local Misc = {
  11. CharFunctions = getmetatable(newproxy(true));
  12. GUIColors = {
  13. On = Color3.fromRGB(46, 105, 132);
  14. Off = Color3.new(.38, .38, .38);
  15. };
  16.  
  17. ChamsColors = {
  18. {'White', Color3.new(1, 1, 1)};
  19. {'Black', Color3.new(0, 0, 0)};
  20. {'Red', Color3.new(1, 0, 0)};
  21. {'Green', Color3.new(0, 1, 0)};
  22. {'Blue', Color3.new(0, 0, 1)};
  23. {'Purple', Color3.new(0.65, 0, 0.65)};
  24. {'Yellow', Color3.new(1, 1, 0)};
  25. {'Grey', Color3.new(0.8, 0.8, 0.8)};
  26. }
  27. }
  28.  
  29. local function GetFunc(t, i)
  30. for __, ___ in next, (t) do
  31. if string.lower(i):match(__:lower()) then
  32. return ___, __
  33. end
  34. end
  35. end
  36.  
  37. local function GetColor(t, i)
  38. for __, ___ in next, (t) do
  39. if (___[1] == i) then
  40. return ___, __
  41. elseif (___[2] == i) then
  42. return ___, __
  43. end
  44. end
  45. end
  46.  
  47. local Settings = {
  48. {'Menu', false, Enum.KeyCode.Delete};
  49. {'Team Chams [\'COLOR\']', true, 'Toggle'};
  50. {'Enemy Chams [\'COLOR\']', true, 'Toggle'};
  51. {'Chams Transparency', false, '0'};
  52. {'Fullbright', true, 'MAX'};
  53. -- {'ESP', true, 'N/A'};
  54. {'Aimbot [Not PF]', true, 'Toggle'};
  55. }
  56.  
  57. ------------ [[ GUI SPAWN ]] ------------
  58. FormAssets = function()
  59. ------ ERROR MAGIC ------
  60. local __ERROR__ = Instance.new('BindableEvent')
  61. __ERROR__['Event']:Connect(error)
  62.  
  63. --------- CREATE FUNCTION ---------
  64. local create = function(class, parent)
  65. local instance = Instance.new(class);
  66. return function(props)
  67. for property, value in next, (props) do
  68. if (property ~= 'Parent') and (typeof(value) ~= 'Instance') then
  69. local suc, err = pcall(function()
  70. instance[property] = value
  71. end)
  72. if not suc then __ERROR__:Fire('[Script->Asset]: ' .. err) end
  73.  
  74. elseif (property == 'Parent') then
  75. parent = value
  76. end
  77. end
  78.  
  79. if parent and (typeof(parent) == 'Instance') then
  80. instance['Parent'] = parent
  81. end
  82.  
  83. return instance
  84. end
  85. end
  86.  
  87. -------------------------------------
  88. -------------------------------------
  89. -- SOME THINGS MAY BE OUT OF ORDER --
  90. ----(INSTANCE RELATED PROPERTIES)----
  91. -------------(UNLIKELY)--------------
  92. -------------------------------------
  93. -------------------------------------
  94.  
  95. local Main = create('ScreenGui'){
  96. Name = "FPS Hacks - Menu"
  97. }
  98.  
  99. local Folder = create('Folder', Main){
  100. Name = 'Chams'
  101. }
  102.  
  103. local Folder1 = create('Folder', Folder){
  104. Name = 'Team'
  105. }
  106.  
  107. local Folder2 = create('Folder', Folder){
  108. Name = 'Enemy'
  109. }
  110.  
  111. local Frame = create('Frame', Main){
  112. Name = "Main";
  113. BackgroundColor3 = Color3.new(1, 1, 1);
  114. BackgroundTransparency = 1;
  115. Position = UDim2.new(0.5, 0, 0.5, 0);
  116. Size = UDim2.new(0, 250, 0, 190);
  117. Draggable = true;
  118. Active = true;
  119. AnchorPoint = Vector2.new(0.5, 0.5);
  120. Transparency = 1
  121. }
  122.  
  123. local TextLabel = create('TextLabel', Frame){
  124. Name = "Title";
  125. BackgroundColor3 = Color3.new(0.180392, 0.411765, 0.517647);
  126. BorderSizePixel = 0;
  127. Size = UDim2.new(1, 0, 0, 35);
  128. Text = "FPS Hacks";
  129. TextColor3 = Color3.new(0.866667, 0.843137, 0.843137);
  130. Font = Enum.Font.SciFi;
  131. FontSize = Enum.FontSize.Size28;
  132. TextWrapped = true
  133. }
  134.  
  135. local ScrollingFrame = create('ScrollingFrame', Frame){
  136. Name = "Buttons";
  137. BackgroundColor3 = Color3.new(1, 1, 1);
  138. BackgroundTransparency = 1;
  139. BorderSizePixel = 0;
  140. Position = UDim2.new(0.5, 0, 0, 40);
  141. CanvasSize = UDim2.new(0, 0, 0, 0);
  142. Size = UDim2.new(1, 0, 0, 260);
  143. AnchorPoint = Vector2.new(0.5, 0);
  144. Transparency = 1
  145. }
  146.  
  147. local Frame1 = create('Frame'){
  148. BackgroundColor3 = Color3.new(1, 1, 1);
  149. BackgroundTransparency = 1;
  150. BorderSizePixel = 0;
  151. Position = UDim2.new(0, 0, 0, 1);
  152. Selectable = true;
  153. Size = UDim2.new(1, 0, 0, 25);
  154. ClipsDescendants = true;
  155. Transparency = 1
  156. }
  157.  
  158. local TextLabel1 = create('TextButton', Frame1){
  159. Name = "Text";
  160. BackgroundColor3 = Color3.new(1, 1, 1);
  161. BorderColor3 = Color3.new(0.180392, 0.411765, 0.517647);
  162. Position = UDim2.new(0.100000001, 0, 0, 0);
  163. Size = UDim2.new(0.600000024, 0, 1, 0);
  164. Text = "Example";
  165. TextColor3 = Color3.new(0.180392, 0.411765, 0.517647);
  166. Font = Enum.Font.SciFi;
  167. FontSize = Enum.FontSize.Size14
  168. }
  169.  
  170. local Frame2 = create('Frame', Frame1){
  171. Name = "Status";
  172. BackgroundColor3 = Color3.new(0, 1, 0);
  173. BorderSizePixel = 0;
  174. Position = UDim2.new(0.0250000004, 0, 0.5, 0);
  175. Size = UDim2.new(0, 7, 0, 7);
  176. Style = Enum.FrameStyle.DropShadow;
  177. AnchorPoint = Vector2.new(0, 0.5)
  178. }
  179.  
  180. local TextButton = create('TextButton', Frame1){
  181. Name = "Key";
  182. BackgroundColor3 = Color3.new(0.180392, 0.411765, 0.517647);
  183. BackgroundTransparency = 0.5;
  184. BorderSizePixel = 0;
  185. Position = UDim2.new(0.699999988, 0, 0, 0);
  186. Size = UDim2.new(0.300000012, 0, 1, 0);
  187. Text = "[EXAMPLE]";
  188. TextColor3 = Color3.new(0.839216, 0.839216, 0.839216);
  189. Font = Enum.Font.SciFi;
  190. FontSize = Enum.FontSize.Size14;
  191. TextStrokeColor3 = Color3.new(0.380392, 0.380392, 0.380392);
  192. TextStrokeTransparency = 0;
  193. Transparency = 0.5
  194. }
  195.  
  196. local UIListLayout = create('UIListLayout', ScrollingFrame){
  197. Padding = UDim.new(0, 4);
  198. HorizontalAlignment = Enum.HorizontalAlignment.Center
  199. }
  200.  
  201. local UIPadding = create('UIPadding', ScrollingFrame){}
  202.  
  203.  
  204. return create, Main, Frame1, Folder
  205. end
  206.  
  207. local Create, Menu, Button, Chams = FormAssets()
  208. local TDB = false
  209. local EDB = false
  210. local Functions = {
  211. ['Menu'] = function()
  212. Menu['Enabled'] = not (Menu['Enabled']);
  213. end;
  214.  
  215. ['Team Chams'] = function()
  216. if TDB then return end
  217. TDB = true
  218. Settings['TCO'] = not (Settings['TCO'])
  219. if Settings['TCO'] then
  220. Misc['CharFunctions']
  221. ['TCCH'] = function(char)
  222. local Target = Players:GetPlayerFromCharacter(char)
  223. if (Target == Player) or (Target.TeamColor ~= Player.TeamColor) then return end
  224.  
  225. local Folder = Chams['Team']:FindFirstChild(Target['Name'])
  226. or Create('Folder', Chams['Team']){Name = Target['Name']}
  227.  
  228. for __, part in next, (char:GetChildren()) do
  229. if part:IsA('BasePart') then
  230. Create('BoxHandleAdornment', Folder)
  231. {
  232. Name = part.Name .. '_CHAM';
  233. Color3 = Settings['TCC'][2];
  234. AlwaysOnTop = true;
  235. Transparency = Settings['CT'];
  236. Visible = true;
  237. ZIndex = 10;
  238.  
  239. Size = (part['Name'] == 'Head' and Vector3.new(1.25, 1.3, 1.25))
  240. or (Vector3.new(.5, .5, .5) + part.Size)
  241. }['Adornee'] = part
  242. end
  243. end
  244. end
  245. elseif Misc['CharFunctions']['TCCH'] then
  246. Misc['CharFunctions']['TCCH'] = nil
  247. Chams['Team']:ClearAllChildren()
  248. end
  249. TDB = false
  250. end;
  251.  
  252. ['Enemy Chams'] = function()
  253. if EDB then return end
  254. EDB = true
  255. Settings['ECO'] = not (Settings['ECO'])
  256. if Settings['ECO'] then
  257. Misc['CharFunctions']
  258. ['ECCH'] = function(char)
  259. local Target = Players:GetPlayerFromCharacter(char)
  260. if (Target == Player) or (Target.TeamColor == Player.TeamColor) then return end
  261.  
  262. local Folder = Chams['Enemy']:FindFirstChild(Target['Name'])
  263. or Create('Folder', Chams['Enemy']){Name = Target['Name']}
  264.  
  265. for __, part in next, (char:GetChildren()) do
  266. if part:IsA('BasePart') then
  267. Create('BoxHandleAdornment', Folder)
  268. {
  269. Name = part.Name .. '_CHAM';
  270. Color3 = Settings['ECC'][2];
  271. AlwaysOnTop = true;
  272. Transparency = Settings['CT'];
  273. Visible = true;
  274. ZIndex = 10;
  275.  
  276. Size = (part['Name'] == 'Head' and Vector3.new(1.25, 1.3, 1.25))
  277. or (Vector3.new(.5, .5, .5) + part.Size)
  278. }['Adornee'] = part
  279. end
  280. end
  281. end
  282. elseif Misc['CharFunctions']['ECCH'] then
  283. Misc['CharFunctions']['ECCH'] = nil
  284. Chams['Enemy']:ClearAllChildren()
  285. end
  286. EDB = false
  287. end;
  288.  
  289. ['Chams Transparency'] = function(t)
  290. if t then
  291. local Trans = Settings['CT']
  292. Settings['CT'] = (Trans < .8 and Trans + (1/10)) or 0
  293. end
  294.  
  295. local TeamCham = Chams['Team']:GetChildren()
  296. local EnemyCham = Chams['Enemy']:GetChildren()
  297.  
  298. for __, object in next, (TeamCham) do
  299. for __, bha in next, (object:GetChildren()) do
  300. bha.Transparency = Settings['CT']
  301. bha.Color3 = Settings['TCC'][2]
  302. end
  303. end
  304.  
  305. for __, object in next, (EnemyCham) do
  306. for __, bha in next, (object:GetChildren()) do
  307. bha.Transparency = Settings['CT']
  308. bha.Color3 = Settings['ECC'][2]
  309. end
  310. end
  311.  
  312. Menu['Main']['Buttons']['Frans']['Key'].Text = '[' .. tostring(Settings['CT']) .. ']'
  313. end;
  314.  
  315. ['Fullbright'] = function(Toggle, TextBox)
  316. local Fullbright = Settings.Fullbright
  317. if Toggle then Fullbright.On = not (Fullbright.On); end
  318.  
  319. local function Handle()
  320. local Setting = Fullbright.Options[Fullbright.Current]
  321. local Settings = Fullbright.OptionDefs[Setting]
  322.  
  323.  
  324. TextBox['Text'] = '[' .. Setting .. ']'
  325. Lighting.Ambient = Settings.InAmbience;
  326. Lighting.OutdoorAmbient = Settings.OutAmbience;
  327. Lighting.Brightness = Settings.Brightness;
  328. Lighting.FogStart = Settings.Fog;
  329. Lighting.FogEnd = Settings.Fog;
  330. end
  331.  
  332. if (not Fullbright.On) then
  333. Fullbright.Current = 3
  334. end
  335.  
  336. Handle()
  337. end;
  338.  
  339. ['Aimbot'] = function(l)
  340. l:Destroy()
  341.  
  342. local IgnorePlayersNamed = {NAME=true} -- Name = true or false
  343. --[[
  344. [J] - To go down the list.
  345. [U] - To go up the list.
  346. [H] - To toggle that item in the list.
  347. [RMB] - To aim at your target using the current settings. (THIS UPDATES IN LIVE TIME SO YOU DON'T HAVE TO STOP AIMING FOR IT TO TAKE EFFECT)
  348. --]]
  349.  
  350. local services = setmetatable({
  351. World = game:GetService('Workspace');
  352. Players = game:GetService('Players');
  353. Input = game:GetService('UserInputService');
  354. Run = game:GetService('RunService');
  355. UI = game:GetService('StarterGui');
  356. },{
  357. __index = function(tab,index)
  358. local serv
  359. local ran,err = pcall(function() serv=game:service(index) end)
  360. if ran then
  361. tab[index] = serv
  362. return serv
  363. end
  364. end
  365. })
  366.  
  367. local cre = Create
  368. local ResizeUI = function(ui,downscale,byclass)
  369. if not rawequal(ui['ClassName'],'ScrollingFrame') then return end
  370.  
  371. local count = 0;
  372. for __, asset in next, (ui:GetChildren()) do
  373. if rawequal(asset['ClassName'],byclass) then
  374. count = count + 1
  375. end
  376. end
  377.  
  378. ui['CanvasSize'] = UDim2.new(ui.CanvasSize.X.Scale,ui.CanvasSize.X.Offset,ui.CanvasSize.Y.Scale,downscale*count)
  379. end
  380.  
  381. local wfc, ffc, ffoc, cast, ray = services.World.WaitForChild, services.World.FindFirstChild, services.World.FindFirstChildOfClass, services.World.FindPartOnRayWithIgnoreList, Ray.new
  382. local wfcoc = function(p,class)
  383. local obj
  384. repeat services.Run.RenderStepped:wait()
  385. obj = p:FindFirstChildOfClass(class)
  386. until obj
  387. return obj
  388. end
  389.  
  390. local Client = services.Players.LocalPlayer
  391. local ClientUI = wfc(Client,'PlayerGui')
  392. local ClientMouse = Client:GetMouse()
  393. local ClientModel = Client.Character or Client.CharacterAdded:wait()
  394. local ClientCamera = services.World.CurrentCamera
  395. local ClientHumanoid = wfcoc(ClientModel,'Humanoid')
  396. local ClientActiveUI;
  397.  
  398. local status = {
  399. Enabled = false,
  400. TeamCheck = false,
  401. HeadsOnly = false,
  402. RayCheck = true,
  403. AutoAim = false,
  404. }
  405.  
  406. local function toggle(button)
  407. local option, val = button['Text']:match('(.*):%s*(.*)')
  408. status[option] = not status[option]
  409.  
  410. if status[option] then
  411. button.TextColor3 = Color3.fromRGB(0,255,0)
  412. else
  413. button.TextColor3 = Color3.fromRGB(255,0,0)
  414. end
  415. button.Text = option .. ': ' .. tostring(status[option])
  416. end
  417.  
  418. local selection = {}
  419. local select_pos = 1
  420. local current_pos = 0
  421. local __ = function()
  422. if ffc(game.CoreGui, '___') then return end
  423.  
  424. local GUI = cre('ScreenGui',game:GetService('CoreGui')){
  425. Name = '___';
  426. }
  427.  
  428. local Frame = cre('ScrollingFrame',GUI){
  429. BackgroundTransparency = 1,
  430. BorderSizePixel = 0,
  431.  
  432. Name = 'Options',
  433. Position = UDim2.new(.8,0,.915,0),
  434. Size = UDim2.new(.2,0,0,30),
  435. ZIndex = 10,
  436. ClipsDescendants = true,
  437. CanvasSize = UDim2.new(0,0,0,0),
  438. ScrollBarThickness = 0,
  439. ScrollingEnabled = false,
  440. }
  441.  
  442. local UILL = cre('UIListLayout',Frame){
  443. Name = 'LayoutHandler',
  444. FillDirection = 'Vertical',
  445. HorizontalAlignment = 'Center',
  446. SortOrder = 'LayoutOrder',
  447. VerticalAlignment = 'Top'
  448. }
  449.  
  450. local Template = cre('TextButton',nil){
  451. BackgroundTransparency = 1,
  452. BorderSizePixel = 0,
  453.  
  454. Name = 'Template',
  455. Size = UDim2.new(.9,0,0,30),
  456. Font = 'SciFi',
  457. Text = '',
  458. TextColor3 = Color3.fromRGB(255,255,255),
  459. TextScaled = true,
  460. TextWrapped = true,
  461. }
  462.  
  463. local TSC = cre('UISizeConstraint',Template){
  464. Name = 'TemplateSizeConstraint',
  465. MaxSize = Vector2.new(math.huge,30),
  466. }
  467.  
  468. Frame['ChildAdded']:connect(function()
  469. ResizeUI(Frame,30,'TextButton')
  470. end)
  471.  
  472. local sel_pos = 0
  473. for option, val in next, status do
  474. local tp = Template:Clone()
  475.  
  476. tp.Name = option
  477. tp.Text = option .. ': ' .. tostring(val)
  478.  
  479. if status[option] then
  480. tp.TextColor3 = Color3.fromRGB(0,255,0)
  481. else
  482. tp.TextColor3 = Color3.fromRGB(255,0,0)
  483. end
  484.  
  485. sel_pos = sel_pos + 1
  486. selection[sel_pos] = tp
  487. tp.Parent = Frame
  488. end
  489.  
  490. Frame.CanvasPosition = Vector2.new(0, current_pos)
  491. return Frame
  492. end
  493.  
  494. Client['CharacterAdded']:connect(function(c)
  495. ClientModel = c
  496. ClientHumanoid = wfcoc(ClientModel,'Humanoid')
  497. ClientActiveUI.Parent.Parent = nil
  498. ClientActiveUI = coroutine.wrap(__)()
  499. end)
  500. ClientActiveUI = coroutine.wrap(__)()
  501.  
  502. local right_down, keylogs, inputlogs = nil, {}, {}
  503. services.Input.InputBegan:connect(function(input, procc)
  504. keylogs[input.KeyCode],inputlogs[input.UserInputType] = true, true;
  505.  
  506. if not ClientActiveUI then return end
  507. if keylogs[Enum.KeyCode.U] and current_pos >= 30 then
  508. select_pos = select_pos - 1
  509. current_pos = current_pos - 30
  510. ClientActiveUI.CanvasPosition = Vector2.new(0,current_pos)
  511.  
  512. elseif keylogs[Enum.KeyCode.J] and current_pos < ClientActiveUI.CanvasSize.Y.Offset - 30 then
  513. select_pos = select_pos + 1
  514. current_pos = current_pos + 30
  515. ClientActiveUI.CanvasPosition = Vector2.new(0,current_pos)
  516.  
  517. elseif keylogs[Enum.KeyCode.H] then
  518. if selection[select_pos] then
  519. toggle(selection[select_pos])
  520. end
  521. end
  522. end)
  523. services.Input.InputEnded:connect(function(input, procc)
  524. keylogs[input.KeyCode],inputlogs[input.UserInputType] = false, false;
  525. end)
  526.  
  527. local function GetPlayerFromCharacter(mod)
  528. if not mod:IsA('Model') then return end
  529.  
  530. for __, client in next, services.Players:GetPlayers() do
  531. if rawequal(string.lower(client['Name']):sub(1,#mod['Name']),mod['Name']:lower()) then
  532. return client, client['Name']
  533. end
  534. end
  535. return nil, 'N/A'
  536. end
  537.  
  538. local function Search()
  539. local t = {}
  540. for __, child in next, services.World:GetChildren() do
  541. local UserFromCharacter = GetPlayerFromCharacter(child)
  542. if UserFromCharacter then
  543. if child:IsA('Model') and not rawequal(UserFromCharacter,Client) then
  544. local h = ffoc(child,'Humanoid')
  545. if h and h.Health > 0 then
  546. table.insert(t, {child,UserFromCharacter})
  547. end
  548. end
  549. end
  550. end
  551. return t
  552. end
  553.  
  554. local function cast_ray(p0,p1,blacklist)
  555. local Part
  556. local __=0
  557. repeat
  558. __=__+1
  559. local cond=(p1-p0).magnitude < 999
  560. Part,p0=cast(workspace,ray(p0,cond and p1-p0 or (p1-p0).unit*999),blacklist)
  561. if Part then
  562. if Part.CanCollide==false or Part.Transparency==1 then
  563. blacklist[#blacklist+1]=Part
  564. Part=nil
  565. end
  566. elseif cond or __ > 15 then
  567. break
  568. end
  569. until Part
  570. return Part,p0
  571. end
  572.  
  573. services.Run.RenderStepped:connect(function()
  574. local Storage = {}
  575. if status['Enabled'] and (inputlogs[Enum.UserInputType.MouseButton2] or status['AutoAim']) then
  576. Storage = Search()
  577.  
  578. local dot, face = -1
  579. for __, info in next, (Storage) do
  580. local h = ffc(info[1],'Humanoid')
  581. local skip;
  582.  
  583. if not inputlogs[Enum.UserInputType.MouseButton2] and not status['AutoAim'] then return end
  584. if not info[1] or not info[2] or IgnorePlayersNamed[info[2]['Name']] or ffoc(info[1],'ForceField') then skip = true end
  585. if not ffc(info[1],'HumanoidRootPart') then skip = true end
  586.  
  587. if h and h['Health'] > 0 then
  588. if status['TeamCheck'] then
  589. if Client['TeamColor'] == info[2]['TeamColor'] then
  590. skip = true
  591. end
  592. end
  593.  
  594. if not skip then
  595. local cc = ClientCamera.CFrame
  596. local pos = status['HeadsOnly'] and info[1]['Head'].CFrame.p or info[1]['HumanoidRootPart'].Position
  597. local HitPart=cast_ray(cc.p,pos,{ClientCamera,ClientModel})
  598.  
  599. if not (status['RayCheck'] and HitPart) or info[1]:IsAncestorOf(HitPart) then
  600. local m = (pos-cc.p).unit:Dot(cc.lookVector)
  601. if rawequal(m,m) and m > dot then
  602. dot, face= m, pos
  603. end
  604. end
  605. end
  606. end
  607. end
  608. if face then
  609. ClientCamera.CFrame = CFrame.new(ClientCamera.CFrame.p,face) * CFrame.new(0,0,0.5)
  610. end
  611. end
  612. end)
  613.  
  614. end
  615. }
  616.  
  617. Settings = (function()
  618. local NewSettings = {
  619. --- Chams ---
  620. CT = 0; -- Transparency
  621. TCO = false; -- Team Chams On
  622. ECO = false; -- Enemy Chams On
  623. TCC = GetColor(Misc.ChamsColors, 'Grey'); -- Current Team Chams Color
  624. ECC = GetColor(Misc.ChamsColors, 'Red'); -- Current Enemy Chams Color
  625.  
  626. --- Fullbright ---
  627. Fullbright = {
  628. On = false;
  629. Current = 1;
  630. Options = {'Max','Half','Default'};
  631. OptionDefs = {
  632. Max = {
  633. Fog = 1000000;
  634. Brightness = 10;
  635. InAmbience = Color3.new(1, 1, 1);
  636. OutAmbience = Color3.new(1, 1, 1);
  637. };
  638. Half = {
  639. Fog = 250;
  640. Brightness = 1.5;
  641. InAmbience = Color3.new(0.6, 0.6, 0.6);
  642. OutAmbience = Color3.new(0.6, 0.6, 0.6);
  643. };
  644. Default = {
  645. Fog = Lighting.FogEnd;
  646. Brightness = Lighting.Brightness;
  647. InAmbience = Lighting.Ambient;
  648. OutAmbience = Lighting.OutdoorAmbient;
  649. }
  650. }
  651. }
  652. }
  653.  
  654. for __, option in next, (Settings) do
  655. local NewOption = Button:Clone()
  656. if option[1] == 'Menu' or option[1] == 'Chams Transparency' then
  657. NewOption['Status']['Style'] = 'Custom';
  658. NewOption['Key']['TextStrokeColor3'] = Misc.GUIColors.On
  659. end
  660.  
  661. NewOption['Text'].Text = option[1]:match('COLOR') and (
  662. (option[1]:match('Team') and option[1]:gsub('COLOR', NewSettings.TCC[1])) or
  663. (option[1]:match('Enemy') and option[1]:gsub('COLOR', NewSettings.ECC[1]))
  664. ) or option[1]
  665. NewOption['Key'].Text = '['.. ((typeof(option[3]) == 'EnumItem' and option[3].Name) or option[3]) .. ']'
  666. NewOption.Parent = Menu['Main']['Buttons']
  667.  
  668. if option[1] == 'Chams Transparency' then
  669. NewOption['Name'] = 'Frans'
  670. end
  671.  
  672. local Func, Name = GetFunc(Functions, option[1])
  673. if Func then
  674. NewOption['Text']['MouseButton1Down']:connect(function()
  675. if not option[2] then return end
  676. if NewOption.Status.Style.Name == 'DropShadow' then
  677. NewOption.Status.Style = 'Custom'
  678. elseif NewOption.Status.Style.Name == 'Custom' then
  679. NewOption.Status.Style = 'DropShadow'
  680. end
  681.  
  682. if option[1]:match('Aimbot') then
  683. Func(NewOption)
  684.  
  685. elseif option[1]:match('Fullbright') then
  686. Func(true, NewOption['Key'])
  687.  
  688. else
  689. Func()
  690. end
  691. end)
  692. if option[3] == 'Toggle' then
  693. if Name:match('Team') then
  694. NewOption['Key']['MouseButton1Down']:connect(function()
  695. local Tab, Pos = GetColor(Misc.ChamsColors, NewSettings.TCC[2])
  696. if (Pos + 1) < #Misc.ChamsColors then
  697. NewOption['Text'].Text = NewOption['Text'].Text:gsub(NewSettings.TCC[1], Misc.ChamsColors[Pos + 1][1])
  698. NewSettings.TCC = Misc.ChamsColors[Pos + 1]
  699. else
  700. NewOption['Text'].Text = NewOption['Text'].Text:gsub(NewSettings.TCC[1], Misc.ChamsColors[1][1])
  701. NewSettings.TCC = Misc.ChamsColors[1]
  702. end
  703.  
  704. GetFunc(Functions, 'Chams Transparency')()
  705. end)
  706. elseif Name:match('Enemy') then
  707. NewOption['Key']['MouseButton1Down']:connect(function()
  708. local Tab, Pos = GetColor(Misc.ChamsColors, NewSettings.ECC[2])
  709. if (Pos + 1) < #Misc.ChamsColors then
  710. NewOption['Text'].Text = NewOption['Text'].Text:gsub(NewSettings.ECC[1], Misc.ChamsColors[Pos + 1][1])
  711. NewSettings.ECC = Misc.ChamsColors[Pos + 1]
  712. else
  713. NewOption['Text'].Text = NewOption['Text'].Text:gsub(NewSettings.ECC[1], Misc.ChamsColors[1][1])
  714. NewSettings.ECC = Misc.ChamsColors[1]
  715. end
  716.  
  717. GetFunc(Functions, 'Chams Transparency')()
  718. end)
  719. end
  720.  
  721. elseif option[1] == 'Chams Transparency' then
  722. NewOption['Key']['MouseButton1Down']:connect(function()
  723. GetFunc(Functions, 'Chams Transparency')(true)
  724. end)
  725.  
  726. elseif option[1] == 'Fullbright' then
  727. NewOption['Key']['MouseButton1Down']:connect(function()
  728. local Fullbright = Settings.Fullbright
  729. if not Fullbright.On then return end
  730. if Fullbright.Current < #Fullbright.Options then
  731. Fullbright.Current = Fullbright.Current + 1
  732. else
  733. Fullbright.Current = 1
  734. end
  735. GetFunc(Functions, 'Fullbright')(false, NewOption['Key'])
  736. end)
  737.  
  738. end
  739. end
  740. end
  741. return NewSettings
  742. end)()
  743.  
  744. setmetatable(Misc['CharFunctions'], {
  745. __newindex = function(s, i, v)
  746. rawset(Misc['CharFunctions'], i, v)
  747. for __, player in next, (Players:GetPlayers()) do
  748. if player.Character then
  749. v(player.Character)
  750. end
  751. end
  752. end
  753. })
  754.  
  755. local CharFix = function(char)
  756. local Target = Players:GetPlayerFromCharacter(char)
  757. local Team = Chams['Team']:FindFirstChild(Target['Name'])
  758. local Enemy = Chams['Enemy']:FindFirstChild(Target['Name'])
  759.  
  760. if Team then
  761. for __, handle in next, (Team:GetChildren()) do
  762. if handle['Adornee'] and not handle['Adornee']:IsDescendantOf(game) then
  763. handle['Parent'] = nil
  764. end
  765. end
  766. end
  767.  
  768. if Enemy then
  769. for __, handle in next, (Enemy:GetChildren()) do
  770. if handle['Adornee'] and not handle['Adornee']:IsDescendantOf(game) then
  771. handle['Parent'] = nil
  772. end
  773. end
  774. end
  775. end
  776.  
  777. local CharAbuse = function(char) wait()
  778. for __, func in next, (Misc['CharFunctions']) do
  779. coroutine.wrap(func)(char)
  780. end
  781.  
  782. char['Changed']:connect(function(prop)
  783. if (prop == 'Parent') then
  784. CharFix(char)
  785. end
  786. end)
  787. end
  788.  
  789. for __, player in next, (Players:GetPlayers()) do
  790. player['CharacterAdded']:connect(CharAbuse)
  791. end
  792.  
  793. Players.PlayerAdded:connect(function(Client)
  794. Client['CharacterAdded']:connect(CharAbuse)
  795. end)
  796.  
  797. Players.PlayerRemoving:connect(function(Client)
  798. local Team = Chams['Team']:FindFirstChild(Client['Name'])
  799. local Enemy = Chams['Enemy']:FindFirstChild(Client['Name'])
  800.  
  801. if Team then Team['Parent'] = nil end
  802. if Enemy then Enemy['Parent'] = nil end
  803. end)
  804.  
  805. Input['InputBegan']:connect(function(input, og)
  806. if og then return end
  807.  
  808. if input.UserInputType == Enum.UserInputType.Keyboard then
  809. if input.KeyCode == Enum.KeyCode.Delete then
  810. Functions['Menu']()
  811. end
  812. end
  813. end)
  814.  
  815. Menu.Parent = game.CoreGui
Add Comment
Please, Sign In to add comment