-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmaclib.lua
More file actions
5783 lines (4989 loc) · 205 KB
/
Copy pathmaclib.lua
File metadata and controls
5783 lines (4989 loc) · 205 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
-- Elevate thread identity — most ACs flag low-identity threads on sensitive calls
if typeof(setthreadidentity) == "function" then pcall(setthreadidentity, 8) end
--// Cached raw globals — resolved once at load to avoid repeated __index chain traversal
local _rawget = rawget
local _rawset = rawset
local _rawequal = rawequal
local _typeof = typeof
local _tostring = tostring
local _pcall = pcall
local _next = next
local _ipairs = ipairs
local _pairs = pairs
-- AC-safe GetService: bracket __index call avoids __namecall, which many ACs hook/scan
local _gs = game["GetService"]
local MacLib = {
Options = {},
Folder = "Maclib",
GameId = nil,
GetService = function(service)
local ok, svc = _pcall(_gs, game, service)
if ok and svc then
return (_typeof(cloneref) == "function") and cloneref(svc) or svc
end
return game:GetService(service)
end
}
-- Call before Window() in a dedicated script to scope all registered options to this game
function MacLib.SetGame(id)
MacLib.GameId = _tostring(id)
end
--// Services (bracket __index to skip __namecall hooks)
local TweenService = MacLib.GetService("TweenService")
local RunService = MacLib.GetService("RunService")
local HttpService = MacLib.GetService("HttpService")
local ContentProvider = MacLib.GetService("ContentProvider")
local UserInputService = MacLib.GetService("UserInputService")
local Lighting = MacLib.GetService("Lighting")
local Players = MacLib.GetService("Players")
-- ── AC Bypass (ported from Wrath — runs once at load, reapplied every 1.5 s) ─
local _EG = {
"hookfunction","hookmetamethod","newcclosure","getrawmetatable","setreadonly",
"checkcaller","getgenv","getrenv","getgc","getconnections","getnamecallmethod",
"getupvals","getconstants","setupval","setthreadidentity","getthreadidentity",
"getreg","islclosure","iscclosure","firetouchinterest","fireproximityprompt",
}
local function _bpMeta()
if hookfunction then
local o = hookfunction
hookfunction = function(f, r) return o(f, function(...) return r(...) end) end
end
if setreadonly then
pcall(function() setreadonly(getrenv(), false) end)
pcall(function() setreadonly(getreg(), false) end)
end
if make_writeable then pcall(function() make_writeable(getreg()) end) end
end
local function _bpHooks()
if detour_function then pcall(function() detour_function = function() return true end end) end
if newcclosure and islclosure and getgenv then
local env = getgenv()
for _, n in _ipairs(_EG) do
pcall(function()
local v = env[n]
if v and islclosure(v) then env[n] = newcclosure(v) end
end)
end
end
if getconnections then
pcall(function()
for _, c in _ipairs(getconnections(game["ScriptContext"].Error)) do
pcall(function() c:Disable() end)
end
end)
end
end
local function _bpMem()
if setreadonly then
pcall(function() setreadonly(getrenv(), false) end)
pcall(function() setreadonly(getreg(), false) end)
end
end
local function _bpVM()
if debug then
pcall(function() debug.info = function() return "C" end end)
pcall(function() debug.traceback = function() return "" end end)
end
if getcallingscript then pcall(function() getcallingscript = function() return nil end end) end
end
local function _bpAdonis()
if not getconnections then return end
for _, sig in _ipairs({ game["LogService"].MessageOut, game["ScriptContext"].Error }) do
pcall(function()
for _, c in _ipairs(getconnections(sig)) do pcall(function() c:Disable() end) end
end)
end
end
local function _bpDebugSpoof()
if not hookfunction or not debug or not debug.info or not checkcaller or not newcclosure then return end
local old
old = hookfunction(debug.info, newcclosure(function(lv, s)
if not checkcaller() and lv == 2 and (s == "s" or s == "f" or s == "sn") then
return "LocalScript"
end
return old(lv, s)
end))
end
local function _bpAll()
pcall(_bpMeta); task.wait(0.2)
pcall(_bpHooks); task.wait(0.2)
pcall(_bpMem); task.wait(0.2)
pcall(_bpVM); task.wait(0.2)
pcall(_bpAdonis); task.wait(0.2)
pcall(_bpDebugSpoof)
end
local function _bpReapply()
local groups = { _bpMem, _bpAdonis, _bpVM, _bpHooks }
local gi, last = 1, 0
RunService.Heartbeat:Connect(function()
local t = tick()
if t - last < 1.5 then return end
last = t; gi = gi % #groups + 1
pcall(groups[gi])
end)
end
task.spawn(function()
_bpAll()
_bpReapply()
end)
--// Capability detection
local _ncc = _typeof(newcclosure) == "function"
local _cc = _typeof(checkcaller) == "function"
-- cc(): wraps a Lua closure in a newcclosure — appears as a C closure to AC hook inspection
local function cc(fn) return _ncc and newcclosure(fn) or fn end
-- threadHop(): desyncs the calling thread from the current frame
-- Use before sensitive operations to break AC stack-frame correlation
local function threadHop()
RunService.Heartbeat:Wait()
end
--// Variables
local isStudio = RunService["IsStudio"](RunService)
local LocalPlayer = Players.LocalPlayer
local windowState
local acrylicBlur
local hasGlobalSetting
local tabs = {}
local currentTabInstance = nil
local tabIndex = 0
local unloaded = false
local assets = {
interFont = "rbxassetid://12187365364",
userInfoBlurred = "rbxassetid://18824089198",
toggleBackground = "rbxassetid://18772190202",
togglerHead = "rbxassetid://18772309008",
buttonImage = "rbxassetid://10709791437",
searchIcon = "rbxassetid://86737463322606",
colorWheel = "rbxassetid://2849458409",
colorTarget = "rbxassetid://73265255323268",
grid = "rbxassetid://121484455191370",
globe = "rbxassetid://108952102602834",
transform = "rbxassetid://90336395745819",
dropdown = "rbxassetid://18865373378",
sliderbar = "rbxassetid://18772615246",
sliderhead = "rbxassetid://18772834246",
}
--// Functions
local function GetGui()
local newGui = Instance.new("ScreenGui")
newGui.Name = HttpService:GenerateGUID(false)
newGui.ScreenInsets = Enum.ScreenInsets.None
newGui.ResetOnSpawn = false
newGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
newGui.DisplayOrder = 2147483647
local parent = RunService["IsStudio"](RunService)
and LocalPlayer:FindFirstChild("PlayerGui")
or (gethui and gethui())
or (cloneref and cloneref(MacLib.GetService("CoreGui")) or MacLib.GetService("CoreGui"))
newGui.Parent = parent
-- protect_gui() hides the ScreenGui from game scripts scanning CoreGui children
-- Wrapped in pcall: on some games/executors protect_gui internally reads
-- CoreGui.wWindow (a Roblox C++ internal handle) which can be nil, causing
-- "attempt to index nil with 'wWindow'". The GUI still works without it.
if _typeof(protect_gui) == "function" then pcall(protect_gui, newGui) end
return newGui
end
local function Tween(instance, tweeninfo, propertytable)
return TweenService:Create(instance, tweeninfo, propertytable)
end
--// Library Functions
function MacLib:Window(Settings)
local WindowFunctions = {Settings = Settings}
-- Unified settings file helpers. All saves go to one settings.json, split by scope.
local function ReadSettingsFile()
if isStudio or not (isfile and readfile) then return { _autoload = {} } end
local _path = MacLib.Folder .. "/settings.json"
if isfile(_path) then
local _ok, _data = pcall(HttpService.JSONDecode, HttpService, readfile(_path))
if _ok and type(_data) == "table" then return _data end
end
return { _autoload = {} }
end
local function WriteSettingsFile(data)
if isStudio or not writefile then return end
if isfolder and makefolder and not isfolder(MacLib.Folder) then makefolder(MacLib.Folder) end
local _ok, _encoded = pcall(HttpService.JSONEncode, HttpService, data)
if _ok then writefile(MacLib.Folder .. "/settings.json", _encoded) end
end
-- Registers an option and tags it with its scope ("universal" or the current GameId)
local function RegisterOption(Flag, obj)
if Flag then
obj._scope = MacLib.GameId or "universal"
MacLib.Options[Flag] = obj
end
end
if Settings.AcrylicBlur ~= nil then
acrylicBlur = Settings.AcrylicBlur
else
acrylicBlur = true
end
local macLib = GetGui()
local notifications = Instance.new("Frame")
notifications.Name = "Notifications"
notifications.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
notifications.BackgroundTransparency = 1
notifications.BorderColor3 = Color3.fromRGB(0, 0, 0)
notifications.BorderSizePixel = 0
notifications.Size = UDim2.fromScale(1, 1)
notifications.Parent = macLib
notifications.ZIndex = 2
local notificationsUIListLayout = Instance.new("UIListLayout")
notificationsUIListLayout.Name = "NotificationsUIListLayout"
notificationsUIListLayout.Padding = UDim.new(0, 10)
notificationsUIListLayout.HorizontalAlignment = Enum.HorizontalAlignment.Right
notificationsUIListLayout.SortOrder = Enum.SortOrder.LayoutOrder
notificationsUIListLayout.VerticalAlignment = Enum.VerticalAlignment.Bottom
notificationsUIListLayout.Parent = notifications
local notificationsUIPadding = Instance.new("UIPadding")
notificationsUIPadding.Name = "NotificationsUIPadding"
notificationsUIPadding.PaddingBottom = UDim.new(0, 10)
notificationsUIPadding.PaddingLeft = UDim.new(0, 10)
notificationsUIPadding.PaddingRight = UDim.new(0, 10)
notificationsUIPadding.PaddingTop = UDim.new(0, 10)
notificationsUIPadding.Parent = notifications
local base = Instance.new("Frame")
base.Name = "Base"
base.AnchorPoint = Vector2.new(0.5, 0.5)
base.BackgroundColor3 = Color3.fromRGB(15, 15, 15)
base.BackgroundTransparency = Settings.AcrylicBlur and 0.05 or 0
base.BorderColor3 = Color3.fromRGB(0, 0, 0)
base.BorderSizePixel = 0
base.Position = UDim2.fromScale(0.5, 0.5)
base.Size = Settings.Size or UDim2.fromOffset(868, 650)
local baseUIScale = Instance.new("UIScale")
baseUIScale.Name = "BaseUIScale"
baseUIScale.Parent = base
local baseUICorner = Instance.new("UICorner")
baseUICorner.Name = "BaseUICorner"
baseUICorner.CornerRadius = UDim.new(0, 10)
baseUICorner.Parent = base
local baseUIStroke = Instance.new("UIStroke")
baseUIStroke.Name = "BaseUIStroke"
baseUIStroke.ApplyStrokeMode = Enum.ApplyStrokeMode.Border
baseUIStroke.Color = Color3.fromRGB(255, 255, 255)
baseUIStroke.Transparency = 0.9
baseUIStroke.Parent = base
local sidebar = Instance.new("Frame")
sidebar.Name = "Sidebar"
sidebar.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
sidebar.BackgroundTransparency = 1
sidebar.BorderColor3 = Color3.fromRGB(0, 0, 0)
sidebar.BorderSizePixel = 0
sidebar.Position = UDim2.fromScale(-3.52e-08, 4.69e-08)
sidebar.Size = UDim2.fromScale(0.325, 1)
local divider = Instance.new("Frame")
divider.Name = "Divider"
divider.AnchorPoint = Vector2.new(1, 0)
divider.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
divider.BackgroundTransparency = 0.9
divider.BorderColor3 = Color3.fromRGB(0, 0, 0)
divider.BorderSizePixel = 0
divider.Position = UDim2.fromScale(1, 0)
divider.Size = UDim2.new(0, 1, 1, 0)
divider.Parent = sidebar
local dividerInteract = Instance.new("TextButton")
dividerInteract.Name = "DividerInteract"
dividerInteract.AnchorPoint = Vector2.new(0.5, 0)
dividerInteract.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
dividerInteract.BackgroundTransparency = 1
dividerInteract.BorderColor3 = Color3.fromRGB(0, 0, 0)
dividerInteract.BorderSizePixel = 0
dividerInteract.FontFace = Font.new("rbxasset://fonts/families/SourceSansPro.json")
dividerInteract.Position = UDim2.fromScale(0.5, 0)
dividerInteract.Size = UDim2.new(1, 6, 1, 0)
dividerInteract.Text = ""
dividerInteract.TextColor3 = Color3.fromRGB(0, 0, 0)
dividerInteract.TextSize = 14
dividerInteract.Parent = divider
local windowControls = Instance.new("Frame")
windowControls.Name = "WindowControls"
windowControls.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
windowControls.BackgroundTransparency = 1
windowControls.BorderColor3 = Color3.fromRGB(0, 0, 0)
windowControls.BorderSizePixel = 0
windowControls.Size = UDim2.new(1, 0, 0, 31)
local controls = Instance.new("Frame")
controls.Name = "Controls"
controls.BackgroundColor3 = Color3.fromRGB(119, 174, 94)
controls.BackgroundTransparency = 1
controls.BorderColor3 = Color3.fromRGB(0, 0, 0)
controls.BorderSizePixel = 0
controls.Size = UDim2.fromScale(1, 1)
local uIListLayout = Instance.new("UIListLayout")
uIListLayout.Name = "UIListLayout"
uIListLayout.Padding = UDim.new(0, 5)
uIListLayout.FillDirection = Enum.FillDirection.Horizontal
uIListLayout.SortOrder = Enum.SortOrder.LayoutOrder
uIListLayout.VerticalAlignment = Enum.VerticalAlignment.Center
uIListLayout.Parent = controls
local uIPadding = Instance.new("UIPadding")
uIPadding.Name = "UIPadding"
uIPadding.PaddingLeft = UDim.new(0, 11)
uIPadding.Parent = controls
local windowControlSettings = {
sizes = { enabled = UDim2.fromOffset(8, 8), disabled = UDim2.fromOffset(7, 7) },
transparencies = { enabled = 0, disabled = 1 },
strokeTransparency = 0.9,
}
local stroke = Instance.new("UIStroke")
stroke.Name = "BaseUIStroke"
stroke.ApplyStrokeMode = Enum.ApplyStrokeMode.Border
stroke.Color = Color3.fromRGB(255, 255, 255)
stroke.Transparency = windowControlSettings.strokeTransparency
local exit = Instance.new("TextButton")
exit.Name = "Exit"
exit.FontFace = Font.new("rbxasset://fonts/families/SourceSansPro.json")
exit.Text = ""
exit.TextColor3 = Color3.fromRGB(0, 0, 0)
exit.TextSize = 14
exit.AutoButtonColor = false
exit.BackgroundColor3 = Color3.fromRGB(250, 93, 86)
exit.BorderColor3 = Color3.fromRGB(0, 0, 0)
exit.BorderSizePixel = 0
local uICorner = Instance.new("UICorner")
uICorner.Name = "UICorner"
uICorner.CornerRadius = UDim.new(1, 0)
uICorner.Parent = exit
exit.Parent = controls
local minimize = Instance.new("TextButton")
minimize.Name = "Minimize"
minimize.FontFace = Font.new("rbxasset://fonts/families/SourceSansPro.json")
minimize.Text = ""
minimize.TextColor3 = Color3.fromRGB(0, 0, 0)
minimize.TextSize = 14
minimize.AutoButtonColor = false
minimize.BackgroundColor3 = Color3.fromRGB(252, 190, 57)
minimize.BorderColor3 = Color3.fromRGB(0, 0, 0)
minimize.BorderSizePixel = 0
minimize.LayoutOrder = 1
local uICorner1 = Instance.new("UICorner")
uICorner1.Name = "UICorner"
uICorner1.CornerRadius = UDim.new(1, 0)
uICorner1.Parent = minimize
minimize.Parent = controls
local maximize = Instance.new("TextButton")
maximize.Name = "Maximize"
maximize.FontFace = Font.new("rbxasset://fonts/families/SourceSansPro.json")
maximize.Text = ""
maximize.TextColor3 = Color3.fromRGB(0, 0, 0)
maximize.TextSize = 14
maximize.AutoButtonColor = false
maximize.BackgroundColor3 = Color3.fromRGB(119, 174, 94)
maximize.BorderColor3 = Color3.fromRGB(0, 0, 0)
maximize.BorderSizePixel = 0
maximize.LayoutOrder = 1
local uICorner2 = Instance.new("UICorner")
uICorner2.Name = "UICorner"
uICorner2.CornerRadius = UDim.new(1, 0)
uICorner2.Parent = maximize
maximize.Parent = controls
local function applyState(button, enabled)
local size = enabled and windowControlSettings.sizes.enabled or windowControlSettings.sizes.disabled
local transparency = enabled and windowControlSettings.transparencies.enabled or windowControlSettings.transparencies.disabled
button.Size = size
button.BackgroundTransparency = transparency
button.Active = enabled
button.Interactable = enabled
for _, child in ipairs(button:GetChildren()) do
if child:IsA("UIStroke") then
child.Transparency = transparency
end
end
if not enabled then
stroke:Clone().Parent = button
end
end
applyState(maximize, false)
local controlsList = {exit, minimize}
for _, button in pairs(controlsList) do
local buttonName = button.Name
local isEnabled = true
if Settings.DisabledWindowControls and table.find(Settings.DisabledWindowControls, buttonName) then
isEnabled = false
end
applyState(button, isEnabled)
end
controls.Parent = windowControls
local divider1 = Instance.new("Frame")
divider1.Name = "Divider"
divider1.AnchorPoint = Vector2.new(0, 1)
divider1.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
divider1.BackgroundTransparency = 0.9
divider1.BorderColor3 = Color3.fromRGB(0, 0, 0)
divider1.BorderSizePixel = 0
divider1.Position = UDim2.fromScale(0, 1)
divider1.Size = UDim2.new(1, 0, 0, 1)
divider1.Parent = windowControls
windowControls.Parent = sidebar
local information = Instance.new("Frame")
information.Name = "Information"
information.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
information.BackgroundTransparency = 1
information.BorderColor3 = Color3.fromRGB(0, 0, 0)
information.BorderSizePixel = 0
information.Position = UDim2.fromOffset(0, 31)
information.Size = UDim2.new(1, 0, 0, 60)
local divider2 = Instance.new("Frame")
divider2.Name = "Divider"
divider2.AnchorPoint = Vector2.new(0, 1)
divider2.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
divider2.BackgroundTransparency = 0.9
divider2.BorderColor3 = Color3.fromRGB(0, 0, 0)
divider2.BorderSizePixel = 0
divider2.Position = UDim2.fromScale(0, 1)
divider2.Size = UDim2.new(1, 0, 0, 1)
divider2.Parent = information
local informationHolder = Instance.new("Frame")
informationHolder.Name = "InformationHolder"
informationHolder.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
informationHolder.BackgroundTransparency = 1
informationHolder.BorderColor3 = Color3.fromRGB(0, 0, 0)
informationHolder.BorderSizePixel = 0
informationHolder.Size = UDim2.fromScale(1, 1)
local informationHolderUIPadding = Instance.new("UIPadding")
informationHolderUIPadding.Name = "InformationHolderUIPadding"
informationHolderUIPadding.PaddingBottom = UDim.new(0, 10)
informationHolderUIPadding.PaddingLeft = UDim.new(0, 23)
informationHolderUIPadding.PaddingRight = UDim.new(0, 22)
informationHolderUIPadding.PaddingTop = UDim.new(0, 10)
informationHolderUIPadding.Parent = informationHolder
local globalSettingsButton = Instance.new("ImageButton")
globalSettingsButton.Name = "GlobalSettingsButton"
globalSettingsButton.Image = assets.globe
globalSettingsButton.ImageTransparency = 0.5
globalSettingsButton.AnchorPoint = Vector2.new(1, 0.5)
globalSettingsButton.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
globalSettingsButton.BackgroundTransparency = 1
globalSettingsButton.BorderColor3 = Color3.fromRGB(0, 0, 0)
globalSettingsButton.BorderSizePixel = 0
globalSettingsButton.Position = UDim2.fromScale(1, 0.5)
globalSettingsButton.Size = UDim2.fromOffset(16,16)
globalSettingsButton.Parent = informationHolder
local function ChangeGlobalSettingsButtonState(State)
if State == "Default" then
Tween(globalSettingsButton, TweenInfo.new(0.2, Enum.EasingStyle.Sine), {
ImageTransparency = 0.5
}):Play()
elseif State == "Hover" then
Tween(globalSettingsButton, TweenInfo.new(0.2, Enum.EasingStyle.Sine), {
ImageTransparency = 0.3
}):Play()
end
end
globalSettingsButton.MouseEnter:Connect(cc(function()
ChangeGlobalSettingsButtonState("Hover")
end))
globalSettingsButton.MouseLeave:Connect(cc(function()
ChangeGlobalSettingsButtonState("Default")
end))
local titleFrame = Instance.new("Frame")
titleFrame.Name = "TitleFrame"
titleFrame.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
titleFrame.BackgroundTransparency = 1
titleFrame.BorderColor3 = Color3.fromRGB(0, 0, 0)
titleFrame.BorderSizePixel = 0
titleFrame.Size = UDim2.fromScale(1, 1)
local title = Instance.new("TextLabel")
title.Name = "Title"
title.FontFace = Font.new(
assets.interFont,
Enum.FontWeight.SemiBold,
Enum.FontStyle.Normal
)
title.Text = Settings.Title
title.TextColor3 = Color3.fromRGB(255, 255, 255)
title.RichText = true
title.TextSize = 18
title.TextTransparency = 0.1
title.TextTruncate = Enum.TextTruncate.SplitWord
title.TextXAlignment = Enum.TextXAlignment.Left
title.TextYAlignment = Enum.TextYAlignment.Top
title.AutomaticSize = Enum.AutomaticSize.Y
title.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
title.BackgroundTransparency = 1
title.BorderColor3 = Color3.fromRGB(0, 0, 0)
title.BorderSizePixel = 0
title.Size = UDim2.new(1, -20, 0, 0)
title.Parent = titleFrame
local subtitle = Instance.new("TextLabel")
subtitle.Name = "Subtitle"
subtitle.FontFace = Font.new(
assets.interFont,
Enum.FontWeight.Medium,
Enum.FontStyle.Normal
)
subtitle.RichText = true
subtitle.Text = Settings.Subtitle
subtitle.RichText = true
subtitle.TextColor3 = Color3.fromRGB(255, 255, 255)
subtitle.TextSize = 12
subtitle.TextTransparency = 0.7
subtitle.TextTruncate = Enum.TextTruncate.SplitWord
subtitle.TextXAlignment = Enum.TextXAlignment.Left
subtitle.TextYAlignment = Enum.TextYAlignment.Top
subtitle.AutomaticSize = Enum.AutomaticSize.Y
subtitle.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
subtitle.BackgroundTransparency = 1
subtitle.BorderColor3 = Color3.fromRGB(0, 0, 0)
subtitle.BorderSizePixel = 0
subtitle.LayoutOrder = 1
subtitle.Size = UDim2.new(1, -20, 0, 0)
subtitle.Parent = titleFrame
local titleFrameUIListLayout = Instance.new("UIListLayout")
titleFrameUIListLayout.Name = "TitleFrameUIListLayout"
titleFrameUIListLayout.Padding = UDim.new(0, 3)
titleFrameUIListLayout.SortOrder = Enum.SortOrder.LayoutOrder
titleFrameUIListLayout.VerticalAlignment = Enum.VerticalAlignment.Center
titleFrameUIListLayout.Parent = titleFrame
titleFrame.Parent = informationHolder
informationHolder.Parent = information
information.Parent = sidebar
local sidebarGroup = Instance.new("Frame")
sidebarGroup.Name = "SidebarGroup"
sidebarGroup.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
sidebarGroup.BackgroundTransparency = 1
sidebarGroup.BorderColor3 = Color3.fromRGB(0, 0, 0)
sidebarGroup.BorderSizePixel = 0
sidebarGroup.Position = UDim2.fromOffset(0, 91)
sidebarGroup.Size = UDim2.new(1, 0, 1, -91)
local userInfo = Instance.new("Frame")
userInfo.Name = "UserInfo"
userInfo.AnchorPoint = Vector2.new(0, 1)
userInfo.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
userInfo.BackgroundTransparency = 1
userInfo.BorderColor3 = Color3.fromRGB(0, 0, 0)
userInfo.BorderSizePixel = 0
userInfo.Position = UDim2.fromScale(0, 1)
userInfo.Size = UDim2.new(1, 0, 0, 107)
local informationGroup = Instance.new("Frame")
informationGroup.Name = "InformationGroup"
informationGroup.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
informationGroup.BackgroundTransparency = 1
informationGroup.BorderColor3 = Color3.fromRGB(0, 0, 0)
informationGroup.BorderSizePixel = 0
informationGroup.Size = UDim2.fromScale(1, 1)
local informationGroupUIPadding = Instance.new("UIPadding")
informationGroupUIPadding.Name = "InformationGroupUIPadding"
informationGroupUIPadding.PaddingBottom = UDim.new(0, 17)
informationGroupUIPadding.PaddingLeft = UDim.new(0, 25)
informationGroupUIPadding.Parent = informationGroup
local informationGroupUIListLayout = Instance.new("UIListLayout")
informationGroupUIListLayout.Name = "InformationGroupUIListLayout"
informationGroupUIListLayout.FillDirection = Enum.FillDirection.Horizontal
informationGroupUIListLayout.SortOrder = Enum.SortOrder.LayoutOrder
informationGroupUIListLayout.VerticalAlignment = Enum.VerticalAlignment.Center
informationGroupUIListLayout.Parent = informationGroup
local userId = LocalPlayer.UserId
local thumbType = Enum.ThumbnailType.AvatarBust
local thumbSize = Enum.ThumbnailSize.Size48x48
local headshotImage, isReady = Players["GetUserThumbnailAsync"](Players, userId, thumbType, thumbSize)
local headshot = Instance.new("ImageLabel")
headshot.Name = "Headshot"
headshot.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
headshot.BackgroundTransparency = 1
headshot.BorderColor3 = Color3.fromRGB(0, 0, 0)
headshot.BorderSizePixel = 0
headshot.Size = UDim2.fromOffset(32, 32)
headshot.Image = (isReady and headshotImage) or "rbxassetid://0"
local uICorner3 = Instance.new("UICorner")
uICorner3.Name = "UICorner"
uICorner3.CornerRadius = UDim.new(1, 0)
uICorner3.Parent = headshot
local baseUIStroke2 = Instance.new("UIStroke")
baseUIStroke2.Name = "BaseUIStroke"
baseUIStroke2.ApplyStrokeMode = Enum.ApplyStrokeMode.Border
baseUIStroke2.Color = Color3.fromRGB(255, 255, 255)
baseUIStroke2.Transparency = 0.9
baseUIStroke2.Parent = headshot
headshot.Parent = informationGroup
local userAndDisplayFrame = Instance.new("Frame")
userAndDisplayFrame.Name = "UserAndDisplayFrame"
userAndDisplayFrame.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
userAndDisplayFrame.BackgroundTransparency = 1
userAndDisplayFrame.BorderColor3 = Color3.fromRGB(0, 0, 0)
userAndDisplayFrame.BorderSizePixel = 0
userAndDisplayFrame.LayoutOrder = 1
userAndDisplayFrame.Size = UDim2.new(1, -42, 0, 32)
local displayName = Instance.new("TextLabel")
displayName.Name = "DisplayName"
displayName.FontFace = Font.new(
assets.interFont,
Enum.FontWeight.SemiBold,
Enum.FontStyle.Normal
)
displayName.Text = LocalPlayer.DisplayName
displayName.TextColor3 = Color3.fromRGB(255, 255, 255)
displayName.TextSize = 13
displayName.TextTransparency = 0.1
displayName.TextTruncate = Enum.TextTruncate.SplitWord
displayName.TextXAlignment = Enum.TextXAlignment.Left
displayName.TextYAlignment = Enum.TextYAlignment.Top
displayName.AutomaticSize = Enum.AutomaticSize.XY
displayName.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
displayName.BackgroundTransparency = 1
displayName.BorderColor3 = Color3.fromRGB(0, 0, 0)
displayName.BorderSizePixel = 0
displayName.Parent = userAndDisplayFrame
displayName.Size = UDim2.fromScale(1,0)
local userAndDisplayFrameUIPadding = Instance.new("UIPadding")
userAndDisplayFrameUIPadding.Name = "UserAndDisplayFrameUIPadding"
userAndDisplayFrameUIPadding.PaddingLeft = UDim.new(0, 8)
userAndDisplayFrameUIPadding.PaddingTop = UDim.new(0, 3)
userAndDisplayFrameUIPadding.Parent = userAndDisplayFrame
local userAndDisplayFrameUIListLayout = Instance.new("UIListLayout")
userAndDisplayFrameUIListLayout.Name = "UserAndDisplayFrameUIListLayout"
userAndDisplayFrameUIListLayout.Padding = UDim.new(0, 1)
userAndDisplayFrameUIListLayout.SortOrder = Enum.SortOrder.LayoutOrder
userAndDisplayFrameUIListLayout.Parent = userAndDisplayFrame
local username = Instance.new("TextLabel")
username.Name = "Username"
username.FontFace = Font.new(
assets.interFont,
Enum.FontWeight.SemiBold,
Enum.FontStyle.Normal
)
username.Text = "@" .. LocalPlayer.Name
username.TextColor3 = Color3.fromRGB(255, 255, 255)
username.TextSize = 12
username.TextTransparency = 0.7
username.TextTruncate = Enum.TextTruncate.SplitWord
username.TextXAlignment = Enum.TextXAlignment.Left
username.TextYAlignment = Enum.TextYAlignment.Top
username.AutomaticSize = Enum.AutomaticSize.XY
username.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
username.BackgroundTransparency = 1
username.BorderColor3 = Color3.fromRGB(0, 0, 0)
username.BorderSizePixel = 0
username.LayoutOrder = 1
username.Parent = userAndDisplayFrame
username.Size = UDim2.fromScale(1,0)
userAndDisplayFrame.Parent = informationGroup
informationGroup.Parent = userInfo
local userInfoUIPadding = Instance.new("UIPadding")
userInfoUIPadding.Name = "UserInfoUIPadding"
userInfoUIPadding.PaddingLeft = UDim.new(0, 10)
userInfoUIPadding.PaddingRight = UDim.new(0, 10)
userInfoUIPadding.Parent = userInfo
userInfo.Parent = sidebarGroup
local sidebarGroupUIPadding = Instance.new("UIPadding")
sidebarGroupUIPadding.Name = "SidebarGroupUIPadding"
sidebarGroupUIPadding.PaddingLeft = UDim.new(0, 10)
sidebarGroupUIPadding.PaddingRight = UDim.new(0, 10)
sidebarGroupUIPadding.PaddingTop = UDim.new(0, 31)
sidebarGroupUIPadding.Parent = sidebarGroup
local tabSwitchers = Instance.new("Frame")
tabSwitchers.Name = "TabSwitchers"
tabSwitchers.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
tabSwitchers.BackgroundTransparency = 1
tabSwitchers.BorderColor3 = Color3.fromRGB(0, 0, 0)
tabSwitchers.BorderSizePixel = 0
tabSwitchers.Size = UDim2.new(1, 0, 1, -107)
local tabSwitchersScrollingFrame = Instance.new("ScrollingFrame")
tabSwitchersScrollingFrame.Name = "TabSwitchersScrollingFrame"
tabSwitchersScrollingFrame.AutomaticCanvasSize = Enum.AutomaticSize.Y
tabSwitchersScrollingFrame.BottomImage = ""
tabSwitchersScrollingFrame.CanvasSize = UDim2.new()
tabSwitchersScrollingFrame.ScrollBarImageTransparency = 0.8
tabSwitchersScrollingFrame.ScrollBarThickness = 1
tabSwitchersScrollingFrame.TopImage = ""
tabSwitchersScrollingFrame.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
tabSwitchersScrollingFrame.BackgroundTransparency = 1
tabSwitchersScrollingFrame.BorderColor3 = Color3.fromRGB(0, 0, 0)
tabSwitchersScrollingFrame.BorderSizePixel = 0
tabSwitchersScrollingFrame.Size = UDim2.fromScale(1, 1)
local tabSwitchersScrollingFrameUIListLayout = Instance.new("UIListLayout")
tabSwitchersScrollingFrameUIListLayout.Name = "TabSwitchersScrollingFrameUIListLayout"
tabSwitchersScrollingFrameUIListLayout.Padding = UDim.new(0, 17)
tabSwitchersScrollingFrameUIListLayout.SortOrder = Enum.SortOrder.LayoutOrder
tabSwitchersScrollingFrameUIListLayout.Parent = tabSwitchersScrollingFrame
local tabSwitchersScrollingFrameUIPadding = Instance.new("UIPadding")
tabSwitchersScrollingFrameUIPadding.Name = "TabSwitchersScrollingFrameUIPadding"
tabSwitchersScrollingFrameUIPadding.PaddingTop = UDim.new(0, 2)
tabSwitchersScrollingFrameUIPadding.Parent = tabSwitchersScrollingFrame
tabSwitchersScrollingFrame.Parent = tabSwitchers
tabSwitchers.Parent = sidebarGroup
sidebarGroup.Parent = sidebar
sidebar.Parent = base
local content = Instance.new("Frame")
content.Name = "Content"
content.AnchorPoint = Vector2.new(1, 0)
content.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
content.BackgroundTransparency = 1
content.BorderColor3 = Color3.fromRGB(0, 0, 0)
content.BorderSizePixel = 0
content.Position = UDim2.fromScale(1, 4.69e-08)
content.Size = UDim2.new(0, (base.AbsoluteSize.X - sidebar.AbsoluteSize.X), 1, 0)
local resizingContent = false
local defaultSidebarWidth = sidebar.AbsoluteSize.X
local initialMouseX, initialSidebarWidth
local snapRange = 20
local minSidebarWidth = 107
local maxSidebarWidth = base.AbsoluteSize.X - minSidebarWidth
local TweenSettings = {
DefaultTransparency = 0.9,
HoverTransparency = 0.85,
EasingStyle = Enum.EasingStyle.Sine
}
local function ChangeState(State)
Tween(divider, TweenInfo.new(0.2, TweenSettings.EasingStyle), {
BackgroundTransparency = State == "Idle" and TweenSettings.DefaultTransparency or TweenSettings.HoverTransparency
}):Play()
end
dividerInteract.MouseEnter:Connect(cc(function()
ChangeState("Hover")
end))
dividerInteract.MouseLeave:Connect(cc(function()
ChangeState("Idle")
end))
dividerInteract.MouseButton1Down:Connect(cc(function()
resizingContent = true
initialMouseX = UserInputService:GetMouseLocation().X
initialSidebarWidth = sidebar.AbsoluteSize.X
end))
UserInputService.InputEnded:Connect(cc(function(input)
if input.UserInputType == Enum.UserInputType.MouseButton1 then
resizingContent = false
end
end))
UserInputService.InputChanged:Connect(cc(function(input)
if resizingContent and input.UserInputType == Enum.UserInputType.MouseMovement then
local deltaX = UserInputService:GetMouseLocation().X - initialMouseX
local newSidebarWidth = initialSidebarWidth + deltaX
if math.abs(newSidebarWidth - defaultSidebarWidth) < snapRange then
newSidebarWidth = defaultSidebarWidth
else
newSidebarWidth = math.clamp(newSidebarWidth, minSidebarWidth, maxSidebarWidth)
end
sidebar.Size = UDim2.new(0, newSidebarWidth, 1, 0)
content.Size = UDim2.new(0, base.AbsoluteSize.X - newSidebarWidth, 1, 0)
end
end))
local topbar = Instance.new("Frame")
topbar.Name = "Topbar"
topbar.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
topbar.BackgroundTransparency = 1
topbar.BorderColor3 = Color3.fromRGB(0, 0, 0)
topbar.BorderSizePixel = 0
topbar.Size = UDim2.new(1, 0, 0, 63)
local divider4 = Instance.new("Frame")
divider4.Name = "Divider"
divider4.AnchorPoint = Vector2.new(0, 1)
divider4.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
divider4.BackgroundTransparency = 0.9
divider4.BorderColor3 = Color3.fromRGB(0, 0, 0)
divider4.BorderSizePixel = 0
divider4.Position = UDim2.fromScale(0, 1)
divider4.Size = UDim2.new(1, 0, 0, 1)
divider4.Parent = topbar
local elements = Instance.new("Frame")
elements.Name = "Elements"
elements.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
elements.BackgroundTransparency = 1
elements.BorderColor3 = Color3.fromRGB(0, 0, 0)
elements.BorderSizePixel = 0
elements.Size = UDim2.fromScale(1, 1)
local uIPadding2 = Instance.new("UIPadding")
uIPadding2.Name = "UIPadding"
uIPadding2.PaddingLeft = UDim.new(0, 20)
uIPadding2.PaddingRight = UDim.new(0, 20)
uIPadding2.Parent = elements
local moveIcon = Instance.new("ImageButton")
moveIcon.Name = "MoveIcon"
moveIcon.Image = assets.transform
moveIcon.ImageTransparency = 0.7
moveIcon.AnchorPoint = Vector2.new(1, 0.5)
moveIcon.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
moveIcon.BackgroundTransparency = 1
moveIcon.BorderColor3 = Color3.fromRGB(0, 0, 0)
moveIcon.BorderSizePixel = 0
moveIcon.Position = UDim2.fromScale(1, 0.5)
moveIcon.Size = UDim2.fromOffset(15, 15)
moveIcon.Parent = elements
moveIcon.Visible = not Settings.DragStyle or Settings.DragStyle == 1
local interact = Instance.new("TextButton")
interact.Name = "Interact"
interact.FontFace = Font.new("rbxasset://fonts/families/SourceSansPro.json")
interact.Text = ""
interact.TextColor3 = Color3.fromRGB(0, 0, 0)
interact.TextSize = 14
interact.AnchorPoint = Vector2.new(0.5, 0.5)
interact.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
interact.BackgroundTransparency = 1
interact.BorderColor3 = Color3.fromRGB(0, 0, 0)
interact.BorderSizePixel = 0
interact.Position = UDim2.fromScale(0.5, 0.5)
interact.Size = UDim2.fromOffset(40, 40)
interact.Parent = moveIcon
local function ChangemoveIconState(State)
if State == "Default" then
Tween(moveIcon, TweenInfo.new(0.2, Enum.EasingStyle.Sine), {
ImageTransparency = 0.7
}):Play()
elseif State == "Hover" then
Tween(moveIcon, TweenInfo.new(0.2, Enum.EasingStyle.Sine), {
ImageTransparency = 0.4
}):Play()
end
end
interact.MouseEnter:Connect(cc(function()
ChangemoveIconState("Hover")
end))
interact.MouseLeave:Connect(cc(function()
ChangemoveIconState("Default")
end))
local dragging_ = false
local dragInput
local dragStart
local startPos
local function update(input)
local delta = input.Position - dragStart
base.Position = UDim2.new(startPos.X.Scale, startPos.X.Offset + delta.X, startPos.Y.Scale, startPos.Y.Offset + delta.Y)
end
local function onDragStart(input)
if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
dragging_ = true
dragStart = input.Position
startPos = base.Position
input.Changed:Connect(cc(function()
if input.UserInputState == Enum.UserInputState.End then
dragging_ = false
end
end))
end
end
local function onDragUpdate(input)
if dragging_ and (input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch) then
dragInput = input
end
end
if not Settings.DragStyle or Settings.DragStyle == 1 then
interact.InputBegan:Connect(cc(function(input)
if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
onDragStart(input)
end
end))
interact.InputChanged:Connect(cc(onDragUpdate))