Repository navigation
Expand file tree
/
Copy pathLibrary.lua
More file actions
2773 lines (2348 loc) · 87.6 KB
/
Copy pathLibrary.lua
File metadata and controls
2773 lines (2348 loc) · 87.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
--[[
Universal UI Library
Reusable Roblox UI framework based on the original interface layout.
Neutral branding, no game-specific logic, no pause system.
]]
local Players = game:GetService("Players")
local Input = game:GetService("UserInputService")
local TweenService = game:GetService("TweenService")
local HttpService = game:GetService("HttpService")
local LocalPlayer = Players.LocalPlayer
local Library = {}
Library.__index = Library
local ColorPickerModule
local function getColorPickerModule()
if ColorPickerModule then
return ColorPickerModule
end
local ok, result = pcall(function()
local source = game:HttpGet(
"https://raw.githubusercontent.com/deepisthatdeep/Ermidklolui/main/ColorPicker.lua?rev=palette-roles-20261001"
)
return loadstring(source)()
end)
if ok and type(result) == "table" and type(result.Create) == "function" then
ColorPickerModule = result
return ColorPickerModule
end
warn("[UI Library] color picker failed to load:", result)
return nil
end
Library.Palette = {
bg = Color3.fromRGB(4, 5, 8),
card = Color3.fromRGB(8, 10, 16),
line = Color3.fromRGB(255, 255, 255),
accent = Color3.fromRGB(255, 255, 255),
accent2 = Color3.fromRGB(255, 255, 255),
glow = Color3.fromRGB(255, 255, 255),
bright = Color3.fromRGB(255, 255, 255),
text = Color3.fromRGB(255, 255, 255),
muted = Color3.fromRGB(255, 255, 255),
}
local function copy(source)
local out = {}
for key, value in pairs(source or {}) do
out[key] = value
end
return out
end
local function colorToHex(color)
return string.format(
"#%02X%02X%02X",
math.floor(color.R * 255 + .5),
math.floor(color.G * 255 + .5),
math.floor(color.B * 255 + .5)
)
end
local function hexToColor(value)
if typeof(value) == "Color3" then
return value
end
value = tostring(value or ""):gsub("#", ""):gsub("%s+", "")
if #value == 3 then
value = value:sub(1, 1):rep(2)
.. value:sub(2, 2):rep(2)
.. value:sub(3, 3):rep(2)
end
if #value ~= 6 or value:find("[^%x]") then
return nil
end
return Color3.fromRGB(
tonumber(value:sub(1, 2), 16),
tonumber(value:sub(3, 4), 16),
tonumber(value:sub(5, 6), 16)
)
end
local function make(className, parent, props)
local object = Instance.new(className)
for key, value in pairs(props or {}) do
object[key] = value
end
object.Parent = parent
return object
end
local function safeCall(callback, ...)
if typeof(callback) ~= "function" then
return
end
local args = table.pack(...)
task.spawn(function()
local ok, err = pcall(callback, table.unpack(args, 1, args.n))
if not ok then
warn("[UI Library] callback error:", err)
end
end)
end
local function proxy(initial, setter)
local valueObject = {Current = initial}
function valueObject:Get()
return self.Current
end
function valueObject:Set(value)
setter(value)
end
return valueObject
end
local function defaultParent()
if gethui then
local ok, result = pcall(gethui)
if ok and result then
return result
end
end
return LocalPlayer:WaitForChild("PlayerGui")
end
local function resolvePalette(custom)
local palette = copy(Library.Palette)
if type(custom) == "table" then
for key, value in pairs(custom) do
if palette[key] ~= nil and typeof(value) == "Color3" then
palette[key] = value
end
end
end
return palette
end
function Library:CreateWindow(cfg)
cfg = cfg or {}
local P = resolvePalette(cfg.Palette)
local DefaultPalette = copy(P)
local paletteFile = tostring(cfg.PaletteFile or "Ermidklolui_palette.json")
local function readSavedPalette()
if type(isfile) ~= "function" or type(readfile) ~= "function" then
return nil
end
local okExists, exists = pcall(isfile, paletteFile)
if not okExists or not exists then
return nil
end
local okRead, raw = pcall(readfile, paletteFile)
if not okRead or type(raw) ~= "string" then
return nil
end
local okDecode, decoded = pcall(function()
return HttpService:JSONDecode(raw)
end)
if not okDecode or type(decoded) ~= "table" then
return nil
end
local source = decoded.colors or decoded
local loaded = {}
for key in pairs(P) do
local parsed = hexToColor(source[key])
if parsed then
loaded[key] = parsed
end
end
return loaded
end
if cfg.AutoLoadPalette ~= false then
local saved = readSavedPalette()
if saved then
for key, value in pairs(saved) do
P[key] = value
end
end
end
-- Bind by semantic role, never by RGB equality: white channels remain independent.
local C = {}
for key in pairs(P) do C[key] = {paletteKey = key} end
local paletteControls = {}
-- Roblox can collect Lua wrappers even while their Instances remain parented.
-- Retain bindings strongly until a target is removed or the window is destroyed.
local paletteBindings = {}
local function themePoint(time, value)
return {Time = time, Value = value}
end
local function themeSequence(first, last)
if last ~= nil then
return {palettePoints = {themePoint(0, first), themePoint(1, last)}}
end
return {palettePoints = first}
end
local function resolve(value)
if type(value) ~= "table" then return value end
if value.paletteKey then return P[value.paletteKey] end
if value.palettePoints then
local points = {}
for _, point in ipairs(value.palettePoints) do
table.insert(points, ColorSequenceKeypoint.new(point.Time, resolve(point.Value)))
end
return ColorSequence.new(points)
end
return value
end
local function remember(object, property, value)
if type(value) == "table" and (value.paletteKey or value.palettePoints) then
paletteBindings[object] = paletteBindings[object] or {}
paletteBindings[object][property] = value
elseif paletteBindings[object] then
paletteBindings[object][property] = nil
end
end
local function paint(object, property, value)
remember(object, property, value)
object[property] = resolve(value)
end
local baseMake = make
local function make(className, parent, props)
local resolved = {}
for property, value in pairs(props or {}) do resolved[property] = resolve(value) end
local object = baseMake(className, parent, resolved)
for property, value in pairs(props or {}) do remember(object, property, value) end
return object
end
local function tween(object, info, props)
local resolved = {}
for property, value in pairs(props) do
-- Theme colors update immediately so an in-flight tween cannot restore an old palette.
if type(value) == "table" and (value.paletteKey or value.palettePoints) then
paint(object, property, value)
else
resolved[property] = value
end
end
return TweenService:Create(object, info, resolved)
end
local function refreshPalette()
for object, properties in pairs(paletteBindings) do
if object.Parent then
for property, value in pairs(properties) do object[property] = resolve(value) end
else
paletteBindings[object] = nil
end
end
end
local connections = {}
local refresh = {}
local tabs = {}
local pages = {}
local nav = {}
local alive = true
local activeTab = nil
local capturingKey = nil
local title = tostring(cfg.Title or "AETHER")
local subtitleText = tostring(cfg.SubTitle or "S P E C T R A L")
local productName = tostring(cfg.ProductName or "PRISM")
local currentPage = tostring(cfg.CurrentPage or "OVERVIEW")
local versionText = tostring(cfg.Version or "UI LIBRARY")
local toggleKey = cfg.ToggleKey
if toggleKey == nil then toggleKey = Enum.KeyCode.RightShift end
local function bind(signal, callback)
local connection = signal:Connect(callback)
table.insert(connections, connection)
return connection
end
local gui = make("ScreenGui", cfg.Parent or defaultParent(), {
Name = tostring(cfg.Name or "UniversalInterface"),
ResetOnSpawn = false,
IgnoreGuiInset = false,
Enabled = true,
ZIndexBehavior = Enum.ZIndexBehavior.Sibling,
DisplayOrder = tonumber(cfg.DisplayOrder) or 100,
})
pcall(function()
if syn and syn.protect_gui then
syn.protect_gui(gui)
end
end)
local window = make("Frame", gui, {
Size = UDim2.fromOffset(940, 610),
Position = UDim2.new(.5, -470, .5, -305),
BackgroundColor3 = C.bg,
BorderSizePixel = 0,
ClipsDescendants = true,
Active = true,
})
make("UIStroke", window, {
Color = C.line,
Thickness = 1,
})
local windowGradient = make("UIGradient", window, {
Rotation = 118,
Color = themeSequence({
themePoint(0, C.bg),
themePoint(.38, Color3.fromRGB(230, 230, 230)),
themePoint(.72, Color3.fromRGB(210, 210, 210)),
themePoint(1, C.bg),
}),
})
local outerGlow = make("Frame", window, {
Name = "OuterGlow",
Position = UDim2.fromOffset(5, 5),
Size = UDim2.new(1, -10, 1, -10),
BackgroundTransparency = 1,
BorderSizePixel = 0,
})
make("UIStroke", outerGlow, {
Color = C.accent2,
Thickness = 1,
Transparency = .82,
})
local innerGlow = make("Frame", window, {
Name = "InnerGlow",
Position = UDim2.fromOffset(10, 10),
Size = UDim2.new(1, -20, 1, -20),
BackgroundTransparency = 1,
BorderSizePixel = 0,
})
make("UIStroke", innerGlow, {
Color = C.accent,
Thickness = 1,
Transparency = .88,
})
local scale = make("UIScale", window, {
Scale = 1,
})
local function text(parent, value, x, y, w, h, size, color, font)
return make("TextLabel", parent, {
Text = tostring(value or ""),
Position = UDim2.fromOffset(x, y),
Size = UDim2.fromOffset(w, h),
BackgroundTransparency = 1,
TextColor3 = color or C.text,
TextStrokeColor3 = Color3.fromRGB(0, 0, 0),
TextStrokeTransparency = .22,
Font = font or Enum.Font.Code,
TextSize = size or 12,
TextWrapped = true,
TextXAlignment = Enum.TextXAlignment.Left,
TextYAlignment = Enum.TextYAlignment.Center,
ZIndex = 9,
})
end
-- Layered celestial/prismatic background field.
local art = make("Frame", window, {
Name = "SpectralField",
Size = UDim2.fromScale(1, 1),
BackgroundTransparency = 1,
})
local glowA = make("Frame", art, {
Position = UDim2.fromOffset(535, -145),
Size = UDim2.fromOffset(380, 380),
BackgroundColor3 = C.accent2,
BackgroundTransparency = .95,
BorderSizePixel = 0,
})
make("UICorner", glowA, {CornerRadius = UDim.new(1, 0)})
make("UIGradient", glowA, {
Rotation = 35,
Transparency = NumberSequence.new({
NumberSequenceKeypoint.new(0, .82),
NumberSequenceKeypoint.new(.45, .92),
NumberSequenceKeypoint.new(1, 1),
}),
})
local glowB = make("Frame", art, {
Position = UDim2.fromOffset(-155, 265),
Size = UDim2.fromOffset(430, 430),
BackgroundColor3 = C.accent,
BackgroundTransparency = .96,
BorderSizePixel = 0,
})
make("UICorner", glowB, {CornerRadius = UDim.new(1, 0)})
local horizon = make("Frame", art, {
Position = UDim2.fromOffset(175, 74),
Size = UDim2.fromOffset(655, 2),
BackgroundColor3 = C.glow,
BackgroundTransparency = .82,
BorderSizePixel = 0,
})
make("UIGradient", horizon, {
Color = themeSequence({
themePoint(0, C.accent),
themePoint(.5, C.accent2),
themePoint(1, C.accent),
}),
Transparency = NumberSequence.new({
NumberSequenceKeypoint.new(0, 1),
NumberSequenceKeypoint.new(.15, .2),
NumberSequenceKeypoint.new(.5, 0),
NumberSequenceKeypoint.new(.85, .2),
NumberSequenceKeypoint.new(1, 1),
}),
})
local function line(parent, x, y, w, h, angle, color, transparency)
return make("Frame", parent, {
Position = UDim2.fromOffset(x, y),
Size = UDim2.fromOffset(w, h),
Rotation = angle or 0,
BackgroundColor3 = color or C.line,
BackgroundTransparency = transparency or 0,
BorderSizePixel = 0,
})
end
local function diamond(parent, x, y, size, color, transparency)
return line(
parent,
x,
y,
size or 7,
size or 7,
45,
color or C.line,
transparency or 0
)
end
local function ring(parent, x, y, size, color, transparency, thickness)
local holder = make("Frame", parent, {
Position = UDim2.fromOffset(x, y),
Size = UDim2.fromOffset(size, size),
BackgroundTransparency = 1,
BorderSizePixel = 0,
})
make("UICorner", holder, {
CornerRadius = UDim.new(1, 0),
})
make("UIStroke", holder, {
Color = color or C.line,
Transparency = transparency or 0,
Thickness = thickness or 1,
})
return holder
end
-- Celestial field: circular halos, orbital arcs, star nodes, and constellation links.
-- This replaces the old rigid lattice/grid while keeping the original frame language.
local function dot(parent, x, y, size, color, transparency)
local node = make("Frame", parent, {
Position = UDim2.fromOffset(x, y),
Size = UDim2.fromOffset(size or 3, size or 3),
BackgroundColor3 = color or C.glow,
BackgroundTransparency = transparency or 0,
BorderSizePixel = 0,
})
make("UICorner", node, {
CornerRadius = UDim.new(1, 0),
})
return node
end
local function segment(parent, x0, y0, x1, y1, color, transparency, thickness)
local dx, dy = x1 - x0, y1 - y0
local length = math.sqrt(dx * dx + dy * dy)
local edge = line(parent, (x0 + x1) / 2, (y0 + y1) / 2,
length, thickness or 1, math.deg(math.atan2(dy, dx)), color, transparency)
edge.AnchorPoint = Vector2.new(.5, .5)
return edge
end
local function orbitArc(parent, cx, cy, radius, startAngle, endAngle, segments, color, transparency, thickness)
segments = math.max(4, segments or 18)
local step = (endAngle - startAngle) / segments
for index = 0, segments - 1 do
local a0 = math.rad(startAngle + step * index)
local a1 = math.rad(startAngle + step * (index + 1))
local x0 = cx + math.cos(a0) * radius
local y0 = cy + math.sin(a0) * radius
local x1 = cx + math.cos(a1) * radius
local y1 = cy + math.sin(a1) * radius
segment(parent, x0, y0, x1, y1, color or C.line,
transparency or .9, thickness or 1)
end
end
local function constellation(parent, points, color, transparency)
for index, point in ipairs(points) do
local nodeColor = point[4] or color or C.glow
local nodeSize = point[3] or 3
dot(
parent,
point[1] - nodeSize / 2,
point[2] - nodeSize / 2,
nodeSize,
nodeColor,
math.max(0, (transparency or .7) - .18)
)
if index > 1 and point[5] ~= false then
local previous = points[index - 1]
segment(parent, previous[1], previous[2], point[1], point[2],
color or C.line, transparency or .9, 1)
end
end
end
local function starburst(parent, x, y, radius, transparency)
local halo = ring(parent, x - radius, y - radius, radius * 2,
C.glow, math.min(.96, transparency + .28), 1)
halo.Name = "StarHalo"
segment(parent, x - radius, y, x + radius, y, C.glow, transparency, 1)
segment(parent, x, y - radius, x, y + radius, C.glow, transparency, 1)
diamond(parent, x - 2, y - 2, 4, C.bright, transparency * .6)
end
local function orbitDetails(parent, cx, cy, radius, count, startAngle, sweep)
for index = 0, count - 1 do
local angle = math.rad(startAngle + sweep * index / count)
local major = index % 4 == 0
local inner = radius - (major and 6 or 2)
segment(parent, cx + math.cos(angle) * inner, cy + math.sin(angle) * inner,
cx + math.cos(angle) * radius, cy + math.sin(angle) * radius,
C.line, major and .64 or .85, 1)
if major then
local outer = radius + 5
dot(parent, cx + math.cos(angle) * outer - 1,
cy + math.sin(angle) * outer - 1, 2, C.glow, .58)
end
end
end
local function etchedStroke(parent, transparency)
local edge = make("UIStroke", parent, {
Color = C.line, Thickness = 1, Transparency = transparency or .45,
ApplyStrokeMode = Enum.ApplyStrokeMode.Border,
})
make("UIGradient", edge, {
Rotation = 35,
Transparency = NumberSequence.new({
NumberSequenceKeypoint.new(0, .08),
NumberSequenceKeypoint.new(.3, .66),
NumberSequenceKeypoint.new(.5, .22),
NumberSequenceKeypoint.new(.75, .72),
NumberSequenceKeypoint.new(1, .08),
}),
})
return edge
end
-- Keep only quiet perimeter structure.
for _, x in ipairs({8, 930}) do
line(art, x, 8, 1, 594, 0, C.line, .2)
end
for _, y in ipairs({8, 600}) do
line(art, 8, y, 922, 1, 0, C.line, .2)
end
for _, cornerData in ipairs({
{15, 15},
{815, 15},
{15, 533},
{815, 533},
}) do
line(art, cornerData[1], cornerData[2], 20, 1, 0, C.accent, .28)
line(art, cornerData[1], cornerData[2], 1, 20, 0, C.accent, .28)
diamond(art, cornerData[1] + 5, cornerData[2] + 5, 7, C.line, .35)
end
-- Header constellation crown.
orbitArc(art, 421, 42, 66, 205, 335, 16, C.accent2, .78, 1)
orbitArc(art, 421, 42, 48, 202, 338, 14, C.accent, .84, 1)
diamond(art, 417, 28, 8, C.accent, .12)
dot(art, 363, 54, 3, C.glow, .45)
dot(art, 477, 54, 3, C.glow, .45)
constellation(art, {
{352, 47, 3, C.accent2},
{383, 31, 4, C.glow},
{421, 28, 5, C.accent},
{459, 31, 4, C.glow},
{490, 47, 3, C.accent2},
}, C.line, .78)
-- Large upper-left halo group in the main content field.
ring(art, 225, 104, 154, C.accent2, .91, 1)
ring(art, 247, 126, 110, C.line, .88, 1)
ring(art, 270, 149, 64, C.accent, .84, 1)
orbitArc(art, 302, 181, 93, 18, 152, 20, C.accent2, .84, 1)
orbitArc(art, 302, 181, 76, 196, 322, 18, C.accent, .88, 1)
dot(art, 299, 178, 6, C.glow, .5)
diamond(art, 345, 116, 5, C.accent2, .42)
constellation(art, {
{215, 126, 3, C.glow},
{248, 112, 4, C.accent2},
{281, 136, 3, C.glow},
{315, 120, 5, C.accent},
{350, 145, 3, C.glow},
{379, 127, 3, C.accent2},
}, C.line, .88)
-- Main right-side orrery: all circular, no cross-grid.
local orbit = make("Frame", art, {
Name = "CelestialOrrery",
Position = UDim2.fromOffset(610, 135),
Size = UDim2.fromOffset(235, 235),
BackgroundTransparency = 1,
BorderSizePixel = 0,
})
ring(orbit, 5, 5, 225, C.accent2, .86, 1)
ring(orbit, 24, 24, 187, C.line, .83, 1)
ring(orbit, 48, 48, 139, C.accent, .87, 1)
ring(orbit, 77, 77, 81, C.line, .82, 1)
ring(orbit, 101, 101, 33, C.glow, .82, 1)
orbitArc(orbit, 117, 117, 102, 16, 124, 20, C.accent2, .64, 1)
orbitArc(orbit, 117, 117, 102, 196, 304, 20, C.accent, .68, 1)
orbitArc(orbit, 117, 117, 73, 116, 250, 18, C.line, .73, 1)
orbitArc(orbit, 117, 117, 51, 286, 414, 16, C.glow, .8, 1)
for angle = 0, 330, 30 do
local radians = math.rad(angle)
local radius = angle % 60 == 0 and 105 or 91
local x = 117 + math.cos(radians) * radius
local y = 117 + math.sin(radians) * radius
local size = angle % 90 == 0 and 5 or 3
dot(
orbit,
x - size / 2,
y - size / 2,
size,
angle % 60 == 0 and C.accent2 or C.glow,
angle % 60 == 0 and .36 or .55
)
end
diamond(orbit, 113, 113, 8, C.glow, .34)
dot(orbit, 72, 52, 4, C.accent, .38)
dot(orbit, 170, 156, 4, C.accent2, .38)
constellation(orbit, {
{36, 154, 3, C.glow},
{65, 130, 4, C.accent2},
{96, 145, 3, C.glow},
{126, 126, 5, C.accent},
{156, 142, 3, C.glow},
{190, 118, 4, C.accent2},
}, C.line, .86)
-- Lower halo group replacing the old lower lancet/grid region.
local lowerHalo = make("Frame", art, {
Name = "LowerHalo",
Position = UDim2.fromOffset(315, 326),
Size = UDim2.fromOffset(300, 165),
BackgroundTransparency = 1,
BorderSizePixel = 0,
})
ring(lowerHalo, 8, 0, 164, C.accent, .9, 1)
ring(lowerHalo, 29, 21, 122, C.line, .86, 1)
ring(lowerHalo, 54, 46, 72, C.accent2, .86, 1)
orbitArc(lowerHalo, 90, 82, 76, 210, 340, 18, C.accent2, .72, 1)
orbitArc(lowerHalo, 90, 82, 57, 18, 150, 18, C.accent, .78, 1)
ring(lowerHalo, 175, 23, 112, C.line, .9, 1)
orbitArc(lowerHalo, 231, 79, 51, 36, 194, 18, C.accent2, .78, 1)
orbitArc(lowerHalo, 231, 79, 37, 212, 366, 16, C.accent, .82, 1)
dot(lowerHalo, 226, 74, 7, C.glow, .47)
constellation(lowerHalo, {
{12, 118, 3, C.glow},
{49, 103, 4, C.accent2},
{83, 122, 3, C.glow},
{124, 105, 4, C.accent},
{163, 127, 3, C.glow},
{203, 108, 4, C.accent2},
{245, 126, 3, C.glow},
{286, 107, 4, C.accent},
}, C.line, .88)
-- Left sidebar constellation spine.
orbitArc(art, 91, 221, 59, 92, 268, 18, C.accent2, .87, 1)
orbitArc(art, 91, 221, 42, 274, 446, 16, C.accent, .9, 1)
constellation(art, {
{31, 118, 3, C.glow},
{57, 150, 4, C.accent2},
{38, 190, 3, C.glow},
{66, 228, 4, C.accent},
{43, 267, 3, C.glow},
{70, 306, 4, C.accent2},
{46, 346, 3, C.glow},
{78, 381, 4, C.accent},
}, C.line, .89)
-- Crescent / moon cluster.
local crescentHolder = make("Frame", art, {
Position = UDim2.fromOffset(73, 357),
Size = UDim2.fromOffset(88, 88),
BackgroundTransparency = 1,
BorderSizePixel = 0,
})
ring(crescentHolder, 0, 0, 88, C.accent2, .76, 1)
ring(crescentHolder, 15, 6, 76, C.bg, .12, 13)
orbitArc(crescentHolder, 44, 44, 38, 105, 256, 14, C.accent, .62, 1)
dot(crescentHolder, 14, 59, 5, C.accent, .3)
dot(crescentHolder, 52, 10, 4, C.glow, .42)
-- Sparse star scatter; deterministic positions keep the artwork stable.
local starScatter = {
{196, 92, 2}, {228, 249, 3}, {267, 294, 2}, {326, 91, 2},
{391, 173, 3}, {438, 112, 2}, {473, 277, 3}, {515, 191, 2},
{556, 96, 3}, {585, 292, 2}, {621, 408, 3}, {669, 103, 2},
{713, 418, 3}, {760, 389, 2}, {801, 94, 3}, {829, 454, 2},
{245, 423, 3}, {285, 467, 2}, {414, 451, 3}, {523, 434, 2},
{572, 468, 3}, {681, 462, 2}, {747, 479, 3}, {805, 440, 2},
}
for index, star in ipairs(starScatter) do
local color = index % 5 == 0 and C.accent2
or index % 3 == 0 and C.accent
or C.glow
dot(
art,
star[1],
star[2],
star[3],
color,
.5 + (index % 4) * .08
)
end
-- Extra constellation families to make the field visibly denser.
constellation(art, {
{203, 187, 3, C.glow},
{236, 174, 4, C.accent},
{268, 196, 3, C.glow},
{301, 182, 4, C.accent2},
{333, 205, 3, C.glow},
}, C.line, .84)
constellation(art, {
{399, 92, 3, C.glow},
{430, 112, 4, C.accent2},
{462, 96, 3, C.glow},
{495, 121, 4, C.accent},
{526, 104, 3, C.glow},
{556, 128, 3, C.accent2},
}, C.line, .86)
constellation(art, {
{386, 286, 3, C.glow},
{419, 266, 4, C.accent},
{450, 291, 3, C.glow},
{482, 273, 4, C.accent2},
{514, 299, 3, C.glow},
{547, 281, 4, C.accent},
}, C.line, .85)
constellation(art, {
{218, 368, 3, C.glow},
{247, 347, 4, C.accent2},
{279, 371, 3, C.glow},
{309, 352, 4, C.accent},
{338, 378, 3, C.glow},
}, C.line, .86)
constellation(art, {
{610, 382, 3, C.glow},
{642, 362, 4, C.accent},
{674, 386, 3, C.glow},
{705, 368, 4, C.accent2},
{737, 394, 3, C.glow},
{772, 374, 4, C.accent},
{806, 402, 3, C.glow},
}, C.line, .84)
constellation(art, {
{604, 91, 3, C.glow},
{633, 112, 4, C.accent2},
{659, 94, 3, C.glow},
{687, 118, 4, C.accent},
{714, 101, 3, C.glow},
}, C.line, .87)
-- Small standalone stars between clusters.
for _, star in ipairs({
{193, 316, 3}, {352, 126, 2}, {371, 427, 3},
{459, 343, 2}, {536, 153, 3}, {583, 354, 2},
{650, 444, 3}, {720, 321, 2}, {786, 172, 3},
{836, 287, 2}, {574, 224, 2}, {330, 242, 2},
}) do
dot(art, star[1], star[2], star[3], C.glow, .48)
end
-- Engraved astronomical scales and focal stars, kept behind the controls.
orbitDetails(orbit, 117, 117, 109, 48, 0, 360)
orbitDetails(lowerHalo, 90, 82, 80, 32, 0, 360)
orbitDetails(art, 302, 181, 89, 28, 18, 280)
for _, star in ipairs({
{208, 96, 6}, {918, 154, 5}, {916, 352, 6},
{210, 461, 5}, {851, 550, 6}, {290, 550, 5},
{181, 482, 5}, {41, 466, 4},
}) do
starburst(art, star[1], star[2], star[3], .48)
end
constellation(art, {
{239, 555, 2}, {279, 549, 3}, {322, 560, 2},
{368, 552, 3}, {408, 562, 2},
}, C.line, .8)
constellation(art, {
{684, 558, 2}, {723, 549, 3}, {766, 560, 2},
{809, 552, 3}, {856, 558, 2},
}, C.line, .8)
for index = 0, 12 do
dot(art, 919, 199 + index * 9, index % 3 == 0 and 2 or 1, C.glow, .65)
end
-- Footer rail remains as the only strong straight guide across the content.
line(art, 225, 550, 683, 1, 0, C.line, .84)
diamond(art, 562, 547, 6, C.accent, .35)
ring(art, 558, 543, 14, C.glow, .76, 1)
local contentVeil = make("Frame", window, {
Name = "ContentGlass",
Position = UDim2.fromOffset(202, 16),
Size = UDim2.fromOffset(718, 578),
BackgroundColor3 = C.card,
BackgroundTransparency = .68,
BorderSizePixel = 0,
})
make("UIGradient", contentVeil, {
Rotation = 132,
Color = themeSequence({
themePoint(0, Color3.fromRGB(14, 20, 37)),
themePoint(.48, Color3.fromRGB(9, 12, 25)),
themePoint(1, Color3.fromRGB(20, 11, 32)),
}),
Transparency = NumberSequence.new({
NumberSequenceKeypoint.new(0, .48),
NumberSequenceKeypoint.new(.5, .66),
NumberSequenceKeypoint.new(1, .52),
}),
})
-- Inner content frame with clipped-corner illusion.
local innerFrame = make("Frame", window, {
Name = "InnerContentFrame",
Position = UDim2.fromOffset(214, 68),
Size = UDim2.fromOffset(697, 474),
BackgroundTransparency = 1,
BorderSizePixel = 0,
})
make("UIStroke", innerFrame, {
Color = C.line,
Thickness = 1,
Transparency = .62,
})
for _, cornerData in ipairs({
{0, 0, 1, 1},
{697, 0, -1, 1},
{0, 474, 1, -1},
{697, 474, -1, -1},
}) do
local x, y, sx, sy = table.unpack(cornerData)
line(
innerFrame,
x + (sx < 0 and -20 or 0),
y,
20,
1,
0,
C.accent,
.24
)
line(
innerFrame,
x,
y + (sy < 0 and -20 or 0),
1,
20,
0,
C.accent,
.24
)
diamond(
innerFrame,
x + (sx < 0 and -8 or 1),
y + (sy < 0 and -8 or 1),
6,
C.line,
.18
)
end
local header = make("Frame", window, {
Size = UDim2.fromOffset(746, 62),
BackgroundTransparency = 1,
Active = true,
})
local titleLabel = text(header, title, 25, 15, 150, 39, 32, C.text, Enum.Font.Antique)
local subtitleLabel = text(window, subtitleText, 24, 57, 150, 24, 10, C.text)
local titleRail = line(window, 24, 86, 141, 1, 0, C.accent2, .55)
line(window, 24, 89, 87, 1, 0, C.accent, .78)
diamond(window, 156, 82, 7, C.glow, .42)
local breadcrumb = text(
header,
string.upper(currentPage) .. " / " .. string.upper(productName),
193,
20,
490,
25,
13,
C.bright
)
-- Header heraldry around the breadcrumb.
line(header, 188, 12, 1, 39, 0, C.line, .36)
diamond(header, 184, 27, 8, C.accent, .12)
line(header, 202, 49, 356, 1, 0, C.line, .62)
diamond(header, 563, 46, 6, C.line, .28)
line(header, 574, 49, 91, 1, 0, C.line, .74)
local function button(parent, buttonTitle, x, y, width, callback)
local object = make("TextButton", parent, {
Text = tostring(buttonTitle or ""),
TextTransparency = 0,
Position = UDim2.fromOffset(x, y),
Size = UDim2.fromOffset(width, 30),
BackgroundColor3 = C.card,
BackgroundTransparency = .06,
BorderSizePixel = 0,
Font = Enum.Font.Code,
TextSize = 12,