R

fuxk azure

public
rrixh Apr 17, 2024 Never 102
Clone
Plaintext .zip 4501 lines (3926 loc) | 227.87 KB
1
--// leak
2
3
repeat wait() until game:IsLoaded()
4
5
game:GetService("CorePackages").Packages:Destroy()
6
7
assert(getrawmetatable)
8
grm = getrawmetatable(game)
9
setreadonly(grm, false)
10
old = grm.__namecall
11
grm.__namecall = newcclosure(function(self, ...)
12
local args = {...}
13
if tostring(args[1]) == "TeleportDetect" then
14
return
15
elseif tostring(args[1]) == "CHECKER_1" then
16
return
17
elseif tostring(args[1]) == "CHECKER" then
18
return
19
elseif tostring(args[1]) == "GUI_CHECK" then
20
return
21
elseif tostring(args[1]) == "OneMoreTime" then
22
return
23
elseif tostring(args[1]) == "checkingSPEED" then
24
return
25
elseif tostring(args[1]) == "BANREMOTE" then
26
return
27
elseif tostring(args[1]) == "PERMAIDBAN" then
28
return
29
elseif tostring(args[1]) == "KICKREMOTE" then
30
return
31
elseif tostring(args[1]) == "BR_KICKPC" then
32
return
33
elseif tostring(args[1]) == "BR_KICKMOBILE" then
34
return
35
end
36
return old(self, ...)
37
end)
38
39
local library = {
40
flags = { },
41
items = { }
42
}
43
44
local players = game:GetService("Players")
45
local uis = game:GetService("UserInputService")
46
local runservice = game:GetService("RunService")
47
local tweenservice = game:GetService("TweenService")
48
local marketplaceservice = game:GetService("MarketplaceService")
49
local textservice = game:GetService("TextService")
50
local coregui = game:GetService("CoreGui")
51
local httpservice = game:GetService("HttpService")
52
53
local player = players.LocalPlayer
54
local mouse = player:GetMouse()
55
local camera = game.Workspace.CurrentCamera
56
57
library.theme = {
58
fontsize = 17,
59
titlesize = 18,
60
font = Enum.Font.Code,
61
background = "rbxassetid://0",
62
tilesize = 90,
63
cursor = false,
64
cursorimg = "https://t0.rbxcdn.com/42f66da98c40252ee151326a82aab51f",
65
backgroundcolor = Color3.fromRGB(20, 20, 20),
66
tabstextcolor = Color3.fromRGB(168,122,207),
67
bordercolor = Color3.fromRGB(75, 207, 255),
68
accentcolor = Color3.fromRGB(168,122,207),
69
accentcolor2 = Color3.fromRGB(88,65,108),
70
outlinecolor = Color3.fromRGB(20,20,20),
71
outlinecolor2 = Color3.fromRGB(30,30,30),--119, 64, 167
72
sectorcolor = Color3.fromRGB(30, 30, 30),
73
toptextcolor = Color3.fromRGB(255, 255, 255),
74
topheight = 48,
75
topcolor = Color3.fromRGB(30, 30, 30),
76
topcolor2 = Color3.fromRGB(12,12,12), -- Color3.fromRGB(12, 12, 12),
77
buttoncolor = Color3.fromRGB(49, 49, 49),
78
buttoncolor2 = Color3.fromRGB(29,29,29),
79
itemscolor = Color3.fromRGB(170, 170, 170),
80
itemscolor2 = Color3.fromRGB(255,255,255)
81
}
82
83
if library.theme.cursor and Drawing then
84
local success = pcall(function()
85
library.cursor = Drawing.new("Image")
86
library.cursor.Data = game:HttpGet(library.theme.cursorimg)
87
library.cursor.Size = Vector2.new(64, 64)
88
library.cursor.Visible = uis.MouseEnabled
89
library.cursor.Rounding = 0
90
library.cursor.Position = Vector2.new(mouse.X - 32, mouse.Y + 6)
91
end)
92
if success and library.cursor then
93
uis.InputChanged:Connect(function(input)
94
if uis.MouseEnabled then
95
if input.UserInputType == Enum.UserInputType.MouseMovement then
96
library.cursor.Position = Vector2.new(input.Position.X - 32, input.Position.Y + 7)
97
end
98
end
99
end)
100
101
game:GetService("RunService").RenderStepped:Connect(function()
102
uis.OverrideMouseIconBehavior = Enum.OverrideMouseIconBehavior.ForceHide
103
library.cursor.Visible = uis.MouseEnabled and (uis.MouseIconEnabled or game:GetService("GuiService").MenuIsOpen)
104
end)
105
elseif not success and library.cursor then
106
library.cursor:Remove()
107
end
108
end
109
110
function library:CreateWatermark(name, position)
111
local gamename = marketplaceservice:GetProductInfo(game.PlaceId).Name
112
local watermark = { }
113
watermark.Visible = true
114
watermark.text = " " .. name:gsub("{game}", gamename):gsub("{fps}", "0 FPS") .. " "
115
116
watermark.main = Instance.new("ScreenGui", coregui)
117
watermark.main.Name = "Watermark"
118
if syn then
119
syn.protect_gui(watermark.main)
120
end
121
122
if getgenv().watermark then
123
getgenv().watermark:Remove()
124
end
125
getgenv().watermark = watermark.main
126
127
watermark.mainbar = Instance.new("Frame", watermark.main)
128
watermark.mainbar.Name = "Main"
129
watermark.mainbar.BorderColor3 = Color3.fromRGB(80, 80, 80)
130
watermark.mainbar.Visible = watermark.Visible
131
watermark.mainbar.BorderSizePixel = 0
132
watermark.mainbar.ZIndex = 5
133
watermark.mainbar.Position = UDim2.new(0, position and position.X or 10, 0, position and position.Y or 10)
134
watermark.mainbar.Size = UDim2.new(0, 0, 0, 25)
135
136
watermark.Gradient = Instance.new("UIGradient", watermark.mainbar)
137
watermark.Gradient.Rotation = 90
138
watermark.Gradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, Color3.fromRGB(40, 40, 40)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(10, 10, 10)) })
139
140
watermark.Outline = Instance.new("Frame", watermark.mainbar)
141
watermark.Outline.Name = "outline"
142
watermark.Outline.ZIndex = 4
143
watermark.Outline.BorderSizePixel = 0
144
watermark.Outline.Visible = watermark.Visible
145
watermark.Outline.BackgroundColor3 = library.theme.outlinecolor
146
watermark.Outline.Position = UDim2.fromOffset(-1, -1)
147
148
watermark.BlackOutline = Instance.new("Frame", watermark.mainbar)
149
watermark.BlackOutline.Name = "blackline"
150
watermark.BlackOutline.ZIndex = 3
151
watermark.BlackOutline.BorderSizePixel = 0
152
watermark.BlackOutline.BackgroundColor3 = library.theme.outlinecolor2
153
watermark.BlackOutline.Visible = watermark.Visible
154
watermark.BlackOutline.Position = UDim2.fromOffset(-2, -2)
155
156
watermark.label = Instance.new("TextLabel", watermark.mainbar)
157
watermark.label.Name = "FPSLabel"
158
watermark.label.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
159
watermark.label.BackgroundTransparency = 1.000
160
watermark.label.Position = UDim2.new(0, 0, 0, 0)
161
watermark.label.Size = UDim2.new(0, 238, 0, 25)
162
watermark.label.Font = library.theme.font
163
watermark.label.ZIndex = 6
164
watermark.label.Visible = watermark.Visible
165
watermark.label.Text = watermark.text
166
watermark.label.TextColor3 = Color3.fromRGB(255, 255, 255)
167
watermark.label.TextSize = 15
168
watermark.label.TextStrokeTransparency = 0.000
169
watermark.label.TextXAlignment = Enum.TextXAlignment.Left
170
watermark.label.Size = UDim2.new(0, watermark.label.TextBounds.X+10, 0, 25)
171
172
watermark.topbar = Instance.new("Frame", watermark.mainbar)
173
watermark.topbar.Name = "TopBar"
174
watermark.topbar.ZIndex = 6
175
watermark.topbar.BackgroundColor3 = library.theme.accentcolor
176
watermark.topbar.BorderSizePixel = 0
177
watermark.topbar.Visible = watermark.Visible
178
watermark.topbar.Size = UDim2.new(0, 0, 0, 1)
179
180
watermark.mainbar.Size = UDim2.new(0, watermark.label.TextBounds.X, 0, 25)
181
watermark.topbar.Size = UDim2.new(0, watermark.label.TextBounds.X+6, 0, 1)
182
watermark.Outline.Size = watermark.mainbar.Size + UDim2.fromOffset(2, 2)
183
watermark.BlackOutline.Size = watermark.mainbar.Size + UDim2.fromOffset(4, 4)
184
185
watermark.mainbar.Size = UDim2.new(0, watermark.label.TextBounds.X+4, 0, 25)
186
watermark.label.Size = UDim2.new(0, watermark.label.TextBounds.X+4, 0, 25)
187
watermark.topbar.Size = UDim2.new(0, watermark.label.TextBounds.X+6, 0, 1)
188
watermark.Outline.Size = watermark.mainbar.Size + UDim2.fromOffset(2, 2)
189
watermark.BlackOutline.Size = watermark.mainbar.Size + UDim2.fromOffset(4, 4)
190
191
local startTime, counter, oldfps = os.clock(), 0, nil
192
runservice.Heartbeat:Connect(function()
193
watermark.label.Visible = watermark.Visible
194
watermark.mainbar.Visible = watermark.Visible
195
watermark.topbar.Visible = watermark.Visible
196
watermark.Outline.Visible = watermark.Visible
197
watermark.BlackOutline.Visible = watermark.Visible
198
199
if not name:find("{fps}") then
200
watermark.label.Text = " " .. name:gsub("{game}", gamename):gsub("{fps}", "0 FPS") .. " "
201
end
202
203
if name:find("{fps}") then
204
local currentTime = os.clock()
205
counter = counter + 1
206
if currentTime - startTime >= 1 then
207
local fps = math.floor(counter / (currentTime - startTime))
208
counter = 0
209
startTime = currentTime
210
211
if fps ~= oldfps then
212
watermark.label.Text = " " .. name:gsub("{game}", gamename):gsub("{fps}", fps .. " FPS") .. " "
213
214
watermark.label.Size = UDim2.new(0, watermark.label.TextBounds.X+10, 0, 25)
215
watermark.mainbar.Size = UDim2.new(0, watermark.label.TextBounds.X, 0, 25)
216
watermark.topbar.Size = UDim2.new(0, watermark.label.TextBounds.X, 0, 1)
217
218
watermark.Outline.Size = watermark.mainbar.Size + UDim2.fromOffset(2, 2)
219
watermark.BlackOutline.Size = watermark.mainbar.Size + UDim2.fromOffset(4, 4)
220
end
221
oldfps = fps
222
end
223
end
224
end)
225
226
watermark.mainbar.MouseEnter:Connect(function()
227
tweenservice:Create(watermark.mainbar, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { BackgroundTransparency = 1, Active = false }):Play()
228
tweenservice:Create(watermark.topbar, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { BackgroundTransparency = 1, Active = false }):Play()
229
tweenservice:Create(watermark.label, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { TextTransparency = 1, Active = false }):Play()
230
tweenservice:Create(watermark.Outline, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { BackgroundTransparency = 1, Active = false }):Play()
231
tweenservice:Create(watermark.BlackOutline, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { BackgroundTransparency = 1, Active = false }):Play()
232
end)
233
234
watermark.mainbar.MouseLeave:Connect(function()
235
tweenservice:Create(watermark.mainbar, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { BackgroundTransparency = 0, Active = true }):Play()
236
tweenservice:Create(watermark.topbar, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { BackgroundTransparency = 0, Active = true }):Play()
237
tweenservice:Create(watermark.label, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { TextTransparency = 0, Active = true }):Play()
238
tweenservice:Create(watermark.Outline, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { BackgroundTransparency = 0, Active = true }):Play()
239
tweenservice:Create(watermark.BlackOutline, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { BackgroundTransparency = 0, Active = true }):Play()
240
end)
241
242
function watermark:UpdateTheme(theme)
243
theme = theme or library.theme
244
watermark.Outline.BackgroundColor3 = theme.outlinecolor
245
watermark.BlackOutline.BackgroundColor3 = theme.outlinecolor2
246
watermark.label.Font = theme.font
247
watermark.topbar.BackgroundColor3 = theme.accentcolor
248
end
249
250
return watermark
251
end
252
253
function library:CreateWindow(name, size, hidebutton)
254
local window = { }
255
256
window.name = name or ""
257
window.size = UDim2.fromOffset(size.X, size.Y) or UDim2.fromOffset(492, 598)
258
window.hidebutton = hidebutton or Enum.KeyCode.RightShift
259
window.theme = library.theme
260
261
local updateevent = Instance.new("BindableEvent")
262
function window:UpdateTheme(theme)
263
updateevent:Fire(theme or library.theme)
264
window.theme = (theme or library.theme)
265
end
266
267
window.Main = Instance.new("ScreenGui", coregui)
268
window.Main.Name = name
269
window.Main.DisplayOrder = 15
270
if syn then
271
syn.protect_gui(window.Main)
272
end
273
274
if getgenv().uilib then
275
getgenv().uilib:Remove()
276
end
277
getgenv().uilib = window.Main
278
279
local dragging, dragInput, dragStart, startPos
280
uis.InputChanged:Connect(function(input)
281
if input == dragInput and dragging then
282
local delta = input.Position - dragStart
283
window.Frame.Position = UDim2.new(startPos.X.Scale, startPos.X.Offset + delta.X, startPos.Y.Scale, startPos.Y.Offset + delta.Y)
284
end
285
end)
286
287
local dragstart = function(input)
288
if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
289
dragging = true
290
dragStart = input.Position
291
startPos = window.Frame.Position
292
293
input.Changed:Connect(function()
294
if input.UserInputState == Enum.UserInputState.End then
295
dragging = false
296
end
297
end)
298
end
299
end
300
301
local dragend = function(input)
302
if input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch then
303
dragInput = input
304
end
305
end
306
307
window.Frame = Instance.new("TextButton", window.Main)
308
window.Frame.Name = "main"
309
window.Frame.Position = UDim2.fromScale(0.5, 0.5)
310
window.Frame.BorderSizePixel = 0
311
window.Frame.Size = window.size
312
window.Frame.AutoButtonColor = false
313
window.Frame.Text = ""
314
window.Frame.BackgroundColor3 = window.theme.backgroundcolor
315
window.Frame.AnchorPoint = Vector2.new(0.5, 0.5)
316
updateevent.Event:Connect(function(theme)
317
window.Frame.BackgroundColor3 = theme.backgroundcolor
318
end)
319
320
uis.InputBegan:Connect(function(key)
321
if key.KeyCode == window.hidebutton then
322
window.Frame.Visible = not window.Frame.Visible
323
end
324
end)
325
326
local function checkIfGuiInFront(Pos)
327
local objects = coregui:GetGuiObjectsAtPosition(Pos.X, Pos.Y)
328
for i,v in pairs(objects) do
329
if not string.find(v:GetFullName(), window.name) then
330
table.remove(objects, i)
331
end
332
end
333
return (#objects ~= 0 and objects[1].AbsolutePosition ~= Pos)
334
end
335
336
window.BlackOutline = Instance.new("Frame", window.Frame)
337
window.BlackOutline.Name = "outline"
338
window.BlackOutline.ZIndex = 1
339
window.BlackOutline.Size = window.size + UDim2.fromOffset(2, 2)
340
window.BlackOutline.BorderSizePixel = 0
341
window.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
342
window.BlackOutline.Position = UDim2.fromOffset(-1, -1)
343
updateevent.Event:Connect(function(theme)
344
window.BlackOutline.BackgroundColor3 = theme.outlinecolor2
345
end)
346
347
window.Outline = Instance.new("Frame", window.Frame)
348
window.Outline.Name = "outline"
349
window.Outline.ZIndex = 0
350
window.Outline.Size = window.size + UDim2.fromOffset(4, 4)
351
window.Outline.BorderSizePixel = 0
352
window.Outline.BackgroundColor3 = window.theme.outlinecolor
353
window.Outline.Position = UDim2.fromOffset(-2, -2)
354
updateevent.Event:Connect(function(theme)
355
window.Outline.BackgroundColor3 = theme.outlinecolor
356
end)
357
358
window.BlackOutline2 = Instance.new("Frame", window.Frame)
359
window.BlackOutline2.Name = "outline"
360
window.BlackOutline2.ZIndex = -1
361
window.BlackOutline2.Size = window.size + UDim2.fromOffset(6, 6)
362
window.BlackOutline2.BorderSizePixel = 0
363
window.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
364
window.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
365
updateevent.Event:Connect(function(theme)
366
window.BlackOutline2.BackgroundColor3 = theme.outlinecolor2
367
end)
368
369
window.TopBar = Instance.new("Frame", window.Frame)
370
window.TopBar.Name = "top"
371
window.TopBar.Size = UDim2.fromOffset(window.size.X.Offset, window.theme.topheight)
372
window.TopBar.BorderSizePixel = 0
373
window.TopBar.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
374
window.TopBar.InputBegan:Connect(dragstart)
375
window.TopBar.InputChanged:Connect(dragend)
376
updateevent.Event:Connect(function(theme)
377
window.TopBar.Size = UDim2.fromOffset(window.size.X.Offset, theme.topheight)
378
end)
379
380
window.TopGradient = Instance.new("UIGradient", window.TopBar)
381
window.TopGradient.Rotation = 90
382
window.TopGradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, window.theme.topcolor), ColorSequenceKeypoint.new(1.00, window.theme.topcolor2) })
383
updateevent.Event:Connect(function(theme)
384
window.TopGradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, theme.topcolor), ColorSequenceKeypoint.new(1.00, theme.topcolor2) })
385
end)
386
387
window.NameLabel = Instance.new("TextLabel", window.TopBar)
388
window.NameLabel.TextColor3 = window.theme.toptextcolor
389
window.NameLabel.Text = window.name
390
window.NameLabel.TextXAlignment = Enum.TextXAlignment.Left
391
window.NameLabel.Font = window.theme.font
392
window.NameLabel.Name = "title"
393
window.NameLabel.Position = UDim2.fromOffset(4, -2)
394
window.NameLabel.BackgroundTransparency = 1
395
window.NameLabel.Size = UDim2.fromOffset(190, window.TopBar.AbsoluteSize.Y / 2 - 2)
396
window.NameLabel.TextSize = window.theme.titlesize
397
updateevent.Event:Connect(function(theme)
398
window.NameLabel.TextColor3 = theme.toptextcolor
399
window.NameLabel.Font = theme.font
400
window.NameLabel.TextSize = theme.titlesize
401
end)
402
403
window.Line2 = Instance.new("Frame", window.TopBar)
404
window.Line2.Name = "line"
405
window.Line2.Position = UDim2.fromOffset(0, window.TopBar.AbsoluteSize.Y / 2.1)
406
window.Line2.Size = UDim2.fromOffset(window.size.X.Offset, 1)
407
window.Line2.BorderSizePixel = 0
408
window.Line2.BackgroundColor3 = window.theme.accentcolor
409
updateevent.Event:Connect(function(theme)
410
window.Line2.BackgroundColor3 = theme.accentcolor
411
end)
412
413
window.TabList = Instance.new("Frame", window.TopBar)
414
window.TabList.Name = "tablist"
415
window.TabList.BackgroundTransparency = 1
416
window.TabList.Position = UDim2.fromOffset(0, window.TopBar.AbsoluteSize.Y / 2 + 1)
417
window.TabList.Size = UDim2.fromOffset(window.size.X.Offset, window.TopBar.AbsoluteSize.Y / 2)
418
window.TabList.BorderSizePixel = 0
419
window.TabList.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
420
421
window.TabList.InputBegan:Connect(dragstart)
422
window.TabList.InputChanged:Connect(dragend)
423
424
window.BlackLine = Instance.new("Frame", window.Frame)
425
window.BlackLine.Name = "blackline"
426
window.BlackLine.Size = UDim2.fromOffset(window.size.X.Offset, 1)
427
window.BlackLine.BorderSizePixel = 0
428
window.BlackLine.ZIndex = 9
429
window.BlackLine.BackgroundColor3 = window.theme.outlinecolor2
430
window.BlackLine.Position = UDim2.fromOffset(0, window.TopBar.AbsoluteSize.Y)
431
updateevent.Event:Connect(function(theme)
432
window.BlackLine.BackgroundColor3 = theme.outlinecolor2
433
end)
434
435
window.BackgroundImage = Instance.new("ImageLabel", window.Frame)
436
window.BackgroundImage.Name = "background"
437
window.BackgroundImage.BorderSizePixel = 0
438
window.BackgroundImage.ScaleType = Enum.ScaleType.Tile
439
window.BackgroundImage.Position = window.BlackLine.Position + UDim2.fromOffset(0, 1)
440
window.BackgroundImage.Size = UDim2.fromOffset(window.size.X.Offset, window.size.Y.Offset - window.TopBar.AbsoluteSize.Y - 1)
441
window.BackgroundImage.Image = window.theme.background or ""
442
window.BackgroundImage.ImageTransparency = window.BackgroundImage.Image ~= "" and 0 or 1
443
window.BackgroundImage.ImageColor3 = Color3.new()
444
window.BackgroundImage.BackgroundColor3 = window.theme.backgroundcolor
445
window.BackgroundImage.TileSize = UDim2.new(0, window.theme.tilesize, 0, window.theme.tilesize)
446
updateevent.Event:Connect(function(theme)
447
window.BackgroundImage.Image = theme.background or ""
448
window.BackgroundImage.ImageTransparency = window.BackgroundImage.Image ~= "" and 0 or 1
449
window.BackgroundImage.BackgroundColor3 = theme.backgroundcolor
450
window.BackgroundImage.TileSize = UDim2.new(0, theme.tilesize, 0, theme.tilesize)
451
end)
452
453
window.Line = Instance.new("Frame", window.Frame)
454
window.Line.Name = "line"
455
window.Line.Position = UDim2.fromOffset(0, 0)
456
window.Line.Size = UDim2.fromOffset(60, 1)
457
window.Line.BorderSizePixel = 0
458
window.Line.BackgroundColor3 = window.theme.accentcolor
459
updateevent.Event:Connect(function(theme)
460
window.Line.BackgroundColor3 = theme.accentcolor
461
end)
462
463
window.ListLayout = Instance.new("UIListLayout", window.TabList)
464
window.ListLayout.FillDirection = Enum.FillDirection.Horizontal
465
window.ListLayout.SortOrder = Enum.SortOrder.LayoutOrder
466
467
window.OpenedColorPickers = { }
468
window.Tabs = { }
469
470
function window:CreateTab(name)
471
local tab = { }
472
tab.name = name or ""
473
474
local textservice = game:GetService("TextService")
475
local size = textservice:GetTextSize(tab.name, window.theme.fontsize, window.theme.font, Vector2.new(200,300))
476
477
tab.TabButton = Instance.new("TextButton", window.TabList)
478
tab.TabButton.TextColor3 = window.theme.tabstextcolor
479
tab.TabButton.Text = tab.name
480
tab.TabButton.AutoButtonColor = false
481
tab.TabButton.Font = window.theme.font
482
tab.TabButton.TextYAlignment = Enum.TextYAlignment.Center
483
tab.TabButton.BackgroundTransparency = 1
484
tab.TabButton.BorderSizePixel = 0
485
tab.TabButton.Size = UDim2.fromOffset(size.X + 15, window.TabList.AbsoluteSize.Y - 1)
486
tab.TabButton.Name = tab.name
487
tab.TabButton.TextSize = window.theme.fontsize
488
updateevent.Event:Connect(function(theme)
489
local size = textservice:GetTextSize(tab.name, theme.fontsize, theme.font, Vector2.new(200,300))
490
tab.TabButton.TextColor3 = tab.TabButton.Name == "SelectedTab" and theme.accentcolor or theme.tabstextcolor
491
tab.TabButton.Font = theme.font
492
tab.TabButton.Size = UDim2.fromOffset(size.X + 15, window.TabList.AbsoluteSize.Y - 1)
493
tab.TabButton.TextSize = theme.fontsize
494
end)
495
496
tab.Left = Instance.new("ScrollingFrame", window.Frame)
497
tab.Left.Name = "leftside"
498
tab.Left.BorderSizePixel = 0
499
tab.Left.Size = UDim2.fromOffset(window.size.X.Offset / 2, window.size.Y.Offset - (window.TopBar.AbsoluteSize.Y + 1))
500
tab.Left.BackgroundTransparency = 1
501
tab.Left.Visible = false
502
tab.Left.ScrollBarThickness = 0
503
tab.Left.ScrollingDirection = "Y"
504
tab.Left.Position = window.BlackLine.Position + UDim2.fromOffset(0, 1)
505
506
tab.LeftListLayout = Instance.new("UIListLayout", tab.Left)
507
tab.LeftListLayout.FillDirection = Enum.FillDirection.Vertical
508
tab.LeftListLayout.SortOrder = Enum.SortOrder.LayoutOrder
509
tab.LeftListLayout.Padding = UDim.new(0, 12)
510
511
tab.LeftListPadding = Instance.new("UIPadding", tab.Left)
512
tab.LeftListPadding.PaddingTop = UDim.new(0, 12)
513
tab.LeftListPadding.PaddingLeft = UDim.new(0, 12)
514
tab.LeftListPadding.PaddingRight = UDim.new(0, 12)
515
516
tab.Right = Instance.new("ScrollingFrame", window.Frame)
517
tab.Right.Name = "rightside"
518
tab.Right.ScrollBarThickness = 0
519
tab.Right.ScrollingDirection = "Y"
520
tab.Right.Visible = false
521
tab.Right.BorderSizePixel = 0
522
tab.Right.Size = UDim2.fromOffset(window.size.X.Offset / 2, window.size.Y.Offset - (window.TopBar.AbsoluteSize.Y + 1))
523
tab.Right.BackgroundTransparency = 1
524
tab.Right.Position = tab.Left.Position + UDim2.fromOffset(tab.Left.AbsoluteSize.X, 0)
525
526
tab.RightListLayout = Instance.new("UIListLayout", tab.Right)
527
tab.RightListLayout.FillDirection = Enum.FillDirection.Vertical
528
tab.RightListLayout.SortOrder = Enum.SortOrder.LayoutOrder
529
tab.RightListLayout.Padding = UDim.new(0, 12)
530
531
tab.RightListPadding = Instance.new("UIPadding", tab.Right)
532
tab.RightListPadding.PaddingTop = UDim.new(0, 12)
533
tab.RightListPadding.PaddingLeft = UDim.new(0, 6)
534
tab.RightListPadding.PaddingRight = UDim.new(0, 12)
535
536
local block = false
537
function tab:SelectTab()
538
repeat
539
wait()
540
until block == false
541
542
block = true
543
for i,v in pairs(window.Tabs) do
544
if v ~= tab then
545
v.TabButton.TextColor3 = Color3.fromRGB(230, 230, 230)
546
v.TabButton.Name = "Tab"
547
v.Left.Visible = false
548
v.Right.Visible = false
549
end
550
end
551
552
tab.TabButton.TextColor3 = window.theme.accentcolor
553
tab.TabButton.Name = "SelectedTab"
554
tab.Right.Visible = true
555
tab.Left.Visible = true
556
window.Line:TweenSizeAndPosition(UDim2.fromOffset(size.X + 15, 1), UDim2.new(0, (tab.TabButton.AbsolutePosition.X - window.Frame.AbsolutePosition.X), 0, 0) + (window.BlackLine.Position - UDim2.fromOffset(0, 1)), Enum.EasingDirection.In, Enum.EasingStyle.Sine, 0.15)
557
wait(0.2)
558
block = false
559
end
560
561
if #window.Tabs == 0 then
562
tab:SelectTab()
563
end
564
565
tab.TabButton.MouseButton1Down:Connect(function()
566
tab:SelectTab()
567
end)
568
569
tab.SectorsLeft = { }
570
tab.SectorsRight = { }
571
572
function tab:CreateSector(name,side)
573
local sector = { }
574
sector.name = name or ""
575
sector.side = side:lower() or "left"
576
577
sector.Main = Instance.new("Frame", sector.side == "left" and tab.Left or tab.Right)
578
sector.Main.Name = sector.name:gsub(" ", "") .. "Sector"
579
sector.Main.BorderSizePixel = 0
580
sector.Main.ZIndex = 4
581
sector.Main.Size = UDim2.fromOffset(window.size.X.Offset / 2 - 17, 20)
582
sector.Main.BackgroundColor3 = window.theme.sectorcolor
583
--sector.Main.Position = sector.side == "left" and UDim2.new(0, 11, 0, 12) or UDim2.new(0, window.size.X.Offset - sector.Main.AbsoluteSize.X - 11, 0, 12)
584
updateevent.Event:Connect(function(theme)
585
sector.Main.BackgroundColor3 = theme.sectorcolor
586
end)
587
588
sector.Line = Instance.new("Frame", sector.Main)
589
sector.Line.Name = "line"
590
sector.Line.ZIndex = 4
591
sector.Line.Size = UDim2.fromOffset(sector.Main.Size.X.Offset + 4, 1)
592
sector.Line.BorderSizePixel = 0
593
sector.Line.Position = UDim2.fromOffset(-2, -2)
594
sector.Line.BackgroundColor3 = window.theme.accentcolor
595
updateevent.Event:Connect(function(theme)
596
sector.Line.BackgroundColor3 = theme.accentcolor
597
end)
598
599
sector.BlackOutline = Instance.new("Frame", sector.Main)
600
sector.BlackOutline.Name = "outline"
601
sector.BlackOutline.ZIndex = 3
602
sector.BlackOutline.Size = sector.Main.Size + UDim2.fromOffset(2, 2)
603
sector.BlackOutline.BorderSizePixel = 0
604
sector.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
605
sector.BlackOutline.Position = UDim2.fromOffset(-1, -1)
606
sector.Main:GetPropertyChangedSignal("Size"):Connect(function()
607
sector.BlackOutline.Size = sector.Main.Size + UDim2.fromOffset(2, 2)
608
end)
609
updateevent.Event:Connect(function(theme)
610
sector.BlackOutline.BackgroundColor3 = theme.outlinecolor2
611
end)
612
613
614
sector.Outline = Instance.new("Frame", sector.Main)
615
sector.Outline.Name = "outline"
616
sector.Outline.ZIndex = 2
617
sector.Outline.Size = sector.Main.Size + UDim2.fromOffset(4, 4)
618
sector.Outline.BorderSizePixel = 0
619
sector.Outline.BackgroundColor3 = window.theme.outlinecolor
620
sector.Outline.Position = UDim2.fromOffset(-2, -2)
621
sector.Main:GetPropertyChangedSignal("Size"):Connect(function()
622
sector.Outline.Size = sector.Main.Size + UDim2.fromOffset(4, 4)
623
end)
624
updateevent.Event:Connect(function(theme)
625
sector.Outline.BackgroundColor3 = theme.outlinecolor
626
end)
627
628
sector.BlackOutline2 = Instance.new("Frame", sector.Main)
629
sector.BlackOutline2.Name = "outline"
630
sector.BlackOutline2.ZIndex = 1
631
sector.BlackOutline2.Size = sector.Main.Size + UDim2.fromOffset(6, 6)
632
sector.BlackOutline2.BorderSizePixel = 0
633
sector.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
634
sector.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
635
sector.Main:GetPropertyChangedSignal("Size"):Connect(function()
636
sector.BlackOutline2.Size = sector.Main.Size + UDim2.fromOffset(6, 6)
637
end)
638
updateevent.Event:Connect(function(theme)
639
sector.BlackOutline2.BackgroundColor3 = theme.outlinecolor2
640
end)
641
642
local size = textservice:GetTextSize(sector.name, 15, window.theme.font, Vector2.new(2000, 2000))
643
sector.Label = Instance.new("TextLabel", sector.Main)
644
sector.Label.AnchorPoint = Vector2.new(0,0.5)
645
sector.Label.Position = UDim2.fromOffset(12, -1)
646
sector.Label.Size = UDim2.fromOffset(math.clamp(textservice:GetTextSize(sector.name, 15, window.theme.font, Vector2.new(200,300)).X + 13, 0, sector.Main.Size.X.Offset), size.Y)
647
sector.Label.BackgroundTransparency = 1
648
sector.Label.BorderSizePixel = 0
649
sector.Label.ZIndex = 6
650
sector.Label.Text = sector.name
651
sector.Label.TextColor3 = Color3.new(1,1,2552/255)
652
sector.Label.TextStrokeTransparency = 1
653
sector.Label.Font = window.theme.font
654
sector.Label.TextSize = 15
655
updateevent.Event:Connect(function(theme)
656
local size = textservice:GetTextSize(sector.name, 15, theme.font, Vector2.new(2000, 2000))
657
sector.Label.Size = UDim2.fromOffset(math.clamp(textservice:GetTextSize(sector.name, 15, theme.font, Vector2.new(200,300)).X + 13, 0, sector.Main.Size.X.Offset), size.Y)
658
sector.Label.Font = theme.font
659
end)
660
661
sector.LabelBackFrame = Instance.new("Frame", sector.Main)
662
sector.LabelBackFrame.Name = "labelframe"
663
sector.LabelBackFrame.ZIndex = 5
664
sector.LabelBackFrame.Size = UDim2.fromOffset(sector.Label.Size.X.Offset, 10)
665
sector.LabelBackFrame.BorderSizePixel = 0
666
sector.LabelBackFrame.BackgroundColor3 = Color3.fromRGB(30, 30, 30)
667
sector.LabelBackFrame.Position = UDim2.fromOffset(sector.Label.Position.X.Offset, sector.BlackOutline2.Position.Y.Offset)
668
669
sector.Items = Instance.new("Frame", sector.Main)
670
sector.Items.Name = "items"
671
sector.Items.ZIndex = 2
672
sector.Items.BackgroundTransparency = 1
673
sector.Items.Size = UDim2.fromOffset(170, 140)
674
sector.Items.AutomaticSize = Enum.AutomaticSize.Y
675
sector.Items.BorderSizePixel = 0
676
677
sector.ListLayout = Instance.new("UIListLayout", sector.Items)
678
sector.ListLayout.FillDirection = Enum.FillDirection.Vertical
679
sector.ListLayout.SortOrder = Enum.SortOrder.LayoutOrder
680
sector.ListLayout.Padding = UDim.new(0, 12)
681
682
sector.ListPadding = Instance.new("UIPadding", sector.Items)
683
sector.ListPadding.PaddingTop = UDim.new(0, 15)
684
sector.ListPadding.PaddingLeft = UDim.new(0, 6)
685
sector.ListPadding.PaddingRight = UDim.new(0, 6)
686
687
table.insert(sector.side:lower() == "left" and tab.SectorsLeft or tab.SectorsRight, sector)
688
689
function sector:FixSize()
690
sector.Main.Size = UDim2.fromOffset(window.size.X.Offset / 2 - 17, sector.ListLayout.AbsoluteContentSize.Y + 22)
691
local sizeleft, sizeright = 0, 0
692
for i,v in pairs(tab.SectorsLeft) do
693
sizeleft = sizeleft + v.Main.AbsoluteSize.Y
694
end
695
for i,v in pairs(tab.SectorsRight) do
696
sizeright = sizeright + v.Main.AbsoluteSize.Y
697
end
698
699
tab.Left.CanvasSize = UDim2.fromOffset(tab.Left.AbsoluteSize.X, sizeleft + ((#tab.SectorsLeft - 1) * tab.LeftListPadding.PaddingTop.Offset) + 20)
700
tab.Right.CanvasSize = UDim2.fromOffset(tab.Right.AbsoluteSize.X, sizeright + ((#tab.SectorsRight - 1) * tab.RightListPadding.PaddingTop.Offset) + 20)
701
end
702
703
function sector:AddButton(text, callback)
704
local button = { }
705
button.text = text or ""
706
button.callback = callback or function() end
707
708
button.Main = Instance.new("TextButton", sector.Items)
709
button.Main.BorderSizePixel = 0
710
button.Main.Text = ""
711
button.Main.AutoButtonColor = false
712
button.Main.Name = "button"
713
button.Main.ZIndex = 5
714
button.Main.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 14)
715
button.Main.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
716
717
button.Gradient = Instance.new("UIGradient", button.Main)
718
button.Gradient.Rotation = 90
719
button.Gradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, window.theme.buttoncolor), ColorSequenceKeypoint.new(1.00, window.theme.buttoncolor2) })
720
updateevent.Event:Connect(function(theme)
721
button.Gradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, theme.buttoncolor), ColorSequenceKeypoint.new(1.00, theme.buttoncolor2) })
722
end)
723
724
button.BlackOutline2 = Instance.new("Frame", button.Main)
725
button.BlackOutline2.Name = "blackline"
726
button.BlackOutline2.ZIndex = 4
727
button.BlackOutline2.Size = button.Main.Size + UDim2.fromOffset(6, 6)
728
button.BlackOutline2.BorderSizePixel = 0
729
button.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
730
button.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
731
updateevent.Event:Connect(function(theme)
732
button.BlackOutline2.BackgroundColor3 = theme.outlinecolor2
733
end)
734
735
button.Outline = Instance.new("Frame", button.Main)
736
button.Outline.Name = "blackline"
737
button.Outline.ZIndex = 4
738
button.Outline.Size = button.Main.Size + UDim2.fromOffset(4, 4)
739
button.Outline.BorderSizePixel = 0
740
button.Outline.BackgroundColor3 = window.theme.outlinecolor
741
button.Outline.Position = UDim2.fromOffset(-2, -2)
742
updateevent.Event:Connect(function(theme)
743
button.Outline.BackgroundColor3 = theme.outlinecolor
744
end)
745
746
button.BlackOutline = Instance.new("Frame", button.Main)
747
button.BlackOutline.Name = "blackline"
748
button.BlackOutline.ZIndex = 4
749
button.BlackOutline.Size = button.Main.Size + UDim2.fromOffset(2, 2)
750
button.BlackOutline.BorderSizePixel = 0
751
button.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
752
button.BlackOutline.Position = UDim2.fromOffset(-1, -1)
753
updateevent.Event:Connect(function(theme)
754
button.BlackOutline.BackgroundColor3 = theme.outlinecolor2
755
end)
756
757
button.Label = Instance.new("TextLabel", button.Main)
758
button.Label.Name = "Label"
759
button.Label.BackgroundTransparency = 1
760
button.Label.Position = UDim2.new(0, -1, 0, 0)
761
button.Label.ZIndex = 5
762
button.Label.Size = button.Main.Size
763
button.Label.Font = window.theme.font
764
button.Label.Text = button.text
765
button.Label.TextColor3 = window.theme.itemscolor2
766
button.Label.TextSize = 15
767
button.Label.TextStrokeTransparency = 1
768
button.Label.TextXAlignment = Enum.TextXAlignment.Center
769
button.Main.MouseButton1Down:Connect(button.callback)
770
updateevent.Event:Connect(function(theme)
771
button.Label.Font = theme.font
772
button.Label.TextColor3 = theme.itemscolor
773
end)
774
775
button.BlackOutline2.MouseEnter:Connect(function()
776
button.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
777
end)
778
779
button.BlackOutline2.MouseLeave:Connect(function()
780
button.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
781
end)
782
783
sector:FixSize()
784
return button
785
end
786
787
function sector:AddLabel(text)
788
local label = { }
789
790
label.Main = Instance.new("TextLabel", sector.Items)
791
label.Main.Name = "Label"
792
label.Main.BackgroundTransparency = 1
793
label.Main.Position = UDim2.new(0, -1, 0, 0)
794
label.Main.ZIndex = 4
795
label.Main.AutomaticSize = Enum.AutomaticSize.XY
796
label.Main.Font = window.theme.font
797
label.Main.Text = text
798
label.Main.TextColor3 = window.theme.itemscolor
799
label.Main.TextSize = 15
800
label.Main.TextStrokeTransparency = 1
801
label.Main.TextXAlignment = Enum.TextXAlignment.Left
802
updateevent.Event:Connect(function(theme)
803
label.Main.Font = theme.font
804
label.Main.TextColor3 = theme.itemscolor
805
end)
806
807
function label:Set(value)
808
label.Main.Text = value
809
end
810
811
sector:FixSize()
812
return label
813
end
814
815
function sector:AddToggle(text, default, callback, flag)
816
local toggle = { }
817
toggle.text = text or ""
818
toggle.default = default or false
819
toggle.callback = callback or function(value) end
820
toggle.flag = flag or text or ""
821
822
toggle.value = toggle.default
823
824
toggle.Main = Instance.new("TextButton", sector.Items)
825
toggle.Main.Name = "toggle"
826
toggle.Main.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
827
toggle.Main.BorderColor3 = window.theme.outlinecolor
828
toggle.Main.BorderSizePixel = 0
829
toggle.Main.Size = UDim2.fromOffset(8, 8)
830
toggle.Main.AutoButtonColor = false
831
toggle.Main.ZIndex = 5
832
toggle.Main.Font = Enum.Font.SourceSans
833
toggle.Main.Text = ""
834
toggle.Main.TextColor3 = Color3.fromRGB(0, 0, 0)
835
toggle.Main.TextSize = 15
836
updateevent.Event:Connect(function(theme)
837
toggle.Main.BorderColor3 = theme.outlinecolor
838
end)
839
840
toggle.BlackOutline2 = Instance.new("Frame", toggle.Main)
841
toggle.BlackOutline2.Name = "blackline"
842
toggle.BlackOutline2.ZIndex = 4
843
toggle.BlackOutline2.Size = toggle.Main.Size + UDim2.fromOffset(6, 6)
844
toggle.BlackOutline2.BorderSizePixel = 0
845
toggle.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
846
toggle.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
847
updateevent.Event:Connect(function(theme)
848
toggle.BlackOutline2.BackgroundColor3 = theme.outlinecolor2
849
end)
850
851
toggle.Outline = Instance.new("Frame", toggle.Main)
852
toggle.Outline.Name = "blackline"
853
toggle.Outline.ZIndex = 4
854
toggle.Outline.Size = toggle.Main.Size + UDim2.fromOffset(4, 4)
855
toggle.Outline.BorderSizePixel = 0
856
toggle.Outline.BackgroundColor3 = window.theme.outlinecolor
857
toggle.Outline.Position = UDim2.fromOffset(-2, -2)
858
updateevent.Event:Connect(function(theme)
859
toggle.Outline.BackgroundColor3 = theme.outlinecolor
860
end)
861
862
toggle.BlackOutline = Instance.new("Frame", toggle.Main)
863
toggle.BlackOutline.Name = "blackline"
864
toggle.BlackOutline.ZIndex = 4
865
toggle.BlackOutline.Size = toggle.Main.Size + UDim2.fromOffset(2, 2)
866
toggle.BlackOutline.BorderSizePixel = 0
867
toggle.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
868
toggle.BlackOutline.Position = UDim2.fromOffset(-1, -1)
869
updateevent.Event:Connect(function(theme)
870
toggle.BlackOutline.BackgroundColor3 = theme.outlinecolor2
871
end)
872
873
toggle.Gradient = Instance.new("UIGradient", toggle.Main)
874
toggle.Gradient.Rotation = (22.5 * 13)
875
toggle.Gradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, Color3.fromRGB(30, 30, 30)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(45, 45, 45)) })
876
877
toggle.Label = Instance.new("TextButton", toggle.Main)
878
toggle.Label.Name = "Label"
879
toggle.Label.AutoButtonColor = false
880
toggle.Label.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
881
toggle.Label.BackgroundTransparency = 1
882
toggle.Label.Position = UDim2.fromOffset(toggle.Main.AbsoluteSize.X + 10, -2)
883
toggle.Label.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 71, toggle.BlackOutline.Size.Y.Offset)
884
toggle.Label.Font = window.theme.font
885
toggle.Label.ZIndex = 5
886
toggle.Label.Text = toggle.text
887
toggle.Label.TextColor3 = window.theme.itemscolor
888
toggle.Label.TextSize = 15
889
toggle.Label.TextStrokeTransparency = 1
890
toggle.Label.TextXAlignment = Enum.TextXAlignment.Left
891
updateevent.Event:Connect(function(theme)
892
toggle.Label.Font = theme.font
893
toggle.Label.TextColor3 = toggle.value and window.theme.itemscolor2 or theme.itemscolor
894
end)
895
896
toggle.CheckedFrame = Instance.new("Frame", toggle.Main)
897
toggle.CheckedFrame.ZIndex = 5
898
toggle.CheckedFrame.BorderSizePixel = 0
899
toggle.CheckedFrame.BackgroundColor3 = Color3.fromRGB(255, 255, 255) -- Color3.fromRGB(204, 0, 102)
900
toggle.CheckedFrame.Size = toggle.Main.Size
901
902
toggle.Gradient2 = Instance.new("UIGradient", toggle.CheckedFrame)
903
toggle.Gradient2.Rotation = (22.5 * 13)
904
toggle.Gradient2.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, window.theme.accentcolor2), ColorSequenceKeypoint.new(1.00, window.theme.accentcolor) })
905
updateevent.Event:Connect(function(theme)
906
toggle.Gradient2.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, theme.accentcolor2), ColorSequenceKeypoint.new(1.00, theme.accentcolor) })
907
end)
908
909
toggle.Items = Instance.new("Frame", toggle.Main)
910
toggle.Items.Name = "\n"
911
toggle.Items.ZIndex = 4
912
toggle.Items.Size = UDim2.fromOffset(60, toggle.BlackOutline.AbsoluteSize.Y)
913
toggle.Items.BorderSizePixel = 0
914
toggle.Items.BackgroundTransparency = 1
915
toggle.Items.BackgroundColor3 = Color3.new(0, 0, 0)
916
toggle.Items.Position = UDim2.fromOffset(sector.Main.Size.X.Offset - 71, 0)
917
918
toggle.ListLayout = Instance.new("UIListLayout", toggle.Items)
919
toggle.ListLayout.FillDirection = Enum.FillDirection.Horizontal
920
toggle.ListLayout.HorizontalAlignment = Enum.HorizontalAlignment.Right
921
toggle.ListLayout.SortOrder = Enum.SortOrder.LayoutOrder
922
toggle.ListLayout.Padding = UDim.new(0.04, 6)
923
924
if toggle.flag and toggle.flag ~= "" then
925
library.flags[toggle.flag] = toggle.default or false
926
end
927
928
function toggle:Set(value)
929
if value then
930
toggle.Label.TextColor3 = window.theme.itemscolor2
931
else
932
toggle.Label.TextColor3 = window.theme.itemscolor
933
end
934
935
toggle.value = value
936
toggle.CheckedFrame.Visible = value
937
if toggle.flag and toggle.flag ~= "" then
938
library.flags[toggle.flag] = toggle.value
939
end
940
pcall(toggle.callback, value)
941
end
942
function toggle:Get()
943
return toggle.value
944
end
945
toggle:Set(toggle.default)
946
947
function toggle:AddKeybind(default, flag)
948
local keybind = { }
949
950
keybind.default = default or "None"
951
keybind.value = keybind.default
952
keybind.flag = flag or ( (toggle.text or "") .. tostring(#toggle.Items:GetChildren()))
953
954
local shorter_keycodes = {
955
["LeftShift"] = "LSHIFT",
956
["RightShift"] = "RSHIFT",
957
["LeftControl"] = "LCTRL",
958
["RightControl"] = "RCTRL",
959
["LeftAlt"] = "LALT",
960
["RightAlt"] = "RALT"
961
}
962
963
local text = keybind.default == "None" and "[None]" or "[" .. (shorter_keycodes[keybind.default.Name] or keybind.default.Name) .. "]"
964
local size = textservice:GetTextSize(text, 15, window.theme.font, Vector2.new(2000, 2000))
965
966
keybind.Main = Instance.new("TextButton", toggle.Items)
967
keybind.Main.Name = "keybind"
968
keybind.Main.BackgroundTransparency = 1
969
keybind.Main.BorderSizePixel = 0
970
keybind.Main.ZIndex = 5
971
keybind.Main.Size = UDim2.fromOffset(size.X + 2, size.Y - 7)
972
keybind.Main.Text = text
973
keybind.Main.Font = window.theme.font
974
keybind.Main.TextColor3 = Color3.fromRGB(136, 136, 136)
975
keybind.Main.TextSize = 15
976
keybind.Main.TextXAlignment = Enum.TextXAlignment.Right
977
keybind.Main.MouseButton1Down:Connect(function()
978
keybind.Main.Text = "[...]"
979
keybind.Main.TextColor3 = window.theme.accentcolor
980
end)
981
updateevent.Event:Connect(function(theme)
982
keybind.Main.Font = theme.font
983
if keybind.Main.Text == "[...]" then
984
keybind.Main.TextColor3 = theme.accentcolor
985
else
986
keybind.Main.TextColor3 = Color3.fromRGB(136, 136, 136)
987
end
988
end)
989
990
if keybind.flag and keybind.flag ~= "" then
991
library.flags[keybind.flag] = keybind.default
992
end
993
function keybind:Set(key)
994
if key == "None" then
995
keybind.Main.Text = "[" .. key .. "]"
996
keybind.value = key
997
if keybind.flag and keybind.flag ~= "" then
998
library.flags[keybind.flag] = key
999
end
1000
end
1001
keybind.Main.Text = "[" .. (shorter_keycodes[key.Name] or key.Name) .. "]"
1002
keybind.value = key
1003
if keybind.flag and keybind.flag ~= "" then
1004
library.flags[keybind.flag] = keybind.value
1005
end
1006
end
1007
1008
function keybind:Get()
1009
return keybind.value
1010
end
1011
1012
uis.InputBegan:Connect(function(input, gameProcessed)
1013
if not gameProcessed then
1014
if keybind.Main.Text == "[...]" then
1015
keybind.Main.TextColor3 = Color3.fromRGB(136, 136, 136)
1016
if input.UserInputType == Enum.UserInputType.Keyboard then
1017
keybind:Set(input.KeyCode)
1018
else
1019
keybind:Set("None")
1020
end
1021
else
1022
if keybind.value ~= "None" and input.KeyCode == keybind.value then
1023
toggle:Set(not toggle.CheckedFrame.Visible)
1024
end
1025
end
1026
end
1027
end)
1028
1029
table.insert(library.items, keybind)
1030
return keybind
1031
end
1032
1033
function toggle:AddDropdown(items, default, multichoice, callback, flag)
1034
local dropdown = { }
1035
1036
dropdown.defaultitems = items or { }
1037
dropdown.default = default
1038
dropdown.callback = callback or function() end
1039
dropdown.multichoice = multichoice or false
1040
dropdown.values = { }
1041
dropdown.flag = flag or ( (toggle.text or "") .. tostring(#(sector.Items:GetChildren())) .. "a")
1042
1043
dropdown.Main = Instance.new("TextButton", sector.Items)
1044
dropdown.Main.Name = "dropdown"
1045
dropdown.Main.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
1046
dropdown.Main.BorderSizePixel = 0
1047
dropdown.Main.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 16)
1048
dropdown.Main.Position = UDim2.fromOffset(0, 0)
1049
dropdown.Main.ZIndex = 5
1050
dropdown.Main.AutoButtonColor = false
1051
dropdown.Main.Font = window.theme.font
1052
dropdown.Main.Text = ""
1053
dropdown.Main.TextColor3 = Color3.fromRGB(255, 255, 255)
1054
dropdown.Main.TextSize = 15
1055
dropdown.Main.TextXAlignment = Enum.TextXAlignment.Left
1056
updateevent.Event:Connect(function(theme)
1057
dropdown.Main.Font = theme.font
1058
end)
1059
1060
dropdown.Gradient = Instance.new("UIGradient", dropdown.Main)
1061
dropdown.Gradient.Rotation = 90
1062
dropdown.Gradient.Color = ColorSequence.new{ColorSequenceKeypoint.new(0.00, Color3.fromRGB(49, 49, 49)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(39, 39, 39))}
1063
1064
dropdown.SelectedLabel = Instance.new("TextLabel", dropdown.Main)
1065
dropdown.SelectedLabel.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
1066
dropdown.SelectedLabel.BackgroundTransparency = 1
1067
dropdown.SelectedLabel.Position = UDim2.fromOffset(5, 2)
1068
dropdown.SelectedLabel.Size = UDim2.fromOffset(130, 13)
1069
dropdown.SelectedLabel.Font = window.theme.font
1070
dropdown.SelectedLabel.Text = toggle.text
1071
dropdown.SelectedLabel.ZIndex = 5
1072
dropdown.SelectedLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
1073
dropdown.SelectedLabel.TextSize = 15
1074
dropdown.SelectedLabel.TextStrokeTransparency = 1
1075
dropdown.SelectedLabel.TextXAlignment = Enum.TextXAlignment.Left
1076
updateevent.Event:Connect(function(theme)
1077
dropdown.SelectedLabel.Font = theme.font
1078
end)
1079
1080
dropdown.Nav = Instance.new("ImageButton", dropdown.Main)
1081
dropdown.Nav.Name = "navigation"
1082
dropdown.Nav.BackgroundTransparency = 1
1083
dropdown.Nav.LayoutOrder = 10
1084
dropdown.Nav.Position = UDim2.fromOffset(sector.Main.Size.X.Offset - 26, 5)
1085
dropdown.Nav.Rotation = 90
1086
dropdown.Nav.ZIndex = 5
1087
dropdown.Nav.Size = UDim2.fromOffset(8, 8)
1088
dropdown.Nav.Image = "rbxassetid://4918373417"
1089
dropdown.Nav.ImageColor3 = Color3.fromRGB(210, 210, 210)
1090
1091
dropdown.BlackOutline2 = Instance.new("Frame", dropdown.Main)
1092
dropdown.BlackOutline2.Name = "blackline"
1093
dropdown.BlackOutline2.ZIndex = 4
1094
dropdown.BlackOutline2.Size = dropdown.Main.Size + UDim2.fromOffset(6, 6)
1095
dropdown.BlackOutline2.BorderSizePixel = 0
1096
dropdown.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
1097
dropdown.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
1098
updateevent.Event:Connect(function(theme)
1099
dropdown.BlackOutline2.BackgroundColor3 = theme.outlinecolor2
1100
end)
1101
1102
dropdown.Outline = Instance.new("Frame", dropdown.Main)
1103
dropdown.Outline.Name = "blackline"
1104
dropdown.Outline.ZIndex = 4
1105
dropdown.Outline.Size = dropdown.Main.Size + UDim2.fromOffset(4, 4)
1106
dropdown.Outline.BorderSizePixel = 0
1107
dropdown.Outline.BackgroundColor3 = window.theme.outlinecolor
1108
dropdown.Outline.Position = UDim2.fromOffset(-2, -2)
1109
updateevent.Event:Connect(function(theme)
1110
dropdown.Outline.BackgroundColor3 = theme.outlinecolor
1111
end)
1112
1113
dropdown.BlackOutline = Instance.new("Frame", dropdown.Main)
1114
dropdown.BlackOutline.Name = "blackline444"
1115
dropdown.BlackOutline.ZIndex = 4
1116
dropdown.BlackOutline.Size = dropdown.Main.Size + UDim2.fromOffset(2, 2)
1117
dropdown.BlackOutline.BorderSizePixel = 0
1118
dropdown.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
1119
dropdown.BlackOutline.Position = UDim2.fromOffset(-1, -1)
1120
updateevent.Event:Connect(function(theme)
1121
dropdown.BlackOutline.BackgroundColor3 = theme.outlinecolor2
1122
end)
1123
1124
dropdown.ItemsFrame = Instance.new("ScrollingFrame", dropdown.Main)
1125
dropdown.ItemsFrame.Name = "itemsframe"
1126
dropdown.ItemsFrame.BorderSizePixel = 0
1127
dropdown.ItemsFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
1128
dropdown.ItemsFrame.Position = UDim2.fromOffset(0, dropdown.Main.Size.Y.Offset + 8)
1129
dropdown.ItemsFrame.ScrollBarThickness = 2
1130
dropdown.ItemsFrame.ZIndex = 8
1131
dropdown.ItemsFrame.ScrollingDirection = "Y"
1132
dropdown.ItemsFrame.Visible = false
1133
dropdown.ItemsFrame.Size = UDim2.new(0, 0, 0, 0)
1134
dropdown.ItemsFrame.CanvasSize = UDim2.fromOffset(dropdown.Main.AbsoluteSize.X, 0)
1135
1136
dropdown.ListLayout = Instance.new("UIListLayout", dropdown.ItemsFrame)
1137
dropdown.ListLayout.FillDirection = Enum.FillDirection.Vertical
1138
dropdown.ListLayout.SortOrder = Enum.SortOrder.LayoutOrder
1139
1140
dropdown.ListPadding = Instance.new("UIPadding", dropdown.ItemsFrame)
1141
dropdown.ListPadding.PaddingTop = UDim.new(0, 2)
1142
dropdown.ListPadding.PaddingBottom = UDim.new(0, 2)
1143
dropdown.ListPadding.PaddingLeft = UDim.new(0, 2)
1144
dropdown.ListPadding.PaddingRight = UDim.new(0, 2)
1145
1146
dropdown.BlackOutline2Items = Instance.new("Frame", dropdown.Main)
1147
dropdown.BlackOutline2Items.Name = "blackline3"
1148
dropdown.BlackOutline2Items.ZIndex = 7
1149
dropdown.BlackOutline2Items.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(6, 6)
1150
dropdown.BlackOutline2Items.BorderSizePixel = 0
1151
dropdown.BlackOutline2Items.BackgroundColor3 = window.theme.outlinecolor2
1152
dropdown.BlackOutline2Items.Position = dropdown.ItemsFrame.Position + UDim2.fromOffset(-3, -3)
1153
dropdown.BlackOutline2Items.Visible = false
1154
updateevent.Event:Connect(function(theme)
1155
dropdown.BlackOutline2Items.BackgroundColor3 = theme.outlinecolor2
1156
end)
1157
1158
dropdown.OutlineItems = Instance.new("Frame", dropdown.Main)
1159
dropdown.OutlineItems.Name = "blackline8"
1160
dropdown.OutlineItems.ZIndex = 7
1161
dropdown.OutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(4, 4)
1162
dropdown.OutlineItems.BorderSizePixel = 0
1163
dropdown.OutlineItems.BackgroundColor3 = window.theme.outlinecolor
1164
dropdown.OutlineItems.Position = dropdown.ItemsFrame.Position + UDim2.fromOffset(-2, -2)
1165
dropdown.OutlineItems.Visible = false
1166
updateevent.Event:Connect(function(theme)
1167
dropdown.OutlineItems.BackgroundColor3 = theme.outlinecolor
1168
end)
1169
1170
dropdown.BlackOutlineItems = Instance.new("Frame", dropdown.Main)
1171
dropdown.BlackOutlineItems.Name = "blackline3"
1172
dropdown.BlackOutlineItems.ZIndex = 7
1173
dropdown.BlackOutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(-2, -2)
1174
dropdown.BlackOutlineItems.BorderSizePixel = 0
1175
dropdown.BlackOutlineItems.BackgroundColor3 = window.theme.outlinecolor2
1176
dropdown.BlackOutlineItems.Position = dropdown.ItemsFrame.Position + UDim2.fromOffset(-1, -1)
1177
dropdown.BlackOutlineItems.Visible = false
1178
updateevent.Event:Connect(function(theme)
1179
dropdown.BlackOutlineItems.BackgroundColor3 = theme.outlinecolor2
1180
end)
1181
1182
dropdown.IgnoreBackButtons = Instance.new("TextButton", dropdown.Main)
1183
dropdown.IgnoreBackButtons.BackgroundTransparency = 1
1184
dropdown.IgnoreBackButtons.BorderSizePixel = 0
1185
dropdown.IgnoreBackButtons.Position = UDim2.fromOffset(0, dropdown.Main.Size.Y.Offset + 8)
1186
dropdown.IgnoreBackButtons.Size = UDim2.new(0, 0, 0, 0)
1187
dropdown.IgnoreBackButtons.ZIndex = 7
1188
dropdown.IgnoreBackButtons.Text = ""
1189
dropdown.IgnoreBackButtons.Visible = false
1190
dropdown.IgnoreBackButtons.AutoButtonColor = false
1191
1192
if dropdown.flag and dropdown.flag ~= "" then
1193
library.flags[dropdown.flag] = dropdown.multichoice and { dropdown.default or dropdown.defaultitems[1] or "" } or (dropdown.default or dropdown.defaultitems[1] or "")
1194
end
1195
1196
function dropdown:isSelected(item)
1197
for i, v in pairs(dropdown.values) do
1198
if v == item then
1199
return true
1200
end
1201
end
1202
return false
1203
end
1204
1205
function dropdown:updateText(text)
1206
if #text >= 27 then
1207
text = text:sub(1, 25) .. ".."
1208
end
1209
dropdown.SelectedLabel.Text = text
1210
end
1211
1212
dropdown.Changed = Instance.new("BindableEvent")
1213
function dropdown:Set(value)
1214
if type(value) == "table" then
1215
dropdown.values = value
1216
dropdown:updateText(table.concat(value, ", "))
1217
pcall(dropdown.callback, value)
1218
else
1219
dropdown:updateText(value)
1220
dropdown.values = { value }
1221
pcall(dropdown.callback, value)
1222
end
1223
1224
dropdown.Changed:Fire(value)
1225
if dropdown.flag and dropdown.flag ~= "" then
1226
library.flags[dropdown.flag] = dropdown.multichoice and dropdown.values or dropdown.values[1]
1227
end
1228
end
1229
1230
function dropdown:Get()
1231
return dropdown.multichoice and dropdown.values or dropdown.values[1]
1232
end
1233
1234
dropdown.items = { }
1235
function dropdown:Add(v)
1236
local Item = Instance.new("TextButton", dropdown.ItemsFrame)
1237
Item.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
1238
Item.TextColor3 = Color3.fromRGB(255, 255, 255)
1239
Item.BorderSizePixel = 0
1240
Item.Position = UDim2.fromOffset(0, 0)
1241
Item.Size = UDim2.fromOffset(dropdown.Main.Size.X.Offset - 4, 20)
1242
Item.ZIndex = 9
1243
Item.Text = v
1244
Item.Name = v
1245
Item.AutoButtonColor = false
1246
Item.Font = window.theme.font
1247
Item.TextSize = 15
1248
Item.TextXAlignment = Enum.TextXAlignment.Left
1249
Item.TextStrokeTransparency = 1
1250
dropdown.ItemsFrame.CanvasSize = dropdown.ItemsFrame.CanvasSize + UDim2.fromOffset(0, Item.AbsoluteSize.Y)
1251
1252
Item.MouseButton1Down:Connect(function()
1253
if dropdown.multichoice then
1254
if dropdown:isSelected(v) then
1255
for i2, v2 in pairs(dropdown.values) do
1256
if v2 == v then
1257
table.remove(dropdown.values, i2)
1258
end
1259
end
1260
dropdown:Set(dropdown.values)
1261
else
1262
table.insert(dropdown.values, v)
1263
dropdown:Set(dropdown.values)
1264
end
1265
1266
return
1267
else
1268
dropdown.Nav.Rotation = 90
1269
dropdown.ItemsFrame.Visible = false
1270
dropdown.ItemsFrame.Active = false
1271
dropdown.OutlineItems.Visible = false
1272
dropdown.BlackOutlineItems.Visible = false
1273
dropdown.BlackOutline2Items.Visible = false
1274
dropdown.IgnoreBackButtons.Visible = false
1275
dropdown.IgnoreBackButtons.Active = false
1276
end
1277
1278
dropdown:Set(v)
1279
return
1280
end)
1281
1282
runservice.RenderStepped:Connect(function()
1283
if dropdown.multichoice and dropdown:isSelected(v) or dropdown.values[1] == v then
1284
Item.BackgroundColor3 = Color3.fromRGB(64, 64, 64)
1285
Item.TextColor3 = window.theme.accentcolor
1286
Item.Text = " " .. v
1287
else
1288
Item.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
1289
Item.TextColor3 = Color3.fromRGB(255, 255, 255)
1290
Item.Text = v
1291
end
1292
end)
1293
1294
table.insert(dropdown.items, v)
1295
dropdown.ItemsFrame.Size = UDim2.fromOffset(dropdown.Main.Size.X.Offset, math.clamp(#dropdown.items * Item.AbsoluteSize.Y, 20, 156) + 4)
1296
dropdown.ItemsFrame.CanvasSize = UDim2.fromOffset(dropdown.ItemsFrame.AbsoluteSize.X, (#dropdown.items * Item.AbsoluteSize.Y) + 4)
1297
1298
dropdown.OutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(4, 4)
1299
dropdown.BlackOutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(2, 2)
1300
dropdown.BlackOutline2Items.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(6, 6)
1301
dropdown.IgnoreBackButtons.Size = dropdown.ItemsFrame.Size
1302
end
1303
1304
function dropdown:Remove(value)
1305
local item = dropdown.ItemsFrame:FindFirstChild(value)
1306
if item then
1307
for i,v in pairs(dropdown.items) do
1308
if v == value then
1309
table.remove(dropdown.items, i)
1310
end
1311
end
1312
1313
dropdown.ItemsFrame.Size = UDim2.fromOffset(dropdown.Main.Size.X.Offset, math.clamp(#dropdown.items * item.AbsoluteSize.Y, 20, 156) + 4)
1314
dropdown.ItemsFrame.CanvasSize = UDim2.fromOffset(dropdown.ItemsFrame.AbsoluteSize.X, (#dropdown.items * item.AbsoluteSize.Y) + 4)
1315
1316
dropdown.OutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(2, 2)
1317
dropdown.BlackOutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(4, 4)
1318
dropdown.BlackOutline2Items.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(6, 6)
1319
dropdown.IgnoreBackButtons.Size = dropdown.ItemsFrame.Size
1320
1321
item:Remove()
1322
end
1323
end
1324
1325
for i,v in pairs(dropdown.defaultitems) do
1326
dropdown:Add(v)
1327
end
1328
1329
if dropdown.default then
1330
dropdown:Set(dropdown.default)
1331
end
1332
1333
local MouseButton1Down = function()
1334
if dropdown.Nav.Rotation == 90 then
1335
tweenservice:Create(dropdown.Nav, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { Rotation = -90 }):Play()
1336
if dropdown.items and #dropdown.items ~= 0 then
1337
dropdown.ItemsFrame.ScrollingEnabled = true
1338
sector.Main.Parent.ScrollingEnabled = false
1339
dropdown.ItemsFrame.Visible = true
1340
dropdown.ItemsFrame.Active = true
1341
dropdown.IgnoreBackButtons.Visible = true
1342
dropdown.IgnoreBackButtons.Active = true
1343
dropdown.OutlineItems.Visible = true
1344
dropdown.BlackOutlineItems.Visible = true
1345
dropdown.BlackOutline2Items.Visible = true
1346
end
1347
else
1348
tweenservice:Create(dropdown.Nav, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { Rotation = 90 }):Play()
1349
dropdown.ItemsFrame.ScrollingEnabled = false
1350
sector.Main.Parent.ScrollingEnabled = true
1351
dropdown.ItemsFrame.Visible = false
1352
dropdown.ItemsFrame.Active = false
1353
dropdown.IgnoreBackButtons.Visible = false
1354
dropdown.IgnoreBackButtons.Active = false
1355
dropdown.OutlineItems.Visible = false
1356
dropdown.BlackOutlineItems.Visible = false
1357
dropdown.BlackOutline2Items.Visible = false
1358
end
1359
end
1360
1361
dropdown.Main.MouseButton1Down:Connect(MouseButton1Down)
1362
dropdown.Nav.MouseButton1Down:Connect(MouseButton1Down)
1363
1364
dropdown.BlackOutline2.MouseEnter:Connect(function()
1365
dropdown.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
1366
end)
1367
dropdown.BlackOutline2.MouseLeave:Connect(function()
1368
dropdown.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
1369
end)
1370
1371
sector:FixSize()
1372
table.insert(library.items, dropdown)
1373
return dropdown
1374
end
1375
1376
function toggle:AddTextbox(default, callback, flag)
1377
local textbox = { }
1378
textbox.callback = callback or function() end
1379
textbox.default = default
1380
textbox.value = ""
1381
textbox.flag = flag or ( (toggle.text or "") .. tostring(#(sector.Items:GetChildren())) .. "a")
1382
1383
textbox.Holder = Instance.new("Frame", sector.Items)
1384
textbox.Holder.Name = "holder"
1385
textbox.Holder.ZIndex = 5
1386
textbox.Holder.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 14)
1387
textbox.Holder.BorderSizePixel = 0
1388
textbox.Holder.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
1389
1390
textbox.Gradient = Instance.new("UIGradient", textbox.Holder)
1391
textbox.Gradient.Rotation = 90
1392
textbox.Gradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, Color3.fromRGB(49, 49, 49)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(39, 39, 39)) })
1393
1394
textbox.Main = Instance.new("TextBox", textbox.Holder)
1395
textbox.Main.PlaceholderText = ""
1396
textbox.Main.Text = ""
1397
textbox.Main.BackgroundTransparency = 1
1398
textbox.Main.Font = window.theme.font
1399
textbox.Main.Name = "textbox"
1400
textbox.Main.MultiLine = false
1401
textbox.Main.ClearTextOnFocus = false
1402
textbox.Main.ZIndex = 5
1403
textbox.Main.TextScaled = true
1404
textbox.Main.Size = textbox.Holder.Size
1405
textbox.Main.TextSize = 15
1406
textbox.Main.TextColor3 = Color3.fromRGB(255, 255, 255)
1407
textbox.Main.BorderSizePixel = 0
1408
textbox.Main.BackgroundColor3 = Color3.fromRGB(30, 30, 30)
1409
textbox.Main.TextXAlignment = Enum.TextXAlignment.Left
1410
1411
if textbox.flag and textbox.flag ~= "" then
1412
library.flags[textbox.flag] = textbox.default or ""
1413
end
1414
1415
function textbox:Set(text)
1416
textbox.value = text
1417
textbox.Main.Text = text
1418
if textbox.flag and textbox.flag ~= "" then
1419
library.flags[textbox.flag] = text
1420
end
1421
pcall(textbox.callback, text)
1422
end
1423
updateevent.Event:Connect(function(theme)
1424
textbox.Main.Font = theme.font
1425
end)
1426
1427
function textbox:Get()
1428
return textbox.value
1429
end
1430
1431
if textbox.default then
1432
textbox:Set(textbox.default)
1433
end
1434
1435
textbox.Main.FocusLost:Connect(function()
1436
textbox:Set(textbox.Main.Text)
1437
end)
1438
1439
textbox.BlackOutline2 = Instance.new("Frame", textbox.Main)
1440
textbox.BlackOutline2.Name = "blackline"
1441
textbox.BlackOutline2.ZIndex = 4
1442
textbox.BlackOutline2.Size = textbox.Main.Size + UDim2.fromOffset(6, 6)
1443
textbox.BlackOutline2.BorderSizePixel = 0
1444
textbox.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
1445
textbox.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
1446
updateevent.Event:Connect(function(theme)
1447
textbox.BlackOutline2.BackgroundColor3 = theme.outlinecolor2
1448
end)
1449
1450
textbox.Outline = Instance.new("Frame", textbox.Main)
1451
textbox.Outline.Name = "blackline"
1452
textbox.Outline.ZIndex = 4
1453
textbox.Outline.Size = textbox.Main.Size + UDim2.fromOffset(4, 4)
1454
textbox.Outline.BorderSizePixel = 0
1455
textbox.Outline.BackgroundColor3 = window.theme.outlinecolor
1456
textbox.Outline.Position = UDim2.fromOffset(-2, -2)
1457
updateevent.Event:Connect(function(theme)
1458
textbox.Outline.BackgroundColor3 = theme.outlinecolor
1459
end)
1460
1461
textbox.BlackOutline = Instance.new("Frame", textbox.Main)
1462
textbox.BlackOutline.Name = "blackline"
1463
textbox.BlackOutline.ZIndex = 4
1464
textbox.BlackOutline.Size = textbox.Main.Size + UDim2.fromOffset(2, 2)
1465
textbox.BlackOutline.BorderSizePixel = 0
1466
textbox.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
1467
textbox.BlackOutline.Position = UDim2.fromOffset(-1, -1)
1468
updateevent.Event:Connect(function(theme)
1469
textbox.BlackOutline.BackgroundColor3 = theme.outlinecolor2
1470
end)
1471
1472
textbox.BlackOutline2.MouseEnter:Connect(function()
1473
textbox.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
1474
end)
1475
textbox.BlackOutline2.MouseLeave:Connect(function()
1476
textbox.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
1477
end)
1478
1479
sector:FixSize()
1480
table.insert(library.items, textbox)
1481
return textbox
1482
end
1483
1484
function toggle:AddColorpicker(default, callback, flag)
1485
local colorpicker = { }
1486
1487
colorpicker.callback = callback or function() end
1488
colorpicker.default = default or Color3.fromRGB(255, 255, 255)
1489
colorpicker.value = colorpicker.default
1490
colorpicker.flag = flag or ( (toggle.text or "") .. tostring(#toggle.Items:GetChildren()))
1491
1492
colorpicker.Main = Instance.new("Frame", toggle.Items)
1493
colorpicker.Main.ZIndex = 6
1494
colorpicker.Main.BorderSizePixel = 0
1495
colorpicker.Main.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
1496
colorpicker.Main.Size = UDim2.fromOffset(16, 10)
1497
1498
colorpicker.Gradient = Instance.new("UIGradient", colorpicker.Main)
1499
colorpicker.Gradient.Rotation = 90
1500
1501
local clr = Color3.new(math.clamp(colorpicker.value.R / 1.7, 0, 1), math.clamp(colorpicker.value.G / 1.7, 0, 1), math.clamp(colorpicker.value.B / 1.7, 0, 1))
1502
colorpicker.Gradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, colorpicker.value), ColorSequenceKeypoint.new(1.00, clr) })
1503
1504
colorpicker.BlackOutline2 = Instance.new("Frame", colorpicker.Main)
1505
colorpicker.BlackOutline2.Name = "blackline"
1506
colorpicker.BlackOutline2.ZIndex = 4
1507
colorpicker.BlackOutline2.Size = colorpicker.Main.Size + UDim2.fromOffset(6, 6)
1508
colorpicker.BlackOutline2.BorderSizePixel = 0
1509
colorpicker.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
1510
colorpicker.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
1511
updateevent.Event:Connect(function(theme)
1512
if window.OpenedColorPickers[colorpicker.MainPicker] then
1513
colorpicker.BlackOutline2.BackgroundColor3 = theme.accentcolor
1514
else
1515
colorpicker.BlackOutline2.BackgroundColor3 = theme.outlinecolor2
1516
end
1517
end)
1518
1519
colorpicker.Outline = Instance.new("Frame", colorpicker.Main)
1520
colorpicker.Outline.Name = "blackline"
1521
colorpicker.Outline.ZIndex = 4
1522
colorpicker.Outline.Size = colorpicker.Main.Size + UDim2.fromOffset(4, 4)
1523
colorpicker.Outline.BorderSizePixel = 0
1524
colorpicker.Outline.BackgroundColor3 = window.theme.outlinecolor
1525
colorpicker.Outline.Position = UDim2.fromOffset(-2, -2)
1526
updateevent.Event:Connect(function(theme)
1527
colorpicker.Outline.BackgroundColor3 = theme.outlinecolor
1528
end)
1529
1530
colorpicker.BlackOutline = Instance.new("Frame", colorpicker.Main)
1531
colorpicker.BlackOutline.Name = "blackline"
1532
colorpicker.BlackOutline.ZIndex = 4
1533
colorpicker.BlackOutline.Size = colorpicker.Main.Size + UDim2.fromOffset(2, 2)
1534
colorpicker.BlackOutline.BorderSizePixel = 0
1535
colorpicker.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
1536
colorpicker.BlackOutline.Position = UDim2.fromOffset(-1, -1)
1537
updateevent.Event:Connect(function(theme)
1538
colorpicker.BlackOutline.BackgroundColor3 = theme.outlinecolor2
1539
end)
1540
1541
colorpicker.BlackOutline2.MouseEnter:Connect(function()
1542
colorpicker.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
1543
end)
1544
1545
colorpicker.BlackOutline2.MouseLeave:Connect(function()
1546
if not window.OpenedColorPickers[colorpicker.MainPicker] then
1547
colorpicker.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
1548
end
1549
end)
1550
1551
colorpicker.MainPicker = Instance.new("TextButton", colorpicker.Main)
1552
colorpicker.MainPicker.Name = "picker"
1553
colorpicker.MainPicker.ZIndex = 100
1554
colorpicker.MainPicker.Visible = false
1555
colorpicker.MainPicker.AutoButtonColor = false
1556
colorpicker.MainPicker.Text = ""
1557
window.OpenedColorPickers[colorpicker.MainPicker] = false
1558
colorpicker.MainPicker.Size = UDim2.fromOffset(180, 196)
1559
colorpicker.MainPicker.BorderSizePixel = 0
1560
colorpicker.MainPicker.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
1561
colorpicker.MainPicker.Rotation = 0.000000000000001
1562
colorpicker.MainPicker.Position = UDim2.fromOffset(-colorpicker.MainPicker.AbsoluteSize.X + colorpicker.Main.AbsoluteSize.X, 17)
1563
1564
colorpicker.BlackOutline3 = Instance.new("Frame", colorpicker.MainPicker)
1565
colorpicker.BlackOutline3.Name = "blackline"
1566
colorpicker.BlackOutline3.ZIndex = 98
1567
colorpicker.BlackOutline3.Size = colorpicker.MainPicker.Size + UDim2.fromOffset(6, 6)
1568
colorpicker.BlackOutline3.BorderSizePixel = 0
1569
colorpicker.BlackOutline3.BackgroundColor3 = window.theme.outlinecolor2
1570
colorpicker.BlackOutline3.Position = UDim2.fromOffset(-3, -3)
1571
updateevent.Event:Connect(function(theme)
1572
colorpicker.BlackOutline3.BackgroundColor3 = theme.outlinecolor2
1573
end)
1574
1575
colorpicker.Outline2 = Instance.new("Frame", colorpicker.MainPicker)
1576
colorpicker.Outline2.Name = "blackline"
1577
colorpicker.Outline2.ZIndex = 98
1578
colorpicker.Outline2.Size = colorpicker.MainPicker.Size + UDim2.fromOffset(4, 4)
1579
colorpicker.Outline2.BorderSizePixel = 0
1580
colorpicker.Outline2.BackgroundColor3 = window.theme.outlinecolor
1581
colorpicker.Outline2.Position = UDim2.fromOffset(-2, -2)
1582
updateevent.Event:Connect(function(theme)
1583
colorpicker.Outline2.BackgroundColor3 = theme.outlinecolor
1584
end)
1585
1586
colorpicker.BlackOutline3 = Instance.new("Frame", colorpicker.MainPicker)
1587
colorpicker.BlackOutline3.Name = "blackline"
1588
colorpicker.BlackOutline3.ZIndex = 98
1589
colorpicker.BlackOutline3.Size = colorpicker.MainPicker.Size + UDim2.fromOffset(2, 2)
1590
colorpicker.BlackOutline3.BorderSizePixel = 0
1591
colorpicker.BlackOutline3.BackgroundColor3 = window.theme.outlinecolor2
1592
colorpicker.BlackOutline3.Position = UDim2.fromOffset(-1, -1)
1593
updateevent.Event:Connect(function(theme)
1594
colorpicker.BlackOutline3.BackgroundColor3 = theme.outlinecolor2
1595
end)
1596
1597
colorpicker.hue = Instance.new("ImageLabel", colorpicker.MainPicker)
1598
colorpicker.hue.ZIndex = 101
1599
colorpicker.hue.Position = UDim2.new(0,3,0,3)
1600
colorpicker.hue.Size = UDim2.new(0,172,0,172)
1601
colorpicker.hue.Image = "rbxassetid://4155801252"
1602
colorpicker.hue.ScaleType = Enum.ScaleType.Stretch
1603
colorpicker.hue.BackgroundColor3 = Color3.new(1,0,0)
1604
colorpicker.hue.BorderColor3 = window.theme.outlinecolor2
1605
updateevent.Event:Connect(function(theme)
1606
colorpicker.hue.BorderColor3 = theme.outlinecolor2
1607
end)
1608
1609
colorpicker.hueselectorpointer = Instance.new("ImageLabel", colorpicker.MainPicker)
1610
colorpicker.hueselectorpointer.ZIndex = 101
1611
colorpicker.hueselectorpointer.BackgroundTransparency = 1
1612
colorpicker.hueselectorpointer.BorderSizePixel = 0
1613
colorpicker.hueselectorpointer.Position = UDim2.new(0, 0, 0, 0)
1614
colorpicker.hueselectorpointer.Size = UDim2.new(0, 7, 0, 7)
1615
colorpicker.hueselectorpointer.Image = "rbxassetid://6885856475"
1616
1617
colorpicker.selector = Instance.new("TextLabel", colorpicker.MainPicker)
1618
colorpicker.selector.ZIndex = 100
1619
colorpicker.selector.Position = UDim2.new(0,3,0,181)
1620
colorpicker.selector.Size = UDim2.new(0,173,0,10)
1621
colorpicker.selector.BackgroundColor3 = Color3.fromRGB(255,255,255)
1622
colorpicker.selector.BorderColor3 = window.theme.outlinecolor2
1623
colorpicker.selector.Text = ""
1624
updateevent.Event:Connect(function(theme)
1625
colorpicker.selector.BorderColor3 = theme.outlinecolor2
1626
end)
1627
1628
colorpicker.gradient = Instance.new("UIGradient", colorpicker.selector)
1629
colorpicker.gradient.Color = ColorSequence.new({
1630
ColorSequenceKeypoint.new(0, Color3.new(1,0,0)),
1631
ColorSequenceKeypoint.new(0.17, Color3.new(1,0,1)),
1632
ColorSequenceKeypoint.new(0.33,Color3.new(0,0,1)),
1633
ColorSequenceKeypoint.new(0.5,Color3.new(0,1,1)),
1634
ColorSequenceKeypoint.new(0.67, Color3.new(0,1,0)),
1635
ColorSequenceKeypoint.new(0.83, Color3.new(1,1,0)),
1636
ColorSequenceKeypoint.new(1, Color3.new(1,0,0))
1637
})
1638
1639
colorpicker.pointer = Instance.new("Frame", colorpicker.selector)
1640
colorpicker.pointer.ZIndex = 101
1641
colorpicker.pointer.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
1642
colorpicker.pointer.Position = UDim2.new(0,0,0,0)
1643
colorpicker.pointer.Size = UDim2.new(0,2,0,10)
1644
colorpicker.pointer.BorderColor3 = Color3.fromRGB(255, 255, 255)
1645
1646
if colorpicker.flag and colorpicker.flag ~= "" then
1647
library.flags[colorpicker.flag] = colorpicker.default
1648
end
1649
1650
function colorpicker:RefreshHue()
1651
local x = (mouse.X - colorpicker.hue.AbsolutePosition.X) / colorpicker.hue.AbsoluteSize.X
1652
local y = (mouse.Y - colorpicker.hue.AbsolutePosition.Y) / colorpicker.hue.AbsoluteSize.Y
1653
colorpicker.hueselectorpointer:TweenPosition(UDim2.new(math.clamp(x * colorpicker.hue.AbsoluteSize.X, 0.5, 0.952 * colorpicker.hue.AbsoluteSize.X) / colorpicker.hue.AbsoluteSize.X, 0, math.clamp(y * colorpicker.hue.AbsoluteSize.Y, 0.5, 0.885 * colorpicker.hue.AbsoluteSize.Y) / colorpicker.hue.AbsoluteSize.Y, 0), Enum.EasingDirection.In, Enum.EasingStyle.Sine, 0.05)
1654
colorpicker:Set(Color3.fromHSV(colorpicker.color, math.clamp(x * colorpicker.hue.AbsoluteSize.X, 0.5, 1 * colorpicker.hue.AbsoluteSize.X) / colorpicker.hue.AbsoluteSize.X, 1 - (math.clamp(y * colorpicker.hue.AbsoluteSize.Y, 0.5, 1 * colorpicker.hue.AbsoluteSize.Y) / colorpicker.hue.AbsoluteSize.Y)))
1655
end
1656
1657
function colorpicker:RefreshSelector()
1658
local pos = math.clamp((mouse.X - colorpicker.hue.AbsolutePosition.X) / colorpicker.hue.AbsoluteSize.X, 0, 1)
1659
colorpicker.color = 1 - pos
1660
colorpicker.pointer:TweenPosition(UDim2.new(pos, 0, 0, 0), Enum.EasingDirection.In, Enum.EasingStyle.Sine, 0.05)
1661
colorpicker.hue.BackgroundColor3 = Color3.fromHSV(1 - pos, 1, 1)
1662
1663
local x = (colorpicker.hueselectorpointer.AbsolutePosition.X - colorpicker.hue.AbsolutePosition.X) / colorpicker.hue.AbsoluteSize.X
1664
local y = (colorpicker.hueselectorpointer.AbsolutePosition.Y - colorpicker.hue.AbsolutePosition.Y) / colorpicker.hue.AbsoluteSize.Y
1665
colorpicker:Set(Color3.fromHSV(colorpicker.color, math.clamp(x * colorpicker.hue.AbsoluteSize.X, 0.5, 1 * colorpicker.hue.AbsoluteSize.X) / colorpicker.hue.AbsoluteSize.X, 1 - (math.clamp(y * colorpicker.hue.AbsoluteSize.Y, 0.5, 1 * colorpicker.hue.AbsoluteSize.Y) / colorpicker.hue.AbsoluteSize.Y)))
1666
end
1667
1668
function colorpicker:Set(value)
1669
local color = Color3.new(math.clamp(value.r, 0, 1), math.clamp(value.g, 0, 1), math.clamp(value.b, 0, 1))
1670
colorpicker.value = color
1671
if colorpicker.flag and colorpicker.flag ~= "" then
1672
library.flags[colorpicker.flag] = color
1673
end
1674
local clr = Color3.new(math.clamp(color.R / 1.7, 0, 1), math.clamp(color.G / 1.7, 0, 1), math.clamp(color.B / 1.7, 0, 1))
1675
colorpicker.Gradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, color), ColorSequenceKeypoint.new(1.00, clr) })
1676
pcall(colorpicker.callback, color)
1677
end
1678
1679
function colorpicker:Get(value)
1680
return colorpicker.value
1681
end
1682
colorpicker:Set(colorpicker.default)
1683
1684
local dragging_selector = false
1685
local dragging_hue = false
1686
1687
colorpicker.selector.InputBegan:Connect(function(input)
1688
if input.UserInputType == Enum.UserInputType.MouseButton1 then
1689
dragging_selector = true
1690
colorpicker:RefreshSelector()
1691
end
1692
end)
1693
1694
colorpicker.selector.InputEnded:Connect(function(input)
1695
if input.UserInputType == Enum.UserInputType.MouseButton1 then
1696
dragging_selector = false
1697
colorpicker:RefreshSelector()
1698
end
1699
end)
1700
1701
colorpicker.hue.InputBegan:Connect(function(input)
1702
if input.UserInputType == Enum.UserInputType.MouseButton1 then
1703
dragging_hue = true
1704
colorpicker:RefreshHue()
1705
end
1706
end)
1707
1708
colorpicker.hue.InputEnded:Connect(function(input)
1709
if input.UserInputType == Enum.UserInputType.MouseButton1 then
1710
dragging_hue = false
1711
colorpicker:RefreshHue()
1712
end
1713
end)
1714
1715
uis.InputChanged:Connect(function(input)
1716
if dragging_selector and input.UserInputType == Enum.UserInputType.MouseMovement then
1717
colorpicker:RefreshSelector()
1718
end
1719
if dragging_hue and input.UserInputType == Enum.UserInputType.MouseMovement then
1720
colorpicker:RefreshHue()
1721
end
1722
end)
1723
1724
local inputBegan = function(input)
1725
if input.UserInputType == Enum.UserInputType.MouseButton1 then
1726
for i,v in pairs(window.OpenedColorPickers) do
1727
if v and i ~= colorpicker.MainPicker then
1728
i.Visible = false
1729
window.OpenedColorPickers[i] = false
1730
end
1731
end
1732
1733
colorpicker.MainPicker.Visible = not colorpicker.MainPicker.Visible
1734
window.OpenedColorPickers[colorpicker.MainPicker] = colorpicker.MainPicker.Visible
1735
if window.OpenedColorPickers[colorpicker.MainPicker] then
1736
colorpicker.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
1737
else
1738
colorpicker.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
1739
end
1740
end
1741
end
1742
1743
colorpicker.Main.InputBegan:Connect(inputBegan)
1744
colorpicker.Outline.InputBegan:Connect(inputBegan)
1745
colorpicker.BlackOutline2.InputBegan:Connect(inputBegan)
1746
table.insert(library.items, colorpicker)
1747
return colorpicker
1748
end
1749
1750
function toggle:AddSlider(min, default, max, decimals, callback, flag)
1751
local slider = { }
1752
slider.text = text or ""
1753
slider.callback = callback or function(value) end
1754
slider.min = min or 0
1755
slider.max = max or 100
1756
slider.decimals = decimals or 1
1757
slider.default = default or slider.min
1758
slider.flag = flag or ( (toggle.text or "") .. tostring(#toggle.Items:GetChildren()))
1759
1760
slider.value = slider.default
1761
local dragging = false
1762
1763
slider.Main = Instance.new("TextButton", sector.Items)
1764
slider.Main.Name = "slider"
1765
slider.Main.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
1766
slider.Main.Position = UDim2.fromOffset(0, 0)
1767
slider.Main.BorderSizePixel = 0
1768
slider.Main.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 12)
1769
slider.Main.AutoButtonColor = false
1770
slider.Main.Text = ""
1771
slider.Main.ZIndex = 7
1772
1773
slider.InputLabel = Instance.new("TextLabel", slider.Main)
1774
slider.InputLabel.BackgroundTransparency = 1
1775
slider.InputLabel.Size = slider.Main.Size
1776
slider.InputLabel.Font = window.theme.font
1777
slider.InputLabel.Text = "0"
1778
slider.InputLabel.TextColor3 = Color3.fromRGB(240, 240, 240)
1779
slider.InputLabel.Position = slider.Main.Position
1780
slider.InputLabel.Selectable = false
1781
slider.InputLabel.TextSize = 15
1782
slider.InputLabel.ZIndex = 9
1783
slider.InputLabel.TextStrokeTransparency = 1
1784
slider.InputLabel.TextXAlignment = Enum.TextXAlignment.Center
1785
updateevent.Event:Connect(function(theme)
1786
slider.InputLabel.Font = theme.font
1787
slider.InputLabel.TextColor3 = theme.itemscolor
1788
end)
1789
1790
slider.BlackOutline2 = Instance.new("Frame", slider.Main)
1791
slider.BlackOutline2.Name = "blackline"
1792
slider.BlackOutline2.ZIndex = 4
1793
slider.BlackOutline2.Size = slider.Main.Size + UDim2.fromOffset(6, 6)
1794
slider.BlackOutline2.BorderSizePixel = 0
1795
slider.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
1796
slider.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
1797
updateevent.Event:Connect(function(theme)
1798
slider.BlackOutline2.BackgroundColor3 = theme.outlinecolor2
1799
end)
1800
1801
slider.Outline = Instance.new("Frame", slider.Main)
1802
slider.Outline.Name = "blackline"
1803
slider.Outline.ZIndex = 4
1804
slider.Outline.Size = slider.Main.Size + UDim2.fromOffset(4, 4)
1805
slider.Outline.BorderSizePixel = 0
1806
slider.Outline.BackgroundColor3 = window.theme.outlinecolor
1807
slider.Outline.Position = UDim2.fromOffset(-2, -2)
1808
updateevent.Event:Connect(function(theme)
1809
slider.Outline.BackgroundColor3 = theme.outlinecolor
1810
end)
1811
1812
slider.BlackOutline = Instance.new("Frame", slider.Main)
1813
slider.BlackOutline.Name = "blackline"
1814
slider.BlackOutline.ZIndex = 4
1815
slider.BlackOutline.Size = slider.Main.Size + UDim2.fromOffset(2, 2)
1816
slider.BlackOutline.BorderSizePixel = 0
1817
slider.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
1818
slider.BlackOutline.Position = UDim2.fromOffset(-1, -1)
1819
updateevent.Event:Connect(function(theme)
1820
slider.BlackOutline.BackgroundColor3 = theme.outlinecolor2
1821
end)
1822
1823
slider.Gradient = Instance.new("UIGradient", slider.Main)
1824
slider.Gradient.Rotation = 90
1825
slider.Gradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, Color3.fromRGB(49, 49, 49)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(41, 41, 41)) })
1826
1827
slider.SlideBar = Instance.new("Frame", slider.Main)
1828
slider.SlideBar.BackgroundColor3 = Color3.fromRGB(255, 255, 255) --Color3.fromRGB(204, 0, 102)
1829
slider.SlideBar.ZIndex = 8
1830
slider.SlideBar.BorderSizePixel = 0
1831
slider.SlideBar.Size = UDim2.fromOffset(0, slider.Main.Size.Y.Offset)
1832
1833
slider.Gradient2 = Instance.new("UIGradient", slider.SlideBar)
1834
slider.Gradient2.Rotation = 90
1835
slider.Gradient2.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, window.theme.accentcolor), ColorSequenceKeypoint.new(1.00, window.theme.accentcolor2) })
1836
updateevent.Event:Connect(function(theme)
1837
slider.Gradient2.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, theme.accentcolor), ColorSequenceKeypoint.new(1.00, theme.accentcolor2) })
1838
end)
1839
1840
slider.BlackOutline2.MouseEnter:Connect(function()
1841
slider.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
1842
end)
1843
slider.BlackOutline2.MouseLeave:Connect(function()
1844
slider.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
1845
end)
1846
1847
if slider.flag and slider.flag ~= "" then
1848
library.flags[slider.flag] = slider.default or slider.min or 0
1849
end
1850
1851
function slider:Get()
1852
return slider.value
1853
end
1854
1855
function slider:Set(value)
1856
slider.value = math.clamp(math.round(value * slider.decimals) / slider.decimals, slider.min, slider.max)
1857
local percent = 1 - ((slider.max - slider.value) / (slider.max - slider.min))
1858
if slider.flag and slider.flag ~= "" then
1859
library.flags[slider.flag] = slider.value
1860
end
1861
slider.SlideBar:TweenSize(UDim2.fromOffset(percent * slider.Main.AbsoluteSize.X, slider.Main.AbsoluteSize.Y), Enum.EasingDirection.In, Enum.EasingStyle.Sine, 0.05)
1862
slider.InputLabel.Text = slider.value
1863
pcall(slider.callback, slider.value)
1864
end
1865
slider:Set(slider.default)
1866
1867
function slider:Refresh()
1868
local mousePos = camera:WorldToViewportPoint(mouse.Hit.p)
1869
local percent = math.clamp(mousePos.X - slider.SlideBar.AbsolutePosition.X, 0, slider.Main.AbsoluteSize.X) / slider.Main.AbsoluteSize.X
1870
local value = math.floor((slider.min + (slider.max - slider.min) * percent) * slider.decimals) / slider.decimals
1871
value = math.clamp(value, slider.min, slider.max)
1872
slider:Set(value)
1873
end
1874
1875
slider.SlideBar.InputBegan:Connect(function(input)
1876
if input.UserInputType == Enum.UserInputType.MouseButton1 then
1877
dragging = true
1878
slider:Refresh()
1879
end
1880
end)
1881
1882
slider.SlideBar.InputEnded:Connect(function(input)
1883
if input.UserInputType == Enum.UserInputType.MouseButton1 then
1884
dragging = false
1885
end
1886
end)
1887
1888
slider.Main.InputBegan:Connect(function(input)
1889
if input.UserInputType == Enum.UserInputType.MouseButton1 then
1890
dragging = true
1891
slider:Refresh()
1892
end
1893
end)
1894
1895
slider.Main.InputEnded:Connect(function(input)
1896
if input.UserInputType == Enum.UserInputType.MouseButton1 then
1897
dragging = false
1898
end
1899
end)
1900
1901
uis.InputChanged:Connect(function(input)
1902
if dragging and input.UserInputType == Enum.UserInputType.MouseMovement then
1903
slider:Refresh()
1904
end
1905
end)
1906
1907
sector:FixSize()
1908
table.insert(library.items, slider)
1909
return slider
1910
end
1911
1912
toggle.Main.MouseButton1Down:Connect(function()
1913
toggle:Set(not toggle.CheckedFrame.Visible)
1914
end)
1915
toggle.Label.InputBegan:Connect(function(input)
1916
if input.UserInputType == Enum.UserInputType.MouseButton1 then
1917
toggle:Set(not toggle.CheckedFrame.Visible)
1918
end
1919
end)
1920
1921
local MouseEnter = function()
1922
toggle.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
1923
end
1924
local MouseLeave = function()
1925
toggle.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
1926
end
1927
1928
toggle.Label.MouseEnter:Connect(MouseEnter)
1929
toggle.Label.MouseLeave:Connect(MouseLeave)
1930
toggle.BlackOutline2.MouseEnter:Connect(MouseEnter)
1931
toggle.BlackOutline2.MouseLeave:Connect(MouseLeave)
1932
1933
sector:FixSize()
1934
table.insert(library.items, toggle)
1935
return toggle
1936
end
1937
1938
function sector:AddTextbox(text, default, callback, flag)
1939
local textbox = { }
1940
textbox.text = text or ""
1941
textbox.callback = callback or function() end
1942
textbox.default = default
1943
textbox.value = ""
1944
textbox.flag = flag or text or ""
1945
1946
textbox.Label = Instance.new("TextButton", sector.Items)
1947
textbox.Label.Name = "Label"
1948
textbox.Label.AutoButtonColor = false
1949
textbox.Label.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
1950
textbox.Label.BackgroundTransparency = 1
1951
textbox.Label.Position = UDim2.fromOffset(sector.Main.Size.X.Offset, 0)
1952
textbox.Label.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 0)
1953
textbox.Label.Font = window.theme.font
1954
textbox.Label.ZIndex = 5
1955
textbox.Label.Text = textbox.text
1956
textbox.Label.TextColor3 = window.theme.itemscolor
1957
textbox.Label.TextSize = 15
1958
textbox.Label.TextStrokeTransparency = 1
1959
textbox.Label.TextXAlignment = Enum.TextXAlignment.Left
1960
updateevent.Event:Connect(function(theme)
1961
textbox.Label.Font = theme.font
1962
end)
1963
1964
textbox.Holder = Instance.new("Frame", sector.Items)
1965
textbox.Holder.Name = "holder"
1966
textbox.Holder.ZIndex = 5
1967
textbox.Holder.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 14)
1968
textbox.Holder.BorderSizePixel = 0
1969
textbox.Holder.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
1970
1971
textbox.Gradient = Instance.new("UIGradient", textbox.Holder)
1972
textbox.Gradient.Rotation = 90
1973
textbox.Gradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, Color3.fromRGB(49, 49, 49)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(39, 39, 39)) })
1974
1975
textbox.Main = Instance.new("TextBox", textbox.Holder)
1976
textbox.Main.PlaceholderText = textbox.text
1977
textbox.Main.PlaceholderColor3 = Color3.fromRGB(190, 190, 190)
1978
textbox.Main.Text = ""
1979
textbox.Main.BackgroundTransparency = 1
1980
textbox.Main.Font = window.theme.font
1981
textbox.Main.Name = "textbox"
1982
textbox.Main.MultiLine = false
1983
textbox.Main.ClearTextOnFocus = false
1984
textbox.Main.ZIndex = 5
1985
textbox.Main.TextScaled = true
1986
textbox.Main.Size = textbox.Holder.Size
1987
textbox.Main.TextSize = 15
1988
textbox.Main.TextColor3 = Color3.fromRGB(255, 255, 255)
1989
textbox.Main.BorderSizePixel = 0
1990
textbox.Main.BackgroundColor3 = Color3.fromRGB(30, 30, 30)
1991
textbox.Main.TextXAlignment = Enum.TextXAlignment.Left
1992
1993
if textbox.flag and textbox.flag ~= "" then
1994
library.flags[textbox.flag] = textbox.default or ""
1995
end
1996
1997
function textbox:Set(text)
1998
textbox.value = text
1999
textbox.Main.Text = text
2000
if textbox.flag and textbox.flag ~= "" then
2001
library.flags[textbox.flag] = text
2002
end
2003
pcall(textbox.callback, text)
2004
end
2005
updateevent.Event:Connect(function(theme)
2006
textbox.Main.Font = theme.font
2007
end)
2008
2009
function textbox:Get()
2010
return textbox.value
2011
end
2012
2013
if textbox.default then
2014
textbox:Set(textbox.default)
2015
end
2016
2017
textbox.Main.FocusLost:Connect(function()
2018
textbox:Set(textbox.Main.Text)
2019
end)
2020
2021
textbox.BlackOutline2 = Instance.new("Frame", textbox.Main)
2022
textbox.BlackOutline2.Name = "blackline"
2023
textbox.BlackOutline2.ZIndex = 4
2024
textbox.BlackOutline2.Size = textbox.Main.Size + UDim2.fromOffset(6, 6)
2025
textbox.BlackOutline2.BorderSizePixel = 0
2026
textbox.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
2027
textbox.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
2028
updateevent.Event:Connect(function(theme)
2029
textbox.BlackOutline2.BackgroundColor3 = theme.outlinecolor2
2030
end)
2031
2032
textbox.Outline = Instance.new("Frame", textbox.Main)
2033
textbox.Outline.Name = "blackline"
2034
textbox.Outline.ZIndex = 4
2035
textbox.Outline.Size = textbox.Main.Size + UDim2.fromOffset(4, 4)
2036
textbox.Outline.BorderSizePixel = 0
2037
textbox.Outline.BackgroundColor3 = window.theme.outlinecolor
2038
textbox.Outline.Position = UDim2.fromOffset(-2, -2)
2039
updateevent.Event:Connect(function(theme)
2040
textbox.Outline.BackgroundColor3 = theme.outlinecolor
2041
end)
2042
2043
textbox.BlackOutline = Instance.new("Frame", textbox.Main)
2044
textbox.BlackOutline.Name = "blackline"
2045
textbox.BlackOutline.ZIndex = 4
2046
textbox.BlackOutline.Size = textbox.Main.Size + UDim2.fromOffset(2, 2)
2047
textbox.BlackOutline.BorderSizePixel = 0
2048
textbox.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
2049
textbox.BlackOutline.Position = UDim2.fromOffset(-1, -1)
2050
updateevent.Event:Connect(function(theme)
2051
textbox.BlackOutline.BackgroundColor3 = theme.outlinecolor2
2052
end)
2053
2054
textbox.BlackOutline2.MouseEnter:Connect(function()
2055
textbox.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
2056
end)
2057
textbox.BlackOutline2.MouseLeave:Connect(function()
2058
textbox.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
2059
end)
2060
2061
sector:FixSize()
2062
table.insert(library.items, textbox)
2063
return textbox
2064
end
2065
2066
function sector:AddSlider(text, min, default, max, decimals, callback, flag)
2067
local slider = { }
2068
slider.text = text or ""
2069
slider.callback = callback or function(value) end
2070
slider.min = min or 0
2071
slider.max = max or 100
2072
slider.decimals = decimals or 1
2073
slider.default = default or slider.min
2074
slider.flag = flag or text or ""
2075
2076
slider.value = slider.default
2077
local dragging = false
2078
2079
slider.MainBack = Instance.new("Frame", sector.Items)
2080
slider.MainBack.Name = "MainBack"
2081
slider.MainBack.ZIndex = 7
2082
slider.MainBack.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 25)
2083
slider.MainBack.BorderSizePixel = 0
2084
slider.MainBack.BackgroundTransparency = 1
2085
2086
slider.Label = Instance.new("TextLabel", slider.MainBack)
2087
slider.Label.BackgroundTransparency = 1
2088
slider.Label.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 6)
2089
slider.Label.Font = window.theme.font
2090
slider.Label.Text = slider.text .. ":"
2091
slider.Label.TextColor3 = window.theme.itemscolor
2092
slider.Label.Position = UDim2.fromOffset(0, 0)
2093
slider.Label.TextSize = 15
2094
slider.Label.ZIndex = 4
2095
slider.Label.TextStrokeTransparency = 1
2096
slider.Label.TextXAlignment = Enum.TextXAlignment.Left
2097
updateevent.Event:Connect(function(theme)
2098
slider.Label.Font = theme.font
2099
slider.Label.TextColor3 = theme.itemscolor
2100
end)
2101
2102
local size = textservice:GetTextSize(slider.Label.Text, slider.Label.TextSize, slider.Label.Font, Vector2.new(200,300))
2103
slider.InputLabel = Instance.new("TextBox", slider.MainBack)
2104
slider.InputLabel.BackgroundTransparency = 1
2105
slider.InputLabel.ClearTextOnFocus = false
2106
slider.InputLabel.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - size.X - 15, 12)
2107
slider.InputLabel.Font = window.theme.font
2108
slider.InputLabel.Text = "0"
2109
slider.InputLabel.TextColor3 = window.theme.itemscolor
2110
slider.InputLabel.Position = UDim2.fromOffset(size.X + 3, -3)
2111
slider.InputLabel.TextSize = 15
2112
slider.InputLabel.ZIndex = 4
2113
slider.InputLabel.TextStrokeTransparency = 1
2114
slider.InputLabel.TextXAlignment = Enum.TextXAlignment.Left
2115
updateevent.Event:Connect(function(theme)
2116
slider.InputLabel.Font = theme.font
2117
slider.InputLabel.TextColor3 = theme.itemscolor
2118
2119
local size = textservice:GetTextSize(slider.Label.Text, slider.Label.TextSize, slider.Label.Font, Vector2.new(200,300))
2120
slider.InputLabel.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - size.X - 15, 12)
2121
end)
2122
2123
slider.Main = Instance.new("TextButton", slider.MainBack)
2124
slider.Main.Name = "slider"
2125
slider.Main.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
2126
slider.Main.Position = UDim2.fromOffset(0, 15)
2127
slider.Main.BorderSizePixel = 0
2128
slider.Main.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 12)
2129
slider.Main.AutoButtonColor = false
2130
slider.Main.Text = ""
2131
slider.Main.ZIndex = 5
2132
2133
slider.BlackOutline2 = Instance.new("Frame", slider.Main)
2134
slider.BlackOutline2.Name = "blackline"
2135
slider.BlackOutline2.ZIndex = 4
2136
slider.BlackOutline2.Size = slider.Main.Size + UDim2.fromOffset(6, 6)
2137
slider.BlackOutline2.BorderSizePixel = 0
2138
slider.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
2139
slider.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
2140
updateevent.Event:Connect(function(theme)
2141
slider.BlackOutline2.BackgroundColor3 = theme.outlinecolor2
2142
end)
2143
2144
slider.Outline = Instance.new("Frame", slider.Main)
2145
slider.Outline.Name = "blackline"
2146
slider.Outline.ZIndex = 4
2147
slider.Outline.Size = slider.Main.Size + UDim2.fromOffset(4, 4)
2148
slider.Outline.BorderSizePixel = 0
2149
slider.Outline.BackgroundColor3 = window.theme.outlinecolor
2150
slider.Outline.Position = UDim2.fromOffset(-2, -2)
2151
updateevent.Event:Connect(function(theme)
2152
slider.Outline.BackgroundColor3 = theme.outlinecolor
2153
end)
2154
2155
slider.BlackOutline = Instance.new("Frame", slider.Main)
2156
slider.BlackOutline.Name = "blackline"
2157
slider.BlackOutline.ZIndex = 4
2158
slider.BlackOutline.Size = slider.Main.Size + UDim2.fromOffset(2, 2)
2159
slider.BlackOutline.BorderSizePixel = 0
2160
slider.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
2161
slider.BlackOutline.Position = UDim2.fromOffset(-1, -1)
2162
updateevent.Event:Connect(function(theme)
2163
slider.BlackOutline.BackgroundColor3 = theme.outlinecolor2
2164
end)
2165
2166
slider.Gradient = Instance.new("UIGradient", slider.Main)
2167
slider.Gradient.Rotation = 90
2168
slider.Gradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, Color3.fromRGB(49, 49, 49)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(41, 41, 41)) })
2169
2170
slider.SlideBar = Instance.new("Frame", slider.Main)
2171
slider.SlideBar.BackgroundColor3 = Color3.fromRGB(255, 255, 255) --Color3.fromRGB(204, 0, 102)
2172
slider.SlideBar.ZIndex = 5
2173
slider.SlideBar.BorderSizePixel = 0
2174
slider.SlideBar.Size = UDim2.fromOffset(0, slider.Main.Size.Y.Offset)
2175
2176
slider.Gradient2 = Instance.new("UIGradient", slider.SlideBar)
2177
slider.Gradient2.Rotation = 90
2178
slider.Gradient2.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, window.theme.accentcolor), ColorSequenceKeypoint.new(1.00, window.theme.accentcolor2) })
2179
updateevent.Event:Connect(function(theme)
2180
slider.Gradient2.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, theme.accentcolor), ColorSequenceKeypoint.new(1.00, theme.accentcolor2) })
2181
end)
2182
2183
slider.BlackOutline2.MouseEnter:Connect(function()
2184
slider.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
2185
end)
2186
slider.BlackOutline2.MouseLeave:Connect(function()
2187
slider.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
2188
end)
2189
2190
if slider.flag and slider.flag ~= "" then
2191
library.flags[slider.flag] = slider.default or slider.min or 0
2192
end
2193
2194
function slider:Get()
2195
return slider.value
2196
end
2197
2198
function slider:Set(value)
2199
slider.value = math.clamp(math.round(value * slider.decimals) / slider.decimals, slider.min, slider.max)
2200
local percent = 1 - ((slider.max - slider.value) / (slider.max - slider.min))
2201
if slider.flag and slider.flag ~= "" then
2202
library.flags[slider.flag] = slider.value
2203
end
2204
slider.SlideBar:TweenSize(UDim2.fromOffset(percent * slider.Main.AbsoluteSize.X, slider.Main.AbsoluteSize.Y), Enum.EasingDirection.In, Enum.EasingStyle.Sine, 0.05)
2205
slider.InputLabel.Text = slider.value
2206
pcall(slider.callback, slider.value)
2207
end
2208
slider:Set(slider.default)
2209
2210
slider.InputLabel.FocusLost:Connect(function(Return)
2211
if not Return then
2212
return
2213
end
2214
if (slider.InputLabel.Text:match("^%d+$")) then
2215
slider:Set(tonumber(slider.InputLabel.Text))
2216
else
2217
slider.InputLabel.Text = tostring(slider.value)
2218
end
2219
end)
2220
2221
function slider:Refresh()
2222
local mousePos = camera:WorldToViewportPoint(mouse.Hit.p)
2223
local percent = math.clamp(mousePos.X - slider.SlideBar.AbsolutePosition.X, 0, slider.Main.AbsoluteSize.X) / slider.Main.AbsoluteSize.X
2224
local value = math.floor((slider.min + (slider.max - slider.min) * percent) * slider.decimals) / slider.decimals
2225
value = math.clamp(value, slider.min, slider.max)
2226
slider:Set(value)
2227
end
2228
2229
slider.SlideBar.InputBegan:Connect(function(input)
2230
if input.UserInputType == Enum.UserInputType.MouseButton1 then
2231
dragging = true
2232
slider:Refresh()
2233
end
2234
end)
2235
2236
slider.SlideBar.InputEnded:Connect(function(input)
2237
if input.UserInputType == Enum.UserInputType.MouseButton1 then
2238
dragging = false
2239
end
2240
end)
2241
2242
slider.Main.InputBegan:Connect(function(input)
2243
if input.UserInputType == Enum.UserInputType.MouseButton1 then
2244
dragging = true
2245
slider:Refresh()
2246
end
2247
end)
2248
2249
slider.Main.InputEnded:Connect(function(input)
2250
if input.UserInputType == Enum.UserInputType.MouseButton1 then
2251
dragging = false
2252
end
2253
end)
2254
2255
uis.InputChanged:Connect(function(input)
2256
if dragging and input.UserInputType == Enum.UserInputType.MouseMovement then
2257
slider:Refresh()
2258
end
2259
end)
2260
2261
sector:FixSize()
2262
table.insert(library.items, slider)
2263
return slider
2264
end
2265
2266
function sector:AddColorpicker(text, default, callback, flag)
2267
local colorpicker = { }
2268
2269
colorpicker.text = text or ""
2270
colorpicker.callback = callback or function() end
2271
colorpicker.default = default or Color3.fromRGB(255, 255, 255)
2272
colorpicker.value = colorpicker.default
2273
colorpicker.flag = flag or text or ""
2274
2275
colorpicker.Label = Instance.new("TextLabel", sector.Items)
2276
colorpicker.Label.BackgroundTransparency = 1
2277
colorpicker.Label.Size = UDim2.fromOffset(156, 10)
2278
colorpicker.Label.ZIndex = 4
2279
colorpicker.Label.Font = window.theme.font
2280
colorpicker.Label.Text = colorpicker.text
2281
colorpicker.Label.TextColor3 = window.theme.itemscolor
2282
colorpicker.Label.TextSize = 15
2283
colorpicker.Label.TextStrokeTransparency = 1
2284
colorpicker.Label.TextXAlignment = Enum.TextXAlignment.Left
2285
updateevent.Event:Connect(function(theme)
2286
colorpicker.Label.Font = theme.font
2287
colorpicker.Label.TextColor3 = theme.itemscolor
2288
end)
2289
2290
colorpicker.Main = Instance.new("Frame", colorpicker.Label)
2291
colorpicker.Main.ZIndex = 6
2292
colorpicker.Main.BorderSizePixel = 0
2293
colorpicker.Main.Position = UDim2.fromOffset(sector.Main.Size.X.Offset - 29, 0)
2294
colorpicker.Main.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
2295
colorpicker.Main.Size = UDim2.fromOffset(16, 10)
2296
2297
colorpicker.Gradient = Instance.new("UIGradient", colorpicker.Main)
2298
colorpicker.Gradient.Rotation = 90
2299
2300
local clr = Color3.new(math.clamp(colorpicker.value.R / 1.7, 0, 1), math.clamp(colorpicker.value.G / 1.7, 0, 1), math.clamp(colorpicker.value.B / 1.7, 0, 1))
2301
colorpicker.Gradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, colorpicker.value), ColorSequenceKeypoint.new(1.00, clr) })
2302
2303
colorpicker.BlackOutline2 = Instance.new("Frame", colorpicker.Main)
2304
colorpicker.BlackOutline2.Name = "blackline"
2305
colorpicker.BlackOutline2.ZIndex = 4
2306
colorpicker.BlackOutline2.Size = colorpicker.Main.Size + UDim2.fromOffset(6, 6)
2307
colorpicker.BlackOutline2.BorderSizePixel = 0
2308
colorpicker.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
2309
colorpicker.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
2310
updateevent.Event:Connect(function(theme)
2311
colorpicker.BlackOutline2.BackgroundColor3 = window.OpenedColorPickers[colorpicker.MainPicker] and theme.accentcolor or theme.outlinecolor2
2312
end)
2313
2314
colorpicker.Outline = Instance.new("Frame", colorpicker.Main)
2315
colorpicker.Outline.Name = "blackline"
2316
colorpicker.Outline.ZIndex = 4
2317
colorpicker.Outline.Size = colorpicker.Main.Size + UDim2.fromOffset(4, 4)
2318
colorpicker.Outline.BorderSizePixel = 0
2319
colorpicker.Outline.BackgroundColor3 = window.theme.outlinecolor
2320
colorpicker.Outline.Position = UDim2.fromOffset(-2, -2)
2321
updateevent.Event:Connect(function(theme)
2322
colorpicker.Outline.BackgroundColor3 = theme.outlinecolor
2323
end)
2324
2325
colorpicker.BlackOutline = Instance.new("Frame", colorpicker.Main)
2326
colorpicker.BlackOutline.Name = "blackline"
2327
colorpicker.BlackOutline.ZIndex = 4
2328
colorpicker.BlackOutline.Size = colorpicker.Main.Size + UDim2.fromOffset(2, 2)
2329
colorpicker.BlackOutline.BorderSizePixel = 0
2330
colorpicker.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
2331
colorpicker.BlackOutline.Position = UDim2.fromOffset(-1, -1)
2332
updateevent.Event:Connect(function(theme)
2333
colorpicker.BlackOutline.BackgroundColor3 = theme.outlinecolor2
2334
end)
2335
2336
colorpicker.BlackOutline2.MouseEnter:Connect(function()
2337
colorpicker.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
2338
end)
2339
colorpicker.BlackOutline2.MouseLeave:Connect(function()
2340
if not window.OpenedColorPickers[colorpicker.MainPicker] then
2341
colorpicker.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
2342
end
2343
end)
2344
2345
colorpicker.MainPicker = Instance.new("TextButton", colorpicker.Main)
2346
colorpicker.MainPicker.Name = "picker"
2347
colorpicker.MainPicker.ZIndex = 100
2348
colorpicker.MainPicker.Visible = false
2349
colorpicker.MainPicker.AutoButtonColor = false
2350
colorpicker.MainPicker.Text = ""
2351
window.OpenedColorPickers[colorpicker.MainPicker] = false
2352
colorpicker.MainPicker.Size = UDim2.fromOffset(180, 196)
2353
colorpicker.MainPicker.BorderSizePixel = 0
2354
colorpicker.MainPicker.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
2355
colorpicker.MainPicker.Rotation = 0.000000000000001
2356
colorpicker.MainPicker.Position = UDim2.fromOffset(-colorpicker.MainPicker.AbsoluteSize.X + colorpicker.Main.AbsoluteSize.X, 15)
2357
2358
colorpicker.BlackOutline3 = Instance.new("Frame", colorpicker.MainPicker)
2359
colorpicker.BlackOutline3.Name = "blackline"
2360
colorpicker.BlackOutline3.ZIndex = 98
2361
colorpicker.BlackOutline3.Size = colorpicker.MainPicker.Size + UDim2.fromOffset(6, 6)
2362
colorpicker.BlackOutline3.BorderSizePixel = 0
2363
colorpicker.BlackOutline3.BackgroundColor3 = window.theme.outlinecolor2
2364
colorpicker.BlackOutline3.Position = UDim2.fromOffset(-3, -3)
2365
updateevent.Event:Connect(function(theme)
2366
colorpicker.BlackOutline3.BackgroundColor3 = theme.outlinecolor2
2367
end)
2368
2369
colorpicker.Outline2 = Instance.new("Frame", colorpicker.MainPicker)
2370
colorpicker.Outline2.Name = "blackline"
2371
colorpicker.Outline2.ZIndex = 98
2372
colorpicker.Outline2.Size = colorpicker.MainPicker.Size + UDim2.fromOffset(4, 4)
2373
colorpicker.Outline2.BorderSizePixel = 0
2374
colorpicker.Outline2.BackgroundColor3 = window.theme.outlinecolor
2375
colorpicker.Outline2.Position = UDim2.fromOffset(-2, -2)
2376
updateevent.Event:Connect(function(theme)
2377
colorpicker.Outline2.BackgroundColor3 = theme.outlinecolor
2378
end)
2379
2380
colorpicker.BlackOutline3 = Instance.new("Frame", colorpicker.MainPicker)
2381
colorpicker.BlackOutline3.Name = "blackline"
2382
colorpicker.BlackOutline3.ZIndex = 98
2383
colorpicker.BlackOutline3.Size = colorpicker.MainPicker.Size + UDim2.fromOffset(2, 2)
2384
colorpicker.BlackOutline3.BorderSizePixel = 0
2385
colorpicker.BlackOutline3.BackgroundColor3 = window.theme.outlinecolor2
2386
colorpicker.BlackOutline3.Position = UDim2.fromOffset(-1, -1)
2387
updateevent.Event:Connect(function(theme)
2388
colorpicker.BlackOutline3.BackgroundColor3 = theme.outlinecolor2
2389
end)
2390
2391
colorpicker.hue = Instance.new("ImageLabel", colorpicker.MainPicker)
2392
colorpicker.hue.ZIndex = 101
2393
colorpicker.hue.Position = UDim2.new(0,3,0,3)
2394
colorpicker.hue.Size = UDim2.new(0,172,0,172)
2395
colorpicker.hue.Image = "rbxassetid://4155801252"
2396
colorpicker.hue.ScaleType = Enum.ScaleType.Stretch
2397
colorpicker.hue.BackgroundColor3 = Color3.new(1,0,0)
2398
colorpicker.hue.BorderColor3 = window.theme.outlinecolor2
2399
updateevent.Event:Connect(function(theme)
2400
colorpicker.hue.BorderColor3 = theme.outlinecolor2
2401
end)
2402
2403
colorpicker.hueselectorpointer = Instance.new("ImageLabel", colorpicker.MainPicker)
2404
colorpicker.hueselectorpointer.ZIndex = 101
2405
colorpicker.hueselectorpointer.BackgroundTransparency = 1
2406
colorpicker.hueselectorpointer.BorderSizePixel = 0
2407
colorpicker.hueselectorpointer.Position = UDim2.new(0, 0, 0, 0)
2408
colorpicker.hueselectorpointer.Size = UDim2.new(0, 7, 0, 7)
2409
colorpicker.hueselectorpointer.Image = "rbxassetid://6885856475"
2410
2411
colorpicker.selector = Instance.new("TextLabel", colorpicker.MainPicker)
2412
colorpicker.selector.ZIndex = 100
2413
colorpicker.selector.Position = UDim2.new(0,3,0,181)
2414
colorpicker.selector.Size = UDim2.new(0,173,0,10)
2415
colorpicker.selector.BackgroundColor3 = Color3.fromRGB(255,255,255)
2416
colorpicker.selector.BorderColor3 = window.theme.outlinecolor2
2417
colorpicker.selector.Text = ""
2418
updateevent.Event:Connect(function(theme)
2419
colorpicker.selector.BorderColor3 = theme.outlinecolor2
2420
end)
2421
2422
colorpicker.gradient = Instance.new("UIGradient", colorpicker.selector)
2423
colorpicker.gradient.Color = ColorSequence.new({
2424
ColorSequenceKeypoint.new(0, Color3.new(1,0,0)),
2425
ColorSequenceKeypoint.new(0.17, Color3.new(1,0,1)),
2426
ColorSequenceKeypoint.new(0.33,Color3.new(0,0,1)),
2427
ColorSequenceKeypoint.new(0.5,Color3.new(0,1,1)),
2428
ColorSequenceKeypoint.new(0.67, Color3.new(0,1,0)),
2429
ColorSequenceKeypoint.new(0.83, Color3.new(1,1,0)),
2430
ColorSequenceKeypoint.new(1, Color3.new(1,0,0))
2431
})
2432
2433
colorpicker.pointer = Instance.new("Frame", colorpicker.selector)
2434
colorpicker.pointer.ZIndex = 101
2435
colorpicker.pointer.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
2436
colorpicker.pointer.Position = UDim2.new(0,0,0,0)
2437
colorpicker.pointer.Size = UDim2.new(0,2,0,10)
2438
colorpicker.pointer.BorderColor3 = Color3.fromRGB(255, 255, 255)
2439
2440
if colorpicker.flag and colorpicker.flag ~= "" then
2441
library.flags[colorpicker.flag] = colorpicker.default
2442
end
2443
2444
function colorpicker:RefreshSelector()
2445
local pos = math.clamp((mouse.X - colorpicker.hue.AbsolutePosition.X) / colorpicker.hue.AbsoluteSize.X, 0, 1)
2446
colorpicker.color = 1 - pos
2447
colorpicker.pointer:TweenPosition(UDim2.new(pos, 0, 0, 0), Enum.EasingDirection.In, Enum.EasingStyle.Sine, 0.05)
2448
colorpicker.hue.BackgroundColor3 = Color3.fromHSV(1 - pos, 1, 1)
2449
end
2450
2451
function colorpicker:RefreshHue()
2452
local x = (mouse.X - colorpicker.hue.AbsolutePosition.X) / colorpicker.hue.AbsoluteSize.X
2453
local y = (mouse.Y - colorpicker.hue.AbsolutePosition.Y) / colorpicker.hue.AbsoluteSize.Y
2454
colorpicker.hueselectorpointer:TweenPosition(UDim2.new(math.clamp(x * colorpicker.hue.AbsoluteSize.X, 0.5, 0.952 * colorpicker.hue.AbsoluteSize.X) / colorpicker.hue.AbsoluteSize.X, 0, math.clamp(y * colorpicker.hue.AbsoluteSize.Y, 0.5, 0.885 * colorpicker.hue.AbsoluteSize.Y) / colorpicker.hue.AbsoluteSize.Y, 0), Enum.EasingDirection.In, Enum.EasingStyle.Sine, 0.05)
2455
colorpicker:Set(Color3.fromHSV(colorpicker.color, math.clamp(x * colorpicker.hue.AbsoluteSize.X, 0.5, 1 * colorpicker.hue.AbsoluteSize.X) / colorpicker.hue.AbsoluteSize.X, 1 - (math.clamp(y * colorpicker.hue.AbsoluteSize.Y, 0.5, 1 * colorpicker.hue.AbsoluteSize.Y) / colorpicker.hue.AbsoluteSize.Y)))
2456
end
2457
2458
function colorpicker:Set(value)
2459
local color = Color3.new(math.clamp(value.r, 0, 1), math.clamp(value.g, 0, 1), math.clamp(value.b, 0, 1))
2460
colorpicker.value = color
2461
if colorpicker.flag and colorpicker.flag ~= "" then
2462
library.flags[colorpicker.flag] = color
2463
end
2464
local clr = Color3.new(math.clamp(color.R / 1.7, 0, 1), math.clamp(color.G / 1.7, 0, 1), math.clamp(color.B / 1.7, 0, 1))
2465
colorpicker.Gradient.Color = ColorSequence.new({ ColorSequenceKeypoint.new(0.00, color), ColorSequenceKeypoint.new(1.00, clr) })
2466
pcall(colorpicker.callback, color)
2467
end
2468
function colorpicker:Get()
2469
return colorpicker.value
2470
end
2471
colorpicker:Set(colorpicker.default)
2472
2473
function colorpicker:AddDropdown(items, default, multichoice, callback, flag)
2474
local dropdown = { }
2475
2476
dropdown.defaultitems = items or { }
2477
dropdown.default = default
2478
dropdown.callback = callback or function() end
2479
dropdown.multichoice = multichoice or false
2480
dropdown.values = { }
2481
dropdown.flag = flag or ((colorpicker.text or "") .. tostring( #(sector.Items:GetChildren()) ))
2482
2483
dropdown.Main = Instance.new("TextButton", sector.Items)
2484
dropdown.Main.Name = "dropdown"
2485
dropdown.Main.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
2486
dropdown.Main.BorderSizePixel = 0
2487
dropdown.Main.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 16)
2488
dropdown.Main.Position = UDim2.fromOffset(0, 0)
2489
dropdown.Main.ZIndex = 5
2490
dropdown.Main.AutoButtonColor = false
2491
dropdown.Main.Font = window.theme.font
2492
dropdown.Main.Text = ""
2493
dropdown.Main.TextColor3 = Color3.fromRGB(255, 255, 255)
2494
dropdown.Main.TextSize = 15
2495
dropdown.Main.TextXAlignment = Enum.TextXAlignment.Left
2496
updateevent.Event:Connect(function(theme)
2497
dropdown.Main.Font = theme.font
2498
end)
2499
2500
dropdown.Gradient = Instance.new("UIGradient", dropdown.Main)
2501
dropdown.Gradient.Rotation = 90
2502
dropdown.Gradient.Color = ColorSequence.new{ColorSequenceKeypoint.new(0.00, Color3.fromRGB(49, 49, 49)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(39, 39, 39))}
2503
2504
dropdown.SelectedLabel = Instance.new("TextLabel", dropdown.Main)
2505
dropdown.SelectedLabel.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
2506
dropdown.SelectedLabel.BackgroundTransparency = 1
2507
dropdown.SelectedLabel.Position = UDim2.fromOffset(5, 2)
2508
dropdown.SelectedLabel.Size = UDim2.fromOffset(130, 13)
2509
dropdown.SelectedLabel.Font = window.theme.font
2510
dropdown.SelectedLabel.Text = colorpicker.text
2511
dropdown.SelectedLabel.ZIndex = 5
2512
dropdown.SelectedLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
2513
dropdown.SelectedLabel.TextSize = 15
2514
dropdown.SelectedLabel.TextStrokeTransparency = 1
2515
dropdown.SelectedLabel.TextXAlignment = Enum.TextXAlignment.Left
2516
updateevent.Event:Connect(function(theme)
2517
dropdown.SelectedLabel.Font = theme.font
2518
end)
2519
2520
dropdown.Nav = Instance.new("ImageButton", dropdown.Main)
2521
dropdown.Nav.Name = "navigation"
2522
dropdown.Nav.BackgroundTransparency = 1
2523
dropdown.Nav.LayoutOrder = 10
2524
dropdown.Nav.Position = UDim2.fromOffset(sector.Main.Size.X.Offset - 26, 5)
2525
dropdown.Nav.Rotation = 90
2526
dropdown.Nav.ZIndex = 5
2527
dropdown.Nav.Size = UDim2.fromOffset(8, 8)
2528
dropdown.Nav.Image = "rbxassetid://4918373417"
2529
dropdown.Nav.ImageColor3 = Color3.fromRGB(210, 210, 210)
2530
2531
dropdown.BlackOutline2 = Instance.new("Frame", dropdown.Main)
2532
dropdown.BlackOutline2.Name = "blackline"
2533
dropdown.BlackOutline2.ZIndex = 4
2534
dropdown.BlackOutline2.Size = dropdown.Main.Size + UDim2.fromOffset(6, 6)
2535
dropdown.BlackOutline2.BorderSizePixel = 0
2536
dropdown.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
2537
dropdown.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
2538
updateevent.Event:Connect(function(theme)
2539
dropdown.BlackOutline2.BackgroundColor3 = theme.outlinecolor2
2540
end)
2541
2542
dropdown.Outline = Instance.new("Frame", dropdown.Main)
2543
dropdown.Outline.Name = "blackline"
2544
dropdown.Outline.ZIndex = 4
2545
dropdown.Outline.Size = dropdown.Main.Size + UDim2.fromOffset(4, 4)
2546
dropdown.Outline.BorderSizePixel = 0
2547
dropdown.Outline.BackgroundColor3 = window.theme.outlinecolor
2548
dropdown.Outline.Position = UDim2.fromOffset(-2, -2)
2549
updateevent.Event:Connect(function(theme)
2550
dropdown.Outline.BackgroundColor3 = theme.outlinecolor
2551
end)
2552
2553
dropdown.BlackOutline = Instance.new("Frame", dropdown.Main)
2554
dropdown.BlackOutline.Name = "blackline"
2555
dropdown.BlackOutline.ZIndex = 4
2556
dropdown.BlackOutline.Size = dropdown.Main.Size + UDim2.fromOffset(2, 2)
2557
dropdown.BlackOutline.BorderSizePixel = 0
2558
dropdown.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
2559
dropdown.BlackOutline.Position = UDim2.fromOffset(-1, -1)
2560
updateevent.Event:Connect(function(theme)
2561
dropdown.BlackOutline.BackgroundColor3 = theme.outlinecolor2
2562
end)
2563
2564
dropdown.ItemsFrame = Instance.new("ScrollingFrame", dropdown.Main)
2565
dropdown.ItemsFrame.Name = "itemsframe"
2566
dropdown.ItemsFrame.BorderSizePixel = 0
2567
dropdown.ItemsFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
2568
dropdown.ItemsFrame.Position = UDim2.fromOffset(0, dropdown.Main.Size.Y.Offset + 8)
2569
dropdown.ItemsFrame.ScrollBarThickness = 2
2570
dropdown.ItemsFrame.ZIndex = 8
2571
dropdown.ItemsFrame.ScrollingDirection = "Y"
2572
dropdown.ItemsFrame.Visible = false
2573
dropdown.ItemsFrame.CanvasSize = UDim2.fromOffset(dropdown.Main.AbsoluteSize.X, 0)
2574
2575
dropdown.ListLayout = Instance.new("UIListLayout", dropdown.ItemsFrame)
2576
dropdown.ListLayout.FillDirection = Enum.FillDirection.Vertical
2577
dropdown.ListLayout.SortOrder = Enum.SortOrder.LayoutOrder
2578
2579
dropdown.ListPadding = Instance.new("UIPadding", dropdown.ItemsFrame)
2580
dropdown.ListPadding.PaddingTop = UDim.new(0, 2)
2581
dropdown.ListPadding.PaddingBottom = UDim.new(0, 2)
2582
dropdown.ListPadding.PaddingLeft = UDim.new(0, 2)
2583
dropdown.ListPadding.PaddingRight = UDim.new(0, 2)
2584
2585
dropdown.BlackOutline2Items = Instance.new("Frame", dropdown.Main)
2586
dropdown.BlackOutline2Items.Name = "blackline"
2587
dropdown.BlackOutline2Items.ZIndex = 7
2588
dropdown.BlackOutline2Items.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(6, 6)
2589
dropdown.BlackOutline2Items.BorderSizePixel = 0
2590
dropdown.BlackOutline2Items.BackgroundColor3 = window.theme.outlinecolor2
2591
dropdown.BlackOutline2Items.Position = dropdown.ItemsFrame.Position + UDim2.fromOffset(-3, -3)
2592
dropdown.BlackOutline2Items.Visible = false
2593
updateevent.Event:Connect(function(theme)
2594
dropdown.BlackOutline2Items.BackgroundColor3 = theme.outlinecolor2
2595
end)
2596
2597
dropdown.OutlineItems = Instance.new("Frame", dropdown.Main)
2598
dropdown.OutlineItems.Name = "blackline"
2599
dropdown.OutlineItems.ZIndex = 7
2600
dropdown.OutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(4, 4)
2601
dropdown.OutlineItems.BorderSizePixel = 0
2602
dropdown.OutlineItems.BackgroundColor3 = window.theme.outlinecolor
2603
dropdown.OutlineItems.Position = dropdown.ItemsFrame.Position + UDim2.fromOffset(-2, -2)
2604
dropdown.OutlineItems.Visible = false
2605
updateevent.Event:Connect(function(theme)
2606
dropdown.OutlineItems.BackgroundColor3 = theme.outlinecolor
2607
end)
2608
2609
dropdown.BlackOutlineItems = Instance.new("Frame", dropdown.Main)
2610
dropdown.BlackOutlineItems.Name = "blackline"
2611
dropdown.BlackOutlineItems.ZIndex = 7
2612
dropdown.BlackOutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(-2, -2)
2613
dropdown.BlackOutlineItems.BorderSizePixel = 0
2614
dropdown.BlackOutlineItems.BackgroundColor3 = window.theme.outlinecolor2
2615
dropdown.BlackOutlineItems.Position = dropdown.ItemsFrame.Position + UDim2.fromOffset(-1, -1)
2616
dropdown.BlackOutlineItems.Visible = false
2617
updateevent.Event:Connect(function(theme)
2618
dropdown.BlackOutlineItems.BackgroundColor3 = theme.outlinecolor2
2619
end)
2620
2621
dropdown.IgnoreBackButtons = Instance.new("TextButton", dropdown.Main)
2622
dropdown.IgnoreBackButtons.BackgroundTransparency = 1
2623
dropdown.IgnoreBackButtons.BorderSizePixel = 0
2624
dropdown.IgnoreBackButtons.Position = UDim2.fromOffset(0, dropdown.Main.Size.Y.Offset + 8)
2625
dropdown.IgnoreBackButtons.Size = UDim2.new(0, 0, 0, 0)
2626
dropdown.IgnoreBackButtons.ZIndex = 7
2627
dropdown.IgnoreBackButtons.Text = ""
2628
dropdown.IgnoreBackButtons.Visible = false
2629
dropdown.IgnoreBackButtons.AutoButtonColor = false
2630
2631
if dropdown.flag and dropdown.flag ~= "" then
2632
library.flags[dropdown.flag] = dropdown.multichoice and { dropdown.default or dropdown.defaultitems[1] or "" } or (dropdown.default or dropdown.defaultitems[1] or "")
2633
end
2634
2635
function dropdown:isSelected(item)
2636
for i, v in pairs(dropdown.values) do
2637
if v == item then
2638
return true
2639
end
2640
end
2641
return false
2642
end
2643
2644
function dropdown:updateText(text)
2645
if #text >= 27 then
2646
text = text:sub(1, 25) .. ".."
2647
end
2648
dropdown.SelectedLabel.Text = text
2649
end
2650
2651
dropdown.Changed = Instance.new("BindableEvent")
2652
function dropdown:Set(value)
2653
if type(value) == "table" then
2654
dropdown.values = value
2655
dropdown:updateText(table.concat(value, ", "))
2656
pcall(dropdown.callback, value)
2657
else
2658
dropdown:updateText(value)
2659
dropdown.values = { value }
2660
pcall(dropdown.callback, value)
2661
end
2662
2663
dropdown.Changed:Fire(value)
2664
if dropdown.flag and dropdown.flag ~= "" then
2665
library.flags[dropdown.flag] = dropdown.multichoice and dropdown.values or dropdown.values[1]
2666
end
2667
end
2668
2669
function dropdown:Get()
2670
return dropdown.multichoice and dropdown.values or dropdown.values[1]
2671
end
2672
2673
dropdown.items = { }
2674
function dropdown:Add(v)
2675
local Item = Instance.new("TextButton", dropdown.ItemsFrame)
2676
Item.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
2677
Item.TextColor3 = Color3.fromRGB(255, 255, 255)
2678
Item.BorderSizePixel = 0
2679
Item.Position = UDim2.fromOffset(0, 0)
2680
Item.Size = UDim2.fromOffset(dropdown.Main.Size.X.Offset - 4, 20)
2681
Item.ZIndex = 9
2682
Item.Text = v
2683
Item.Name = v
2684
Item.AutoButtonColor = false
2685
Item.Font = window.theme.font
2686
Item.TextSize = 15
2687
Item.TextXAlignment = Enum.TextXAlignment.Left
2688
Item.TextStrokeTransparency = 1
2689
dropdown.ItemsFrame.CanvasSize = dropdown.ItemsFrame.CanvasSize + UDim2.fromOffset(0, Item.AbsoluteSize.Y)
2690
2691
Item.MouseButton1Down:Connect(function()
2692
if dropdown.multichoice then
2693
if dropdown:isSelected(v) then
2694
for i2, v2 in pairs(dropdown.values) do
2695
if v2 == v then
2696
table.remove(dropdown.values, i2)
2697
end
2698
end
2699
dropdown:Set(dropdown.values)
2700
else
2701
table.insert(dropdown.values, v)
2702
dropdown:Set(dropdown.values)
2703
end
2704
2705
return
2706
else
2707
dropdown.Nav.Rotation = 90
2708
dropdown.ItemsFrame.Visible = false
2709
dropdown.ItemsFrame.Active = false
2710
dropdown.OutlineItems.Visible = false
2711
dropdown.BlackOutlineItems.Visible = false
2712
dropdown.BlackOutline2Items.Visible = false
2713
dropdown.IgnoreBackButtons.Visible = false
2714
dropdown.IgnoreBackButtons.Active = false
2715
end
2716
2717
dropdown:Set(v)
2718
return
2719
end)
2720
2721
runservice.RenderStepped:Connect(function()
2722
if dropdown.multichoice and dropdown:isSelected(v) or dropdown.values[1] == v then
2723
Item.BackgroundColor3 = Color3.fromRGB(64, 64, 64)
2724
Item.TextColor3 = window.theme.accentcolor
2725
Item.Text = " " .. v
2726
else
2727
Item.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
2728
Item.TextColor3 = Color3.fromRGB(255, 255, 255)
2729
Item.Text = v
2730
end
2731
end)
2732
2733
table.insert(dropdown.items, v)
2734
dropdown.ItemsFrame.Size = UDim2.fromOffset(dropdown.Main.Size.X.Offset, math.clamp(#dropdown.items * Item.AbsoluteSize.Y, 20, 156) + 4)
2735
dropdown.ItemsFrame.CanvasSize = UDim2.fromOffset(dropdown.ItemsFrame.AbsoluteSize.X, (#dropdown.items * Item.AbsoluteSize.Y) + 4)
2736
2737
dropdown.OutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(4, 4)
2738
dropdown.BlackOutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(2, 2)
2739
dropdown.BlackOutline2Items.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(6, 6)
2740
dropdown.IgnoreBackButtons.Size = dropdown.ItemsFrame.Size
2741
end
2742
2743
function dropdown:Remove(value)
2744
local item = dropdown.ItemsFrame:FindFirstChild(value)
2745
if item then
2746
for i,v in pairs(dropdown.items) do
2747
if v == value then
2748
table.remove(dropdown.items, i)
2749
end
2750
end
2751
2752
dropdown.ItemsFrame.Size = UDim2.fromOffset(dropdown.Main.Size.X.Offset, math.clamp(#dropdown.items * item.AbsoluteSize.Y, 20, 156) + 4)
2753
dropdown.ItemsFrame.CanvasSize = UDim2.fromOffset(dropdown.ItemsFrame.AbsoluteSize.X, (#dropdown.items * item.AbsoluteSize.Y) + 4)
2754
2755
dropdown.OutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(2, 2)
2756
dropdown.BlackOutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(4, 4)
2757
dropdown.BlackOutline2Items.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(6, 6)
2758
dropdown.IgnoreBackButtons.Size = dropdown.ItemsFrame.Size
2759
2760
item:Remove()
2761
end
2762
end
2763
2764
for i,v in pairs(dropdown.defaultitems) do
2765
dropdown:Add(v)
2766
end
2767
2768
if dropdown.default then
2769
dropdown:Set(dropdown.default)
2770
end
2771
2772
local MouseButton1Down = function()
2773
if dropdown.Nav.Rotation == 90 then
2774
dropdown.ItemsFrame.ScrollingEnabled = true
2775
sector.Main.Parent.ScrollingEnabled = false
2776
tweenservice:Create(dropdown.Nav, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { Rotation = -90 }):Play()
2777
dropdown.ItemsFrame.Visible = true
2778
dropdown.ItemsFrame.Active = true
2779
dropdown.IgnoreBackButtons.Visible = true
2780
dropdown.IgnoreBackButtons.Active = true
2781
dropdown.OutlineItems.Visible = true
2782
dropdown.BlackOutlineItems.Visible = true
2783
dropdown.BlackOutline2Items.Visible = true
2784
else
2785
dropdown.ItemsFrame.ScrollingEnabled = false
2786
sector.Main.Parent.ScrollingEnabled = true
2787
tweenservice:Create(dropdown.Nav, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { Rotation = 90 }):Play()
2788
dropdown.ItemsFrame.Visible = false
2789
dropdown.ItemsFrame.Active = false
2790
dropdown.IgnoreBackButtons.Visible = false
2791
dropdown.IgnoreBackButtons.Active = false
2792
dropdown.OutlineItems.Visible = false
2793
dropdown.BlackOutlineItems.Visible = false
2794
dropdown.BlackOutline2Items.Visible = false
2795
end
2796
end
2797
2798
dropdown.Main.MouseButton1Down:Connect(MouseButton1Down)
2799
dropdown.Nav.MouseButton1Down:Connect(MouseButton1Down)
2800
2801
dropdown.BlackOutline2.MouseEnter:Connect(function()
2802
dropdown.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
2803
end)
2804
dropdown.BlackOutline2.MouseLeave:Connect(function()
2805
dropdown.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
2806
end)
2807
2808
sector:FixSize()
2809
table.insert(library.items, dropdown)
2810
return dropdown
2811
end
2812
2813
local dragging_selector = false
2814
local dragging_hue = false
2815
2816
colorpicker.selector.InputBegan:Connect(function(input)
2817
if input.UserInputType == Enum.UserInputType.MouseButton1 then
2818
dragging_selector = true
2819
colorpicker:RefreshSelector()
2820
end
2821
end)
2822
2823
colorpicker.selector.InputEnded:Connect(function(input)
2824
if input.UserInputType == Enum.UserInputType.MouseButton1 then
2825
dragging_selector = false
2826
colorpicker:RefreshSelector()
2827
end
2828
end)
2829
2830
colorpicker.hue.InputBegan:Connect(function(input)
2831
if input.UserInputType == Enum.UserInputType.MouseButton1 then
2832
dragging_hue = true
2833
colorpicker:RefreshHue()
2834
end
2835
end)
2836
2837
colorpicker.hue.InputEnded:Connect(function(input)
2838
if input.UserInputType == Enum.UserInputType.MouseButton1 then
2839
dragging_hue = false
2840
colorpicker:RefreshHue()
2841
end
2842
end)
2843
2844
uis.InputChanged:Connect(function(input)
2845
if dragging_selector and input.UserInputType == Enum.UserInputType.MouseMovement then
2846
colorpicker:RefreshSelector()
2847
end
2848
if dragging_hue and input.UserInputType == Enum.UserInputType.MouseMovement then
2849
colorpicker:RefreshHue()
2850
end
2851
end)
2852
2853
local inputBegan = function(input)
2854
if input.UserInputType == Enum.UserInputType.MouseButton1 then
2855
for i,v in pairs(window.OpenedColorPickers) do
2856
if v and i ~= colorpicker.MainPicker then
2857
i.Visible = false
2858
window.OpenedColorPickers[i] = false
2859
end
2860
end
2861
2862
colorpicker.MainPicker.Visible = not colorpicker.MainPicker.Visible
2863
window.OpenedColorPickers[colorpicker.MainPicker] = colorpicker.MainPicker.Visible
2864
if window.OpenedColorPickers[colorpicker.MainPicker] then
2865
colorpicker.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
2866
else
2867
colorpicker.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
2868
end
2869
end
2870
end
2871
2872
colorpicker.Main.InputBegan:Connect(inputBegan)
2873
colorpicker.Outline.InputBegan:Connect(inputBegan)
2874
colorpicker.BlackOutline2.InputBegan:Connect(inputBegan)
2875
2876
sector:FixSize()
2877
table.insert(library.items, colorpicker)
2878
return colorpicker
2879
end
2880
2881
function sector:AddKeybind(text,default,newkeycallback,callback,flag)
2882
local keybind = { }
2883
2884
keybind.text = text or ""
2885
keybind.default = default or "None"
2886
keybind.callback = callback or function() end
2887
keybind.newkeycallback = newkeycallback or function(key) end
2888
keybind.flag = flag or text or ""
2889
2890
keybind.value = keybind.default
2891
2892
keybind.Main = Instance.new("TextLabel", sector.Items)
2893
keybind.Main.BackgroundTransparency = 1
2894
keybind.Main.Size = UDim2.fromOffset(156, 10)
2895
keybind.Main.ZIndex = 4
2896
keybind.Main.Font = window.theme.font
2897
keybind.Main.Text = keybind.text
2898
keybind.Main.TextColor3 = window.theme.itemscolor
2899
keybind.Main.TextSize = 15
2900
keybind.Main.TextStrokeTransparency = 1
2901
keybind.Main.TextXAlignment = Enum.TextXAlignment.Left
2902
updateevent.Event:Connect(function(theme)
2903
keybind.Main.Font = theme.font
2904
keybind.Main.TextColor3 = theme.itemscolor
2905
end)
2906
2907
keybind.Bind = Instance.new("TextButton", keybind.Main)
2908
keybind.Bind.Name = "keybind"
2909
keybind.Bind.BackgroundTransparency = 1
2910
keybind.Bind.BorderColor3 = window.theme.outlinecolor
2911
keybind.Bind.ZIndex = 5
2912
keybind.Bind.BorderSizePixel = 0
2913
keybind.Bind.Position = UDim2.fromOffset(sector.Main.Size.X.Offset - 10, 0)
2914
keybind.Bind.Font = window.theme.font
2915
keybind.Bind.TextColor3 = Color3.fromRGB(136, 136, 136)
2916
keybind.Bind.TextSize = 15
2917
keybind.Bind.TextXAlignment = Enum.TextXAlignment.Right
2918
keybind.Bind.MouseButton1Down:Connect(function()
2919
keybind.Bind.Text = "[...]"
2920
keybind.Bind.TextColor3 = window.theme.accentcolor
2921
end)
2922
updateevent.Event:Connect(function(theme)
2923
keybind.Bind.BorderColor3 = theme.outlinecolor
2924
keybind.Bind.Font = theme.font
2925
end)
2926
2927
if keybind.flag and keybind.flag ~= "" then
2928
library.flags[keybind.flag] = keybind.default
2929
end
2930
2931
local shorter_keycodes = {
2932
["LeftShift"] = "LSHIFT",
2933
["RightShift"] = "RSHIFT",
2934
["LeftControl"] = "LCTRL",
2935
["RightControl"] = "RCTRL",
2936
["LeftAlt"] = "LALT",
2937
["RightAlt"] = "RALT"
2938
}
2939
2940
function keybind:Set(value)
2941
if value == "None" then
2942
keybind.value = value
2943
keybind.Bind.Text = "[" .. value .. "]"
2944
2945
local size = textservice:GetTextSize(keybind.Bind.Text, keybind.Bind.TextSize, keybind.Bind.Font, Vector2.new(2000, 2000))
2946
keybind.Bind.Size = UDim2.fromOffset(size.X, size.Y)
2947
keybind.Bind.Position = UDim2.fromOffset(sector.Main.Size.X.Offset - 10 - keybind.Bind.AbsoluteSize.X, 0)
2948
if keybind.flag and keybind.flag ~= "" then
2949
library.flags[keybind.flag] = value
2950
end
2951
pcall(keybind.newkeycallback, value)
2952
end
2953
2954
keybind.value = value
2955
keybind.Bind.Text = "[" .. (shorter_keycodes[value.Name or value] or (value.Name or value)) .. "]"
2956
2957
local size = textservice:GetTextSize(keybind.Bind.Text, keybind.Bind.TextSize, keybind.Bind.Font, Vector2.new(2000, 2000))
2958
keybind.Bind.Size = UDim2.fromOffset(size.X, size.Y)
2959
keybind.Bind.Position = UDim2.fromOffset(sector.Main.Size.X.Offset - 10 - keybind.Bind.AbsoluteSize.X, 0)
2960
if keybind.flag and keybind.flag ~= "" then
2961
library.flags[keybind.flag] = value
2962
end
2963
pcall(keybind.newkeycallback, value)
2964
end
2965
keybind:Set(keybind.default and keybind.default or "None")
2966
2967
function keybind:Get()
2968
return keybind.value
2969
end
2970
2971
uis.InputBegan:Connect(function(input, gameProcessed)
2972
if not gameProcessed then
2973
if keybind.Bind.Text == "[...]" then
2974
keybind.Bind.TextColor3 = Color3.fromRGB(136, 136, 136)
2975
if input.UserInputType == Enum.UserInputType.Keyboard then
2976
keybind:Set(input.KeyCode)
2977
else
2978
keybind:Set("None")
2979
end
2980
else
2981
if keybind.value ~= "None" and input.KeyCode == keybind.value then
2982
pcall(keybind.callback)
2983
end
2984
end
2985
end
2986
end)
2987
2988
sector:FixSize()
2989
table.insert(library.items, keybind)
2990
return keybind
2991
end
2992
2993
function sector:AddDropdown(text, items, default, multichoice, callback, flag)
2994
local dropdown = { }
2995
2996
dropdown.text = text or ""
2997
dropdown.defaultitems = items or { }
2998
dropdown.default = default
2999
dropdown.callback = callback or function() end
3000
dropdown.multichoice = multichoice or false
3001
dropdown.values = { }
3002
dropdown.flag = flag or text or ""
3003
3004
dropdown.MainBack = Instance.new("Frame", sector.Items)
3005
dropdown.MainBack.Name = "backlabel"
3006
dropdown.MainBack.ZIndex = 7
3007
dropdown.MainBack.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 34)
3008
dropdown.MainBack.BorderSizePixel = 0
3009
dropdown.MainBack.BackgroundTransparency = 1
3010
3011
dropdown.Label = Instance.new("TextLabel", dropdown.MainBack)
3012
dropdown.Label.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
3013
dropdown.Label.BackgroundTransparency = 1
3014
dropdown.Label.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 10)
3015
dropdown.Label.Position = UDim2.fromOffset(0, 0)
3016
dropdown.Label.Font = window.theme.font
3017
dropdown.Label.Text = dropdown.text
3018
dropdown.Label.ZIndex = 4
3019
dropdown.Label.TextColor3 = window.theme.itemscolor
3020
dropdown.Label.TextSize = 15
3021
dropdown.Label.TextStrokeTransparency = 1
3022
dropdown.Label.TextXAlignment = Enum.TextXAlignment.Left
3023
3024
updateevent.Event:Connect(function(theme)
3025
dropdown.Label.Font = theme.font
3026
dropdown.Label.TextColor3 = theme.itemscolor
3027
end)
3028
3029
dropdown.Main = Instance.new("TextButton", dropdown.MainBack)
3030
dropdown.Main.Name = "dropdown"
3031
dropdown.Main.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
3032
dropdown.Main.BorderSizePixel = 0
3033
dropdown.Main.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 16)
3034
dropdown.Main.Position = UDim2.fromOffset(0, 17)
3035
dropdown.Main.ZIndex = 5
3036
dropdown.Main.AutoButtonColor = false
3037
dropdown.Main.Font = window.theme.font
3038
dropdown.Main.Text = ""
3039
dropdown.Main.TextColor3 = Color3.fromRGB(255, 255, 255)
3040
dropdown.Main.TextSize = 15
3041
dropdown.Main.TextXAlignment = Enum.TextXAlignment.Left
3042
updateevent.Event:Connect(function(theme)
3043
dropdown.Main.Font = theme.font
3044
end)
3045
3046
dropdown.Gradient = Instance.new("UIGradient", dropdown.Main)
3047
dropdown.Gradient.Rotation = 90
3048
dropdown.Gradient.Color = ColorSequence.new{ColorSequenceKeypoint.new(0.00, Color3.fromRGB(49, 49, 49)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(39, 39, 39))}
3049
3050
dropdown.SelectedLabel = Instance.new("TextLabel", dropdown.Main)
3051
dropdown.SelectedLabel.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
3052
dropdown.SelectedLabel.BackgroundTransparency = 1
3053
dropdown.SelectedLabel.Position = UDim2.fromOffset(5, 2)
3054
dropdown.SelectedLabel.Size = UDim2.fromOffset(130, 13)
3055
dropdown.SelectedLabel.Font = window.theme.font
3056
dropdown.SelectedLabel.Text = dropdown.text
3057
dropdown.SelectedLabel.ZIndex = 5
3058
dropdown.SelectedLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
3059
dropdown.SelectedLabel.TextSize = 15
3060
dropdown.SelectedLabel.TextStrokeTransparency = 1
3061
dropdown.SelectedLabel.TextXAlignment = Enum.TextXAlignment.Left
3062
updateevent.Event:Connect(function(theme)
3063
dropdown.SelectedLabel.Font = theme.font
3064
end)
3065
3066
dropdown.Nav = Instance.new("ImageButton", dropdown.Main)
3067
dropdown.Nav.Name = "navigation"
3068
dropdown.Nav.BackgroundTransparency = 1
3069
dropdown.Nav.LayoutOrder = 10
3070
dropdown.Nav.Position = UDim2.fromOffset(sector.Main.Size.X.Offset - 26, 5)
3071
dropdown.Nav.Rotation = 90
3072
dropdown.Nav.ZIndex = 5
3073
dropdown.Nav.Size = UDim2.fromOffset(8, 8)
3074
dropdown.Nav.Image = "rbxassetid://4918373417"
3075
dropdown.Nav.ImageColor3 = Color3.fromRGB(210, 210, 210)
3076
3077
dropdown.BlackOutline2 = Instance.new("Frame", dropdown.Main)
3078
dropdown.BlackOutline2.Name = "blackline"
3079
dropdown.BlackOutline2.ZIndex = 4
3080
dropdown.BlackOutline2.Size = dropdown.Main.Size + UDim2.fromOffset(6, 6)
3081
dropdown.BlackOutline2.BorderSizePixel = 0
3082
dropdown.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
3083
dropdown.BlackOutline2.Position = UDim2.fromOffset(-3, -3)
3084
updateevent.Event:Connect(function(theme)
3085
dropdown.BlackOutline2.BackgroundColor3 = theme.outlinecolor2
3086
end)
3087
3088
dropdown.Outline = Instance.new("Frame", dropdown.Main)
3089
dropdown.Outline.Name = "blackline"
3090
dropdown.Outline.ZIndex = 4
3091
dropdown.Outline.Size = dropdown.Main.Size + UDim2.fromOffset(4, 4)
3092
dropdown.Outline.BorderSizePixel = 0
3093
dropdown.Outline.BackgroundColor3 = window.theme.outlinecolor
3094
dropdown.Outline.Position = UDim2.fromOffset(-2, -2)
3095
updateevent.Event:Connect(function(theme)
3096
dropdown.Outline.BackgroundColor3 = theme.outlinecolor
3097
end)
3098
3099
dropdown.BlackOutline = Instance.new("Frame", dropdown.Main)
3100
dropdown.BlackOutline.Name = "blackline"
3101
dropdown.BlackOutline.ZIndex = 4
3102
dropdown.BlackOutline.Size = dropdown.Main.Size + UDim2.fromOffset(2, 2)
3103
dropdown.BlackOutline.BorderSizePixel = 0
3104
dropdown.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
3105
dropdown.BlackOutline.Position = UDim2.fromOffset(-1, -1)
3106
updateevent.Event:Connect(function(theme)
3107
dropdown.BlackOutline.BackgroundColor3 = theme.outlinecolor2
3108
end)
3109
3110
dropdown.ItemsFrame = Instance.new("ScrollingFrame", dropdown.Main)
3111
dropdown.ItemsFrame.Name = "itemsframe"
3112
dropdown.ItemsFrame.BorderSizePixel = 0
3113
dropdown.ItemsFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
3114
dropdown.ItemsFrame.Position = UDim2.fromOffset(0, dropdown.Main.Size.Y.Offset + 8)
3115
dropdown.ItemsFrame.ScrollBarThickness = 2
3116
dropdown.ItemsFrame.ZIndex = 8
3117
dropdown.ItemsFrame.ScrollingDirection = "Y"
3118
dropdown.ItemsFrame.Visible = false
3119
dropdown.ItemsFrame.CanvasSize = UDim2.fromOffset(dropdown.Main.AbsoluteSize.X, 0)
3120
3121
dropdown.ListLayout = Instance.new("UIListLayout", dropdown.ItemsFrame)
3122
dropdown.ListLayout.FillDirection = Enum.FillDirection.Vertical
3123
dropdown.ListLayout.SortOrder = Enum.SortOrder.LayoutOrder
3124
3125
dropdown.ListPadding = Instance.new("UIPadding", dropdown.ItemsFrame)
3126
dropdown.ListPadding.PaddingTop = UDim.new(0, 2)
3127
dropdown.ListPadding.PaddingBottom = UDim.new(0, 2)
3128
dropdown.ListPadding.PaddingLeft = UDim.new(0, 2)
3129
dropdown.ListPadding.PaddingRight = UDim.new(0, 2)
3130
3131
dropdown.BlackOutline2Items = Instance.new("Frame", dropdown.Main)
3132
dropdown.BlackOutline2Items.Name = "blackline"
3133
dropdown.BlackOutline2Items.ZIndex = 7
3134
dropdown.BlackOutline2Items.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(6, 6)
3135
dropdown.BlackOutline2Items.BorderSizePixel = 0
3136
dropdown.BlackOutline2Items.BackgroundColor3 = window.theme.outlinecolor2
3137
dropdown.BlackOutline2Items.Position = dropdown.ItemsFrame.Position + UDim2.fromOffset(-3, -3)
3138
dropdown.BlackOutline2Items.Visible = false
3139
updateevent.Event:Connect(function(theme)
3140
dropdown.BlackOutline2Items.BackgroundColor3 = theme.outlinecolor2
3141
end)
3142
3143
dropdown.OutlineItems = Instance.new("Frame", dropdown.Main)
3144
dropdown.OutlineItems.Name = "blackline"
3145
dropdown.OutlineItems.ZIndex = 7
3146
dropdown.OutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(4, 4)
3147
dropdown.OutlineItems.BorderSizePixel = 0
3148
dropdown.OutlineItems.BackgroundColor3 = window.theme.outlinecolor
3149
dropdown.OutlineItems.Position = dropdown.ItemsFrame.Position + UDim2.fromOffset(-2, -2)
3150
dropdown.OutlineItems.Visible = false
3151
updateevent.Event:Connect(function(theme)
3152
dropdown.OutlineItems.BackgroundColor3 = theme.outlinecolor
3153
end)
3154
3155
dropdown.BlackOutlineItems = Instance.new("Frame", dropdown.Main)
3156
dropdown.BlackOutlineItems.Name = "blackline"
3157
dropdown.BlackOutlineItems.ZIndex = 7
3158
dropdown.BlackOutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(-2, -2)
3159
dropdown.BlackOutlineItems.BorderSizePixel = 0
3160
dropdown.BlackOutlineItems.BackgroundColor3 = window.theme.outlinecolor2
3161
dropdown.BlackOutlineItems.Position = dropdown.ItemsFrame.Position + UDim2.fromOffset(-1, -1)
3162
dropdown.BlackOutlineItems.Visible = false
3163
updateevent.Event:Connect(function(theme)
3164
dropdown.BlackOutlineItems.BackgroundColor3 = theme.outlinecolor2
3165
end)
3166
3167
dropdown.IgnoreBackButtons = Instance.new("TextButton", dropdown.Main)
3168
dropdown.IgnoreBackButtons.BackgroundTransparency = 1
3169
dropdown.IgnoreBackButtons.BorderSizePixel = 0
3170
dropdown.IgnoreBackButtons.Position = UDim2.fromOffset(0, dropdown.Main.Size.Y.Offset + 8)
3171
dropdown.IgnoreBackButtons.Size = UDim2.new(0, 0, 0, 0)
3172
dropdown.IgnoreBackButtons.ZIndex = 7
3173
dropdown.IgnoreBackButtons.Text = ""
3174
dropdown.IgnoreBackButtons.Visible = false
3175
dropdown.IgnoreBackButtons.AutoButtonColor = false
3176
3177
if dropdown.flag and dropdown.flag ~= "" then
3178
library.flags[dropdown.flag] = dropdown.multichoice and { dropdown.default or dropdown.defaultitems[1] or "" } or (dropdown.default or dropdown.defaultitems[1] or "")
3179
end
3180
3181
function dropdown:isSelected(item)
3182
for i, v in pairs(dropdown.values) do
3183
if v == item then
3184
return true
3185
end
3186
end
3187
return false
3188
end
3189
3190
function dropdown:GetOptions()
3191
return dropdown.values
3192
end
3193
3194
function dropdown:updateText(text)
3195
if #text >= 27 then
3196
text = text:sub(1, 25) .. ".."
3197
end
3198
dropdown.SelectedLabel.Text = text
3199
end
3200
3201
dropdown.Changed = Instance.new("BindableEvent")
3202
function dropdown:Set(value)
3203
if type(value) == "table" then
3204
dropdown.values = value
3205
dropdown:updateText(table.concat(value, ", "))
3206
pcall(dropdown.callback, value)
3207
else
3208
dropdown:updateText(value)
3209
dropdown.values = { value }
3210
pcall(dropdown.callback, value)
3211
end
3212
3213
dropdown.Changed:Fire(value)
3214
if dropdown.flag and dropdown.flag ~= "" then
3215
library.flags[dropdown.flag] = dropdown.multichoice and dropdown.values or dropdown.values[1]
3216
end
3217
end
3218
3219
function dropdown:Get()
3220
return dropdown.multichoice and dropdown.values or dropdown.values[1]
3221
end
3222
3223
dropdown.items = { }
3224
function dropdown:Add(v)
3225
local Item = Instance.new("TextButton", dropdown.ItemsFrame)
3226
Item.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
3227
Item.TextColor3 = Color3.fromRGB(255, 255, 255)
3228
Item.BorderSizePixel = 0
3229
Item.Position = UDim2.fromOffset(0, 0)
3230
Item.Size = UDim2.fromOffset(dropdown.Main.Size.X.Offset - 4, 20)
3231
Item.ZIndex = 9
3232
Item.Text = v
3233
Item.Name = v
3234
Item.AutoButtonColor = false
3235
Item.Font = window.theme.font
3236
Item.TextSize = 15
3237
Item.TextXAlignment = Enum.TextXAlignment.Left
3238
Item.TextStrokeTransparency = 1
3239
dropdown.ItemsFrame.CanvasSize = dropdown.ItemsFrame.CanvasSize + UDim2.fromOffset(0, Item.AbsoluteSize.Y)
3240
3241
Item.MouseButton1Down:Connect(function()
3242
if dropdown.multichoice then
3243
if dropdown:isSelected(v) then
3244
for i2, v2 in pairs(dropdown.values) do
3245
if v2 == v then
3246
table.remove(dropdown.values, i2)
3247
end
3248
end
3249
dropdown:Set(dropdown.values)
3250
else
3251
table.insert(dropdown.values, v)
3252
dropdown:Set(dropdown.values)
3253
end
3254
3255
return
3256
else
3257
dropdown.Nav.Rotation = 90
3258
dropdown.ItemsFrame.Visible = false
3259
dropdown.ItemsFrame.Active = false
3260
dropdown.OutlineItems.Visible = false
3261
dropdown.BlackOutlineItems.Visible = false
3262
dropdown.BlackOutline2Items.Visible = false
3263
dropdown.IgnoreBackButtons.Visible = false
3264
dropdown.IgnoreBackButtons.Active = false
3265
end
3266
3267
dropdown:Set(v)
3268
return
3269
end)
3270
3271
runservice.RenderStepped:Connect(function()
3272
if dropdown.multichoice and dropdown:isSelected(v) or dropdown.values[1] == v then
3273
Item.BackgroundColor3 = Color3.fromRGB(64, 64, 64)
3274
Item.TextColor3 = window.theme.accentcolor
3275
Item.Text = " " .. v
3276
else
3277
Item.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
3278
Item.TextColor3 = Color3.fromRGB(255, 255, 255)
3279
Item.Text = v
3280
end
3281
end)
3282
3283
table.insert(dropdown.items, v)
3284
dropdown.ItemsFrame.Size = UDim2.fromOffset(dropdown.Main.Size.X.Offset, math.clamp(#dropdown.items * Item.AbsoluteSize.Y, 20, 156) + 4)
3285
dropdown.ItemsFrame.CanvasSize = UDim2.fromOffset(dropdown.ItemsFrame.AbsoluteSize.X, (#dropdown.items * Item.AbsoluteSize.Y) + 4)
3286
3287
dropdown.OutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(4, 4)
3288
dropdown.BlackOutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(2, 2)
3289
dropdown.BlackOutline2Items.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(6, 6)
3290
dropdown.IgnoreBackButtons.Size = dropdown.ItemsFrame.Size
3291
end
3292
3293
function dropdown:Remove(value)
3294
local item = dropdown.ItemsFrame:FindFirstChild(value)
3295
if item then
3296
for i,v in pairs(dropdown.items) do
3297
if v == value then
3298
table.remove(dropdown.items, i)
3299
end
3300
end
3301
3302
dropdown.ItemsFrame.Size = UDim2.fromOffset(dropdown.Main.Size.X.Offset, math.clamp(#dropdown.items * item.AbsoluteSize.Y, 20, 156) + 4)
3303
dropdown.ItemsFrame.CanvasSize = UDim2.fromOffset(dropdown.ItemsFrame.AbsoluteSize.X, (#dropdown.items * item.AbsoluteSize.Y) + 4)
3304
3305
dropdown.OutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(2, 2)
3306
dropdown.BlackOutlineItems.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(4, 4)
3307
dropdown.BlackOutline2Items.Size = dropdown.ItemsFrame.Size + UDim2.fromOffset(6, 6)
3308
dropdown.IgnoreBackButtons.Size = dropdown.ItemsFrame.Size
3309
3310
item:Remove()
3311
end
3312
end
3313
3314
for i,v in pairs(dropdown.defaultitems) do
3315
dropdown:Add(v)
3316
end
3317
3318
if dropdown.default then
3319
dropdown:Set(dropdown.default)
3320
end
3321
3322
local MouseButton1Down = function()
3323
if dropdown.Nav.Rotation == 90 then
3324
tweenservice:Create(dropdown.Nav, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { Rotation = -90 }):Play()
3325
if dropdown.items and #dropdown.items ~= 0 then
3326
dropdown.ItemsFrame.ScrollingEnabled = true
3327
sector.Main.Parent.ScrollingEnabled = false
3328
dropdown.ItemsFrame.Visible = true
3329
dropdown.ItemsFrame.Active = true
3330
dropdown.IgnoreBackButtons.Visible = true
3331
dropdown.IgnoreBackButtons.Active = true
3332
dropdown.OutlineItems.Visible = true
3333
dropdown.BlackOutlineItems.Visible = true
3334
dropdown.BlackOutline2Items.Visible = true
3335
end
3336
else
3337
tweenservice:Create(dropdown.Nav, TweenInfo.new(0.1, Enum.EasingStyle.Linear, Enum.EasingDirection.In), { Rotation = 90 }):Play()
3338
dropdown.ItemsFrame.ScrollingEnabled = false
3339
sector.Main.Parent.ScrollingEnabled = true
3340
dropdown.ItemsFrame.Visible = false
3341
dropdown.ItemsFrame.Active = false
3342
dropdown.IgnoreBackButtons.Visible = false
3343
dropdown.IgnoreBackButtons.Active = false
3344
dropdown.OutlineItems.Visible = false
3345
dropdown.BlackOutlineItems.Visible = false
3346
dropdown.BlackOutline2Items.Visible = false
3347
end
3348
end
3349
3350
dropdown.Main.MouseButton1Down:Connect(MouseButton1Down)
3351
dropdown.Nav.MouseButton1Down:Connect(MouseButton1Down)
3352
3353
dropdown.BlackOutline2.MouseEnter:Connect(function()
3354
dropdown.BlackOutline2.BackgroundColor3 = window.theme.accentcolor
3355
end)
3356
dropdown.BlackOutline2.MouseLeave:Connect(function()
3357
dropdown.BlackOutline2.BackgroundColor3 = window.theme.outlinecolor2
3358
end)
3359
3360
sector:FixSize()
3361
table.insert(library.items, dropdown)
3362
return dropdown
3363
end
3364
3365
function sector:AddSeperator(text)
3366
local seperator = { }
3367
seperator.text = text or ""
3368
3369
seperator.main = Instance.new("Frame", sector.Items)
3370
seperator.main.Name = "Main"
3371
seperator.main.ZIndex = 5
3372
seperator.main.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 12, 10)
3373
seperator.main.BorderSizePixel = 0
3374
seperator.main.BackgroundTransparency = 1
3375
3376
seperator.line = Instance.new("Frame", seperator.main)
3377
seperator.line.Name = "Line"
3378
seperator.line.ZIndex = 7
3379
seperator.line.BackgroundColor3 = Color3.fromRGB(70, 70, 70)
3380
seperator.line.BorderSizePixel = 0
3381
seperator.line.Size = UDim2.fromOffset(sector.Main.Size.X.Offset - 26, 1)
3382
seperator.line.Position = UDim2.fromOffset(7, 5)
3383
3384
seperator.outline = Instance.new("Frame", seperator.line)
3385
seperator.outline.Name = "Outline"
3386
seperator.outline.ZIndex = 6
3387
seperator.outline.BorderSizePixel = 0
3388
seperator.outline.BackgroundColor3 = window.theme.outlinecolor2
3389
seperator.outline.Position = UDim2.fromOffset(-1, -1)
3390
seperator.outline.Size = seperator.line.Size - UDim2.fromOffset(-2, -2)
3391
updateevent.Event:Connect(function(theme)
3392
seperator.outline.BackgroundColor3 = theme.outlinecolor2
3393
end)
3394
3395
seperator.label = Instance.new("TextLabel", seperator.main)
3396
seperator.label.Name = "Label"
3397
seperator.label.BackgroundTransparency = 1
3398
seperator.label.Size = seperator.main.Size
3399
seperator.label.Font = window.theme.font
3400
seperator.label.ZIndex = 8
3401
seperator.label.Text = seperator.text
3402
seperator.label.TextColor3 = Color3.fromRGB(255, 255, 255)
3403
seperator.label.TextSize = window.theme.fontsize
3404
seperator.label.TextStrokeTransparency = 1
3405
seperator.label.TextXAlignment = Enum.TextXAlignment.Center
3406
updateevent.Event:Connect(function(theme)
3407
seperator.label.Font = theme.font
3408
seperator.label.TextSize = theme.fontsize
3409
end)
3410
3411
local textSize = textservice:GetTextSize(seperator.text, window.theme.fontsize, window.theme.font, Vector2.new(2000, 2000))
3412
local textStart = seperator.main.AbsoluteSize.X / 2 - (textSize.X / 2)
3413
3414
sector.LabelBackFrame = Instance.new("Frame", seperator.main)
3415
sector.LabelBackFrame.Name = "LabelBack"
3416
sector.LabelBackFrame.ZIndex = 7
3417
sector.LabelBackFrame.Size = UDim2.fromOffset(textSize.X + 12, 10)
3418
sector.LabelBackFrame.BorderSizePixel = 0
3419
sector.LabelBackFrame.BackgroundColor3 = Color3.fromRGB(30, 30, 30)
3420
sector.LabelBackFrame.Position = UDim2.new(0, textStart - 6, 0, 0)
3421
updateevent.Event:Connect(function(theme)
3422
textSize = textservice:GetTextSize(seperator.text, theme.fontsize, theme.font, Vector2.new(2000, 2000))
3423
textStart = seperator.main.AbsoluteSize.X / 2 - (textSize.X / 2)
3424
3425
sector.LabelBackFrame.Size = UDim2.fromOffset(textSize.X + 12, 10)
3426
sector.LabelBackFrame.Position = UDim2.new(0, textStart - 6, 0, 0)
3427
end)
3428
3429
sector:FixSize()
3430
return seperator
3431
end
3432
3433
return sector
3434
end
3435
3436
function tab:CreateConfigSystem(side)
3437
local configSystem = { }
3438
3439
configSystem.configFolder = window.name .. "/" .. tostring(game.PlaceId)
3440
if (not isfolder(configSystem.configFolder)) then
3441
makefolder(configSystem.configFolder)
3442
end
3443
3444
configSystem.sector = tab:CreateSector("Configs", side or "left")
3445
3446
local ConfigName = configSystem.sector:AddTextbox("Config Name", "", ConfigName, function() end, "")
3447
local default = tostring(listfiles(configSystem.configFolder)[1] or ""):gsub(configSystem.configFolder .. "\\", ""):gsub(".txt", "")
3448
local Config = configSystem.sector:AddDropdown("Configs", {}, default, false, function() end, "")
3449
for i,v in pairs(listfiles(configSystem.configFolder)) do
3450
if v:find(".txt") then
3451
Config:Add(tostring(v):gsub(configSystem.configFolder .. "\\", ""):gsub(".txt", ""))
3452
end
3453
end
3454
3455
configSystem.Create = configSystem.sector:AddButton("Create", function()
3456
for i,v in pairs(listfiles(configSystem.configFolder)) do
3457
Config:Remove(tostring(v):gsub(configSystem.configFolder .. "\\", ""):gsub(".txt", ""))
3458
end
3459
3460
if ConfigName:Get() and ConfigName:Get() ~= "" then
3461
local config = {}
3462
3463
for i,v in pairs(library.flags) do
3464
if (v ~= nil and v ~= "") then
3465
if (typeof(v) == "Color3") then
3466
config[i] = { v.R, v.G, v.B }
3467
elseif (tostring(v):find("Enum.KeyCode")) then
3468
config[i] = v.Name
3469
elseif (typeof(v) == "table") then
3470
config[i] = { v }
3471
else
3472
config[i] = v
3473
end
3474
end
3475
end
3476
3477
writefile(configSystem.configFolder .. "/" .. ConfigName:Get() .. ".txt", httpservice:JSONEncode(config))
3478
3479
for i,v in pairs(listfiles(configSystem.configFolder)) do
3480
if v:find(".txt") then
3481
Config:Add(tostring(v):gsub(configSystem.configFolder .. "\\", ""):gsub(".txt", ""))
3482
end
3483
end
3484
end
3485
end)
3486
3487
configSystem.Save = configSystem.sector:AddButton("Save", function()
3488
local config = {}
3489
if Config:Get() and Config:Get() ~= "" then
3490
for i,v in pairs(library.flags) do
3491
if (v ~= nil and v ~= "") then
3492
if (typeof(v) == "Color3") then
3493
config[i] = { v.R, v.G, v.B }
3494
elseif (tostring(v):find("Enum.KeyCode")) then
3495
config[i] = "Enum.KeyCode." .. v.Name
3496
elseif (typeof(v) == "table") then
3497
config[i] = { v }
3498
else
3499
config[i] = v
3500
end
3501
end
3502
end
3503
3504
writefile(configSystem.configFolder .. "/" .. Config:Get() .. ".txt", httpservice:JSONEncode(config))
3505
end
3506
end)
3507
3508
configSystem.Load = configSystem.sector:AddButton("Load", function()
3509
local Success = pcall(readfile, configSystem.configFolder .. "/" .. Config:Get() .. ".txt")
3510
if (Success) then
3511
pcall(function()
3512
local ReadConfig = httpservice:JSONDecode(readfile(configSystem.configFolder .. "/" .. Config:Get() .. ".txt"))
3513
local NewConfig = {}
3514
3515
for i,v in pairs(ReadConfig) do
3516
if (typeof(v) == "table") then
3517
if (typeof(v[1]) == "number") then
3518
NewConfig[i] = Color3.new(v[1], v[2], v[3])
3519
elseif (typeof(v[1]) == "table") then
3520
NewConfig[i] = v[1]
3521
end
3522
elseif (tostring(v):find("Enum.KeyCode.")) then
3523
NewConfig[i] = Enum.KeyCode[tostring(v):gsub("Enum.KeyCode.", "")]
3524
else
3525
NewConfig[i] = v
3526
end
3527
end
3528
3529
library.flags = NewConfig
3530
3531
for i,v in pairs(library.flags) do
3532
for i2,v2 in pairs(library.items) do
3533
if (i ~= nil and i ~= "" and i ~= "Configs_Name" and i ~= "Configs" and v2.flag ~= nil) then
3534
if (v2.flag == i) then
3535
pcall(function()
3536
v2:Set(v)
3537
end)
3538
end
3539
end
3540
end
3541
end
3542
end)
3543
end
3544
end)
3545
3546
configSystem.Delete = configSystem.sector:AddButton("Delete", function()
3547
for i,v in pairs(listfiles(configSystem.configFolder)) do
3548
Config:Remove(tostring(v):gsub(configSystem.configFolder .. "\\", ""):gsub(".txt", ""))
3549
end
3550
3551
if (not Config:Get() or Config:Get() == "") then return end
3552
if (not isfile(configSystem.configFolder .. "/" .. Config:Get() .. ".txt")) then return end
3553
delfile(configSystem.configFolder .. "/" .. Config:Get() .. ".txt")
3554
3555
for i,v in pairs(listfiles(configSystem.configFolder)) do
3556
if v:find(".txt") then
3557
Config:Add(tostring(v):gsub(configSystem.configFolder .. "\\", ""):gsub(".txt", ""))
3558
end
3559
end
3560
end)
3561
3562
return configSystem
3563
end
3564
3565
--[[ not finished lol
3566
function tab:CreatePlayerlist(name)
3567
local list = { }
3568
list.name = name or ""
3569
3570
list.Main = Instance.new("Frame", tab.TabPage)
3571
list.Main.Name = list.name:gsub(" ", "") .. "Sector"
3572
list.Main.BorderColor3 = window.theme.outlinecolor
3573
list.Main.ZIndex = 2
3574
list.Main.Size = UDim2.fromOffset(window.size.X.Offset - 22, 220)
3575
list.Main.BackgroundColor3 = window.theme.sectorcolor
3576
list.Main.Position = UDim2.new(0, 11, 0, 12)
3577
3578
tab.SectorsLeft[#tab.SectorsLeft + 1] = 220
3579
--tab.SectorsRight[#tab.SectorsLeft + 1].space = 220
3580
3581
list.Line = Instance.new("Frame", list.Main)
3582
list.Line.Name = "line"
3583
list.Line.ZIndex = 2
3584
list.Line.Size = UDim2.fromOffset(list.Main.Size.X.Offset + 2, 1)
3585
list.Line.BorderSizePixel = 0
3586
list.Line.Position = UDim2.fromOffset(-1, -1)
3587
list.Line.BackgroundColor3 = window.theme.accentcolor
3588
3589
list.BlackOutline = Instance.new("Frame", list.Main)
3590
list.BlackOutline.Name = "blackline"
3591
list.BlackOutline.ZIndex = 1
3592
list.BlackOutline.Size = list.Main.Size + UDim2.fromOffset(4, 4)
3593
list.BlackOutline.BorderSizePixel = 0
3594
list.BlackOutline.BackgroundColor3 = window.theme.outlinecolor2
3595
list.BlackOutline.Position = UDim2.fromOffset(-2, -2)
3596
3597
local size = textservice:GetTextSize(list.name, 13, window.theme.font, Vector2.new(2000, 2000))
3598
list.Label = Instance.new("TextLabel", list.Main)
3599
list.Label.AnchorPoint = Vector2.new(0,0.5)
3600
list.Label.Position = UDim2.fromOffset(12, -1)
3601
list.Label.Size = UDim2.fromOffset(math.clamp(textservice:GetTextSize(list.name, 13, window.theme.font, Vector2.new(200,300)).X + 10, 0, list.Main.Size.X.Offset), size.Y)
3602
list.Label.BackgroundTransparency = 1
3603
list.Label.BorderSizePixel = 0
3604
list.Label.ZIndex = 4
3605
list.Label.Text = list.name
3606
list.Label.TextColor3 = Color3.new(1,1,2552/255)
3607
list.Label.TextStrokeTransparency = 1
3608
list.Label.Font = window.theme.font
3609
list.Label.TextSize = 13
3610
3611
list.LabelBackFrame = Instance.new("Frame", list.Label)
3612
list.LabelBackFrame.Name = "labelframe"
3613
list.LabelBackFrame.ZIndex = 3
3614
list.LabelBackFrame.Size = UDim2.fromOffset(list.Label.Size.X.Offset, 10)
3615
list.LabelBackFrame.BorderSizePixel = 0
3616
list.LabelBackFrame.BackgroundColor3 = Color3.fromRGB(30, 30, 30)
3617
list.LabelBackFrame.Position = UDim2.fromOffset(0, 6)
3618
3619
list.Items = Instance.new("ScrollingFrame", list.Main)
3620
list.Items.Name = "items"
3621
list.Items.ZIndex = 2
3622
list.Items.ScrollBarThickness = 1
3623
list.Items.BackgroundTransparency = 1
3624
list.Items.Size = list.Main.Size - UDim2.fromOffset(10, 15)
3625
list.Items.ScrollingDirection = "Y"
3626
list.Items.BorderSizePixel = 0
3627
list.Items.Position = UDim2.fromOffset(5, 10)
3628
list.Items.CanvasSize = list.Items.Size
3629
3630
list.ListLayout = Instance.new("UIListLayout", list.Items)
3631
list.ListLayout.FillDirection = Enum.FillDirection.Vertical
3632
list.ListLayout.SortOrder = Enum.SortOrder.LayoutOrder
3633
list.ListLayout.Padding = UDim.new(0, 0)
3634
3635
list.ListPadding = Instance.new("UIPadding", list.Items)
3636
list.ListPadding.PaddingTop = UDim.new(0, 2)
3637
list.ListPadding.PaddingLeft = UDim.new(0, 6)
3638
list.ListPadding.PaddingRight = UDim.new(0, 6)
3639
3640
list.items = { }
3641
function list:AddPlayer(Player)
3642
local player = { }
3643
3644
player.Main = Instance.new("Frame", list.Items)
3645
player.Main.Name = Player.Name
3646
player.Main.BorderColor3 = window.theme.outlinecolor
3647
player.Main.ZIndex = 3
3648
player.Main.Size = UDim2.fromOffset(list.Items.AbsoluteSize.X - 12, 20)
3649
player.Main.BackgroundColor3 = window.theme.sectorcolor
3650
player.Main.Position = UDim2.new(0, 0, 0, 0)
3651
3652
table.insert(list.items, Player)
3653
list.Items.CanvasSize = UDim2.fromOffset(list.Items.AbsoluteSize.X, (#list.items * 20))
3654
list.Items.Size = UDim2.fromOffset(list.Items.AbsoluteSize.X, math.clamp(list.Items.CanvasSize.Y.Offset, 0, 205))
3655
return player
3656
end
3657
3658
function list:RemovePlayer(Player)
3659
local p = list.Items:FindFirstChild(Player)
3660
if p then
3661
for i,v in pairs(list.items) do
3662
if v == Player then
3663
table.remove(list.items, i)
3664
end
3665
end
3666
3667
p:Remove()
3668
list.Items.CanvasSize = UDim2.fromOffset(list.Items.AbsoluteSize.X, (#list.items * 90))
3669
end
3670
end
3671
3672
for i,v in pairs(game:GetService("Players"):GetPlayers()) do
3673
list:AddPlayer(v)
3674
end
3675
3676
game:GetService("Players").PlayerAdded:Connect(function(v)
3677
list:AddPlayer(v)
3678
end)
3679
3680
return list
3681
end
3682
]]--
3683
3684
table.insert(window.Tabs, tab)
3685
return tab
3686
end
3687
3688
return window
3689
end
3690
3691
local Version = {
3692
Value = "0.0.1"
3693
}
3694
3695
local target_aim = {
3696
Aiming = {
3697
Target = {
3698
Enabled = nil,
3699
Key = nil,
3700
Prediction = nil,
3701
Radius = nil,
3702
TargetPart = nil,
3703
Alerts = nil,
3704
JumpOffset = nil,
3705
TargetStats = nil,
3706
LookAt = nil
3707
}
3708
}
3709
}
3710
3711
3712
3713
3714
3715
3716
local NotifyLibrary = loadstring(game:HttpGet("https://raw.githubusercontent.com/Kinlei/Dynissimo/main/Scripts/AkaliNotif.lua"))()
3717
local Notify = NotifyLibrary.Notify
3718
local Window = library:CreateWindow("fuxk u fuxk azure bitxh", Vector2.new(500, 350), Enum.KeyCode.RightShift)
3719
3720
local AimingTab = Window:CreateTab("lame tab")
3721
local MiscTab = Window:CreateTab("hide")
3722
local ExtraTab = Window:CreateTab("bullshit")
3723
3724
local MovementTab = MiscTab:CreateSector("Movement", "left")
3725
local MiscSec = MiscTab:CreateSector("miscellaneous","left")
3726
local FakeAnimationsSec = MiscTab:CreateSector("Fake Animations", "left")
3727
local AASec = MiscTab:CreateSector("Anti Lock", "right")
3728
3729
local UtilitiesSec = AimingTab:CreateSector("Utilities", "left")
3730
local TargetLockSection = AimingTab:CreateSector("Target", "left")
3731
local AimingLockSection = AimingTab:CreateSector("Aim Assist", "right")
3732
3733
MiscSec:AddToggle("AntiFling", false, function(parameter)
3734
game.Players.LocalPlayer.Character.HumanoidRootPart.Anchored = parameter
3735
end)
3736
3737
3738
3739
3740
3741
FakeAnimationsSec:AddDropdown("Run", {"None","Rthro", "Zombie","Werewolf","Ninja","Toy","Superhero","OldSchool","Cartoony","Stylish","Vampire"}, "None", false, function(dropdown)
3742
zxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx = dropdown
3743
end)
3744
3745
game:GetService("RunService").Stepped:Connect(function ()
3746
if zxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx == "None" then
3747
elseif zxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx == "Rthro" then
3748
player.Character.Animate.run.RunAnim.AnimationId = "http://www.roblox.com/asset/?id=2510198475"
3749
elseif zxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx == "Werewolf" then
3750
player.Character.Animate.run.RunAnim.AnimationId = "http://www.roblox.com/asset/?id=1083216690"
3751
elseif zxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx == "Zombie" then
3752
player.Character.Animate.run.RunAnim.AnimationId = "http://www.roblox.com/asset/?id=616163682"
3753
elseif zxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx == "Ninja" then
3754
player.Character.Animate.run.RunAnim.AnimationId = "http://www.roblox.com/asset/?id=656118852"
3755
elseif zxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx == "Toy" then
3756
player.Character.Animate.run.RunAnim.AnimationId = "http://www.roblox.com/asset/?id=782842708"
3757
elseif zxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx == "Superhero" then
3758
player.Character.Animate.run.RunAnim.AnimationId = "http://www.roblox.com/asset/?id=616117076"
3759
elseif zxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx == "OldSchool" then
3760
player.Character.Animate.run.RunAnim.AnimationId = "http://www.roblox.com/asset/?id=5319844329"
3761
elseif zxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx == "Cartoony" then
3762
player.Character.Animate.run.RunAnim.AnimationId = "http://www.roblox.com/asset/?id=742638842"
3763
elseif zxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx == "Stylish" then
3764
player.Character.Animate.run.RunAnim.AnimationId = "http://www.roblox.com/asset/?id=616140816"
3765
elseif zxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx == "Vampire" then
3766
player.Character.Animate.run.RunAnim.AnimationId = "http://www.roblox.com/asset/?id=1083462077"
3767
end
3768
end)
3769
3770
local SpeedBindxd = MovementTab:AddToggle("Speed", false, function(parameter)
3771
speedenablelolol = parameter
3772
end)
3773
3774
SpeedBindxd:AddKeybind()
3775
3776
spawn(function()
3777
runservice.Heartbeat:Connect(function()
3778
if speedenablelolol == true then
3779
player.Character.HumanoidRootPart.CFrame = player.Character.HumanoidRootPart.CFrame + player.Character.Humanoid.MoveDirection * SpeedValue
3780
end
3781
end)
3782
end)
3783
3784
MovementTab:AddSlider("Speed Amount", 1,1,5000,10, function(State)
3785
SpeedValue = State/1000
3786
end)
3787
3788
MovementTab:AddToggle("Auto Jump", false, function(parameter)
3789
AutoJumpXDlOLOLOL = parameter
3790
end)
3791
3792
local targewttstrafebind = MovementTab:AddToggle("Target Strafe", false, function(parameter)
3793
targetstrafeenabled = parameter
3794
end)
3795
3796
targewttstrafebind:AddKeybind()
3797
3798
MovementTab:AddSlider("Speed", 1,0,10,100, function(State)
3799
speedtargetlocks = State
3800
end)
3801
3802
MovementTab:AddSlider("Distance", 1,0,20,100, function(State)
3803
distancetargetlol = State
3804
end)
3805
3806
MovementTab:AddSlider("Height", 1,0,20,100, function(State)
3807
heighttargetlol = State
3808
end)
3809
3810
local FlightBindxdxd = MovementTab:AddToggle("Flight", false, function(parameter)
3811
if parameter then
3812
FlyLoop = game:GetService("RunService").Stepped:Connect(function()
3813
spawn(function()
3814
pcall(function()
3815
local speed = FlySpeed
3816
local velocity = Vector3.new(0, 1, 0)
3817
local UserInputService = game:GetService("UserInputService")
3818
3819
if UserInputService:IsKeyDown(Enum.KeyCode.W) then
3820
velocity = velocity + (workspace.CurrentCamera.CoordinateFrame.lookVector * speed)
3821
end
3822
if UserInputService:IsKeyDown(Enum.KeyCode.A) then
3823
velocity = velocity + (workspace.CurrentCamera.CoordinateFrame.rightVector * -speed)
3824
end
3825
if UserInputService:IsKeyDown(Enum.KeyCode.S) then
3826
velocity = velocity + (workspace.CurrentCamera.CoordinateFrame.lookVector * -speed)
3827
end
3828
if UserInputService:IsKeyDown(Enum.KeyCode.D) then
3829
velocity = velocity + (workspace.CurrentCamera.CoordinateFrame.rightVector * speed)
3830
end
3831
3832
player.Character.HumanoidRootPart.Velocity = velocity
3833
player.Character.Humanoid:ChangeState("Freefall")
3834
end)
3835
end)
3836
end)
3837
elseif parameter == false and FlyLoop then
3838
FlyLoop:Disconnect()
3839
player.Character.Humanoid:ChangeState("Landing")
3840
end
3841
end)
3842
3843
FlightBindxdxd:AddKeybind()
3844
3845
MovementTab:AddSlider("fag speed", 1,1,5000,1, function(State)
3846
FlySpeed = State/1000*50
3847
end)
3848
3849
spawn(function()
3850
runservice.Heartbeat:Connect(function()
3851
if targetstrafeenabled and target_aim.Aiming.Target.Enabled and TargetAimEnabled then
3852
aroundtarget(speedtargetlocks,distancetargetlol,heighttargetlol,AZURE_TmKALRSX)
3853
end
3854
end)
3855
end)
3856
3857
AASec:AddButton("die retard",function()
3858
for _,parts in pairs(player.Character:GetChildren()) do
3859
if parts:IsA("BasePart") then
3860
parts:Destroy()
3861
end
3862
end
3863
end)
3864
3865
local AABindLOL = AASec:AddToggle("Enable", false, function(parameter)
3866
aaenabled = parameter
3867
end)
3868
3869
AABindLOL:AddKeybind()
3870
3871
AASec:AddDropdown("Mode", {"Custom","Prediction Changer", "Prediction Disabler","Up","Down","AirOrthodox","Prediction Multiplier", "Spinbot Desync"}, "Custom", false, function(dropdown)
3872
aamodex = dropdown
3873
end)
3874
3875
AASec:AddSlider("Custom X", -10000,10000,10000,1, function(State)
3876
x_val = State
3877
end)
3878
3879
AASec:AddSlider("Custom Y", -10000,10000,10000,1, function(State)
3880
y_val = State
3881
end)
3882
3883
AASec:AddSlider("Custom Z", -10000,10000,10000,1, function(State)
3884
z_val = State
3885
end)
3886
AASec:AddLabel""
3887
AASec:AddSlider("faggot xhanger", -20,5,20,1, function(State)
3888
Custom123 = State
3889
end)
3890
3891
AASec:AddLabel""
3892
3893
AASec:AddSlider("Desync Angles", -1000,1000,1000,1, function(State)
3894
DesyncAngles = State
3895
end)
3896
3897
local heartbeat = game:GetService("RunService").Heartbeat
3898
local renderstepped = game:GetService("RunService").RenderStepped
3899
local stepped = game:GetService("RunService").Stepped
3900
local v3 = Vector3.new
3901
local hrp = game.Players.LocalPlayer.Character.HumanoidRootPart
3902
local lp = game.Players.LocalPlayer
3903
3904
spawn(function()
3905
heartbeat:Connect(function()
3906
if player.Character.Humanoid.Health <= 10 then
3907
AABindLOL:Set(false)
3908
end
3909
end)
3910
end)
3911
3912
spawn(function()
3913
local hrp, c, vel, movel = nil, nil, nil, 0.1
3914
c = lp.Character
3915
hrp = lp.Character.HumanoidRootPart
3916
while true do
3917
heartbeat:Wait()
3918
while aaenabled and not (c and c.Parent and hrp and hrp.Parent) do
3919
heartbeat:Wait()
3920
c = lp.Character
3921
hrp = lp.Character.HumanoidRootPart
3922
end
3923
if aaenabled and c and c.Parent and hrp and hrp.Parent and aamodex == "Custom" then
3924
vel = hrp.Velocity
3925
hrp.Velocity = vel*-0+v3(x_val,y_val,z_val)
3926
renderstepped:Wait()
3927
hrp.Velocity = vel
3928
stepped:Wait()
3929
if c and c.Parent and hrp and hrp.Parent then
3930
hrp.Velocity = vel + v3(0, movel, 0)
3931
movel = movel * -1
3932
end
3933
elseif aaenabled and c and c.Parent and hrp and hrp.Parent and aamodex == "Prediction Changer" then
3934
vel = hrp.Velocity
3935
hrp.Velocity = vel*Custom123+v3(0,0,0)
3936
renderstepped:Wait()
3937
hrp.Velocity = vel
3938
stepped:Wait()
3939
if c and c.Parent and hrp and hrp.Parent then
3940
hrp.Velocity = vel + v3(0, movel, 0)
3941
movel = movel * -1
3942
end
3943
3944
elseif aaenabled and c and c.Parent and hrp and hrp.Parent and aamodex == "Prediction Disabler" then
3945
vel = hrp.Velocity
3946
hrp.Velocity = vel*-0+v3(-0,-0,-0)
3947
renderstepped:Wait()
3948
hrp.Velocity = vel
3949
stepped:Wait()
3950
if c and c.Parent and hrp and hrp.Parent then
3951
hrp.Velocity = vel + v3(0, movel, 0)
3952
movel = movel * -1
3953
end
3954
elseif aaenabled and c and c.Parent and hrp and hrp.Parent and aamodex == "Up" then
3955
vel = hrp.Velocity
3956
hrp.Velocity = vel*-0+v3(-0,10000000000000000000,-0)
3957
renderstepped:Wait()
3958
hrp.Velocity = vel
3959
stepped:Wait()
3960
if c and c.Parent and hrp and hrp.Parent then
3961
hrp.Velocity = vel + v3(0, movel, 0)
3962
movel = movel * -1
3963
end
3964
elseif aaenabled and c and c.Parent and hrp and hrp.Parent and aamodex == "Down" then
3965
vel = hrp.Velocity
3966
hrp.Velocity = vel*-0+v3(-0,-10000000000000000000,-0)
3967
renderstepped:Wait()
3968
hrp.Velocity = vel
3969
stepped:Wait()
3970
if c and c.Parent and hrp and hrp.Parent then
3971
hrp.Velocity = vel + v3(0, movel, 0)
3972
movel = movel * -1
3973
end
3974
elseif aaenabled and c and c.Parent and hrp and hrp.Parent and aamodex == "AirOrthodox" then
3975
vel = hrp.Velocity
3976
hrp.Velocity = vel*1+v3(77,77,77)
3977
renderstepped:Wait()
3978
hrp.Velocity = vel
3979
stepped:Wait()
3980
if c and c.Parent and hrp and hrp.Parent then
3981
hrp.Velocity = vel + v3(0, movel, 0)
3982
movel = movel * -1
3983
end
3984
elseif aaenabled and c and c.Parent and hrp and hrp.Parent and aamodex == "Prediction Multiplier" then
3985
vel = hrp.Velocity
3986
hrp.Velocity = vel*7+v3(0,0,0)
3987
renderstepped:Wait()
3988
hrp.Velocity = vel
3989
stepped:Wait()
3990
if c and c.Parent and hrp and hrp.Parent then
3991
hrp.Velocity = vel + v3(0, movel, 0)
3992
movel = movel * -1
3993
end
3994
elseif aaenabled and c and c.Parent and hrp and hrp.Parent and aamodex == "Spinbot Desync" then
3995
vel = hrp.Velocity
3996
hrp.Velocity = vel * 0 + v3(0,10000000000000000000,0)
3997
renderstepped:Wait()
3998
if c and c.Parent and hrp and hrp.Parent then
3999
hrp.Velocity = vel
4000
end
4001
player.Character.HumanoidRootPart.CFrame = player.Character.HumanoidRootPart.CFrame * CFrame.Angles(0, math.rad(DesyncAngles), 0)
4002
end
4003
end
4004
end)
4005
4006
4007
4008
spawn(function()
4009
runservice.Heartbeat:Connect(function()
4010
if AutoJumpXDlOLOLOL == true and player.Character.Humanoid:GetState() ~= Enum.HumanoidStateType.Freefall and player.Character.Humanoid.MoveDirection.Magnitude > 0 then
4011
player.Character.Humanoid:ChangeState("Jumping")
4012
settotruexdxd:Set(true)
4013
end
4014
4015
end)
4016
end)
4017
4018
settotruexdxd = UtilitiesSec:AddToggle("No Jump Cooldown", false, function(parameter)
4019
nn_nojumpcooldown = parameter
4020
end)
4021
4022
spawn(function()
4023
runservice.Heartbeat:Connect(function()
4024
if nn_nojumpcooldown then
4025
player.Character.Humanoid.UseJumpPower = false
4026
else
4027
player.Character.Humanoid.UseJumpPower = true
4028
end
4029
end)
4030
end)
4031
4032
UtilitiesSec:AddToggle("No Slowdown", false, function(parameter)
4033
nn_noslowdown = parameter
4034
end)
4035
4036
spawn(function()
4037
runservice.Heartbeat:Connect(function()
4038
if nn_noslowdown then
4039
local bodyeffectsBounderies = player.Character.BodyEffects.Movement:FindFirstChild('NoJumping') or player.Character.BodyEffects.Movement:FindFirstChild('ReduceWalk') or player.Character.BodyEffects.Movement:FindFirstChild('NoWalkSpeed')
4040
if bodyeffectsBounderies then
4041
bodyeffectsBounderies:Destroy()
4042
end
4043
if player.Character.BodyEffects.Reload.Value == true then
4044
player.Character.BodyEffects.Reload.Value = false
4045
end
4046
end
4047
end)
4048
end)
4049
4050
AimingLockSection:AddToggle("Enabled", false, function(parameter)
4051
aimbotenab = parameter
4052
end)
4053
4054
AimingLockSection:AddKeybind("Keybind",nil,function (val)
4055
botbindlol = val
4056
end)
4057
4058
AimingLockSection:AddTextbox("Prediction", nil, function(State)
4059
aimbotprediction = State
4060
end)
4061
4062
AimingLockSection:AddDropdown("Aim-Part", {"Head", "HumanoidRootPart", "UpperTorso", "LowerTorso"}, "HumanoidRootPart", false, function(dropdown)
4063
oldvallol = dropdown
4064
end)
4065
4066
AimingLockSection:AddToggle("Smoothing", false, function(parameter)
4067
SmoothingEnabLOLL = parameter
4068
end)
4069
4070
AimingLockSection:AddTextbox("Smoothing", nil, function(State)
4071
SmoothingValIg = State
4072
end)
4073
4074
AimingLockSection:AddDropdown("Smoothing Style", {"Linear", "Sine", "Back", "Quad","Quart", "Quint", "Bounce", "Elastic","Exponential", "Circular", "Cubic"}, "Linear", false, function(dropdown)
4075
smoothingtypexd = dropdown
4076
end)
4077
4078
AimingLockSection:AddDropdown("Smoothing Direction", {"In", "Out", "InOut"}, "InOut", false, function(dropdown)
4079
easingdirectionxdxlol = dropdown
4080
end)
4081
4082
AimingLockSection:AddToggle("Jump Part", false, function(parameter)
4083
jumppartthingy = parameter
4084
end)
4085
4086
4087
AimingLockSection:AddDropdown("Jump Part Value", {"Head", "HumanoidRootPart", "UpperTorso", "LowerTorso","RightUpperLeg","RightLowerLeg","RightFoot","LeftUpperLeg","LeftLowerLeg","LeftFoot"}, "RightFoot", false, function(dropdown)
4088
jumppartvaluesxd = dropdown
4089
end)
4090
4091
spawn(function()
4092
runservice.Stepped:Connect(function()
4093
if AZURE_TmKALxRxSX.Character.Humanoid:GetState() == Enum.HumanoidStateType.Freefall then
4094
aimbotpartxd = jumppartvaluesxd
4095
else
4096
aimbotpartxd = oldvallol
4097
end
4098
end)
4099
end)
4100
4101
spawn(function()
4102
uis.InputBegan:Connect(function (input)
4103
if input.KeyCode == botbindlol then
4104
AimbotBindEnabled = not AimbotBindEnabled
4105
if AimbotBindEnabled then
4106
AZURE_TmKALxRxSX = targetchosen()
4107
end
4108
end
4109
end)
4110
end)
4111
4112
4113
4114
TargetLockSection:AddToggle("Enabled", false, function(parameter)
4115
target_aim.Aiming.Target.Enabled = parameter
4116
end)
4117
4118
TargetLockSection:AddKeybind("Keybind",nil,function (val)
4119
target_aim.Aiming.Target.Key = val
4120
end)
4121
4122
TargetLockSection:AddTextbox("Prediction", nil, function(State)
4123
target_aim.Aiming.Target.Prediction = State
4124
end)
4125
4126
TargetLockSection:AddSlider("Jump Offset", -3,0,3,100, function(State)
4127
OriginalOffsetXDZX = State
4128
end)
4129
4130
spawn(function()
4131
runservice.Stepped:Connect(function()
4132
if AZURE_TmKALRSX.Character.Humanoid:GetState() == Enum.HumanoidStateType.Freefall then
4133
target_aim.Aiming.Target.JumpOffset = OriginalOffsetXDZX
4134
else
4135
target_aim.Aiming.Target.JumpOffset = 0
4136
end
4137
end)
4138
end)
4139
4140
TargetLockSection:AddDropdown("Hit-Part", {"Head", "HumanoidRootPart", "UpperTorso", "LowerTorso"}, "HumanoidRootPart", false, function(dropdown)
4141
hit_partxd = dropdown
4142
end)
4143
4144
TargetLockSection:AddToggle("Randomized", false, function(parameter)
4145
randomizatxionxd = parameter
4146
end)
4147
4148
TargetLockSection:AddToggle("Notifications", false, function(parameter)
4149
target_aim.Aiming.Target.Alerts = parameter
4150
end)
4151
4152
TargetLockSection:AddToggle("Look At", false, function(parameter)
4153
target_aim.Aiming.Target.LookAt = parameter
4154
end)
4155
4156
TargetLockSection:AddToggle("View At", false, function(parameter)
4157
viewatxd = parameter
4158
end)
4159
4160
spawn(function()
4161
runservice.Stepped:Connect(function()
4162
if target_aim.Aiming.Target.Enabled and viewatxd and TargetAimEnabled then
4163
workspace.CurrentCamera.CameraSubject = AZURE_TmKALRSX.Character.Humanoid
4164
spawn(function()
4165
if viewatxd == false then
4166
workspace.CurrentCamera.CameraSubject = player.Character.Humanoid
4167
end
4168
end)
4169
else
4170
workspace.CurrentCamera.CameraSubject = player.Character.Humanoid
4171
end
4172
end)
4173
end)
4174
4175
local dotenabled = TargetLockSection:AddToggle("Dot", false, function(parameter)
4176
dotenabledlol = parameter
4177
end)
4178
4179
dotenabled:AddColorpicker(Color3.fromRGB(168,122,207), function(ztx)
4180
colorxdlololxdxd = ztx
4181
end)
4182
4183
TargetLockSection:AddToggle("Dot on Cursor", false, function(parameter)
4184
dotoncursorx = parameter
4185
end)
4186
4187
local highlighxdxdxd = TargetLockSection:AddToggle("Highlight", false, function(parameter)
4188
hightlightendalbed = parameter
4189
end)
4190
4191
highlighxdxdxd:AddColorpicker(Color3.fromRGB(168,122,207), function(ztx)
4192
fillcolorxd = ztx
4193
end)
4194
4195
highlighxdxdxd:AddColorpicker(Color3.fromRGB(88,65,108), function(ztx)
4196
outlinecolorxdxdxd = ztx
4197
end)
4198
4199
local highlight_instance = Instance.new("Highlight",game.CoreGui)
4200
4201
spawn(function()
4202
runservice.Stepped:Connect(function()
4203
if target_aim.Aiming.Target.Enabled and hightlightendalbed and TargetAimEnabled then
4204
highlight_instance.Parent = AZURE_TmKALRSX.Character
4205
highlight_instance.FillColor = fillcolorxd
4206
highlight_instance.OutlineColor = outlinecolorxdxdxd
4207
spawn(function()
4208
if hightlightendalbed == false then
4209
highlight_instance.Parent = game.CoreGui
4210
end
4211
end)
4212
else
4213
highlight_instance.Parent = game.CoreGui
4214
end
4215
end)
4216
end)
4217
4218
TargetLockSection:AddToggle("Stats", false, function(parameter)
4219
target_aim.Aiming.Target.TargetStats = parameter
4220
end)
4221
4222
4223
4224
local dotDrawing = Drawing.new("Circle")
4225
4226
spawn(function()
4227
dotDrawing.Filled = true
4228
dotDrawing.Visible = false
4229
dotDrawing.Thickness = 2
4230
dotDrawing.Radius = 7
4231
dotDrawing.NumSides = 60
4232
end)
4233
4234
local DotParent = Instance.new("Part",game.Workspace)
4235
local newBillboard = Instance.new("BillboardGui", DotParent)
4236
4237
local newFrame = Instance.new("Frame", newBillboard)
4238
local newUiCornor = Instance.new("UICorner", newFrame)
4239
4240
task.spawn(function ()
4241
newBillboard.Name = "azure_billboarddot"
4242
newBillboard.Adornee = DotParent
4243
newBillboard.Size = UDim2.new(0.6, 0, 0.6, 0)
4244
newBillboard.AlwaysOnTop = true
4245
newFrame.Size = UDim2.new(1, 0, 1, 0)
4246
newFrame.BackgroundTransparency = 0
4247
newUiCornor.CornerRadius = UDim.new(50, 50)
4248
DotParent.CanCollide = false
4249
DotParent.Anchored = true
4250
DotParent.CFrame = CFrame.new(0,2000,0)
4251
DotParent.Transparency = 1
4252
end)
4253
4254
spawn(function()
4255
runservice.Stepped:Connect(function()
4256
if target_aim.Aiming.Target.Enabled and dotenabledlol then
4257
dotDrawing.Color = colorxdlololxdxd
4258
newFrame.BackgroundColor3 = colorxdlololxdxd
4259
if TargetAimEnabled and dotenabledlol then
4260
DotParent.CFrame = CFrame.new(AZURE_TmKALRSX.Character[target_aim.Aiming.Target.TargetPart].Position+Vector3.new(0,target_aim.Aiming.Target.JumpOffset,0)+(AZURE_TmKALRSX.Character[target_aim.Aiming.Target.TargetPart].Velocity*target_aim.Aiming.Target.Prediction))
4261
dotDrawing.Visible = false
4262
else
4263
DotParent.CFrame = CFrame.new(0,9999,0)
4264
if dotoncursorx then
4265
dotDrawing.Visible = true
4266
dotDrawing.Position = Vector2.new(mouse.X,mouse.Y + game:GetService("GuiService"):GetGuiInset().Y)
4267
spawn(function()
4268
if dotoncursorx == false then
4269
dotDrawing.Visible = false
4270
end
4271
end)
4272
end
4273
spawn(function()
4274
if dotoncursorx == false then
4275
dotDrawing.Visible = false
4276
end
4277
end)
4278
end
4279
else
4280
DotParent.CFrame = CFrame.new(0,9999,0)
4281
dotDrawing.Visible = false
4282
end
4283
end)
4284
end)
4285
4286
4287
spawn(function()
4288
runservice.Stepped:Connect(function()
4289
if randomizatxionxd then
4290
wait(0.6)
4291
player_gayparts = {"Head","UpperTorso","LowerTorso","HumanoidRootPart","RightUpperLeg","RightLowerLeg","LeftUpperLeg","LeftLowerLeg","RightUpperArm","RightLowerArm","LeftLowerArm","LeftUpperArm"}
4292
target_aim.Aiming.Target.TargetPart = player_gayparts[math.random(1,#player_gayparts)]
4293
else
4294
target_aim.Aiming.Target.TargetPart = hit_partxd
4295
end
4296
end)
4297
end)
4298
4299
spawn(function()
4300
runservice.RenderStepped:Connect(function()
4301
if AimbotBindEnabled and aimbotenab and SmoothingEnabLOLL == false then
4302
local main_cframe = CFrame.new(workspace.CurrentCamera.CFrame.p, AZURE_TmKALxRxSX.Character[aimbotpartxd].Position + AZURE_TmKALxRxSX.Character[aimbotpartxd].Velocity/aimbotprediction)
4303
workspace.CurrentCamera.CFrame = workspace.CurrentCamera.CFrame:Lerp(main_cframe, 1, Enum.EasingStyle[smoothingtypexd], Enum.EasingDirection[easingdirectionxdxlol])
4304
elseif AimbotBindEnabled and aimbotenab and SmoothingEnabLOLL == true then
4305
local main_cframe = CFrame.new(workspace.CurrentCamera.CFrame.p, AZURE_TmKALxRxSX.Character[aimbotpartxd].Position + AZURE_TmKALxRxSX.Character[aimbotpartxd].Velocity/aimbotprediction)
4306
workspace.CurrentCamera.CFrame = workspace.CurrentCamera.CFrame:Lerp(main_cframe, SmoothingValIg, Enum.EasingStyle[smoothingtypexd], Enum.EasingDirection[easingdirectionxdxlol])
4307
end
4308
end)
4309
end)
4310
4311
spawn(function()
4312
runservice.RenderStepped:Connect(function()
4313
if TargetAimEnabled and target_aim.Aiming.Target.Enabled and AZURE_TmKALRSX.Character:FindFirstChild("UpperTorso") then
4314
if target_aim.Aiming.Target.LookAt then
4315
player.Character.HumanoidRootPart.CFrame = CFrame.new(player.Character.HumanoidRootPart.CFrame.Position, Vector3.new(AZURE_TmKALRSX.Character.HumanoidRootPart.CFrame.X, player.Character.HumanoidRootPart.CFrame.Position.Y, AZURE_TmKALRSX.Character.HumanoidRootPart.CFrame.Z))
4316
player.Character.Humanoid.AutoRotate = false
4317
spawn(function ()
4318
if target_aim.Aiming.Target.LookAt == false then
4319
player.Character.Humanoid.AutoRotate = true
4320
end
4321
end)
4322
end
4323
else
4324
spawn(function()
4325
player.Character.Humanoid.AutoRotate = true
4326
end)
4327
end
4328
end)
4329
end)
4330
4331
spawn(function()
4332
uis.InputBegan:Connect(function (input)
4333
if input.KeyCode == target_aim.Aiming.Target.Key and target_aim.Aiming.Target.Enabled then
4334
TargetAimEnabled = not TargetAimEnabled
4335
if TargetAimEnabled then
4336
AZURE_TmKALRSX = targetchosen()
4337
if target_aim.Aiming.Target.Alerts then
4338
Notify({
4339
Title = "Azure [v."..Version.Value.."]",
4340
Description = "Targeting: " ..tostring(AZURE_TmKALRSX.Character.Humanoid.DisplayName),
4341
Duration = 3
4342
})
4343
end
4344
elseif not TargetAimEnabled then
4345
if target_aim.Aiming.Target.Alerts then
4346
Notify({
4347
Title = "Azure ["..Version.Value.."]",
4348
Description = "Untargeting: " ..tostring(AZURE_TmKALRSX.Character.Humanoid.DisplayName),
4349
Duration = 3
4350
})
4351
end
4352
end
4353
end
4354
end)
4355
end)
4356
4357
local mt = getrawmetatable(game)
4358
local old = mt.__namecall
4359
setreadonly(mt, false)
4360
mt.__namecall = newcclosure(function(...)
4361
local args = {...}
4362
if target_aim.Aiming.Target.Enabled and TargetAimEnabled and getnamecallmethod() == "FireServer" and args[2] == "UpdateMousePos" then
4363
args[3] = AZURE_TmKALRSX.Character[target_aim.Aiming.Target.TargetPart].Position+Vector3.new(0.01,target_aim.Aiming.Target.JumpOffset,0.01)+(AZURE_TmKALRSX.Character[target_aim.Aiming.Target.TargetPart].Velocity*target_aim.Aiming.Target.Prediction)
4364
return old(unpack(args))
4365
end
4366
return old(...)
4367
end)
4368
4369
local Azure_TargetStats = Instance.new("ScreenGui")
4370
local Background = Instance.new("Frame")
4371
local Picture = Instance.new("ImageLabel")
4372
local Top = Instance.new("Frame")
4373
local UIGradient = Instance.new("UIGradient")
4374
local UIGradient_2 = Instance.new("UIGradient")
4375
local HealthBarBackground = Instance.new("Frame")
4376
local UIGradient_3 = Instance.new("UIGradient")
4377
local HealthBar = Instance.new("Frame")
4378
local UIGradient_4 = Instance.new("UIGradient")
4379
local NameOfTarget = Instance.new("TextLabel")
4380
4381
spawn(function()
4382
Azure_TargetStats.Name = "Azure_TargetStats"
4383
Azure_TargetStats.Parent = game.CoreGui
4384
Azure_TargetStats.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
4385
4386
Background.Name = "Background"
4387
Background.Parent = Azure_TargetStats
4388
Background.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
4389
Background.BorderSizePixel = 0
4390
Background.Position = UDim2.new(0.388957828, 0, 0.700122297, 0)
4391
Background.Size = UDim2.new(0, 358, 0, 71)
4392
Background.Visible = false
4393
4394
Picture.Name = "Picture"
4395
Picture.Parent = Background
4396
Picture.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
4397
Picture.BorderSizePixel = 0
4398
Picture.Position = UDim2.new(0.0279329624, 0, 0.0704225376, 0)
4399
Picture.Size = UDim2.new(0, 59, 0, 59)
4400
Picture.Transparency = 1
4401
Picture.Image = "rbxasset://textures/ui/GuiImagePlaceholder.png"
4402
4403
Top.Name = "Top"
4404
Top.Parent = Background
4405
Top.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
4406
Top.BorderSizePixel = 0
4407
Top.Position = UDim2.new(0, 0, -0.101449274, 0)
4408
Top.Size = UDim2.new(0, 358, 0, 7)
4409
4410
UIGradient.Color = ColorSequence.new{ColorSequenceKeypoint.new(0.00, Color3.fromRGB(184, 159, 227)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(102, 88, 156))}
4411
UIGradient.Rotation = 90
4412
UIGradient.Parent = Top
4413
4414
UIGradient_2.Color = ColorSequence.new{ColorSequenceKeypoint.new(0.00, Color3.fromRGB(52, 52, 52)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(0, 0, 0))}
4415
UIGradient_2.Rotation = 90
4416
UIGradient_2.Parent = Background
4417
4418
HealthBarBackground.Name = "HealthBarBackground"
4419
HealthBarBackground.Parent = Background
4420
HealthBarBackground.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
4421
HealthBarBackground.BorderSizePixel = 0
4422
HealthBarBackground.Position = UDim2.new(0.215083793, 0, 0.348234326, 0)
4423
HealthBarBackground.Size = UDim2.new(0, 270, 0, 19)
4424
HealthBarBackground.Transparency = 1
4425
4426
UIGradient_3.Color = ColorSequence.new{ColorSequenceKeypoint.new(0.00, Color3.fromRGB(58, 58, 58)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(30, 30, 30))}
4427
UIGradient_3.Rotation = 90
4428
UIGradient_3.Parent = HealthBarBackground
4429
4430
HealthBar.Name = "HealthBar"
4431
HealthBar.Parent = HealthBarBackground
4432
HealthBar.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
4433
HealthBar.BorderSizePixel = 0
4434
HealthBar.Position = UDim2.new(-0.00336122862, 0, 0.164894029, 0)
4435
HealthBar.Size = UDim2.new(0, 130, 0, 19)
4436
4437
UIGradient_4.Color = ColorSequence.new{ColorSequenceKeypoint.new(0.00, Color3.fromRGB(184, 159, 227)), ColorSequenceKeypoint.new(1.00, Color3.fromRGB(102, 88, 156))}
4438
UIGradient_4.Rotation = 90
4439
UIGradient_4.Parent = HealthBar
4440
4441
NameOfTarget.Name = "NameOfTarget"
4442
NameOfTarget.Parent = Background
4443
NameOfTarget.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
4444
NameOfTarget.BackgroundTransparency = 1.000
4445
NameOfTarget.Position = UDim2.new(0.220670387, 0, 0.0704225376, 0)
4446
NameOfTarget.Size = UDim2.new(0, 268, 0, 19)
4447
NameOfTarget.Font = Enum.Font.Code
4448
NameOfTarget.TextColor3 = Color3.fromRGB(255, 255, 255)
4449
NameOfTarget.TextScaled = true
4450
NameOfTarget.TextSize = 14.000
4451
NameOfTarget.TextStrokeTransparency = 0.000
4452
NameOfTarget.TextWrapped = true
4453
end)
4454
4455
local IsAlive = function(GetPlayer)
4456
return GetPlayer and GetPlayer.Character and GetPlayer.Character:FindFirstChild("HumanoidRootPart") ~= nil and GetPlayer.Character:FindFirstChild("Humanoid") ~= nil and GetPlayer.Character:FindFirstChild("Head") ~= nil and true or false
4457
end
4458
4459
spawn(function()
4460
while wait() do
4461
if target_aim.Aiming.Target.TargetStats and target_aim.Aiming.Target.Enabled and TargetAimEnabled then
4462
if AZURE_TmKALRSX and IsAlive(AZURE_TmKALRSX) then
4463
Background.Visible = true
4464
NameOfTarget.Text = tostring(AZURE_TmKALRSX.Character.Humanoid.DisplayName).." ["..tostring(AZURE_TmKALRSX.Name).."]"
4465
Picture.Image = "rbxthumb://type=AvatarHeadShot&id=" ..AZURE_TmKALRSX.UserId.. "&w=420&h=420"
4466
HealthBar:TweenSize(UDim2.new(AZURE_TmKALRSX.Character.Humanoid.Health / AZURE_TmKALRSX.Character.Humanoid.MaxHealth, 0, 1, 0), "In", "Linear", 0.25)
4467
spawn(function()
4468
if target_aim.Aiming.Target.TargetStats == false then
4469
Background.Visible = false
4470
end
4471
end)
4472
end
4473
else
4474
Background.Visible = false
4475
end
4476
end
4477
end)
4478
4479
function targetchosen()
4480
local distance = math.huge
4481
local zclosest
4482
local LocalPlayer = game.Players.LocalPlayer
4483
for i, v in pairs(game.Players:GetPlayers()) do
4484
if v ~= LocalPlayer and v.Character and v.Character:FindFirstChild("Humanoid") and v.Character.Humanoid.Health ~= 0 and v.Character:FindFirstChild("HumanoidRootPart") then
4485
local pos = workspace.CurrentCamera:WorldToViewportPoint(v.Character.PrimaryPart.Position)
4486
local magnitude = (Vector2.new(pos.X, pos.Y) - Vector2.new(LocalPlayer:GetMouse().X, LocalPlayer:GetMouse().Y)).magnitude
4487
if magnitude < distance then
4488
zclosest = v
4489
distance = magnitude
4490
end
4491
end
4492
end
4493
return zclosest
4494
end
4495
4496
regera = 0
4497
4498
aroundtarget = function(speed, distance,height,target)
4499
regera = regera + speed
4500
player.Character.HumanoidRootPart.CFrame = target.Character.HumanoidRootPart.CFrame * CFrame.Angles(0, math.rad(regera), 0) * CFrame.new(0, height, distance)
4501
end