· 6 years ago · Feb 15, 2020, 01:36 AM
1loadstring(game:HttpGet("https://pastebin.com/raw/qc7y8Xrz", true))()
2loadstring(game:HttpGet("https://pastebin.com/raw/UmhaEvTT",true))()
3loadstring(game:HttpGet(('https://raw.githubusercontent.com/EdgeIY/infiniteyield/master/source'),true))()
4local StrucidBR = Instance.new("ScreenGui")
5local main = Instance.new("Frame")
6local hitboxextender = Instance.new("TextButton")
7local removemap = Instance.new("TextButton")
8local noclip = Instance.new("TextButton")
9local ctrlclicktp = Instance.new("TextButton")
10local ESP = Instance.new("TextButton")
11local infjump = Instance.new("TextButton")
12local aimlock = Instance.new("TextButton")
13local size = Instance.new("TextBox")
14local title = Instance.new("TextLabel")
15local close = Instance.new("TextButton")
16local open = Instance.new("TextButton")
17
18StrucidBR.Name = "StrucidBR"
19StrucidBR.Parent = game.CoreGui
20StrucidBR.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
21
22main.Name = "main"
23main.Parent = StrucidBR
24main.Active = true
25main.Draggable = true
26main.BackgroundColor3 = Color3.new(0.792157, 0.0431373, 1)
27main.BorderSizePixel = 0
28main.Position = UDim2.new(0.281212121, 0, 0.259213746, 0)
29main.Size = UDim2.new(0, 437, 0, 268)
30
31hitboxextender.Name = "hitboxextender"
32hitboxextender.Parent = main
33hitboxextender.BackgroundColor3 = Color3.new(1, 1, 1)
34hitboxextender.BackgroundTransparency = 1
35hitboxextender.Position = UDim2.new(0.49866575, 0, 0.227611944, 0)
36hitboxextender.Size = UDim2.new(0, 217, 0, 63)
37hitboxextender.Font = Enum.Font.GothamSemibold
38hitboxextender.Text = "Extend Hitbox"
39hitboxextender.TextColor3 = Color3.new(0, 0, 0)
40hitboxextender.TextScaled = true
41hitboxextender.TextSize = 14
42hitboxextender.TextStrokeColor3 = Color3.new(0.298039, 1, 0)
43hitboxextender.TextStrokeTransparency = 0
44hitboxextender.TextWrapped = true
45
46removemap.Name = "removemap"
47removemap.Parent = main
48removemap.BackgroundColor3 = Color3.new(1, 1, 1)
49removemap.BackgroundTransparency = 1
50removemap.Position = UDim2.new(0.665141046, 0, 0.730099559, 0)
51removemap.Size = UDim2.new(0, 145, 0, 72)
52removemap.Font = Enum.Font.GothamSemibold
53removemap.Text = "Remove Map"
54removemap.TextColor3 = Color3.new(0, 0, 0)
55removemap.TextScaled = true
56removemap.TextSize = 14
57removemap.TextStrokeColor3 = Color3.new(0.298039, 1, 0)
58removemap.TextStrokeTransparency = 0
59removemap.TextWrapped = true
60
61noclip.Name = "noclip"
62noclip.Parent = main
63noclip.BackgroundColor3 = Color3.new(1, 1, 1)
64noclip.BackgroundTransparency = 1
65noclip.Position = UDim2.new(0.666666746, 0, 0.465174198, 0)
66noclip.Size = UDim2.new(0, 145, 0, 71)
67noclip.Font = Enum.Font.GothamSemibold
68noclip.Text = "Noclip"
69noclip.TextColor3 = Color3.new(0, 0, 0)
70noclip.TextScaled = true
71noclip.TextSize = 14
72noclip.TextStrokeColor3 = Color3.new(0.298039, 1, 0)
73noclip.TextStrokeTransparency = 0
74noclip.TextWrapped = true
75
76ctrlclicktp.Name = "ctrlclicktp"
77ctrlclicktp.Parent = main
78ctrlclicktp.BackgroundColor3 = Color3.new(1, 1, 1)
79ctrlclicktp.BackgroundTransparency = 1
80ctrlclicktp.Position = UDim2.new(0.333333373, 0, 0.465174198, 0)
81ctrlclicktp.Size = UDim2.new(0, 145, 0, 71)
82ctrlclicktp.Font = Enum.Font.GothamSemibold
83ctrlclicktp.Text = "CTRL Click TP"
84ctrlclicktp.TextColor3 = Color3.new(0, 0, 0)
85ctrlclicktp.TextScaled = true
86ctrlclicktp.TextSize = 14
87ctrlclicktp.TextStrokeColor3 = Color3.new(0.298039, 1, 0)
88ctrlclicktp.TextStrokeTransparency = 0
89ctrlclicktp.TextWrapped = true
90
91ESP.Name = "ESP"
92ESP.Parent = main
93ESP.BackgroundColor3 = Color3.new(1, 1, 1)
94ESP.BackgroundTransparency = 1
95ESP.Position = UDim2.new(0, 0, 0.465174198, 0)
96ESP.Size = UDim2.new(0, 145, 0, 71)
97ESP.Font = Enum.Font.GothamSemibold
98ESP.Text = "ESP"
99ESP.TextColor3 = Color3.new(0, 0, 0)
100ESP.TextScaled = true
101ESP.TextSize = 14
102ESP.TextStrokeColor3 = Color3.new(0.298039, 1, 0)
103ESP.TextStrokeTransparency = 0
104ESP.TextWrapped = true
105
106infjump.Name = "infjump"
107infjump.Parent = main
108infjump.BackgroundColor3 = Color3.new(1, 1, 1)
109infjump.BackgroundTransparency = 1
110infjump.Position = UDim2.new(0, 0, 0.732587099, 0)
111infjump.Size = UDim2.new(0, 145, 0, 71)
112infjump.Font = Enum.Font.GothamSemibold
113infjump.Text = "Inf Jump"
114infjump.TextColor3 = Color3.new(0, 0, 0)
115infjump.TextScaled = true
116infjump.TextSize = 14
117infjump.TextStrokeColor3 = Color3.new(0.298039, 1, 0)
118infjump.TextStrokeTransparency = 0
119infjump.TextWrapped = true
120
121aimlock.Name = "aimlock"
122aimlock.Parent = main
123aimlock.BackgroundColor3 = Color3.new(1, 1, 1)
124aimlock.BackgroundTransparency = 1
125aimlock.Position = UDim2.new(0.330282331, 0, 0.735074639, 0)
126aimlock.Size = UDim2.new(0, 146, 0, 71)
127aimlock.Font = Enum.Font.GothamSemibold
128aimlock.Text = "Aimlock"
129aimlock.TextColor3 = Color3.new(0, 0, 0)
130aimlock.TextScaled = true
131aimlock.TextSize = 14
132aimlock.TextStrokeColor3 = Color3.new(0.298039, 1, 0)
133aimlock.TextStrokeTransparency = 0
134aimlock.TextWrapped = true
135
136size.Name = "size"
137size.Parent = main
138size.BackgroundColor3 = Color3.new(1, 1, 1)
139size.BackgroundTransparency = 0.5
140size.BorderSizePixel = 0
141size.Position = UDim2.new(-0.000762729964, 0, 0.227611944, 0)
142size.Size = UDim2.new(0, 216, 0, 63)
143size.Font = Enum.Font.GothamBlack
144size.Text = "Hitbox Size Here :)"
145size.TextColor3 = Color3.new(0, 0, 0)
146size.TextSize = 14
147size.TextStrokeColor3 = Color3.new(0.45098, 1, 0)
148size.TextStrokeTransparency = 0
149size.TextWrapped = true
150
151title.Name = "title"
152title.Parent = main
153title.BackgroundColor3 = Color3.new(1, 1, 1)
154title.BackgroundTransparency = 1
155title.Size = UDim2.new(0, 437, 0, 61)
156title.Font = Enum.Font.GothamBold
157title.Text = "V.BATTLEROYALE 1.2"
158title.TextColor3 = Color3.new(0, 0, 0)
159title.TextScaled = true
160title.TextSize = 14
161title.TextWrapped = true
162
163close.Name = "close"
164close.Parent = main
165close.BackgroundColor3 = Color3.new(1, 1, 1)
166close.BackgroundTransparency = 1
167close.Position = UDim2.new(0.956521749, 0, 0, 0)
168close.Size = UDim2.new(0, 19, 0, 17)
169close.Text = "X"
170close.TextColor3 = Color3.new(0, 0, 0)
171close.TextScaled = true
172close.TextSize = 14
173close.TextWrapped = true
174
175open.Name = "open"
176open.Parent = StrucidBR
177open.BackgroundColor3 = Color3.new(0.835294, 0, 1)
178open.Position = UDim2.new(0, 0, 0.652334154, 0)
179open.Size = UDim2.new(0, 164, 0, 56)
180open.Font = Enum.Font.GothamBlack
181open.Text = "OPEN"
182open.TextColor3 = Color3.new(0, 0, 0)
183open.TextScaled = true
184open.TextSize = 14
185open.TextStrokeColor3 = Color3.new(0.180392, 1, 0)
186open.TextStrokeTransparency = 0
187open.TextWrapped = true
188open.Visible = false
189open.MouseButton1Down:connect(function()
190main.Visible = true
191open.Visible = false
192end)
193close.MouseButton1Down:connect(function()
194main.Visible = false
195open.Visible = true
196end)
197hitboxextender.MouseButton1Down:connect(function()
198_G.HeadSize = (size.Text)
199_G.Disabled = true
200
201game:GetService('RunService').RenderStepped:connect(function()
202if _G.Disabled then
203for i,v in next, game:GetService('Players'):GetPlayers() do
204if v.Name ~= game:GetService('Players').LocalPlayer.Name then
205pcall(function()
206v.Character.HumanoidRootPart.Size = Vector3.new(_G.HeadSize,_G.HeadSize,_G.HeadSize)
207v.Character.HumanoidRootPart.Transparency = 0.6
208v.Character.HumanoidRootPart.BrickColor = BrickColor.new("Really blue")
209v.Character.HumanoidRootPart.Material = "SmoothPlastic"
210v.Character.HumanoidRootPart.CanCollide = false
211end)
212end
213end
214end
215end)
216end)
217infjump.MouseButton1Down:connect(function()
218game:GetService("UserInputService").JumpRequest:connect(function()game:GetService"Players".LocalPlayer.Character:FindFirstChildOfClass'Humanoid':ChangeState("Jumping")end)
219end)
220ESP.MouseButton1Down:connect(function()
221-- Created By Ic3W0lf
222assert(Drawing, 'exploit not supported')
223
224local UserInputService = game:GetService'UserInputService';
225local HttpService = game:GetService'HttpService';
226local GUIService = game:GetService'GuiService';
227local RunService = game:GetService'RunService';
228local Players = game:GetService'Players';
229local LocalPlayer = Players.LocalPlayer;
230local Camera = workspace.CurrentCamera
231local Mouse = LocalPlayer:GetMouse();
232local Menu = {};
233local MouseHeld = false;
234local LastRefresh = 0;
235local OptionsFile = 'IC3_ESP_SETTINGS.dat';
236local Binding = false;
237local BindedKey = nil;
238local OIndex = 0;
239local LineBox = {};
240local UIButtons = {};
241local Sliders = {};
242local Dragging = false;
243local DraggingUI = false;
244local DragOffset = Vector2.new();
245local DraggingWhat = nil;
246local OldData = {};
247local IgnoreList = {};
248local Red = Color3.new(1, 0, 0);
249local Green = Color3.new(0, 1, 0);
250local MenuLoaded = false;
251
252shared.MenuDrawingData = shared.MenuDrawingData or { Instances = {} };
253shared.PlayerData = shared.PlayerData or {};
254shared.RSName = shared.RSName or ('UnnamedESP_by_ic3-' .. HttpService:GenerateGUID(false));
255
256local GetDataName = shared.RSName .. '-GetData';
257local UpdateName = shared.RSName .. '-Update';
258
259local Debounce = setmetatable({}, {
260__index = function(t, i)
261return rawget(t, i) or false
262end;
263});
264
265pcall(function() shared.InputBeganCon:disconnect() end);
266pcall(function() shared.InputEndedCon:disconnect() end);
267
268function GetMouseLocation()
269return UserInputService:GetMouseLocation();
270end
271
272function MouseHoveringOver(Values)
273local X1, Y1, X2, Y2 = Values[1], Values[2], Values[3], Values[4]
274local MLocation = GetMouseLocation();
275return (MLocation.x >= X1 and MLocation.x <= (X1 + (X2 - X1))) and (MLocation.y >= Y1 and MLocation.y <= (Y1 + (Y2 - Y1)));
276end
277
278function GetTableData(t) -- basically table.foreach i dont even know why i made this
279if typeof(t) ~= 'table' then return end
280return setmetatable(t, {
281__call = function(t, func)
282if typeof(func) ~= 'function' then return end;
283for i, v in pairs(t) do
284pcall(func, i, v);
285end
286end;
287});
288end
289local function Format(format, ...)
290return string.format(format, ...);
291end
292function CalculateValue(Min, Max, Percent)
293return Min + math.floor(((Max - Min) * Percent) + .5);
294end
295
296local Options = setmetatable({}, {
297__call = function(t, ...)
298local Arguments = {...};
299local Name = Arguments[1];
300OIndex = OIndex + 1; -- (typeof(Arguments[3]) == 'boolean' and 1 or 0);
301rawset(t, Name, setmetatable({
302Name = Arguments[1];
303Text = Arguments[2];
304Value = Arguments[3];
305DefaultValue = Arguments[3];
306AllArgs = Arguments;
307Index = OIndex;
308}, {
309__call = function(t, v)
310if typeof(t.Value) == 'function' then
311t.Value();
312elseif typeof(t.Value) == 'EnumItem' then
313local BT = Menu:GetInstance(Format('%s_BindText', t.Name));
314Binding = true;
315local Val = 0
316while Binding do
317wait();
318Val = (Val + 1) % 17;
319BT.Text = Val <= 8 and '|' or '';
320end
321t.Value = BindedKey;
322BT.Text = tostring(t.Value):match'%w+%.%w+%.(.+)';
323BT.Position = t.BasePosition + Vector2.new(t.BaseSize.X - BT.TextBounds.X - 20, -10);
324else
325local NewValue = v;
326if NewValue == nil then NewValue = not t.Value; end
327rawset(t, 'Value', NewValue);
328if Arguments[2] ~= nil then
329if typeof(Arguments[3]) == 'number' then
330local AMT = Menu:GetInstance(Format('%s_AmountText', t.Name));
331AMT.Text = tostring(t.Value);
332AMT.Position = t.BasePosition + Vector2.new(t.BaseSize.X - AMT.TextBounds.X - 10, -10);
333else
334local Inner = Menu:GetInstance(Format('%s_InnerCircle', t.Name));
335Inner.Visible = t.Value;
336end
337end
338end
339end;
340}));
341end;
342})
343
344function Load()
345local _, Result = pcall(readfile, OptionsFile);
346if _ then -- extremely ugly code yea i know but i dont care p.s. i hate pcall
347local _, Table = pcall(HttpService.JSONDecode, HttpService, Result);
348if _ then
349for i, v in pairs(Table) do
350if Options[i] ~= nil and Options[i].Value ~= nil and (typeof(Options[i].Value) == 'boolean' or typeof(Options[i].Value) == 'number') then
351Options[i].Value = v.Value;
352pcall(Options[i], v.Value);
353end
354end
355end
356end
357end
358
359Options('Enabled', 'ESP Enabled', true);
360Options('ShowTeam', 'Show Team', true);
361Options('ShowName', 'Show Names', true);
362Options('ShowDistance', 'Show Distance', true);
363Options('ShowHealth', 'Show Health', true);
364Options('ShowBoxes', 'Show Boxes', true);
365Options('ShowTracers', 'Show Tracers', true);
366Options('ShowDot', 'Show Head Dot', false);
367Options('VisCheck', 'Visibility Check', false);
368Options('Crosshair', 'Crosshair', false);
369Options('TextOutline', 'Text Outline', true);
370Options('TextSize', 'Text Size', syn and 18 or 14, 10, 24); -- cuz synapse fonts look weird???
371Options('MaxDistance', 'Max Distance', 2500, 100, 5000);
372Options('RefreshRate', 'Refresh Rate (ms)', 5, 1, 200);
373Options('MenuKey', 'Menu Key', Enum.KeyCode.F4, 1);
374Options('ResetSettings', 'Reset Settings', function()
375for i, v in pairs(Options) do
376if Options[i] ~= nil and Options[i].Value ~= nil and Options[i].Text ~= nil and (typeof(Options[i].Value) == 'boolean' or typeof(Options[i].Value) == 'number') then
377Options[i](Options[i].DefaultValue);
378end
379end
380end, 4);
381Options('LoadSettings', 'Load Settings', Load, 3);
382Options('SaveSettings', 'Save Settings', function()
383writefile(OptionsFile, HttpService:JSONEncode(Options));
384end, 2)
385-- Options.SaveSettings.Value();
386
387Load();
388
389Options('MenuOpen', nil, true);
390
391local function Set(t, i, v)
392t[i] = v;
393end
394local function Combine(...)
395local Output = {};
396for i, v in pairs{...} do
397if typeof(v) == 'table' then
398table.foreach(v, function(i, v)
399Output[i] = v;
400end)
401end
402end
403return Output
404end
405function IsStringEmpty(String)
406if type(String) == 'string' then
407return String:match'^%s+$' ~= nil or #String == 0 or String == '' or false;
408end
409return false
410end
411
412function NewDrawing(InstanceName)
413local Instance = Drawing.new(InstanceName);
414return (function(Properties)
415for i, v in pairs(Properties) do
416pcall(Set, Instance, i, v);
417end
418return Instance;
419end)
420end
421
422function Menu:AddMenuInstace(Name, Instance)
423if shared.MenuDrawingData.Instances[Name] ~= nil then
424shared.MenuDrawingData.Instances[Name]:Remove();
425end
426shared.MenuDrawingData.Instances[Name] = Instance;
427return Instance;
428end
429function Menu:UpdateMenuInstance(Name)
430local Instance = shared.MenuDrawingData.Instances[Name];
431if Instance ~= nil then
432return (function(Properties)
433for i, v in pairs(Properties) do
434-- print(Format('%s %s -> %s', Name, tostring(i), tostring(v)));
435pcall(Set, Instance, i, v);
436end
437return Instance;
438end)
439end
440end
441function Menu:GetInstance(Name)
442return shared.MenuDrawingData.Instances[Name];
443end
444
445function LineBox:Create(Properties)
446local Box = { Visible = true }; -- prevent errors not really though dont worry bout the Visible = true thing
447
448local Properties = Combine({
449Transparency = 1;
450Thickness = 1;
451Visible = true;
452}, Properties);
453
454Box['TopLeft'] = NewDrawing'Line'(Properties);
455Box['TopRight'] = NewDrawing'Line'(Properties);
456Box['BottomLeft'] = NewDrawing'Line'(Properties);
457Box['BottomRight'] = NewDrawing'Line'(Properties);
458
459function Box:Update(CF, Size, Color, Properties)
460if not CF or not Size then return end
461
462local TLPos, Visible1 = Camera:WorldToViewportPoint((CF * CFrame.new( Size.X, Size.Y, 0)).p);
463local TRPos, Visible2 = Camera:WorldToViewportPoint((CF * CFrame.new(-Size.X, Size.Y, 0)).p);
464local BLPos, Visible3 = Camera:WorldToViewportPoint((CF * CFrame.new( Size.X, -Size.Y, 0)).p);
465local BRPos, Visible4 = Camera:WorldToViewportPoint((CF * CFrame.new(-Size.X, -Size.Y, 0)).p);
466-- ## BEGIN UGLY CODE
467if Visible1 then
468Box['TopLeft'].Visible = true;
469Box['TopLeft'].Color = Color;
470Box['TopLeft'].From = Vector2.new(TLPos.X, TLPos.Y);
471Box['TopLeft'].To = Vector2.new(TRPos.X, TRPos.Y);
472else
473Box['TopLeft'].Visible = false;
474end
475if Visible2 then
476Box['TopRight'].Visible = true;
477Box['TopRight'].Color = Color;
478Box['TopRight'].From = Vector2.new(TRPos.X, TRPos.Y);
479Box['TopRight'].To = Vector2.new(BRPos.X, BRPos.Y);
480else
481Box['TopRight'].Visible = false;
482end
483if Visible3 then
484Box['BottomLeft'].Visible = true;
485Box['BottomLeft'].Color = Color;
486Box['BottomLeft'].From = Vector2.new(BLPos.X, BLPos.Y);
487Box['BottomLeft'].To = Vector2.new(TLPos.X, TLPos.Y);
488else
489Box['BottomLeft'].Visible = false;
490end
491if Visible4 then
492Box['BottomRight'].Visible = true;
493Box['BottomRight'].Color = Color;
494Box['BottomRight'].From = Vector2.new(BRPos.X, BRPos.Y);
495Box['BottomRight'].To = Vector2.new(BLPos.X, BLPos.Y);
496else
497Box['BottomRight'].Visible = false;
498end
499-- ## END UGLY CODE
500if Properties then
501GetTableData(Properties)(function(i, v)
502pcall(Set, Box['TopLeft'], i, v);
503pcall(Set, Box['TopRight'], i, v);
504pcall(Set, Box['BottomLeft'], i, v);
505pcall(Set, Box['BottomRight'], i, v);
506end)
507end
508end
509function Box:SetVisible(bool)
510pcall(Set, Box['TopLeft'], 'Visible', bool);
511pcall(Set, Box['TopRight'], 'Visible', bool);
512pcall(Set, Box['BottomLeft'], 'Visible', bool);
513pcall(Set, Box['BottomRight'], 'Visible', bool);
514end
515function Box:Remove()
516self:SetVisible(false);
517Box['TopLeft']:Remove();
518Box['TopRight']:Remove();
519Box['BottomLeft']:Remove();
520Box['BottomRight']:Remove();
521end
522
523return Box;
524end
525
526function CreateMenu(NewPosition) -- Create Menu
527local function FromHex(HEX)
528HEX = HEX:gsub('#', '');
529return Color3.fromRGB(tonumber('0x' .. HEX:sub(1, 2)), tonumber('0x' .. HEX:sub(3, 4)), tonumber('0x' .. HEX:sub(5, 6)));
530end
531
532local Colors = {
533Primary = {
534Main = FromHex'424242';
535Light = FromHex'6d6d6d';
536Dark = FromHex'1b1b1b';
537};
538Secondary = {
539Main = FromHex'e0e0e0';
540Light = FromHex'ffffff';
541Dark = FromHex'aeaeae';
542};
543};
544
545MenuLoaded = false;
546
547GetTableData(UIButtons)(function(i, v)
548v.Instance.Visible = false;
549v.Instance:Remove();
550end)
551GetTableData(Sliders)(function(i, v)
552v.Instance.Visible = false;
553v.Instance:Remove();
554end)
555
556UIButtons = {};
557Sliders = {};
558
559local BaseSize = Vector2.new(300, 580);
560local BasePosition = NewPosition or Vector2.new(Camera.ViewportSize.X / 8 - (BaseSize.X / 2), Camera.ViewportSize.Y / 2 - (BaseSize.Y / 2));
561
562Menu:AddMenuInstace('CrosshairX', NewDrawing'Line'{
563Visible = false;
564Color = Color3.new(0, 1, 0);
565Transparency = 1;
566Thickness = 1;
567});
568Menu:AddMenuInstace('CrosshairY', NewDrawing'Line'{
569Visible = false;
570Color = Color3.new(0, 1, 0);
571Transparency = 1;
572Thickness = 1;
573});
574
575delay(.025, function() -- since zindex doesnt exist
576Menu:AddMenuInstace('Main', NewDrawing'Square'{
577Size = BaseSize;
578Position = BasePosition;
579Filled = false;
580Color = Colors.Primary.Main;
581Thickness = 3;
582Visible = true;
583});
584end);
585Menu:AddMenuInstace('TopBar', NewDrawing'Square'{
586Position = BasePosition;
587Size = Vector2.new(BaseSize.X, 25);
588Color = Colors.Primary.Dark;
589Filled = true;
590Visible = true;
591});
592Menu:AddMenuInstace('TopBarTwo', NewDrawing'Square'{
593Position = BasePosition + Vector2.new(0, 25);
594Size = Vector2.new(BaseSize.X, 60);
595Color = Colors.Primary.Main;
596Filled = true;
597Visible = true;
598});
599Menu:AddMenuInstace('TopBarText', NewDrawing'Text'{
600Size = 25;
601Position = shared.MenuDrawingData.Instances.TopBarTwo.Position + Vector2.new(25, 15);
602Text = 'Unnamed ESP';
603Color = Colors.Secondary.Light;
604Visible = true;
605});
606Menu:AddMenuInstace('TopBarTextBR', NewDrawing'Text'{
607Size = 15;
608Position = shared.MenuDrawingData.Instances.TopBarTwo.Position + Vector2.new(BaseSize.X - 65, 40);
609Text = 'by ic3w0lf';
610Color = Colors.Secondary.Dark;
611Visible = true;
612});
613Menu:AddMenuInstace('Filling', NewDrawing'Square'{
614Size = BaseSize - Vector2.new(0, 85);
615Position = BasePosition + Vector2.new(0, 85);
616Filled = true;
617Color = Colors.Secondary.Main;
618Transparency= .5;
619Visible = true;
620});
621
622local CPos = 0;
623
624GetTableData(Options)(function(i, v)
625if typeof(v.Value) == 'boolean' and not IsStringEmpty(v.Text) and v.Text ~= nil then
626CPos = CPos + 25;
627local BaseSize = Vector2.new(BaseSize.X, 30);
628local BasePosition = shared.MenuDrawingData.Instances.Filling.Position + Vector2.new(30, v.Index * 25 - 10);
629UIButtons[#UIButtons + 1] = {
630Option = v;
631Instance = Menu:AddMenuInstace(Format('%s_Hitbox', v.Name), NewDrawing'Square'{
632Position = BasePosition - Vector2.new(30, 15);
633Size = BaseSize;
634Visible = false;
635});
636};
637Menu:AddMenuInstace(Format('%s_OuterCircle', v.Name), NewDrawing'Circle'{
638Radius = 10;
639Position = BasePosition;
640Color = Colors.Secondary.Light;
641Filled = true;
642Visible = true;
643});
644Menu:AddMenuInstace(Format('%s_InnerCircle', v.Name), NewDrawing'Circle'{
645Radius = 7;
646Position = BasePosition;
647Color = Colors.Secondary.Dark;
648Filled = true;
649Visible = v.Value;
650});
651Menu:AddMenuInstace(Format('%s_Text', v.Name), NewDrawing'Text'{
652Text = v.Text;
653Size = 20;
654Position = BasePosition + Vector2.new(20, -10);
655Visible = true;
656Color = Colors.Primary.Dark;
657});
658end
659end)
660GetTableData(Options)(function(i, v) -- just to make sure certain things are drawn before or after others, too lazy to actually sort table
661if typeof(v.Value) == 'number' then
662CPos = CPos + 25;
663
664local BaseSize = Vector2.new(BaseSize.X, 30);
665local BasePosition = shared.MenuDrawingData.Instances.Filling.Position + Vector2.new(0, CPos - 10);
666
667local Text = Menu:AddMenuInstace(Format('%s_Text', v.Name), NewDrawing'Text'{
668Text = v.Text;
669Size = 20;
670Position = BasePosition + Vector2.new(20, -10);
671Visible = true;
672Color = Colors.Primary.Dark;
673});
674local AMT = Menu:AddMenuInstace(Format('%s_AmountText', v.Name), NewDrawing'Text'{
675Text = tostring(v.Value);
676Size = 20;
677Position = BasePosition;
678Visible = true;
679Color = Colors.Primary.Dark;
680});
681local Line = Menu:AddMenuInstace(Format('%s_SliderLine', v.Name), NewDrawing'Line'{
682Transparency = 1;
683Color = Colors.Primary.Dark;
684Thickness = 3;
685Visible = true;
686From = BasePosition + Vector2.new(20, 20);
687To = BasePosition + Vector2.new(BaseSize.X - 10, 20);
688});
689CPos = CPos + 10;
690local Slider = Menu:AddMenuInstace(Format('%s_Slider', v.Name), NewDrawing'Circle'{
691Visible = true;
692Filled = true;
693Radius = 6;
694Color = Colors.Secondary.Dark;
695Position = BasePosition + Vector2.new(35, 20);
696})
697
698local CSlider = {Slider = Slider; Line = Line; Min = v.AllArgs[4]; Max = v.AllArgs[5]; Option = v};
699Sliders[#Sliders + 1] = CSlider;
700
701-- local Percent = (v.Value / CSlider.Max) * 100;
702-- local Size = math.abs(Line.From.X - Line.To.X);
703-- local Value = Size * (Percent / 100); -- this shit's inaccurate but fuck it i'm not even gonna bother fixing it
704
705Slider.Position = BasePosition + Vector2.new(40, 20);
706
707v.BaseSize = BaseSize;
708v.BasePosition = BasePosition;
709AMT.Position = BasePosition + Vector2.new(BaseSize.X - AMT.TextBounds.X - 10, -10)
710end
711end)
712GetTableData(Options)(function(i, v) -- just to make sure certain things are drawn before or after others, too lazy to actually sort table
713if typeof(v.Value) == 'EnumItem' then
714CPos = CPos + 30;
715
716local BaseSize = Vector2.new(BaseSize.X, 30);
717local BasePosition = shared.MenuDrawingData.Instances.Filling.Position + Vector2.new(0, CPos - 10);
718
719UIButtons[#UIButtons + 1] = {
720Option = v;
721Instance = Menu:AddMenuInstace(Format('%s_Hitbox', v.Name), NewDrawing'Square'{
722Size = Vector2.new(BaseSize.X, 20) - Vector2.new(30, 0);
723Visible = true;
724Transparency= .5;
725Position = BasePosition + Vector2.new(15, -10);
726Color = Colors.Secondary.Light;
727Filled = true;
728});
729};
730local Text = Menu:AddMenuInstace(Format('%s_Text', v.Name), NewDrawing'Text'{
731Text = v.Text;
732Size = 20;
733Position = BasePosition + Vector2.new(20, -10);
734Visible = true;
735Color = Colors.Primary.Dark;
736});
737local BindText = Menu:AddMenuInstace(Format('%s_BindText', v.Name), NewDrawing'Text'{
738Text = tostring(v.Value):match'%w+%.%w+%.(.+)';
739Size = 20;
740Position = BasePosition;
741Visible = true;
742Color = Colors.Primary.Dark;
743});
744
745Options[i].BaseSize = BaseSize;
746Options[i].BasePosition = BasePosition;
747BindText.Position = BasePosition + Vector2.new(BaseSize.X - BindText.TextBounds.X - 20, -10);
748end
749end)
750GetTableData(Options)(function(i, v) -- just to make sure certain things are drawn before or after others, too lazy to actually sort table
751if typeof(v.Value) == 'function' then
752local BaseSize = Vector2.new(BaseSize.X, 30);
753local BasePosition = shared.MenuDrawingData.Instances.Filling.Position + Vector2.new(0, CPos + (25 * v.AllArgs[4]) - 35);
754
755UIButtons[#UIButtons + 1] = {
756Option = v;
757Instance = Menu:AddMenuInstace(Format('%s_Hitbox', v.Name), NewDrawing'Square'{
758Size = Vector2.new(BaseSize.X, 20) - Vector2.new(30, 0);
759Visible = true;
760Transparency= .5;
761Position = BasePosition + Vector2.new(15, -10);
762Color = Colors.Secondary.Light;
763Filled = true;
764});
765};
766local Text = Menu:AddMenuInstace(Format('%s_Text', v.Name), NewDrawing'Text'{
767Text = v.Text;
768Size = 20;
769Position = BasePosition + Vector2.new(20, -10);
770Visible = true;
771Color = Colors.Primary.Dark;
772});
773
774-- BindText.Position = BasePosition + Vector2.new(BaseSize.X - BindText.TextBounds.X - 10, -10);
775end
776end)
777
778delay(.1, function()
779MenuLoaded = true;
780end);
781
782-- this has to be at the bottom cuz proto drawing api doesnt have zindex :triumph:
783Menu:AddMenuInstace('Cursor1', NewDrawing'Line'{
784Visible = false;
785Color = Color3.new(1, 0, 0);
786Transparency = 1;
787Thickness = 2;
788});
789Menu:AddMenuInstace('Cursor2', NewDrawing'Line'{
790Visible = false;
791Color = Color3.new(1, 0, 0);
792Transparency = 1;
793Thickness = 2;
794});
795Menu:AddMenuInstace('Cursor3', NewDrawing'Line'{
796Visible = false;
797Color = Color3.new(1, 0, 0);
798Transparency = 1;
799Thickness = 2;
800});
801end
802
803CreateMenu();
804
805shared.InputBeganCon = UserInputService.InputBegan:connect(function(input)
806if input.UserInputType.Name == 'MouseButton1' and Options.MenuOpen.Value then
807MouseHeld = true;
808local Bar = Menu:GetInstance'TopBar';
809local Values = {
810Bar.Position.X;
811Bar.Position.Y;
812Bar.Position.X + Bar.Size.X;
813Bar.Position.Y + Bar.Size.Y;
814}
815if MouseHoveringOver(Values) and not syn then -- disable dragging for synapse cuz idk why it breaks
816DraggingUI = true;
817DragOffset = Menu:GetInstance'Main'.Position - GetMouseLocation();
818else
819for i, v in pairs(Sliders) do
820local Values = {
821v.Line.From.X - (v.Slider.Radius);
822v.Line.From.Y - (v.Slider.Radius);
823v.Line.To.X + (v.Slider.Radius);
824v.Line.To.Y + (v.Slider.Radius);
825};
826if MouseHoveringOver(Values) then
827DraggingWhat = v;
828Dragging = true;
829break
830end
831end
832end
833end
834end)
835shared.InputEndedCon = UserInputService.InputEnded:connect(function(input)
836if input.UserInputType.Name == 'MouseButton1' and Options.MenuOpen.Value then
837MouseHeld = false;
838for i, v in pairs(UIButtons) do
839local Values = {
840v.Instance.Position.X;
841v.Instance.Position.Y;
842v.Instance.Position.X + v.Instance.Size.X;
843v.Instance.Position.Y + v.Instance.Size.Y;
844};
845if MouseHoveringOver(Values) then
846v.Option();
847break -- prevent clicking 2 options
848end
849end
850elseif input.UserInputType.Name == 'Keyboard' then
851if Binding then
852BindedKey = input.KeyCode;
853Binding = false;
854elseif input.KeyCode == Options.MenuKey.Value or (input.KeyCode == Enum.KeyCode.Home and UserInputService:IsKeyDown(Enum.KeyCode.LeftControl)) then
855Options.MenuOpen();
856end
857end
858end)
859
860function ToggleMenu()
861if Options.MenuOpen.Value then
862GetTableData(shared.MenuDrawingData.Instances)(function(i, v)
863if OldData[v] then
864pcall(Set, v, 'Visible', true);
865end
866end)
867else
868-- GUIService:SetMenuIsOpen(false);
869GetTableData(shared.MenuDrawingData.Instances)(function(i, v)
870if v.Visible == true then
871OldData[v] = true;
872pcall(Set, v, 'Visible', false);
873end
874end)
875end
876end
877
878function CheckRay(Player, Distance, Position, Unit)
879local Pass = true;
880
881if Distance > 999 then return false; end
882
883local _Ray = Ray.new(Position, Unit * Distance);
884
885local List = {LocalPlayer.Character, Camera, Mouse.TargetFilter};
886
887for i,v in pairs(IgnoreList) do table.insert(List, v); end;
888
889local Hit = workspace:FindPartOnRayWithIgnoreList(_Ray, List);
890if Hit and not Hit:IsDescendantOf(Player.Character) then
891Pass = false;
892if Hit.Transparency >= .3 or not Hit.CanCollide and Hit.ClassName ~= Terrain then -- Detect invisible walls
893IgnoreList[#IgnoreList + 1] = Hit;
894end
895end
896
897return Pass;
898end
899
900function CheckPlayer(Player)
901if not Options.Enabled.Value then return false end
902
903local Pass = true;
904local Distance = 0;
905
906if Player ~= LocalPlayer and Player.Character then
907if not Options.ShowTeam.Value and Player.TeamColor == LocalPlayer.TeamColor then
908Pass = false;
909end
910
911local Head = Player.Character:FindFirstChild'Head';
912
913if Pass and Player.Character and Head then
914Distance = (Camera.CFrame.p - Head.Position).magnitude;
915if Options.VisCheck.Value then
916Pass = CheckRay(Player, Distance, Camera.CFrame.p, (Head.Position - Camera.CFrame.p).unit);
917end
918if Distance > Options.MaxDistance.Value then
919Pass = false;
920end
921end
922else
923Pass = false;
924end
925
926return Pass, Distance;
927end
928
929function UpdatePlayerData()
930if (tick() - LastRefresh) > (Options.RefreshRate.Value / 1000) then
931LastRefresh = tick();
932for i, v in pairs(Players:GetPlayers()) do
933local Data = shared.PlayerData[v.Name] or { Instances = {} };
934
935Data.Instances['Box'] = Data.Instances['Box'] or LineBox:Create{Thickness = 3};
936Data.Instances['Tracer'] = Data.Instances['Tracer'] or NewDrawing'Line'{
937Transparency = 1;
938Thickness = 2;
939}
940Data.Instances['HeadDot'] = Data.Instances['HeadDot'] or NewDrawing'Circle'{
941Filled = true;
942NumSides = 30;
943}
944Data.Instances['NameTag'] = Data.Instances['NameTag'] or NewDrawing'Text'{
945Size = Options.TextSize.Value;
946Center = true;
947Outline = Options.TextOutline.Value;
948Visible = true;
949};
950Data.Instances['DistanceHealthTag'] = Data.Instances['DistanceHealthTag'] or NewDrawing'Text'{
951Size = Options.TextSize.Value - 1;
952Center = true;
953Outline = Options.TextOutline.Value;
954Visible = true;
955};
956
957local NameTag = Data.Instances['NameTag'];
958local DistanceTag = Data.Instances['DistanceHealthTag'];
959local Tracer = Data.Instances['Tracer'];
960local HeadDot = Data.Instances['HeadDot'];
961local Box = Data.Instances['Box'];
962
963local Pass, Distance = CheckPlayer(v);
964
965if Pass and v.Character then
966Data.LastUpdate = tick();
967local Humanoid = v.Character:FindFirstChildOfClass'Humanoid';
968local Head = v.Character:FindFirstChild'Head';
969local HumanoidRootPart = v.Character:FindFirstChild'HumanoidRootPart';
970if v.Character ~= nil and Head then
971local ScreenPosition, Vis = Camera:WorldToViewportPoint(Head.Position);
972if Vis then
973local Color = v.TeamColor == LocalPlayer.TeamColor and Green or Red;
974
975local ScreenPositionUpper = Camera:WorldToViewportPoint(Head.CFrame * CFrame.new(0, Head.Size.Y, 0).p);
976local Scale = Head.Size.Y / 2;
977
978if Options.ShowName.Value then
979NameTag.Visible = true;
980NameTag.Text = v.Name;
981NameTag.Size = Options.TextSize.Value;
982NameTag.Outline = Options.TextOutline.Value;
983NameTag.Position = Vector2.new(ScreenPositionUpper.X, ScreenPositionUpper.Y);
984NameTag.Color = Color;
985if Drawing.Fonts then -- CURRENTLY SYNAPSE ONLY :MEGAHOLY:
986NameTag.Font = Drawing.Fonts.UI;
987end
988else
989NameTag.Visible = false;
990end
991if Options.ShowDistance.Value or Options.ShowHealth.Value then
992DistanceTag.Visible = true;
993DistanceTag.Size = Options.TextSize.Value - 1;
994DistanceTag.Outline = Options.TextOutline.Value;
995DistanceTag.Color = Color3.new(1, 1, 1);
996if Drawing.Fonts then -- CURRENTLY SYNAPSE ONLY :MEGAHOLY:
997NameTag.Font = Drawing.Fonts.UI;
998end
999
1000local Str = '';
1001
1002if Options.ShowDistance.Value then
1003Str = Str .. Format('[%d] ', Distance);
1004end
1005if Options.ShowHealth.Value and Humanoid then
1006Str = Str .. Format('[%d/100]', Humanoid.Health / Humanoid.MaxHealth * 100);
1007end
1008
1009DistanceTag.Text = Str;
1010DistanceTag.Position = Vector2.new(ScreenPositionUpper.X, ScreenPositionUpper.Y) + Vector2.new(0, NameTag.Size);
1011else
1012DistanceTag.Visible = false;
1013end
1014if Options.ShowDot.Value then
1015local Top = Camera:WorldToViewportPoint((Head.CFrame * CFrame.new(0, Scale, 0)).p);
1016local Bottom = Camera:WorldToViewportPoint((Head.CFrame * CFrame.new(0, -Scale, 0)).p);
1017local Radius = (Top - Bottom).y;
1018
1019HeadDot.Visible = true;
1020HeadDot.Color = Color;
1021HeadDot.Position = Vector2.new(ScreenPosition.X, ScreenPosition.Y);
1022HeadDot.Radius = Radius;
1023else
1024HeadDot.Visible = false;
1025end
1026if Options.ShowTracers.Value then
1027Tracer.Visible = true;
1028Tracer.From = Vector2.new(Camera.ViewportSize.X / 2, Camera.ViewportSize.Y);
1029Tracer.To = Vector2.new(ScreenPosition.X, ScreenPosition.Y);
1030Tracer.Color = Color;
1031else
1032Tracer.Visible = false;
1033end
1034if Options.ShowBoxes.Value and HumanoidRootPart then
1035Box:Update(HumanoidRootPart.CFrame, Vector3.new(2, 3, 0) * (Scale * 2), Color);
1036else
1037Box:SetVisible(false);
1038end
1039else
1040NameTag.Visible = false;
1041DistanceTag.Visible = false;
1042Tracer.Visible = false;
1043HeadDot.Visible = false;
1044
1045Box:SetVisible(false);
1046end
1047end
1048else
1049NameTag.Visible = false;
1050DistanceTag.Visible = false;
1051Tracer.Visible = false;
1052HeadDot.Visible = false;
1053
1054Box:SetVisible(false);
1055end
1056
1057shared.PlayerData[v.Name] = Data;
1058end
1059end
1060end
1061
1062function Update()
1063for i, v in pairs(shared.PlayerData) do
1064if not Players:FindFirstChild(tostring(i)) then
1065GetTableData(v.Instances)(function(i, obj)
1066obj.Visible = false;
1067obj:Remove();
1068v.Instances[i] = nil;
1069end)
1070shared.PlayerData[i] = nil;
1071end
1072end
1073
1074local CX = Menu:GetInstance'CrosshairX';
1075local CY = Menu:GetInstance'CrosshairY';
1076if Options.Crosshair.Value then
1077CX.Visible = true;
1078CY.Visible = true;
1079
1080CX.To = Vector2.new((Camera.ViewportSize.X / 2) - 8, (Camera.ViewportSize.Y / 2));
1081CX.From = Vector2.new((Camera.ViewportSize.X / 2) + 8, (Camera.ViewportSize.Y / 2));
1082CY.To = Vector2.new((Camera.ViewportSize.X / 2), (Camera.ViewportSize.Y / 2) - 8);
1083CY.From = Vector2.new((Camera.ViewportSize.X / 2), (Camera.ViewportSize.Y / 2) + 8);
1084else
1085CX.Visible = false;
1086CY.Visible = false;
1087end
1088
1089if Options.MenuOpen.Value and MenuLoaded then
1090local MLocation = GetMouseLocation();
1091shared.MenuDrawingData.Instances.Main.Color = Color3.fromHSV(tick() * 24 % 255/255, 1, 1);
1092local MainInstance = Menu:GetInstance'Main';
1093local Values = {
1094MainInstance.Position.X;
1095MainInstance.Position.Y;
1096MainInstance.Position.X + MainInstance.Size.X;
1097MainInstance.Position.Y + MainInstance.Size.Y;
1098};
1099if MainInstance and MouseHoveringOver(Values) then
1100Debounce.CursorVis = true;
1101-- GUIService:SetMenuIsOpen(true);
1102Menu:UpdateMenuInstance'Cursor1'{
1103Visible = true;
1104From = Vector2.new(MLocation.x, MLocation.y);
1105To = Vector2.new(MLocation.x + 5, MLocation.y + 6);
1106}
1107Menu:UpdateMenuInstance'Cursor2'{
1108Visible = true;
1109From = Vector2.new(MLocation.x, MLocation.y);
1110To = Vector2.new(MLocation.x, MLocation.y + 8);
1111}
1112Menu:UpdateMenuInstance'Cursor3'{
1113Visible = true;
1114From = Vector2.new(MLocation.x, MLocation.y + 6);
1115To = Vector2.new(MLocation.x + 5, MLocation.y + 5);
1116}
1117else
1118if Debounce.CursorVis then
1119Debounce.CursorVis = false;
1120-- GUIService:SetMenuIsOpen(false);
1121Menu:UpdateMenuInstance'Cursor1'{Visible = false};
1122Menu:UpdateMenuInstance'Cursor2'{Visible = false};
1123Menu:UpdateMenuInstance'Cursor3'{Visible = false};
1124end
1125end
1126if MouseHeld then
1127if Dragging then
1128DraggingWhat.Slider.Position = Vector2.new(math.clamp(MLocation.X, DraggingWhat.Line.From.X, DraggingWhat.Line.To.X), DraggingWhat.Slider.Position.Y);
1129local Percent = (DraggingWhat.Slider.Position.X - DraggingWhat.Line.From.X) / ((DraggingWhat.Line.To.X - DraggingWhat.Line.From.X));
1130local Value = CalculateValue(DraggingWhat.Min, DraggingWhat.Max, Percent);
1131DraggingWhat.Option(Value);
1132elseif DraggingUI then
1133Debounce.UIDrag = true;
1134local Main = Menu:GetInstance'Main';
1135local MousePos = GetMouseLocation();
1136Main.Position = MousePos + DragOffset;
1137end
1138else
1139Dragging = false;
1140if DraggingUI and Debounce.UIDrag then
1141Debounce.UIDrag = false;
1142DraggingUI = false;
1143CreateMenu(Menu:GetInstance'Main'.Position);
1144end
1145end
1146if not Debounce.Menu then
1147Debounce.Menu = true;
1148ToggleMenu();
1149end
1150elseif Debounce.Menu and not Options.MenuOpen.Value then
1151Debounce.Menu = false;
1152ToggleMenu();
1153end
1154end
1155
1156RunService:UnbindFromRenderStep(GetDataName);
1157RunService:UnbindFromRenderStep(UpdateName);
1158
1159RunService:BindToRenderStep(GetDataName, 1, UpdatePlayerData);
1160RunService:BindToRenderStep(UpdateName, 1, Update);
1161end)
1162ctrlclicktp.MouseButton1Down:connect(function()
1163loadstring(game:GetObjects("rbxassetid://509249639")[1].Source)()
1164end)
1165noclip.MouseButton1Down:connect(function()
1166nam = game:GetService("Players").LocalPlayer.Name
1167
1168game:GetService('RunService').Stepped:connect(function()
1169for a, b in pairs(game.Workspace:GetChildren()) do
1170if b.Name == nam then
1171for i, v in pairs(game.Workspace[nam]:GetChildren()) do
1172if v:IsA("BasePart") then
1173v.CanCollide = false
1174
1175end
1176end
1177end
1178end
1179end)
1180
1181
1182Workspace[nam].Head.Changed:connect(function()
1183for a, b in pairs(game.Workspace:GetChildren()) do
1184if b.Name == nam then
1185for i, v in pairs(game.Workspace[nam]:GetChildren()) do
1186if v:IsA("BasePart") then
1187v.CanCollide = false
1188
1189end
1190end
1191end
1192end
1193end)
1194end)
1195aimlock.MouseButton1Down:connect(function()
1196--made by Avexus#1234 discord from MrStuperd btw and DO NOT PRESS DELETE ;) GUI aimbot_toggled
1197
1198local UIS = game:GetService('UserInputService')
1199local RS = game:GetService('RunService')
1200local Players = game:GetService('Players')
1201local StarterGui = game:GetService('StarterGui')
1202local Player = Players.LocalPlayer
1203local Studio = RS:IsStudio()
1204local PlayerGui = RS:IsStudio() and Player:WaitForChild('PlayerGui') or game.CoreGui
1205local Mouse = Player:GetMouse()
1206local old_icon = Mouse.Icon
1207local Camera = workspace.CurrentCamera
1208targetpart = 'Head' -- Don't change this.
1209-- It can be changed with the targetpart_change hotkey ingame.
1210local target
1211local target_old
1212local alert = false
1213local lockedon = false
1214local settingkey = false
1215local upvals = nil
1216local val = 1
1217local windows = {}
1218local function hb() RS.Heartbeat:wait() end
1219
1220local version = 1.25
1221local Spawn = nil or game.PlaceId == 292439477 and workspace:WaitForChild('Lobby',2):WaitForChild('Spawn1',2)
1222local spawned = false
1223
1224script.Name = 'GameSense!'
1225Mouse.TargetFilter = Camera
1226
1227-- hotkey
1228toggle_aim = Enum.UserInputType.MouseButton2
1229toggle_aimbot = Enum.KeyCode.Delete
1230toggle_trigger = Enum.KeyCode.Delete
1231toggle_esp = Enum.KeyCode.Delete
1232toggle_gui = Enum.KeyCode.Delete
1233toggle_bottompos = Enum.KeyCode.Delete
1234toggle_performance = Enum.KeyCode.Delete
1235toggle_bones = Enum.KeyCode.Delete
1236toggle_chams = Enum.KeyCode.Delete
1237toggle_tracers = Enum.KeyCode.Delete
1238toggle_boxes = Enum.KeyCode.Delete
1239toggle_font = Enum.KeyCode.Delete
1240ffatoggle = Enum.KeyCode.Delete
1241targetpart_change = Enum.KeyCode.Delete
1242priority_toggle = Enum.KeyCode.Delete
1243sethotkey = Enum.KeyCode.Delete
1244-- aim fov
1245fov_increase = Enum.KeyCode.KeypadPlus
1246fov_decrease = Enum.KeyCode.KeypadMinus
1247-- aim sens (how smooth your crosshair will move)
1248sens_increase = Enum.KeyCode.RightBracket
1249sens_decrease = Enum.KeyCode.LeftBracket
1250
1251-- parts
1252parts = {
1253 'Head';
1254 'Torso'
1255}
1256
1257fonts = {
1258 Enum.Font.SourceSansBold,
1259 Enum.Font.Cartoon,
1260 Enum.Font.Arcade,
1261 Enum.Font.SciFi,
1262 Enum.Font.Fantasy,
1263 Enum.Font.Code,
1264 Enum.Font.Highway,
1265 Enum.Font.Bodoni
1266}
1267
1268textSet = false
1269
1270currentfont = 1
1271ffa = true
1272hidden = false
1273performancemode = true
1274-- aim
1275fov = 6
1276sens = .25
1277drop = .4
1278aim_toggled = false
1279bottompos = true
1280aim_priority = 2
1281-- [2] FOV or [1] Distance
1282aimingcolor = Color3.fromRGB(0,165,255)
1283aimbot_toggled = true
1284aim_line = true
1285locksoundid = 538769304
1286mouseiconid = 18671553
1287
1288-- trigger
1289trigger_toggled = false
1290trigger_delay = 1/20
1291
1292-- esp
1293esp_toggled = false
1294esp_bones = false
1295esp_chams = false
1296esp_tracers = false
1297-- item_esp (coming soon)
1298linesize = 1
1299showdists = true
1300textsize = 14
1301textoffset = 20
1302visiblecolor = Color3.fromRGB(38,255,99)
1303hiddencolor = Color3.fromRGB(255,37,40)
1304headboxsize = 4
1305headboxaimsize = 6
1306headboxshape = 'diamond'
1307-- rectangle or diamond
1308
1309-- box esp
1310bounding_box = true
1311-- box_pointsize = 0 [UNUSED]
1312box_line_size = 1
1313-- box_line_size_visible = 2 [UNUSED]
1314
1315local GUI = Instance.new('ScreenGui',PlayerGui)
1316GUI.Name = 'GameSense '..version
1317GUI.ResetOnSpawn = false
1318
1319ESP = Instance.new('Folder',GUI)
1320ESP.Name = 'ESP'
1321local Bottom = Instance.new('Frame',ESP)
1322Bottom.Name = 'Bottom'
1323Bottom.BackgroundTransparency = 1
1324Bottom.Size = UDim2.new(0,1,0,1)
1325Bottom.Position = UDim2.new(.5,0,1,1)
1326
1327local Status = Instance.new('TextLabel',GUI)
1328Status.Name = 'Status'
1329Status.BackgroundTransparency = 1
1330Status.Size = UDim2.new(0,500,0,50)
1331Status.Position = UDim2.new(.5,-250,.85,0)
1332Status.TextSize = 0
1333Status.Font = Enum.Font.SourceSansBold
1334Status.TextColor3 = Color3.new(1,1,1)
1335Status.TextStrokeColor3 = Color3.new(0,0,0)
1336Status.TextStrokeTransparency = .6
1337Status.Text = 'On Standby'
1338Status.ZIndex = 50
1339
1340local Credits = Status:Clone()
1341Credits.Name = 'Credits'
1342Credits.Parent = GUI
1343Credits.Position = UDim2.new(-1000000,-1000000,-1000000,-1000000)
1344Credits.TextSize = 0
1345Credits.Text = 'GameSense '..version..' by Avexus!'
1346
1347local FovGui = Instance.new('ImageLabel',GUI)
1348FovGui.Name = 'FovGui'
1349FovGui.Image = 'rbxassetid://324848180'
1350FovGui.Size = UDim2.new(0,(Camera.ViewportSize.X/(90/fov))*2,0,(Camera.ViewportSize.X/(90/fov))*2)
1351FovGui.Position = UDim2.new(0.5,-FovGui.AbsoluteSize.X/2,0.5,-FovGui.AbsoluteSize.Y/2)
1352FovGui.BackgroundTransparency = 1
1353FovGui.ImageTransparency = 0.9
1354FovGui.ImageColor3 = Color3.new(1,0,0)
1355
1356local Indicator = Instance.new('TextLabel',GUI)
1357Indicator.Name = 'Indicator'
1358Indicator.Font = Enum.Font.SourceSans
1359Indicator.TextSize = 0
1360Indicator.TextXAlignment = Enum.TextXAlignment.Center
1361Indicator.TextYAlignment = Enum.TextYAlignment.Center
1362Indicator.TextStrokeTransparency = 1
1363Indicator.Text = aim_priority>1 and 'FOV: '..fov or 'Distance'
1364
1365local SensAdjust = Instance.new('TextBox',GUI)
1366SensAdjust.Name = 'SensAdjust'
1367SensAdjust.Font = Enum.Font.SourceSans
1368SensAdjust.BackgroundTransparency = .75
1369SensAdjust.BackgroundColor3 = Color3.new(0,0,0)
1370SensAdjust.BorderColor3 = Color3.new(1,1,1)
1371SensAdjust.Size = UDim2.new(0,50,0,20)
1372SensAdjust.TextStrokeTransparency = 1
1373SensAdjust.TextColor3 = Color3.new(1,1,1)
1374SensAdjust.TextSize = 0
1375SensAdjust.PlaceholderText = 'Sens'
1376SensAdjust.Text = tonumber(sens)
1377SensAdjust.Position = Credits.Position + UDim2.new(0,250,0,75)
1378
1379local SensLabel = Instance.new('TextLabel',SensAdjust)
1380SensLabel.Name = 'SensLabel'
1381SensLabel.Font = Enum.Font.SourceSans
1382SensLabel.Size = UDim2.new(1,0,1,0)
1383SensLabel.BackgroundTransparency = 1
1384SensLabel.TextSize = 0
1385SensLabel.TextColor3 = Color3.new(1,1,1)
1386SensLabel.TextStrokeColor3 = Color3.new(0,0,0)
1387SensLabel.TextStrokeTransparency = 1
1388SensLabel.Text = 'Sens:'
1389SensLabel.Position = UDim2.new(-1,0,0,0)
1390SensLabel.TextXAlignment = Enum.TextXAlignment.Left
1391
1392local FovAdjust = SensAdjust:Clone()
1393FovAdjust.Parent = GUI
1394FovAdjust.PlaceholderText = 'FOV'
1395FovAdjust.Name = 'FovAdjust'
1396FovAdjust.Text = tonumber(fov)
1397FovAdjust.Position = SensAdjust.Position + UDim2.new(0,0,0,20)
1398FovAdjust.SensLabel.Name = 'FovLabel'
1399FovAdjust.FovLabel.Text = 'Fov:'
1400
1401local DropAdjust = SensAdjust:Clone()
1402DropAdjust.Parent = GUI
1403DropAdjust.PlaceholderText = 'Drop'
1404DropAdjust.Name = 'DropAdjust'
1405DropAdjust.Text = tonumber(drop)
1406DropAdjust.Position = SensAdjust.Position + UDim2.new(0,0,0,40)
1407DropAdjust.SensLabel.Name = 'DropLabel'
1408DropAdjust.DropLabel.Text = 'Drop:'
1409
1410local KeysList = Instance.new('TextLabel',GUI)
1411KeysList.Name = 'KeysList'
1412KeysList.Font = Enum.Font.SourceSans
1413KeysList.TextStrokeTransparency = .6
1414KeysList.TextSize = 0
1415KeysList.TextColor3 = Color3.new(1,1,1)
1416KeysList.Size = UDim2.new(0,0,1,0)
1417KeysList.Position = UDim2.new(0,5,0,-280)
1418KeysList.BackgroundTransparency = 1
1419KeysList.Active = false
1420
1421local n = 0
1422
1423spawn(function()
1424 while Status do
1425 Indicator.TextColor3 = Color3.fromHSV(n,.5,1)
1426 FovGui.ImageColor3 = Indicator.TextColor3
1427 if not textSet then
1428 if aim_toggled and target then
1429 Status.TextColor3 = aimingcolor
1430 Status.Text = ('Aiming at '..target.Name)
1431 else
1432 Status.TextColor3 = Color3.fromHSV(n,.5,1)
1433 Status.Text = 'On Standby'
1434 end
1435 end
1436 n = (n+.005)%1
1437 hb()
1438 end
1439end)
1440
1441SensAdjust.InputEnded:Connect(function() if SensAdjust.Text~='' then sens = tonumber(SensAdjust.Text)>0 and tonumber(SensAdjust.Text) or sens end end)
1442FovAdjust.InputEnded:Connect(function() if FovAdjust.Text~='' then fov = tonumber(FovAdjust.Text)>0 and tonumber(FovAdjust.Text) or fov
1443FovGui:TweenSize(UDim2.new(0,(Camera.ViewportSize.X/(90/fov))*2,0,(Camera.ViewportSize.X/(90/fov))*2),Enum.EasingDirection.InOut,Enum.EasingStyle.Quad,.1,true) end end)
1444DropAdjust.InputEnded:Connect(function() if DropAdjust.Text~='' then drop = tonumber(DropAdjust.Text)>=0 and tonumber(DropAdjust.Text) or drop end end)
1445
1446local function distfromspawn(x)
1447 if Spawn then
1448 return x:DistanceFromCharacter(Spawn.Position)
1449 else
1450 return 201
1451 end
1452end
1453
1454local function setText(text)
1455 spawn(function()
1456 textSet = true
1457 Status.Text = text
1458 Status.TextColor3 = Color3.new(1,1,1)
1459 wait(#text/4)
1460 textSet = false
1461 end)
1462end
1463
1464local function playsound(id)
1465 local sound = Instance.new('Sound',Camera)
1466 sound.Volume = 3
1467 sound:Play()
1468 game:GetService('Debris'):AddItem(sound,5)
1469end
1470
1471
1472local function DrawLine(Folder,P1,P2,Thickness,Color,LineTransparency,BorderThickness,BorderColor)
1473 -- Declare variables
1474 local Point1,Point2 = P1.Position,P2.Position
1475 if Point1 and Point2 then
1476 local X,Y = Camera.ViewportSize.X, Camera.ViewportSize.Y
1477 local X1,X2 = (X * Point1.X.Scale + Point1.X.Offset + P1.Size.X.Offset/2), (X * Point2.X.Scale + Point2.X.Offset + P2.Size.X.Offset/2)
1478 local Y1,Y2 = (Y * Point1.Y.Scale + Point1.Y.Offset + P1.Size.Y.Offset/2), (Y * Point2.Y.Scale + Point2.Y.Offset + P2.Size.Y.Offset/2)
1479 local MidX,MidY = (X1+X2)/2, (Y1+Y2)/2
1480 -- Set defaults to prevent errors
1481 Thickness = Thickness or 1
1482 Color = Color or Color3.new(1,1,1)
1483 LineTransparency = LineTransparency or 0
1484 BorderThickness = BorderThickness or 0
1485 BorderColor = BorderColor or Color3.new(0,0,0)
1486 -- Draw the line
1487 local Line = Folder:FindFirstChild(P1.Name..'-'..P2.Name) or Instance.new('Frame',Folder)
1488 Line.Visible = false
1489 Line.BackgroundTransparency = LineTransparency
1490 Line.BorderSizePixel = BorderThickness
1491 Line.BorderColor3 = BorderColor
1492 Line.Size = UDim2.new(0,(Vector2.new(X1,Y1) - Vector2.new(X2,Y2)).magnitude-1,0,Thickness)
1493 Line.Position = UDim2.new(0,MidX-Line.AbsoluteSize.X/2,0,MidY-Line.AbsoluteSize.Y)
1494 Line.BackgroundColor3 = Color
1495 Line.Rotation = math.deg(math.atan2((Y2-Y1),(X2-X1)))
1496 Line.Name = P1.Name..'-'..P2.Name
1497 Line.Visible = true
1498 return Line
1499 else
1500 return nil
1501 end
1502end
1503
1504local function GetNearest(Mode)
1505 local lowest,nearest,gui = math.huge,nil,nil
1506 if Mode==1 then
1507 for _,plr in next,Players:GetPlayers() do
1508 if plr.Name~=Player.Name and plr.Character~=nil and plr.Character:FindFirstChild(targetpart) then
1509 local dist = Player:DistanceFromCharacter(plr.Character[targetpart].Position)
1510 local ray = Ray.new(Player.Character.Head.Position,(plr.Character[targetpart].Position-Player.Character.Head.Position).unit*5000)
1511 local part,point = workspace:FindPartOnRayWithIgnoreList(ray,{Camera,Player.Character,unpack(windows)})
1512 local Z = Camera:WorldToScreenPoint(plr.Character[targetpart].Position).Z
1513 if part and part:IsDescendantOf(plr.Character) and Z>0 and dist < lowest and (ffa or plr.TeamColor~=Player.TeamColor) then lowest = dist nearest = plr.Character end
1514 end
1515 end
1516 elseif Mode==2 then
1517 for _,plr in next,Players:GetPlayers() do
1518 if plr.Name~=Player.Name and plr.Character~=nil and plr.Character:FindFirstChild(targetpart) then
1519 local pos = Camera:WorldToScreenPoint(plr.Character[targetpart].Position)
1520 local ray = Ray.new(Player.Character[targetpart].Position,(plr.Character[targetpart].Position-Player.Character[targetpart].Position).unit*2048)
1521 local part,point = workspace:FindPartOnRayWithIgnoreList(ray,{Camera,Player.Character,unpack(windows)})
1522 local dist = (Vector2.new(Mouse.X,Mouse.Y)-Vector2.new(pos.X,pos.Y)).magnitude
1523 if part and part:IsDescendantOf(plr.Character) and pos.Z>0 and dist <= Camera.ViewportSize.X/(90/fov) and dist < lowest and (ffa or plr.TeamColor~=Player.TeamColor) then lowest = dist nearest = plr.Character end
1524 end
1525 end
1526 end
1527 return nearest
1528end
1529
1530Mouse.Move:Connect(function()
1531 cursor = ESP:FindFirstChild('Cursor') or Instance.new('Frame',ESP)
1532 cursor.Name = 'Cursor'
1533 cursor.BackgroundTransparency = 1
1534 cursor.Size = UDim2.new(0,1,0,1)
1535 cursor.Position = UDim2.new(0,Mouse.X,0,Mouse.Y)
1536end)
1537
1538UIS.InputBegan:Connect(function(Input)
1539 if Input.KeyCode == toggle_aim or Input.UserInputType == toggle_aim then
1540 aim_toggled = true
1541 warn('GS: aim toggled',aim_toggled and 'on' or 'off')
1542 alert = true
1543 while aim_toggled and aimbot_toggled do
1544 target = GetNearest(aim_priority)
1545 if target then
1546 local dist = Player:DistanceFromCharacter(target[targetpart].Position)
1547 local headpos = Camera:WorldToScreenPoint(target[targetpart].Position+Vector3.new(0,dist/(100/drop),0))
1548 local moveto = Vector2.new((headpos.X-Mouse.X)*sens,(headpos.Y-Mouse.Y)*sens)
1549 aimpos = GUI:FindFirstChild('AimPos') or Instance.new('Frame',GUI)
1550 if not GUI:FindFirstChild('AimPos') then
1551 aimpos.Name = 'AimPos'
1552 aimpos.BorderSizePixel = 1
1553 aimpos.BorderColor3 = Color3.new(0,0,0)
1554 aimpos.BackgroundTransparency = 0
1555 aimpos.BackgroundColor3 = Color3.new(1,1,1)
1556 aimpos.Rotation = 45
1557 aimpos.ZIndex = 4
1558 aimpos.Size = UDim2.new(0,3,0,3)
1559 end
1560 aimpos.Position = UDim2.new(0,headpos.X-aimpos.AbsoluteSize.X/2,0,headpos.Y-aimpos.AbsoluteSize.Y/2)
1561 aimpos.Visible = true
1562 mousemoverel(moveto.X,moveto.Y)
1563 if alert or target~=target_old then
1564 playsound(locksoundid)
1565 print('GS: locked onto',target.Name)
1566 lockedon = true
1567 alert = false
1568 end
1569 end
1570 RS.Heartbeat:wait()
1571 target_old = target
1572 if aimpos then
1573 aimpos.Visible = false
1574 end
1575 end
1576 lockedon = false
1577 elseif Input.KeyCode == toggle_trigger then
1578 trigger_toggled = not trigger_toggled
1579 setText('Toggled TriggerBot '..(trigger_toggled and 'On' or 'Off'))
1580 Notification({Title='TriggerBot';Text='TriggerBot was toggled '..(trigger_toggled and 'On' or 'Off');Duration=2;})
1581 warn('trigger toggled',trigger_toggled and 'on' or 'off')
1582 local Box = Instance.new('SelectionBox',PlayerGui)
1583 Box.Color3 = Color3.new(1,0,0)
1584 Box.LineThickness = .05
1585 Box.Adornee = nil
1586 if trigger_delay>0 then wait(trigger_delay) end
1587 while trigger_toggled do
1588 local Target = Mouse.Target
1589 local plr = Players:FindFirstChild(Target.Parent.Name)
1590 if Target and Target.Parent and plr~=nil and plr~=Player and ffa or plr~=nil and plr.TeamColor~=Player.TeamColor then
1591 Box.Adornee = Mouse.Target
1592 mouse1press()
1593 wait()
1594 mouse1release()
1595 end
1596 RS.Heartbeat:wait()
1597 end
1598 Box:Destroy()
1599 elseif Input.KeyCode == toggle_esp then
1600 esp_toggled = not esp_toggled
1601 Notification({Title='ESP';Text='ESP was toggled '..(esp_toggled and 'On' or 'Off');Duration=2;})
1602 setText('Toggled ESP '..(esp_toggled and 'On' or 'Off'))
1603 elseif Input.KeyCode == toggle_aimbot then
1604 aimbot_toggled = not aimbot_toggled
1605 Notification({Title='AimBot';Text='AimBot was toggled '..(aimbot_toggled and 'On' or 'Off');Duration=2;})
1606 setText('Toggled AimBot '..(aimbot_toggled and 'On' or 'Off'))
1607 elseif Input.KeyCode == fov_increase then
1608 fov = fov + .5
1609 FovAdjust.Text = tonumber(fov)
1610 if FovGui.Visible then
1611 FovGui:TweenSize(UDim2.new(0,(Camera.ViewportSize.X/(90/fov))*2,0,(Camera.ViewportSize.X/(90/fov))*2),Enum.EasingDirection.InOut,Enum.EasingStyle.Quad,.1,true)
1612 end
1613 setText('Aim FOV: '..fov)
1614 elseif Input.KeyCode == fov_decrease and fov>0 then
1615 fov = fov - .5
1616 FovAdjust.Text = tonumber(fov)
1617 if FovGui.Visible then
1618 FovGui:TweenSize(UDim2.new(0,(Camera.ViewportSize.X/(90/fov))*2,0,(Camera.ViewportSize.X/(90/fov))*2),Enum.EasingDirection.InOut,Enum.EasingStyle.Quad,.1,true)
1619 end
1620 setText('Aim FOV: '..fov)
1621 elseif Input.KeyCode == sens_increase then
1622 sens = sens + .05
1623 SensAdjust.Text = tonumber(sens)
1624 setText('Sens: '..sens)
1625 elseif Input.KeyCode == sens_decrease then
1626 sens = sens - .05
1627 SensAdjust.Text = tonumber(sens)
1628 setText('Sens: '..sens)
1629 elseif Input.KeyCode == targetpart_change then
1630 val = val+1
1631 targetpart = val<=#parts and parts[val] or parts[1]
1632 if parts[1]==targetpart then val = 1 end
1633 Notification({Title='Target Part';Text='Target part set to '..targetpart;Duration=2;})
1634 setText('Target Part: '..targetpart)
1635 elseif Input.KeyCode == ffatoggle then
1636 ffa = not ffa
1637 Notification({Title='FFA Mode';Text='FFA Mode is '..(ffa and 'Enabled' or 'Disabled');Duration=2;})
1638 setText('FFA Mode: '..(ffa and 'Enabled' or 'Disabled'))
1639 elseif Input.KeyCode == priority_toggle then
1640 aim_priority = aim_priority+1>2 and 0 or 1
1641 aim_priority = aim_priority+1
1642 FovGui.Visible = aim_priority>1
1643 setText('Aim Priority: '..(aim_priority==1 and 'Distance' or 'FOV'))
1644 elseif Input.KeyCode == toggle_bones then
1645 esp_bones = not esp_bones
1646 if not esp_bones then
1647 for _,v in next,ESP:GetDescendants() do
1648 if v:IsA('Frame') and v.Name:match('-') then
1649 v:Destroy()
1650 end
1651 end
1652 end
1653 setText('Toggled ESP Bones '..(esp_bones and 'Enabled' or 'Disabled'))
1654 elseif Input.KeyCode == toggle_gui then
1655 hidden = not hidden
1656 for _,gui in next,GUI:GetDescendants() do
1657 if gui:IsA('GuiObject') and not hidden and not gui.Visible then
1658 gui.Visible = true
1659 Mouse.Icon = 'rbxassetid://'..mouseiconid
1660 elseif gui:IsA('GuiObject') and gui.Visible then
1661 gui.Visible = false
1662 esp_toggled = false
1663 Mouse.Icon = old_icon
1664 end
1665 end
1666 elseif Input.KeyCode == toggle_bottompos then
1667 bottompos = not bottompos
1668 if bottompos then
1669 Bottom.Position = UDim2.new(.5,0,1,1)
1670 end
1671 elseif Input.KeyCode == toggle_performance then
1672 performancemode = not performancemode
1673 setText('Performance Mode '..(performancemode and 'Enabled' or 'Disabled'))
1674 elseif Input.KeyCode == toggle_chams then
1675 esp_chams = not esp_chams
1676 setText('Chams '..(esp_chams and 'Enabled' or 'Disabled'))
1677 elseif Input.KeyCode == toggle_tracers then
1678 esp_tracers = not esp_tracers
1679 setText('Tracers '..(esp_chams and 'Enabled' or 'Disabled'))
1680 elseif Input.KeyCode == toggle_boxes then
1681 bounding_box = not bounding_box
1682 setText('Bounding Boxes '..(bounding_box and 'Enabled' or 'Disabled'))
1683 elseif Input.KeyCode == toggle_font then
1684 currentfont = (currentfont+1)>#fonts and 1 or currentfont+1
1685 for _,v in next,GUI:GetDescendants() do
1686 if v.Name~='KeysList' then
1687 if v:IsA('TextLabel') or v:IsA('TextButton') then
1688 v.Font = fonts[currentfont]
1689 end
1690 end
1691 end
1692 end
1693end)
1694
1695UIS.InputEnded:Connect(function(Input)
1696 if Input.KeyCode == toggle_aim or Input.UserInputType == toggle_aim then
1697 aim_toggled = false
1698 end
1699end)
1700
1701local function checkifspawned(x)
1702 spawned = false
1703 while not spawned and game.PlaceId==292439477 do
1704 spawned = distfromspawn(x)>200 and true or false
1705 wait(1/5)
1706 end
1707 spawned = true
1708end
1709
1710checkifspawned(Player)
1711Player.CharacterAdded:Connect(function(c)
1712 checkifspawned(Player)
1713
1714 for _,v in next,ESP:GetDescendants() do
1715 if v:IsA('Frame') and v.Name:match('-') then
1716 v:Destroy()
1717 end
1718 end
1719end)
1720
1721Notification({Title='Aimbot '..version;Text='Loaded successfully.';Icon='rbxassetid://2572157833';Duration=10;})
1722wait(.5)
1723
1724RS.RenderStepped:Connect(function()
1725 if cursor then
1726 FovGui.Position = cursor.Position-UDim2.new(0,FovGui.AbsoluteSize.X/2,0,FovGui.AbsoluteSize.Y/2)
1727 Indicator.Position = cursor.Position+UDim2.new(0,0,0,40)
1728 end
1729end)
1730
1731Mouse.Button1Down:Connect(function()
1732 spawn(function()
1733 if FovGui.Visible then
1734 FovGui:TweenSize(UDim2.new(0,Camera.ViewportSize.X/(90/fov)*2.35,0,Camera.ViewportSize.X/(90/fov)*2.35),Enum.EasingDirection.InOut,Enum.EasingStyle.Quad,.1,true)
1735 wait(.1)
1736 FovGui:TweenSize(UDim2.new(0,Camera.ViewportSize.X/(90/fov)*2,0,Camera.ViewportSize.X/(90/fov)*2),Enum.EasingDirection.InOut,Enum.EasingStyle.Quad,.1,true)
1737 end
1738 end)
1739end)
1740
1741while true do
1742 Indicator.Text = (aim_priority>1 and 'FOV: '..fov or 'Distance') ..'\nSens: '..sens..(aim_toggled and '\nAiming' or '')
1743 if not bottompos then Bottom.Position = cursor.Position end
1744 if esp_toggled then
1745 for _,v in next,ESP:children() do
1746 if v~=Bottom and not Players:FindFirstChild(v.Name) then
1747 v:Destroy()
1748 end
1749 end
1750 for _,v in next,Players:GetPlayers() do
1751 local Char = v.Character
1752 if Char and spawned and v~=Player and Char:FindFirstChild(targetpart) and distfromspawn(v)>100 then
1753 if ffa or v.TeamColor~=Player.TeamColor then
1754 local X = Camera:GetPartsObscuringTarget({Camera.CFrame.p,Char[targetpart].CFrame.p},{v.Character,Char,Camera,unpack(windows)})
1755 local Dist = Player:DistanceFromCharacter(Char:FindFirstChild(targetpart).Position)
1756 local Color = hiddencolor
1757 local Folder = ESP:FindFirstChild(v.Name) or Instance.new('Folder',ESP)
1758 Folder.Name = v.Name
1759 -- ESP
1760 local Head = Folder:FindFirstChild('Head') or Instance.new('Frame',Folder)
1761 if not Folder:FindFirstChild('Head') then
1762 Head.Name = 'Head'
1763 Head.BorderSizePixel = 1
1764 Head.BorderColor3 = Color3.new(0,0,0)
1765 Head.BackgroundTransparency = 0
1766 end
1767 Head.BackgroundColor3 = #X>0 and hiddencolor or #X==0 and visiblecolor
1768 Head.Rotation = headboxshape=='diamond' and 45 or 0
1769 Head.ZIndex = 3
1770 local HP = Folder:FindFirstChild('HP') or Instance.new('TextLabel',Folder)
1771 if not Folder:FindFirstChild('HP') then
1772 HP.Name = 'HP'
1773 HP.TextTransparency = Head.BackgroundTransparency-.4
1774 HP.Font = fonts[currentfont]
1775 HP.TextStrokeTransparency = .6
1776 HP.BackgroundTransparency = 1
1777 HP.TextSize = 14
1778 end
1779 HP.Text = showdists and Char.Name..'\n'..math.floor(Dist+.5) or Char.Name
1780 if aim_toggled and target==Char then
1781 Head.Size = UDim2.new(0,headboxaimsize,0,headboxaimsize)
1782 Head.BackgroundColor3 = aimingcolor
1783 HP.Text = showdists and '['..Char.Name..']'..'\n'..math.floor(Dist+.5) or '['..Char.Name..']'
1784 HP.TextSize = 16
1785 else
1786 Head.Size = UDim2.new(0,headboxsize,0,headboxsize)
1787 end
1788 HP.TextColor3 = Head.BackgroundColor3
1789 local toScreen = Camera:WorldToScreenPoint(Char[targetpart].CFrame.p)
1790 if #X==0 then Color = visiblecolor end
1791 Head.Position = UDim2.new(0,toScreen.X-Head.Size.X.Offset/2,0,toScreen.Y-Head.Size.Y.Offset/2)
1792 HP.Position = Head.Position-UDim2.new(0,0,0,textoffset)
1793 if esp_tracers then
1794 local Line = DrawLine(Folder,ESP.Bottom,Head,linesize,Head.BackgroundColor3,.75,1,Color3.new(0,0,0))
1795 Line.Visible = Head.Visible
1796 else
1797 local imtired = Folder:FindFirstChild(ESP.Bottom.Name..'-'..Head.Name)
1798 if imtired then
1799 imtired:Destroy()
1800 end
1801 end
1802 if toScreen.Z<=0 then Head.Visible = false else Head.Visible = true end
1803 HP.Visible = Head.Visible
1804 if Char:FindFirstChild('Humanoid') and Char.Humanoid.RigType==Enum.HumanoidRigType.R6 then
1805 local Neck = Folder:FindFirstChild('Neck') or Instance.new('Frame',Folder)
1806 Neck.Name = 'Neck'
1807 Neck.ZIndex = 2
1808 if Char['Torso']~=nil then
1809 local Pos = (Char.Torso.CFrame*CFrame.new(0,.8,0)).p
1810 local X,Y,Z = Camera:WorldToScreenPoint(Pos).X,Camera:WorldToScreenPoint(Pos).Y,Camera:WorldToScreenPoint(Pos).Z
1811 Neck.Position = UDim2.new(0,X,0,Y)
1812 Neck.BorderSizePixel = 0
1813 if Z<=0 then Neck.Visible = false else Neck.Visible = true end
1814 else
1815 Neck.Visible = false
1816 end
1817 --
1818 local Pelvis = Folder:FindFirstChild('Pelvis') or Instance.new('Frame',Folder)
1819 Pelvis.Name = 'Pelvis'
1820 Pelvis.ZIndex = 2
1821 Pelvis.BorderSizePixel = 0
1822 if Char['Torso']~=nil then
1823 local Pos = (Char.Torso.CFrame*CFrame.new(0,-1,0)).p
1824 local X,Y,Z = Camera:WorldToScreenPoint(Pos).X,Camera:WorldToScreenPoint(Pos).Y,Camera:WorldToScreenPoint(Pos).Z
1825 Pelvis.Position = UDim2.new(0,X,0,Y)
1826 if Z<=0 then Pelvis.Visible = false else Pelvis.Visible = true end
1827 else
1828 Pelvis.Visible = false
1829 end
1830 --
1831 local RightFoot = Folder:FindFirstChild('Right Foot') or Instance.new('Frame',Folder)
1832 RightFoot.Name = 'Right Foot'
1833 RightFoot.ZIndex = 2
1834 RightFoot.BorderSizePixel = 0
1835 if Char['Right Leg']~=nil then
1836 local Pos = (Char['Right Leg'].CFrame*CFrame.new(0,-1,0)).p
1837 local X,Y,Z = Camera:WorldToScreenPoint(Pos).X,Camera:WorldToScreenPoint(Pos).Y,Camera:WorldToScreenPoint(Pos).Z
1838 RightFoot.Position = UDim2.new(0,X,0,Y)
1839 if Z<=0 then RightFoot.Visible = false else RightFoot.Visible = true end
1840 else
1841 RightFoot.Visible = false
1842 end
1843 --
1844 local LeftFoot = Folder:FindFirstChild('Left Foot') or Instance.new('Frame',Folder)
1845 LeftFoot.Name = 'Left Foot'
1846 if Char['Left Leg']~=nil then
1847 local Pos = (Char['Left Leg'].CFrame*CFrame.new(0,-1,0)).p
1848 local X,Y,Z = Camera:WorldToScreenPoint(Pos).X,Camera:WorldToScreenPoint(Pos).Y,Camera:WorldToScreenPoint(Pos).Z
1849 LeftFoot.Position = UDim2.new(0,X,0,Y)
1850 LeftFoot.BorderSizePixel = 0
1851 if Z<=0 then LeftFoot.Visible = false else LeftFoot.Visible = true end
1852 else
1853 LeftFoot.Visible = false
1854 end
1855 --
1856 local RightHand = Folder:FindFirstChild('Right Hand') or Instance.new('Frame',Folder)
1857 RightHand.Name = 'Right Hand'
1858 RightHand.ZIndex = 2
1859 RightHand.BorderSizePixel = 0
1860 if Char['Right Arm']~=nil then
1861 local Pos = (Char['Right Arm'].CFrame*CFrame.new(0,-1,0)).p
1862 local X,Y,Z = Camera:WorldToScreenPoint(Pos).X,Camera:WorldToScreenPoint(Pos).Y,Camera:WorldToScreenPoint(Pos).Z
1863 RightHand.Position = UDim2.new(0,X,0,Y)
1864 if Z<=0 then RightHand.Visible = false else RightHand.Visible = true end
1865 else
1866 RightHand.Visible = false
1867 end
1868 --
1869 local LeftHand = Folder:FindFirstChild('Left Hand') or Instance.new('Frame',Folder)
1870 LeftHand.Name = 'Left Hand'
1871 LeftHand.ZIndex = 2
1872 LeftHand.BorderSizePixel = 0
1873 if Char['Left Arm']~=nil then
1874 local Pos = (Char['Left Arm'].CFrame*CFrame.new(0,-1,0)).p
1875 local X,Y,Z = Camera:WorldToScreenPoint(Pos).X,Camera:WorldToScreenPoint(Pos).Y,Camera:WorldToScreenPoint(Pos).Z
1876 LeftHand.Position = UDim2.new(0,X,0,Y)
1877 if Z<=0 then LeftHand.Visible = false else LeftHand.Visible = true end
1878 else
1879 LeftHand.Visible = false
1880 end
1881 -- draw joints
1882 if esp_bones then
1883 if Head.Visible then DrawLine(Folder,Head,Neck,1,Color3.new(1,1,1),Head.BackgroundTransparency) end
1884 if Neck.Visible then DrawLine(Folder,Neck,Pelvis,1,Color3.new(1,1,1),Head.BackgroundTransparency) end
1885 if Neck.Visible then DrawLine(Folder,Neck,RightHand,1,Color3.new(1,1,1),Head.BackgroundTransparency) end
1886 if Neck.Visible then DrawLine(Folder,Neck,LeftHand,1,Color3.new(1,1,1),Head.BackgroundTransparency) end
1887 if Pelvis.Visible then DrawLine(Folder,Pelvis,RightFoot,1,Color3.new(1,1,1),Head.BackgroundTransparency) end
1888 if Pelvis.Visible then DrawLine(Folder,Pelvis,LeftFoot,1,Color3.new(1,1,1),Head.BackgroundTransparency) end
1889 end
1890 end
1891
1892 if esp_chams then
1893 for _,Part in next,Char:children() do
1894 if Part:IsA('BasePart') and Part.Name~='HumanoidRootPart' then
1895 local Adornment = Folder:FindFirstChild(Part.Name..'_Cham') or Instance.new('BoxHandleAdornment',Folder)
1896 if not Folder:FindFirstChild(Part.Name..'_Cham') then
1897 Adornment.Name = Part.Name..'_Cham'
1898 Adornment.Adornee = Part
1899 Adornment.AlwaysOnTop = true
1900 Adornment.Size = Part.Name=='Head' and Vector3.new(1,1,1) or Part.Size
1901 Adornment.ZIndex = 1
1902 end
1903 Adornment.Color3 = Head.BackgroundColor3
1904 end
1905 end
1906 else
1907 for _,v in next,Folder:GetDescendants() do
1908 if v.Name:match('Cham') then
1909 v:Destroy()
1910 end
1911 end
1912 end
1913
1914 if bounding_box and Char:FindFirstChild('HumanoidRootPart') then
1915 local Box = Char:FindFirstChild('Box') or Instance.new('BillboardGui',Char)
1916 if not Char:FindFirstChild('Box') then
1917 Box.Name = 'Box'
1918 Box.Adornee = Char:FindFirstChild('HumanoidRootPart')
1919 Box.AlwaysOnTop = true
1920 Box.LightInfluence = 0
1921 Box.StudsOffset = Vector3.new(0,-Box.Adornee.Size.Y/4,0)
1922 Box.Size = UDim2.new(4,1,5,1)
1923 local Top = Instance.new('Frame',Box)
1924 Top.Size = UDim2.new(1,0,0,box_line_size)
1925 Top.BorderSizePixel = 0
1926 local Bot = Top:Clone()
1927 Bot.Position = UDim2.new(0,0,1,-box_line_size)
1928 Bot.Parent = Box
1929 local Left = Top:Clone()
1930 Left.Size = UDim2.new(0,1,1,0)
1931 Left.Parent = Box
1932 local Right = Left:Clone()
1933 Right.Position = UDim2.new(1,-box_line_size,0,0)
1934 Right.Parent = Box
1935 end
1936 for _,v in next,Box:children() do
1937 if v:IsA('Frame') then
1938 v.BackgroundColor3 = Head.BackgroundColor3
1939 end
1940 end
1941 else
1942 local Box = Char:FindFirstChild('Box')
1943 if Box then
1944 Box:Destroy()
1945 end
1946 end
1947
1948 if lockedon and target and aim_line and ESP:FindFirstChild(target.Name) then
1949 DrawLine(ESP,cursor,ESP:FindFirstChild(target.Name).Head,1,Head.BackgroundColor3,.5)
1950 end
1951
1952 else
1953 if ESP:FindFirstChild(v.Name) then
1954 ESP:FindFirstChild(v.Name):Destroy()
1955 end
1956 end
1957 else
1958 if ESP:FindFirstChild(v.Name) then
1959 ESP:FindFirstChild(v.Name):Destroy()
1960 end
1961 end
1962 end
1963 else
1964 for _,v in next,ESP:children() do
1965 if v:IsA('Folder') then
1966 v:Destroy()
1967 end
1968 end
1969 end
1970 if performancemode then
1971 wait(1/(workspace:GetRealPhysicsFPS()*.75))
1972 else
1973 RS.Stepped:wait()
1974 end
1975end
1976
1977--[[ broken
1978spawn(function()
1979while script and game.PlaceId == 292439477 and workspace:FindFirstChild('Map') do
1980 windows = {}
1981 for _,v in next,workspace.Map:GetChildren() do
1982 if v.Name=='Window' then
1983 table.insert(windows,v)
1984 end
1985 end
1986 wait(2)
1987end
1988end)
1989--]]
1990end)
1991removemap.MouseButton1Down:connect(function()
1992while wait() do
1993for a,z in pairs(game:GetService("Workspace")["BuildStuff"]:GetDescendants()) do
1994z:Destroy()
1995end
1996end
1997end)
1998local Players = game:GetService'Players';
1999local LocalPlayer = Players.LocalPlayer;
2000local Camera = workspace.CurrentCamera;
2001local Dot = Vector3.new().Dot;
2002local Networks = {};
2003
2004for i, v in pairs(debug.getregistry()) do
2005if typeof(v) == 'function' and islclosure(v) then
2006local ups = debug.getupvalues(v);
2007if ups.NWModule and ups.NWModule.FireServer then
2008Networks[#Networks + 1] = ups.NWModule;
2009end
2010end
2011end
2012
2013local Net = Networks[1];
2014
2015assert(#Networks ~= 0, 'No Network');
2016
2017function SameTeam(P1, P2)
2018if P1 == P2 then
2019return false
2020end
2021if P1.Neutral or P2.Neutral then
2022return false
2023elseif P1.TeamColor == P2.TeamColor then
2024return true
2025end
2026return false
2027end
2028
2029function GetPlayerClosestToMouse()
2030local Highest = {0, nil};
2031
2032for i, v in pairs(Players:GetPlayers()) do
2033local Player = v;
2034local Character = Player.Character;
2035if Player ~= LocalPlayer and not SameTeam(Player, LocalPlayer) and Character then
2036local Head = Character:FindFirstChild'Head';
2037if Head then
2038local Direction = Camera.CFrame.lookVector.unit;
2039local Relative = Player.Character.Head.Position - Camera.CFrame.p;
2040local Unit = Relative.unit;
2041
2042local DP = Dot(Direction, Unit);
2043if DP > Highest[1] then
2044Highest = {DP, Player};
2045end
2046end
2047end
2048end
2049
2050return Highest[2];
2051end
2052
2053local Active = true;
2054local Rand = Random.new();
2055
2056for i, v in pairs(Networks) do
2057shared['oFireServer' .. tostring(v)] = shared['oFireServer' .. tostring(v)] or v.FireServer;
2058v.FireServer = function(...)
2059local Arguments = {...};
2060
2061if Active and Arguments[2] == 'Damage' and typeof(Arguments[3]) == 'Instance' and Arguments[3]:IsA'ValueBase' then
2062return true;
2063end
2064
2065return shared['oFireServer' .. tostring(v)](...);
2066end
2067end
2068
2069game:GetService'UserInputService'.InputEnded:connect(function(Input)
2070if Input.UserInputType == Enum.UserInputType.Keyboard and Input.KeyCode == Enum.KeyCode.F3 then
2071Active = not Active;
2072elseif Active and Input.UserInputType == Enum.UserInputType.MouseButton1 then
2073spawn(function()
2074wait(.05);
2075local Player = GetPlayerClosestToMouse();
2076if Player then
2077local Character = Player.Character;
2078if Character then
2079local Humanoid = Character:FindFirstChildOfClass'Humanoid';
2080local Head = Character:FindFirstChild'Head';
2081if Humanoid and Humanoid.Health > 0 and Head then
2082Net:FireServer('Damage', Humanoid, Head, Head.Position, Head.Position + Vector3.new(Rand:NextNumber() / 10, .25 + (Rand:NextNumber() / 10), Rand:NextNumber() / 10))
2083end
2084end
2085end
2086end);
2087end
2088end)
2089for i,v in pairs(workspace:GetDescendants()) do
2090 if v.ClassName == "Part" or v.ClassName == "WedgePart" then
2091 v.Material = "SmoothPlastic"
2092 end
2093end
2094local pi = math.pi
2095local abs = math.abs
2096local clamp = math.clamp
2097local exp = math.exp
2098local rad = math.rad
2099local sign = math.sign
2100local sqrt = math.sqrt
2101local tan = math.tan
2102
2103local ContextActionService = game:GetService("ContextActionService")
2104local Players = game:GetService("Players")
2105local RunService = game:GetService("RunService")
2106local StarterGui = game:GetService("StarterGui")
2107local UserInputService = game:GetService("UserInputService")
2108local Workspace = game:GetService("Workspace")
2109
2110local LocalPlayer = Players.LocalPlayer
2111if not LocalPlayer then
2112 Players:GetPropertyChangedSignal("LocalPlayer"):Wait()
2113 LocalPlayer = Players.LocalPlayer
2114end
2115
2116local Camera = Workspace.CurrentCamera
2117Workspace:GetPropertyChangedSignal("CurrentCamera"):Connect(function()
2118 local newCamera = Workspace.CurrentCamera
2119 if newCamera then
2120 Camera = newCamera
2121 end
2122end)
2123
2124------------------------------------------------------------------------
2125
2126local TOGGLE_INPUT_PRIORITY = Enum.ContextActionPriority.Low.Value
2127local INPUT_PRIORITY = Enum.ContextActionPriority.High.Value
2128local FREECAM_MACRO_KB = {Enum.KeyCode.LeftShift, Enum.KeyCode.P}
2129
2130local NAV_GAIN = Vector3.new(1, 1, 1)*64
2131local PAN_GAIN = Vector2.new(0.75, 1)*8
2132local FOV_GAIN = 300
2133
2134local PITCH_LIMIT = rad(90)
2135
2136local VEL_STIFFNESS = 1.5
2137local PAN_STIFFNESS = 1.0
2138local FOV_STIFFNESS = 4.0
2139
2140------------------------------------------------------------------------
2141
2142local Spring = {} do
2143 Spring.__index = Spring
2144
2145 function Spring.new(freq, pos)
2146 local self = setmetatable({}, Spring)
2147 self.f = freq
2148 self.p = pos
2149 self.v = pos*0
2150 return self
2151 end
2152
2153 function Spring:Update(dt, goal)
2154 local f = self.f*2*pi
2155 local p0 = self.p
2156 local v0 = self.v
2157
2158 local offset = goal - p0
2159 local decay = exp(-f*dt)
2160
2161 local p1 = goal + (v0*dt - offset*(f*dt + 1))*decay
2162 local v1 = (f*dt*(offset*f - v0) + v0)*decay
2163
2164 self.p = p1
2165 self.v = v1
2166
2167 return p1
2168 end
2169
2170 function Spring:Reset(pos)
2171 self.p = pos
2172 self.v = pos*0
2173 end
2174end
2175
2176------------------------------------------------------------------------
2177
2178local cameraPos = Vector3.new()
2179local cameraRot = Vector2.new()
2180local cameraFov = 0
2181
2182local velSpring = Spring.new(VEL_STIFFNESS, Vector3.new())
2183local panSpring = Spring.new(PAN_STIFFNESS, Vector2.new())
2184local fovSpring = Spring.new(FOV_STIFFNESS, 0)
2185
2186------------------------------------------------------------------------
2187
2188local Input = {} do
2189 local thumbstickCurve do
2190 local K_CURVATURE = 2.0
2191 local K_DEADZONE = 0.15
2192
2193 local function fCurve(x)
2194 return (exp(K_CURVATURE*x) - 1)/(exp(K_CURVATURE) - 1)
2195 end
2196
2197 local function fDeadzone(x)
2198 return fCurve((x - K_DEADZONE)/(1 - K_DEADZONE))
2199 end
2200
2201 function thumbstickCurve(x)
2202 return sign(x)*clamp(fDeadzone(abs(x)), 0, 1)
2203 end
2204 end
2205
2206 local gamepad = {
2207 ButtonX = 0,
2208 ButtonY = 0,
2209 DPadDown = 0,
2210 DPadUp = 0,
2211 ButtonL2 = 0,
2212 ButtonR2 = 0,
2213 Thumbstick1 = Vector2.new(),
2214 Thumbstick2 = Vector2.new(),
2215 }
2216
2217 local keyboard = {
2218 W = 0,
2219 A = 0,
2220 S = 0,
2221 D = 0,
2222 E = 0,
2223 Q = 0,
2224 U = 0,
2225 H = 0,
2226 J = 0,
2227 K = 0,
2228 I = 0,
2229 Y = 0,
2230 Up = 0,
2231 Down = 0,
2232 LeftShift = 0,
2233 RightShift = 0,
2234 }
2235
2236 local mouse = {
2237 Delta = Vector2.new(),
2238 MouseWheel = 0,
2239 }
2240
2241 local NAV_GAMEPAD_SPEED = Vector3.new(1, 1, 1)
2242 local NAV_KEYBOARD_SPEED = Vector3.new(1, 1, 1)
2243 local PAN_MOUSE_SPEED = Vector2.new(1, 1)*(pi/64)
2244 local PAN_GAMEPAD_SPEED = Vector2.new(1, 1)*(pi/8)
2245 local FOV_WHEEL_SPEED = 1.0
2246 local FOV_GAMEPAD_SPEED = 0.25
2247 local NAV_ADJ_SPEED = 0.75
2248 local NAV_SHIFT_MUL = 0.25
2249
2250 local navSpeed = 1
2251
2252 function Input.Vel(dt)
2253 navSpeed = clamp(navSpeed + dt*(keyboard.Up - keyboard.Down)*NAV_ADJ_SPEED, 0.01, 4)
2254
2255 local kGamepad = Vector3.new(
2256 thumbstickCurve(gamepad.Thumbstick1.x),
2257 thumbstickCurve(gamepad.ButtonR2) - thumbstickCurve(gamepad.ButtonL2),
2258 thumbstickCurve(-gamepad.Thumbstick1.y)
2259 )*NAV_GAMEPAD_SPEED
2260
2261 local kKeyboard = Vector3.new(
2262 keyboard.D - keyboard.A + keyboard.K - keyboard.H,
2263 keyboard.E - keyboard.Q + keyboard.I - keyboard.Y,
2264 keyboard.S - keyboard.W + keyboard.J - keyboard.U
2265 )*NAV_KEYBOARD_SPEED
2266
2267 local shift = UserInputService:IsKeyDown(Enum.KeyCode.LeftShift) or UserInputService:IsKeyDown(Enum.KeyCode.RightShift)
2268
2269 return (kGamepad + kKeyboard)*(navSpeed*(shift and NAV_SHIFT_MUL or 1))
2270 end
2271
2272 function Input.Pan(dt)
2273 local kGamepad = Vector2.new(
2274 thumbstickCurve(gamepad.Thumbstick2.y),
2275 thumbstickCurve(-gamepad.Thumbstick2.x)
2276 )*PAN_GAMEPAD_SPEED
2277 local kMouse = mouse.Delta*PAN_MOUSE_SPEED
2278 mouse.Delta = Vector2.new()
2279 return kGamepad + kMouse
2280 end
2281
2282 function Input.Fov(dt)
2283 local kGamepad = (gamepad.ButtonX - gamepad.ButtonY)*FOV_GAMEPAD_SPEED
2284 local kMouse = mouse.MouseWheel*FOV_WHEEL_SPEED
2285 mouse.MouseWheel = 0
2286 return kGamepad + kMouse
2287 end
2288
2289 do
2290 local function Keypress(action, state, input)
2291 keyboard[input.KeyCode.Name] = state == Enum.UserInputState.Begin and 1 or 0
2292 return Enum.ContextActionResult.Sink
2293 end
2294
2295 local function GpButton(action, state, input)
2296 gamepad[input.KeyCode.Name] = state == Enum.UserInputState.Begin and 1 or 0
2297 return Enum.ContextActionResult.Sink
2298 end
2299
2300 local function MousePan(action, state, input)
2301 local delta = input.Delta
2302 mouse.Delta = Vector2.new(-delta.y, -delta.x)
2303 return Enum.ContextActionResult.Sink
2304 end
2305
2306 local function Thumb(action, state, input)
2307 gamepad[input.KeyCode.Name] = input.Position
2308 return Enum.ContextActionResult.Sink
2309 end
2310
2311 local function Trigger(action, state, input)
2312 gamepad[input.KeyCode.Name] = input.Position.z
2313 return Enum.ContextActionResult.Sink
2314 end
2315
2316 local function MouseWheel(action, state, input)
2317 mouse[input.UserInputType.Name] = -input.Position.z
2318 return Enum.ContextActionResult.Sink
2319 end
2320
2321 local function Zero(t)
2322 for k, v in pairs(t) do
2323 t[k] = v*0
2324 end
2325 end
2326
2327 function Input.StartCapture()
2328 ContextActionService:BindActionAtPriority("FreecamKeyboard", Keypress, false, INPUT_PRIORITY,
2329 Enum.KeyCode.W, Enum.KeyCode.U,
2330 Enum.KeyCode.A, Enum.KeyCode.H,
2331 Enum.KeyCode.S, Enum.KeyCode.J,
2332 Enum.KeyCode.D, Enum.KeyCode.K,
2333 Enum.KeyCode.E, Enum.KeyCode.I,
2334 Enum.KeyCode.Q, Enum.KeyCode.Y,
2335 Enum.KeyCode.Up, Enum.KeyCode.Down
2336 )
2337 ContextActionService:BindActionAtPriority("FreecamMousePan", MousePan, false, INPUT_PRIORITY, Enum.UserInputType.MouseMovement)
2338 ContextActionService:BindActionAtPriority("FreecamMouseWheel", MouseWheel, false, INPUT_PRIORITY, Enum.UserInputType.MouseWheel)
2339 ContextActionService:BindActionAtPriority("FreecamGamepadButton", GpButton, false, INPUT_PRIORITY, Enum.KeyCode.ButtonX, Enum.KeyCode.ButtonY)
2340 ContextActionService:BindActionAtPriority("FreecamGamepadTrigger", Trigger, false, INPUT_PRIORITY, Enum.KeyCode.ButtonR2, Enum.KeyCode.ButtonL2)
2341 ContextActionService:BindActionAtPriority("FreecamGamepadThumbstick", Thumb, false, INPUT_PRIORITY, Enum.KeyCode.Thumbstick1, Enum.KeyCode.Thumbstick2)
2342 end
2343
2344 function Input.StopCapture()
2345 navSpeed = 1
2346 Zero(gamepad)
2347 Zero(keyboard)
2348 Zero(mouse)
2349 ContextActionService:UnbindAction("FreecamKeyboard")
2350 ContextActionService:UnbindAction("FreecamMousePan")
2351 ContextActionService:UnbindAction("FreecamMouseWheel")
2352 ContextActionService:UnbindAction("FreecamGamepadButton")
2353 ContextActionService:UnbindAction("FreecamGamepadTrigger")
2354 ContextActionService:UnbindAction("FreecamGamepadThumbstick")
2355 end
2356 end
2357end
2358
2359local function GetFocusDistance(cameraFrame)
2360 local znear = 0.1
2361 local viewport = Camera.ViewportSize
2362 local projy = 2*tan(cameraFov/2)
2363 local projx = viewport.x/viewport.y*projy
2364 local fx = cameraFrame.rightVector
2365 local fy = cameraFrame.upVector
2366 local fz = cameraFrame.lookVector
2367
2368 local minVect = Vector3.new()
2369 local minDist = 512
2370
2371 for x = 0, 1, 0.5 do
2372 for y = 0, 1, 0.5 do
2373 local cx = (x - 0.5)*projx
2374 local cy = (y - 0.5)*projy
2375 local offset = fx*cx - fy*cy + fz
2376 local origin = cameraFrame.p + offset*znear
2377 local _, hit = Workspace:FindPartOnRay(Ray.new(origin, offset.unit*minDist))
2378 local dist = (hit - origin).magnitude
2379 if minDist > dist then
2380 minDist = dist
2381 minVect = offset.unit
2382 end
2383 end
2384 end
2385
2386 return fz:Dot(minVect)*minDist
2387end
2388
2389------------------------------------------------------------------------
2390
2391local function StepFreecam(dt)
2392 local vel = velSpring:Update(dt, Input.Vel(dt))
2393 local pan = panSpring:Update(dt, Input.Pan(dt))
2394 local fov = fovSpring:Update(dt, Input.Fov(dt))
2395
2396 local zoomFactor = sqrt(tan(rad(70/2))/tan(rad(cameraFov/2)))
2397
2398 cameraFov = clamp(cameraFov + fov*FOV_GAIN*(dt/zoomFactor), 1, 120)
2399 cameraRot = cameraRot + pan*PAN_GAIN*(dt/zoomFactor)
2400 cameraRot = Vector2.new(clamp(cameraRot.x, -PITCH_LIMIT, PITCH_LIMIT), cameraRot.y%(2*pi))
2401
2402 local cameraCFrame = CFrame.new(cameraPos)*CFrame.fromOrientation(cameraRot.x, cameraRot.y, 0)*CFrame.new(vel*NAV_GAIN*dt)
2403 cameraPos = cameraCFrame.p
2404
2405 Camera.CFrame = cameraCFrame
2406 Camera.Focus = cameraCFrame*CFrame.new(0, 0, -GetFocusDistance(cameraCFrame))
2407 Camera.FieldOfView = cameraFov
2408end
2409
2410------------------------------------------------------------------------
2411
2412local PlayerState = {} do
2413 local mouseBehavior
2414 local mouseIconEnabled
2415 local cameraType
2416 local cameraFocus
2417 local cameraCFrame
2418 local cameraFieldOfView
2419 local screenGuis = {}
2420 local coreGuis = {
2421 Backpack = true,
2422 Chat = true,
2423 Health = true,
2424 PlayerList = true,
2425 }
2426 local setCores = {
2427 BadgesNotificationsActive = true,
2428 PointsNotificationsActive = true,
2429 }
2430
2431 -- Save state and set up for freecam
2432 function PlayerState.Push()
2433 for name in pairs(coreGuis) do
2434 coreGuis[name] = StarterGui:GetCoreGuiEnabled(Enum.CoreGuiType[name])
2435 StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType[name], false)
2436 end
2437 for name in pairs(setCores) do
2438 setCores[name] = StarterGui:GetCore(name)
2439 StarterGui:SetCore(name, false)
2440 end
2441 local playergui = LocalPlayer:FindFirstChildOfClass("PlayerGui")
2442 if playergui then
2443 for _, gui in pairs(playergui:GetChildren()) do
2444 if gui:IsA("ScreenGui") and gui.Enabled then
2445 screenGuis[#screenGuis + 1] = gui
2446 gui.Enabled = false
2447 end
2448 end
2449 end
2450
2451 cameraFieldOfView = Camera.FieldOfView
2452 Camera.FieldOfView = 70
2453
2454 cameraType = Camera.CameraType
2455 Camera.CameraType = Enum.CameraType.Custom
2456
2457 cameraCFrame = Camera.CFrame
2458 cameraFocus = Camera.Focus
2459
2460 mouseIconEnabled = UserInputService.MouseIconEnabled
2461 UserInputService.MouseIconEnabled = false
2462
2463 mouseBehavior = UserInputService.MouseBehavior
2464 UserInputService.MouseBehavior = Enum.MouseBehavior.Default
2465 end
2466
2467 -- Restore state
2468 function PlayerState.Pop()
2469 for name, isEnabled in pairs(coreGuis) do
2470 StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType[name], isEnabled)
2471 end
2472 for name, isEnabled in pairs(setCores) do
2473 StarterGui:SetCore(name, isEnabled)
2474 end
2475 for _, gui in pairs(screenGuis) do
2476 if gui.Parent then
2477 gui.Enabled = true
2478 end
2479 end
2480
2481 Camera.FieldOfView = cameraFieldOfView
2482 cameraFieldOfView = nil
2483
2484 Camera.CameraType = cameraType
2485 cameraType = nil
2486
2487 Camera.CFrame = cameraCFrame
2488 cameraCFrame = nil
2489
2490 Camera.Focus = cameraFocus
2491 cameraFocus = nil
2492
2493 UserInputService.MouseIconEnabled = mouseIconEnabled
2494 mouseIconEnabled = nil
2495
2496 UserInputService.MouseBehavior = mouseBehavior
2497 mouseBehavior = nil
2498 end
2499end
2500
2501local function StartFreecam()
2502 local cameraCFrame = Camera.CFrame
2503 cameraRot = Vector2.new(cameraCFrame:toEulerAnglesYXZ())
2504 cameraPos = cameraCFrame.p
2505 cameraFov = Camera.FieldOfView
2506
2507 velSpring:Reset(Vector3.new())
2508 panSpring:Reset(Vector2.new())
2509 fovSpring:Reset(0)
2510
2511 PlayerState.Push()
2512 RunService:BindToRenderStep("Freecam", Enum.RenderPriority.Camera.Value, StepFreecam)
2513 Input.StartCapture()
2514end
2515
2516local function StopFreecam()
2517 Input.StopCapture()
2518 RunService:UnbindFromRenderStep("Freecam")
2519 PlayerState.Pop()
2520end
2521
2522------------------------------------------------------------------------
2523
2524do
2525 local enabled = false
2526
2527 local function ToggleFreecam()
2528 if enabled then
2529 StopFreecam()
2530 else
2531 StartFreecam()
2532 end
2533 enabled = not enabled
2534 end
2535
2536 local function CheckMacro(macro)
2537 for i = 1, #macro - 1 do
2538 if not UserInputService:IsKeyDown(macro[i]) then
2539 return
2540 end
2541 end
2542 ToggleFreecam()
2543 end
2544
2545 local function HandleActivationInput(action, state, input)
2546 if state == Enum.UserInputState.Begin then
2547 if input.KeyCode == FREECAM_MACRO_KB[#FREECAM_MACRO_KB] then
2548 CheckMacro(FREECAM_MACRO_KB)
2549 end
2550 end
2551 return Enum.ContextActionResult.Pass
2552 end
2553
2554 ContextActionService:BindActionAtPriority("FreecamToggle", HandleActivationInput, false, TOGGLE_INPUT_PRIORITY, FREECAM_MACRO_KB[#FREECAM_MACRO_KB])
2555end
2556PLAYER = game.Players.LocalPlayer
2557MOUSE = PLAYER:GetMouse()
2558CC = game.Workspace.CurrentCamera
2559
2560ENABLED = false
2561ESP_ENABLED = false
2562
2563_G.FREE_FOR_ALL = true
2564
2565_G.BIND = 50
2566_G.ESP_BIND = 52
2567_G.CHANGE_AIM = 'q'
2568
2569_G.AIM_AT = 'Head'
2570
2571wait(1)
2572
2573function GetNearestPlayerToMouse()
2574 local PLAYERS = {}
2575 local PLAYER_HOLD = {}
2576 local DISTANCES = {}
2577 for i, v in pairs(game.Players:GetPlayers()) do
2578 if v ~= PLAYER then
2579 table.insert(PLAYERS, v)
2580 end
2581 end
2582 for i, v in pairs(PLAYERS) do
2583 if _G.FREE_FOR_ALL == false then
2584 if v and (v.Character) ~= nil and v.TeamColor ~= PLAYER.TeamColor then
2585 local AIM = v.Character:FindFirstChild(_G.AIM_AT)
2586 if AIM ~= nil then
2587 local DISTANCE = (AIM.Position - game.Workspace.CurrentCamera.CoordinateFrame.p).magnitude
2588 local RAY = Ray.new(game.Workspace.CurrentCamera.CoordinateFrame.p, (MOUSE.Hit.p - CC.CoordinateFrame.p).unit * DISTANCE)
2589 local HIT,POS = game.Workspace:FindPartOnRay(RAY, game.Workspace)
2590 local DIFF = math.floor((POS - AIM.Position).magnitude)
2591 PLAYER_HOLD[v.Name .. i] = {}
2592 PLAYER_HOLD[v.Name .. i].dist = DISTANCE
2593 PLAYER_HOLD[v.Name .. i].plr = v
2594 PLAYER_HOLD[v.Name .. i].diff = DIFF
2595 table.insert(DISTANCES, DIFF)
2596 end
2597 end
2598 elseif _G.FREE_FOR_ALL == true then
2599 local AIM = v.Character:FindFirstChild(_G.AIM_AT)
2600 if AIM ~= nil then
2601 local DISTANCE = (AIM.Position - game.Workspace.CurrentCamera.CoordinateFrame.p).magnitude
2602 local RAY = Ray.new(game.Workspace.CurrentCamera.CoordinateFrame.p, (MOUSE.Hit.p - CC.CoordinateFrame.p).unit * DISTANCE)
2603 local HIT,POS = game.Workspace:FindPartOnRay(RAY, game.Workspace)
2604 local DIFF = math.floor((POS - AIM.Position).magnitude)
2605 PLAYER_HOLD[v.Name .. i] = {}
2606 PLAYER_HOLD[v.Name .. i].dist = DISTANCE
2607 PLAYER_HOLD[v.Name .. i].plr = v
2608 PLAYER_HOLD[v.Name .. i].diff = DIFF
2609 table.insert(DISTANCES, DIFF)
2610 end
2611 end
2612 end
2613
2614 if unpack(DISTANCES) == nil then
2615 return false
2616 end
2617
2618 local L_DISTANCE = math.floor(math.min(unpack(DISTANCES)))
2619 if L_DISTANCE > 20 then
2620 return false
2621 end
2622
2623 for i, v in pairs(PLAYER_HOLD) do
2624 if v.diff == L_DISTANCE then
2625 return v.plr
2626 end
2627 end
2628 return false
2629end
2630
2631GUI_MAIN = Instance.new('ScreenGui', game.CoreGui)
2632GUI_TARGET = Instance.new('TextLabel', GUI_MAIN)
2633GUI_AIM_AT = Instance.new('TextLabel', GUI_MAIN)
2634
2635GUI_MAIN.Name = 'AIMBOT'
2636
2637GUI_TARGET.Size = UDim2.new(0,200,0,30)
2638GUI_TARGET.BackgroundTransparency = 0.5
2639GUI_TARGET.BackgroundColor = BrickColor.new('Fossil')
2640GUI_TARGET.BorderSizePixel = 0
2641GUI_TARGET.Position = UDim2.new(0.5,-100,0,0)
2642GUI_TARGET.Text = 'AIMBOT : OFF'
2643GUI_TARGET.TextColor3 = Color3.new(1,1,1)
2644GUI_TARGET.TextStrokeTransparency = 1
2645GUI_TARGET.TextWrapped = true
2646GUI_TARGET.FontSize = 'Size24'
2647GUI_TARGET.Font = 'SourceSansBold'
2648
2649GUI_AIM_AT.Size = UDim2.new(0,200,0,20)
2650GUI_AIM_AT.BackgroundTransparency = 0.5
2651GUI_AIM_AT.BackgroundColor = BrickColor.new('Fossil')
2652GUI_AIM_AT.BorderSizePixel = 0
2653GUI_AIM_AT.Position = UDim2.new(0.5,-100,0,30)
2654GUI_AIM_AT.Text = 'AIMING : HEAD'
2655GUI_AIM_AT.TextColor3 = Color3.new(1,1,1)
2656GUI_AIM_AT.TextStrokeTransparency = 1
2657GUI_AIM_AT.TextWrapped = true
2658GUI_AIM_AT.FontSize = 'Size18'
2659GUI_AIM_AT.Font = 'SourceSansBold'
2660
2661local TRACK = false
2662
2663function CREATE(BASE, TEAM)
2664 local ESP_MAIN = Instance.new('BillboardGui', PLAYER.PlayerGui)
2665 local ESP_DOT = Instance.new('Frame', ESP_MAIN)
2666 local ESP_NAME = Instance.new('TextLabel', ESP_MAIN)
2667
2668 ESP_MAIN.Name = 'ESP'
2669 ESP_MAIN.Adornee = BASE
2670 ESP_MAIN.AlwaysOnTop = true
2671 ESP_MAIN.ExtentsOffset = Vector3.new(0, 1, 0)
2672 ESP_MAIN.Size = UDim2.new(0, 5, 0, 5)
2673
2674 ESP_DOT.Name = 'DOT'
2675 ESP_DOT.BackgroundColor = BrickColor.new('Bright red')
2676 ESP_DOT.BackgroundTransparency = 0.3
2677 ESP_DOT.BorderSizePixel = 0
2678 ESP_DOT.Position = UDim2.new(-0.5, 0, -0.5, 0)
2679 ESP_DOT.Size = UDim2.new(2, 0, 2, 0)
2680 ESP_DOT.Visible = true
2681 ESP_DOT.ZIndex = 10
2682
2683 ESP_NAME.Name = 'NAME'
2684 ESP_NAME.BackgroundColor3 = Color3.new(255, 255, 255)
2685 ESP_NAME.BackgroundTransparency = 1
2686 ESP_NAME.BorderSizePixel = 0
2687 ESP_NAME.Position = UDim2.new(0, 0, 0, -40)
2688 ESP_NAME.Size = UDim2.new(1, 0, 10, 0)
2689 ESP_NAME.Visible = true
2690 ESP_NAME.ZIndex = 10
2691 ESP_NAME.Font = 'ArialBold'
2692 ESP_NAME.FontSize = 'Size14'
2693 ESP_NAME.Text = BASE.Parent.Name:upper()
2694 ESP_NAME.TextColor = BrickColor.new('Bright red')
2695end
2696
2697function CLEAR()
2698 for _,v in pairs(PLAYER.PlayerGui:children()) do
2699 if v.Name == 'ESP' and v:IsA('BillboardGui') then
2700 v:Destroy()
2701 end
2702 end
2703end
2704
2705function FIND()
2706 CLEAR()
2707 TRACK = true
2708 spawn(function()
2709 while wait() do
2710 if TRACK then
2711 CLEAR()
2712 for i,v in pairs(game.Players:GetChildren()) do
2713 if v.Character and v.Character:FindFirstChild('Head') then
2714 if _G.FREE_FOR_ALL == false then
2715 if v.TeamColor ~= PLAYER.TeamColor then
2716 if v.Character:FindFirstChild('Head') then
2717 CREATE(v.Character.Head, true)
2718 end
2719 end
2720 else
2721 if v.Character:FindFirstChild('Head') then
2722 CREATE(v.Character.Head, true)
2723 end
2724 end
2725 end
2726 end
2727 end
2728 end
2729 wait(1)
2730 end)
2731end
2732
2733MOUSE.KeyDown:connect(function(KEY)
2734 KEY = KEY:lower():byte()
2735 if KEY == _G.BIND then
2736 ENABLED = true
2737 end
2738end)
2739
2740MOUSE.KeyUp:connect(function(KEY)
2741 KEY = KEY:lower():byte()
2742 if KEY == _G.BIND then
2743 ENABLED = false
2744 end
2745end)
2746
2747MOUSE.KeyDown:connect(function(KEY)
2748 KEY = KEY:lower():byte()
2749 if KEY == _G.ESP_BIND then
2750 if ESP_ENABLED == false then
2751 FIND()
2752 ESP_ENABLED = true
2753 print('ESP : ON')
2754 elseif ESP_ENABLED == true then
2755 wait()
2756 CLEAR()
2757 TRACK = false
2758 ESP_ENABLED = true
2759 print('ESP : OFF')
2760 end
2761 end
2762end)
2763
2764MOUSE.KeyDown:connect(function(KEY)
2765 if KEY == _G.CHANGE_AIM then
2766 if _G.AIM_AT == 'Head' then
2767 _G.AIM_AT = 'Torso'
2768 GUI_AIM_AT.Text = 'AIMING : TORSO'
2769 elseif _G.AIM_AT == 'Torso' then
2770 _G.AIM_AT = 'Head'
2771 GUI_AIM_AT.Text = 'AIMING : HEAD'
2772 end
2773 end
2774end)
2775
2776game:GetService('RunService').RenderStepped:connect(function()
2777 if ENABLED then
2778 local TARGET = GetNearestPlayerToMouse()
2779 if (TARGET ~= false) then
2780 local AIM = TARGET.Character:FindFirstChild(_G.AIM_AT)
2781 if AIM then
2782 CC.CoordinateFrame = CFrame.new(CC.CoordinateFrame.p, AIM.CFrame.p)
2783 end
2784 GUI_TARGET.Text = 'AIMBOT : '.. TARGET.Name:sub(1, 5)
2785 else
2786 GUI_TARGET.Text = 'AIMBOT : OFF'
2787 end
2788 end
2789end)
2790
2791repeat
2792 wait()
2793 if ESP_ENABLED == true then
2794 FIND()
2795 end
2796until ESP_ENABLED == false
2797wait()
2798_G.FREE_FOR_ALL = true
2799_G.BIND = 50 -- LEFT CTRL
2800_G.ESP_BIND = 52 -- LEFT ALT