This repository was archived by the owner on Dec 22, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathpreview script
More file actions
280 lines (237 loc) · 6.32 KB
/
preview script
File metadata and controls
280 lines (237 loc) · 6.32 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
local Library = loadstring(game:HttpGet("https://raw.githubusercontent.com/Vision-Software-LLC/Vision-UI/main/source"))()
local utils = loadstring(game:HttpGet("https://raw.githubusercontent.com/Vision-Software-LLC/scripts/main/utils/source.lua"))()
local icons = Library:Icons()
local window = Library:CreateWindow({
PrimaryColor = Color3.fromRGB(35, 35, 35), -- Defualt is 35, 35, 35
SecondaryColor = Color3.fromRGB(40, 40, 40), -- Defualt is 40, 40, 40
FooterColor = Color3.fromRGB(45, 45, 45), -- Defualt is 45, 45, 45
Title = "Vision UI", -- Defualt is "Vision UI"
TitleSize = 16, -- Defualt is 16
ToggleBind = "RightShift", -- Enum.KeyCode.RightShift (Just put in key of keycode)
SkipStartup = true,
Footer = true,
Callback = function()
print("Window Close Callback")
end
})
local Home = window:CreateTab({
Text = "Home",
Icon = icons.FluentIcons.Home,
CanvasSize = 2,
Default = true
}) -- Text, Icon, CanvasSize, Default
Home:CreateButton({
Text = "Cycle/Create Notifications",
Callback = function()
Library:Notification({
Text = "Hello number",
ShowIndex = true
})
end
}) -- Text, callback
Home:CreateSlider({
Text = "Slider",
ValueName = "studs/s",
Min = 0,
Max = 60,
Step = 1, -- Increment
Default = 16,
Round = false,
Callback = function(value)
print("Slider Value: " .. value)
end
}) -- Text, callback, scale, default
Home:CreateKeybind({
Text = "Keybind",
Default = "F",
Callback = function(held,keycode)
print("Keybind Held: "..tostring(held))
end
}) -- Text, key, callback
Home:CreateColorPicker({
Text = "Color Picker",
Default = Color3.fromRGB(2, 255, 255),
Callback = function(color)
print("HSV: "..tostring(color)) -- For rgb just multiply by 255
end
}) -- Text, default, callback
Home:CreateLabel({
Text = "Label Example: Spacing Below",
}) -- Text
Home:CreateSpacing({
Size = 1, -- 1 = 1 buttons size of spacing, 2 = 2 buttons size of spacing, etc.
}) -- Size
Home:CreateInput({
Text = "Input",
ValueOnly = true,
Callback = function(input)
print("Input: "..input)
end
}) -- Text, ValueOnly, callback
Home:CreateToggle({
Text = "Toggle",
Default = false,
Callback = function(state)
print("Toggle: "..tostring(state))
end
}) -- Text, default, callback
Home:CreateDropdown({
Text = "Dropdown",
MultiSelect = false,
Selections = {"Option 1", "Option 2", "Option"},
Default = 0,
Callback = function(selection)
print("Dropdown: "..selection)
end
})
Home:NestedDropdown({
Text = "Nested Dropdown",
Selections = {"Option 1", {"Nested Option 1", "Nested Option 2"}, "Option 2"},
Default = 1,
Callback = function(selection)
print("Selection Table:")
for i,v in pairs(selection) do
print(v)
end
end
})
local Aimbot = window:CreateTab({
Text = "Aimbot",
Icon = icons.FluentIcons.Aimbot,
Default = false
})
Aimbot:CreateButton({
Text = "Aimbot",
Callback = function()
print("Aimbot Button Clicked")
end
})
local Visuals = window:CreateTab({
Text = "Visuals",
Icon = icons.FluentIcons.Visuals,
Default = false
})
Visuals:CreateButton({
Text = "Visuals",
Callback = function()
print("Visuals Button Clicked")
end
})
local Player = window:CreateTab({
Text = "Player",
Icon = icons.FluentIcons.Player,
Default = false
})
Player:CreateButton({
Text = "Player",
Callback = function()
print("Player Button Clicked")
end
})
local InfoTab = window:CreateTab({ Text = "Info", Icon = icons.FluentIcons.Credits, CanvasSize = 1, Default = false })
InfoTab:CreateLabel({
Text = "Vision Library Version: " .. Library:GetVersion()
})
InfoTab:CreateLabel({
Text = "Vision Utilities Version: " .. utils.Version
})
InfoTab:CreateLabel({
Text = "Executor: " .. utils:GetExecutor()
})
local userDrop = InfoTab:CreateDropdown({
Text = "User Info",
MultiSelect = false,
Selections = {"t"},
Default = 1,
Callback = function(t)
end
})
local PerfInfo = "FPS"
local perfDrop = InfoTab:CreateDropdown({
Text = "Perfomance Info",
MultiSelect = false,
Selections = {'FPS', 'Ping', 'Memory Usage'},
Default = 1,
Callback = function(t)
PerfInfo = t
end
})
local fpsCounter = InfoTab:CreateLabel({
Text = 'Average FPS: ' .. utils.Stats.FPS
})
local Misc = window:CreateTab({
Text = "Misc",
Icon = icons.FluentIcons.Misc,
Default = false
})
Misc:CreateButton({
Text = "Misc",
Callback = function()
print("Misc Button Clicked")
end
})
for i=1,12 do
window:CreateSpacing() -- lol
end
window:SettingsTab({
Visible = true,
CanvasSize = 2,
Text = "Settings",
Icon = icons.FluentIcons.Settings,
EnabledSettings = {
PrimaryColor = true,
SecondaryColor = true,
FooterColor = true,
ButtonBorderColor = true,
TextColor = true,
CheckboxColor = true,
SelectorColor = true,
SliderPrimaryColor = true,
SliderBackgroundColor = true,
InputBoxBackgroundColor = true,
DropdownUnselectedColor = true,
SeparatorColor = true
}
})
SettingsTab:CreateLabel({
Text = "Settings Tab Custom Labels and Buttons Example",
})
SettingsTab:CreateKeybind({
Text = "Toggle GUI Keybind",
Default = "RightShift",
Callback = function(held,keycode)
window:ChangeToggleBind({
NewBind = string.split(tostring(keycode),".")[3]
})
end
})
local function notify(text, icon, showindex)
text = text or "An error has occured:\nPlease report this to the developer."
icon = icon or icons.FluentIcons.Credits
showindex = showindex or false
local notif = Library:Notification({
Text = text,
Icon = icon,
ShowIndex = showindex
})
return notif
end
utils:Try(function() notify("Vision Successfully Loaded!", icons.NotificationIcons.Success) end, "notify", true)
coroutine.wrap(function()
repeat
wait(0.4)
if PerfInfo == "FPS" then
fpsCounter:SetText('Average FPS: '..utils.Stats.FPS)
elseif PerfInfo == "Ping" then
fpsCounter:SetText('Average Ping: '..utils.Stats.Ping)
elseif PerfInfo == "Memory Usage" then
fpsCounter:SetText('Average Memory Usage: '..utils.Stats.Memory)
end
until not getgenv().visionlive
end)()
coroutine.wrap(function()
repeat
wait(1)
userDrop:SetTable({'Username: ' .. utils.Username, 'Display Name: ' .. utils.Displayname, 'User ID: ' .. utils.UserId, 'Account Age: ' .. utils.Age .. ' day(s)', 'Client Uptime: ' .. utils.Uptime.Formatted})
until not getgenv().visionlive
end)()