· 8 years ago · Jan 16, 2018, 09:48 PM
1wait()
2assfuck = game.CoreGui.RobloxGui
3assfuck:WaitForChild("TopBarContainer")
4warn("ok i can start now")
5game.CoreGui.RobloxGui.TopBarContainer.Position=UDim2.new(0,0,0)
6
7
8
9
10
11
12
13local _2 = Instance.new("ScreenGui")
14local _456 = Instance.new("Frame")
15
16
17
18_2.Name = "2"
19_2.Parent = game.Players.LocalPlayer.PlayerGui
20
21_456.Name = "456"
22_456.Parent = _2
23_456.BackgroundColor3 = Color3.new(1, 1, 1)
24_456.Position = UDim2.new(-0.984577894, 0, -0.714471936, 0)
25_456.Size = UDim2.new(0, 3559, 0, 1448)
26_456.Style = Enum.FrameStyle.RobloxRound
27
28
29
30
31
32
33
34
35
36local ScreenGui = Instance.new("ScreenGui")
37local Frame = Instance.new("ImageLabel")
38local Frame1 = Instance.new("ImageLabel")
39local Frame2 = Instance.new("ImageLabel")
40local Frame3 = Instance.new("ImageLabel")
41local Frame4 = Instance.new("ImageLabel")
42
43-- Properties
44
45ScreenGui.Parent = game.Players.LocalPlayer.PlayerGui
46
47Frame.Name = "Frame"
48Frame.Parent = ScreenGui
49Frame.BackgroundColor3 = Color3.new(1, 1, 1)
50Frame.BackgroundTransparency = 1112
51Frame.BorderColor3 = Color3.new(1, 1, 1)
52Frame.BorderSizePixel = 0
53Frame.Position = UDim2.new(0.5, -90, 0.5, -60)
54Frame.Size = UDim2.new(0, 179, 0, 121)
55Frame.Image = "rbxassetid://118129065"
56Frame.ImageColor3 = Color3.new(0.490196, 0.160784, 0.160784)
57Frame.ZIndex=2
58Frame1.Name = "Frame1"
59Frame1.Parent = ScreenGui
60Frame1.BackgroundColor3 = Color3.new(1, 1, 1)
61Frame1.BackgroundTransparency = 1112
62Frame1.BorderColor3 = Color3.new(1, 1, 1)
63Frame1.BorderSizePixel = 0
64Frame1.Position = UDim2.new(0.5, -90, 0.5, -60)
65Frame1.Size = UDim2.new(0, 179, 0, 121)
66Frame1.Image = "rbxassetid://118129065"
67Frame1.ImageColor3 = Color3.new(0.490196, 0.160784, 0.160784)
68
69Frame2.Name = "Frame2"
70Frame2.Parent = ScreenGui
71Frame2.BackgroundColor3 = Color3.new(1, 1, 1)
72Frame2.BackgroundTransparency = 1112
73Frame2.BorderColor3 = Color3.new(1, 1, 1)
74Frame2.BorderSizePixel = 0
75Frame2.Position = UDim2.new(0.5, -90, 0.5, -60)
76Frame2.Size = UDim2.new(0, 179, 0, 121)
77Frame2.Image = "rbxassetid://118129065"
78Frame2.ImageColor3 = Color3.new(0.490196, 0.160784, 0.160784)
79Frame2.ZIndex=2
80Frame3.Name = "Frame3"
81Frame3.Parent = ScreenGui
82Frame3.BackgroundColor3 = Color3.new(1, 1, 1)
83Frame3.BackgroundTransparency = 1112
84Frame3.BorderColor3 = Color3.new(1, 1, 1)
85Frame3.BorderSizePixel = 0
86Frame3.Position = UDim2.new(0.5, -90, 0.5, -60)
87Frame3.Size = UDim2.new(0, 179, 0, 121)
88Frame3.Image = "rbxassetid://118129065"
89Frame3.ImageColor3 = Color3.new(0.490196, 0.160784, 0.160784)
90Frame3.ZIndex=2
91Frame4.Name = "Frame4"
92Frame4.Parent = ScreenGui
93Frame4.BackgroundColor3 = Color3.new(1, 1, 1)
94Frame4.BackgroundTransparency = 1112
95Frame4.BorderColor3 = Color3.new(1, 1, 1)
96Frame4.BorderSizePixel = 0
97Frame4.Position = UDim2.new(0.5, -90, 0.5, -60)
98Frame4.Size = UDim2.new(0, 179, 0, 121)
99Frame4.Image = "rbxassetid://118129065"
100Frame4.ImageColor3 = Color3.new(0.490196, 0.160784, 0.160784)
101Frame4.ZIndex=2
102
103-- Objects
104
105local load = Instance.new("ScreenGui")
106local bar = Instance.new("Frame")
107local _34534 = Instance.new("TextBox")
108
109-- Properties
110
111load.Name = "load"
112load.Parent = game.Players.LocalPlayer.PlayerGui
113
114bar.Name = "bar"
115bar.Parent = load
116bar.BackgroundColor3 = Color3.new(0.439216, 1, 0.458824)
117bar.BorderSizePixel = 0
118bar.Position = UDim2.new(0, 0,0.5, -16)
119bar.Size = UDim2.new(0, 29, 0, 33)
120bar.ZIndex=2
121_34534.Name = "34534"
122_34534.Parent = load
123_34534.BackgroundColor3 = Color3.new(1, 1, 1)
124_34534.BackgroundTransparency = 1
125_34534.Position = UDim2.new(0.5, -100, 0.5, -25)
126_34534.Size = UDim2.new(0, 200, 0, 50)
127_34534.Font = Enum.Font.ArialBold
128_34534.FontSize = Enum.FontSize.Size14
129_34534.Text = "Loading . . ."
130_34534.TextColor3 = Color3.new(0.498039, 0.498039, 0.498039)
131_34534.TextScaled = true
132_34534.TextSize = 14
133_34534.TextWrapped = true
134_34534.ZIndex=2
135
136
137pow = game.Players.LocalPlayer.PlayerGui.ScreenGui
138
139local StartColor = Color3.new(1, 1, 1)
140local EndColor = Color3.new(0,0,0)
141
142 wait(2)
143for i=1,6 do
144
145game.Players.LocalPlayer.PlayerGui.load.bar:TweenSize(UDim2.new(0, 1700,0, 33), "In", "Quad",6,true)
146local tweeninterval = 1
147
148--0.033, 0,0.197, 0 0.023, -90,0.841, -60
149 pow.Frame:TweenSizeAndPosition(UDim2.new(0, 419,0, 331), UDim2.new(0.5, -210,0.5, -166), "Out", "Back", tweeninterval,true)
150
151 pow.Frame1:TweenSizeAndPosition(UDim2.new(0, 419,0, 331), UDim2.new(0.076, -90,0.085, -60), "Out", "Back", tweeninterval,true)
152
153pow.Frame2:TweenSizeAndPosition(UDim2.new(0, 419,0, 331), UDim2.new(0.256, 380,0.095, -60), "Out", "Back", tweeninterval,true)
154
155pow.Frame3:TweenSizeAndPosition(UDim2.new(0, 419,0, 331), UDim2.new(0.801, -90,0.792, -60), "Out", "Back", tweeninterval,true)
156
157pow.Frame4:TweenSizeAndPosition(UDim2.new(0, 419,0, 331), UDim2.new(0.023, -90,0.841, -60), "Out", "Back", tweeninterval,true)
158
159wait(0.6)
160print("worked")
161
162pow.Frame1:TweenPosition(UDim2.new(0.5, -210,0.5, -166), "Out", "Back", tweeninterval,true)
163
164pow.Frame2:TweenPosition(UDim2.new(0.5, -210,0.5, -166), "Out", "Back", tweeninterval,true)
165
166pow.Frame3:TweenPosition(UDim2.new(0.5, -210,0.5, -166), "Out", "Back", tweeninterval,true)
167
168pow.Frame4:TweenPosition(UDim2.new(0.5, -210,0.5, -166), "Out", "Back", tweeninterval,true)
169
170wait(0.6)
171
172
173for i = 1,20 do
174 pow.Frame.ImageColor3 = StartColor:lerp(EndColor,i/20)
175pow.Frame1.ImageColor3 = StartColor:lerp(EndColor,i/20)
176pow.Frame2.ImageColor3 = StartColor:lerp(EndColor,i/20)
177pow.Frame3.ImageColor3 = StartColor:lerp(EndColor,i/20)
178pow.Frame4.ImageColor3 = StartColor:lerp(EndColor,i/20)
179
180
181 end
182end
183
184wait(8)
185pow:Remove()
186game.Players.LocalPlayer.PlayerGui.load:Remove()
187game.Players.LocalPlayer.PlayerGui["2"]:Remove()
188
189
190
191
192
193
194
195
196
197local Panel = Instance.new("ScreenGui")
198local gayporn = Instance.new("Frame")
199local Settings = Instance.new("ImageButton")
200local SettingsIcon = Instance.new("ImageLabel")
201local TopBarShadow = Instance.new("ImageLabel")
202local Scripts = Instance.new("TextLabel")
203local haha = Instance.new("TextLabel")
204local Creds = Instance.new("TextLabel")
205local Header1 = Instance.new("TextBox")
206local Header = Instance.new("TextBox")
207local Spacing1 = Instance.new("TextBox")
208local Spacing2 = Instance.new("TextBox")
209local scriptbutton = Instance.new("TextButton")
210local scarebutton = Instance.new("TextButton")
211local Credstbuttom = Instance.new("TextButton")
212local open = Instance.new("TextLabel")
213local Dex = Instance.new("TextButton")
214local RemoteSpy = Instance.new("TextButton")
215local analsex = Instance.new("Frame")
216local TextButton = Instance.new("TextButton")
217local TextLabel = Instance.new("TextLabel")
218
219-- Properties
220
221Panel.Name = "Panel"
222Panel.Parent = game.CoreGui
223
224
225
226gayporn.Name = "gayporn"
227gayporn.Parent = Panel
228gayporn.Active = true
229gayporn.BackgroundColor3 = Color3.new(0.121569, 0.121569, 0.121569)
230gayporn.BackgroundTransparency = 0.5
231gayporn.BorderSizePixel = 0
232gayporn.Position = UDim2.new(0,0, 0,-36)
233gayporn.Size = UDim2.new(1, 0, 0, 36)
234
235Settings.Name = "Settings"
236Settings.Parent = gayporn
237Settings.BackgroundTransparency = 1
238Settings.Size = UDim2.new(0, 50, 0, 36)
239Settings.AutoButtonColor = false
240
241SettingsIcon.Name = "SettingsIcon"
242SettingsIcon.Parent = Settings
243SettingsIcon.BackgroundColor3 = Color3.new(0.647059, 0.619608, 0.403922)
244SettingsIcon.BackgroundTransparency = 1
245SettingsIcon.Position = UDim2.new(0.319999993, -16, 0.375, -12)
246SettingsIcon.Size = UDim2.new(0, 41, 0, 31)
247SettingsIcon.Image = "rbxassetid://1003379313"
248SettingsIcon.ImageColor3 = Color3.new(1, 1, 1)
249SettingsIcon.ImageTransparency = 0
250
251TopBarShadow.Name = "TopBarShadow"
252TopBarShadow.Parent = gayporn
253TopBarShadow.BackgroundTransparency = 1
254TopBarShadow.Position = UDim2.new(0, 0, 1, 0)
255TopBarShadow.Size = UDim2.new(1, 0, 0, 3)
256TopBarShadow.Image = "rbxasset://textures/ui/TopBar/dropshadow.png"
257
258Scripts.Name = "Scripts"
259Scripts.Parent = gayporn
260Scripts.BackgroundColor3 = Color3.new(1, 1, 1)
261Scripts.BackgroundTransparency = 1
262Scripts.Position = UDim2.new(0.0729413033, 0, 0.0555555597, 0)
263Scripts.Size = UDim2.new(0, 65, 0, 30)
264Scripts.Font = Enum.Font.ArialBold
265Scripts.FontSize = Enum.FontSize.Size14
266Scripts.Text = "Scripts"
267Scripts.TextColor3 = Color3.new(0.694118, 0.156863, 0.156863)
268Scripts.TextSize = 14
269Scripts.TextWrapped = true
270
271haha.Name = "haha"
272haha.Parent = gayporn
273haha.BackgroundColor3 = Color3.new(1, 1, 1)
274haha.BackgroundTransparency = 1
275haha.Position = UDim2.new(0.158545226, 0, 0.0833333358, 0)
276haha.Size = UDim2.new(0, 77, 0, 30)
277haha.Font = Enum.Font.ArialBold
278haha.FontSize = Enum.FontSize.Size14
279haha.Text = "Don't press"
280haha.TextColor3 = Color3.new(0.694118, 0.156863, 0.156863)
281haha.TextSize = 14
282haha.TextWrapped = true
283
284Creds.Name = "Creds"
285Creds.Parent = gayporn
286Creds.BackgroundColor3 = Color3.new(1, 1, 1)
287Creds.BackgroundTransparency = 1
288Creds.Position = UDim2.new(0.247436374, 0, 0.0833333358, 0)
289Creds.Size = UDim2.new(0, 77, 0, 30)
290Creds.Font = Enum.Font.ArialBold
291Creds.FontSize = Enum.FontSize.Size14
292Creds.Text = "Credits"
293Creds.TextColor3 = Color3.new(0.694118, 0.156863, 0.156863)
294Creds.TextSize = 14
295Creds.TextWrapped = true
296
297
298Header1.Name = "Header1"
299Header1.Parent = gayporn
300Header1.BackgroundColor3 = Color3.new(0.694118, 0.156863, 0.156863)
301Header1.BorderSizePixel = 0
302Header1.Position = UDim2.new(0.0484913811, 0, -0.0833333358, 0)
303Header1.Size = UDim2.new(0, 6, 0, 39)
304Header1.Font = Enum.Font.SourceSans
305Header1.FontSize = Enum.FontSize.Size14
306Header1.Text = ""
307Header1.TextSize = 14
308
309Header.Name = "Header"
310Header.Parent = gayporn
311Header.BackgroundColor3 = Color3.new(0.694118, 0.156863, 0.156863)
312Header.BorderSizePixel = 0
313Header.Position = UDim2.new(0.0668103471, 0, -0.055555556, 0)
314Header.Size = UDim2.new(0, 6, 0, 38)
315Header.Font = Enum.Font.SourceSans
316Header.FontSize = Enum.FontSize.Size14
317Header.Text = ""
318Header.TextSize = 14
319
320Spacing1.Name = "Spacing1"
321Spacing1.Parent = gayporn
322Spacing1.BackgroundColor3 = Color3.new(0.694118, 0.156863, 0.156863)
323Spacing1.BorderSizePixel = 0
324Spacing1.Position = UDim2.new(0.148706898, 0, -0.0833333358, 0)
325Spacing1.Size = UDim2.new(0, 6, 0, 39)
326Spacing1.Font = Enum.Font.SourceSans
327Spacing1.FontSize = Enum.FontSize.Size14
328Spacing1.Text = ""
329Spacing1.TextSize = 14
330
331Spacing2.Name = "Spacing2"
332Spacing2.Parent = gayporn
333Spacing2.BackgroundColor3 = Color3.new(0.694118, 0.156863, 0.156863)
334Spacing2.BorderSizePixel = 0
335Spacing2.Position = UDim2.new(0.24784483, 0, 0, 0)
336Spacing2.Size = UDim2.new(0, 6, 0, 36)
337Spacing2.Font = Enum.Font.SourceSans
338Spacing2.FontSize = Enum.FontSize.Size14
339Spacing2.Text = ""
340Spacing2.TextSize = 14
341
342scriptbutton.Name = "scriptbutton"
343scriptbutton.Parent = gayporn
344scriptbutton.BackgroundColor3 = Color3.new(1, 1, 1)
345scriptbutton.BackgroundTransparency = 1
346scriptbutton.Position = UDim2.new(0.0732758641, 0, 0, 0)
347scriptbutton.Size = UDim2.new(0, 70, 0, 36)
348scriptbutton.Font = Enum.Font.SourceSans
349scriptbutton.FontSize = Enum.FontSize.Size14
350scriptbutton.Text = ""
351scriptbutton.TextSize = 14
352
353
354scarebutton.Name = "scarebutton"
355scarebutton.Parent = gayporn
356scarebutton.BackgroundColor3 = Color3.new(1, 1, 1)
357scarebutton.BackgroundTransparency = 1
358scarebutton.Position = UDim2.new(0.15840517, 0, 0, 0)
359scarebutton.Size = UDim2.new(0, 83, 0, 36)
360scarebutton.Font = Enum.Font.SourceSans
361scarebutton.FontSize = Enum.FontSize.Size14
362scarebutton.Text = ""
363scarebutton.TextSize = 14
364
365Credstbuttom.Name = "Credstbuttom"
366Credstbuttom.Parent = gayporn
367Credstbuttom.BackgroundColor3 = Color3.new(1, 1, 1)
368Credstbuttom.BackgroundTransparency = 1
369Credstbuttom.Position = UDim2.new(0.25431034, 0, 0, 0)
370Credstbuttom.Size = UDim2.new(0, 62, 0, 36)
371Credstbuttom.Font = Enum.Font.SourceSans
372Credstbuttom.FontSize = Enum.FontSize.Size14
373Credstbuttom.Text = ""
374Credstbuttom.TextSize = 14
375
376open.Name = "open"
377open.Parent = gayporn
378open.BackgroundColor3 = Color3.new(1, 1, 1)
379open.BackgroundTransparency = 1
380open.Position = UDim2.new(0.130387932, 0, 0, 0)
381open.Size = UDim2.new(0, 44, 0, 32)
382open.Visible = false
383open.Font = Enum.Font.SourceSans
384open.FontSize = Enum.FontSize.Size60
385open.Text = ">"
386open.TextColor3 = Color3.new(0.694118, 0.156863, 0.156863)
387open.TextSize = 50
388open.TextWrapped = true
389
390Dex.Name = "Dex"
391Dex.Parent = gayporn
392Dex.BackgroundColor3 = Color3.new(1, 1, 1)
393Dex.BackgroundTransparency = 1
394Dex.Position = UDim2.new(0.177801728, 0, 0, 0)
395Dex.Size = UDim2.new(0, 68, 0, 36)
396Dex.Visible = false
397Dex.Font = Enum.Font.ArialBold
398Dex.FontSize = Enum.FontSize.Size14
399Dex.Text = "DEX"
400Dex.TextColor3 = Color3.new(0.694118, 0.156863, 0.156863)
401Dex.TextSize = 14
402
403RemoteSpy.Name = "RemoteSpy"
404RemoteSpy.Parent = gayporn
405RemoteSpy.BackgroundColor3 = Color3.new(1, 1, 1)
406RemoteSpy.BackgroundTransparency = 1
407RemoteSpy.Position = UDim2.new(0.25431034, 0, 0, 0)
408RemoteSpy.Size = UDim2.new(0, 68, 0, 36)
409RemoteSpy.Visible = false
410RemoteSpy.Font = Enum.Font.ArialBold
411RemoteSpy.FontSize = Enum.FontSize.Size14
412RemoteSpy.Text = "MrSpy"
413RemoteSpy.TextColor3 = Color3.new(0.694118, 0.156863, 0.156863)
414RemoteSpy.TextSize = 14
415
416analsex.Name = "analsex"
417analsex.Parent = Panel
418analsex.BackgroundColor3 = Color3.new(1, 1, 1)
419analsex.BorderSizePixel = 0
420analsex.Position = UDim2.new(0.5, -50, 0.5, -50)
421analsex.Size = UDim2.new(0, 103, 0, 100)
422analsex.Visible = false
423analsex.Style = Enum.FrameStyle.RobloxRound
424
425TextButton.Parent = analsex
426TextButton.BackgroundColor3 = Color3.new(1, 1, 1)
427TextButton.Position = UDim2.new(-0.135922343, 0, -1.13, 0)
428TextButton.Size = UDim2.new(0, 112, 0, 80)
429TextButton.Style = Enum.ButtonStyle.RobloxRoundDefaultButton
430TextButton.Font = Enum.Font.SourceSans
431TextButton.FontSize = Enum.FontSize.Size14
432TextButton.Text = "Stellar"
433TextButton.TextSize = 14
434
435TextLabel.Parent = analsex
436TextLabel.BackgroundColor3 = Color3.new(1, 1, 1)
437TextLabel.BackgroundTransparency = 1
438TextLabel.Position = UDim2.new(-0.398058265, 0, 0.219999999, 0)
439TextLabel.Size = UDim2.new(0, 158, 0, 50)
440TextLabel.Font = Enum.Font.SourceSans
441TextLabel.FontSize = Enum.FontSize.Size14
442TextLabel.Text = "amb | foreign#7396\n"
443TextLabel.TextColor3 = Color3.new(0.796079, 0.313726, 0.733333)
444TextLabel.TextSize = 14
445
446wait(1)
447gui=game.CoreGui.Panel
448xd=gui.gayporn
449local stuff = {xd.scarebutton;xd.haha;xd.Creds}
450
451
452button = scriptbutton
453open = false
454function clicked()
455wait()
456if open == false then
457 open = true
458 game.CoreGui.Panel.gayporn.Spacing1.Visible=false
459for i = 1,#stuff do
460
461stuff [i].Visible = false
462
463end
464xd.Dex.Visible=true
465xd.RemoteSpy.Visible=true
466xd.open.Visible=true
467
468elseif open ==true then
469 open = false
470 for i = 1,#stuff do
471
472stuff [i].Visible = true
473
474 end
475 game.CoreGui.Panel.gayporn.Spacing1.Visible=true
476 xd.Dex.Visible=false
477 xd.RemoteSpy.Visible=false
478 xd.open.Visible=false
479end
480end
481
482
483button.MouseButton1Click:connect(clicked)
484
485button2 = scarebutton
486open1 = false
487function clicked()
488 wait()
489 if open1 ==false then
490 open1 = true
491 game.CoreGui.RobloxGui:Remove()
492 elseif open1 ==true then
493 open1 = false
494 print("nigger killer")
495 end
496end
497button2.MouseButton1Click:connect(clicked)
498
499button3 = Credstbuttom
500open3 = false
501function clicked()
502 wait()
503 wait()
504 if open3 ==false then
505 open3 = true
506 game.CoreGui.Panel.analsex.Visible=true
507 elseif open3 ==true then
508 open3 = false
509 game.CoreGui.Panel.analsex.Visible=false
510 end
511end
512button3.MouseButton1Click:connect(clicked)
513
514
515
516button5 = RemoteSpy
517function clicked()
518 wait()
519 --== Made by Kurokku/Rebug REX ==--
520
521--[[
522Note: Things are still being made as this is only the starting version. Bugs are expected
523
524Compatible For:
525-Protosmasher
526-Synapse
527-Veil
528-QTX
529-RC7
530-Elysian
531-Seraph (Might crash though)
532-Prob some other exploits too, but I could be wrong.
533
534Clipboard Works For:
535-Protosmasher
536-Veil
537-Synapse
538-Elysian
539-More in the future
540--]]
541
542--== Creation Functions ==--
543
544function BreakCode()
545script:Destroy()
546end
547
548local service = setmetatable({}, {
549 __index = function(t, k)
550 return game:GetService(k)
551 end
552})
553
554if service.Players.LocalPlayer.PlayerGui:FindFirstChild("Mr.Spy - Rebug REX/Kurokku") then
555service.Players.LocalPlayer.PlayerGui:FindFirstChild("Mr.Spy - Rebug REX/Kurokku"):Destroy() --You're dumb if you don't know what this does
556end
557
558function Create(cls,props)
559 local inst = Instance.new(cls)
560 for i,v in pairs(props) do
561if i == "ZIndex" then
562inst[i] = v+10000000
563else
564inst[i] = v
565end
566 end
567 return inst
568end
569
570_G.Exploit = (function()
571local writeable = pcall(function() make_writeable(getrawmetatable(game)) end)
572local setwrite = pcall(function() setreadonly(getrawmetatable(game), false) end)
573local synapse = Synapse or false
574local backup = pcall(function() getrawmetatable(game) end)
575
576return (
577 (writeable and "Writeable") or
578 (setwrite and "SetWrite") or
579 (synapse and "Synapse") or
580 (backup and "BackUp") or
581 "Unknown Exploit"
582 )
583end)()
584
585function GetType(item)
586 if type(item) == "string" then
587 return "\""..item.."\""
588 elseif type(item) == "table" then
589local str = "{"
590local max = 0
591local numb = 1
592 for i,v in pairs(item) do
593 max = max+1
594 end
595 for i,v in pairs(item) do
596 if numb == max then
597 str = str.."["..GetType(i).."] = "..GetType(v)
598 else
599 str = str.."["..GetType(i).."] = "..GetType(v)..", "
600 end
601 numb = numb + 1
602 end
603 str = str.."}"
604 return str
605 elseif type(item) == "userdata" then
606 local a,b = pcall(function()
607 return item.ClassName
608 end)
609 if a then
610 return item:GetFullName()
611 else
612 if tostring(b):match("not a valid member of %w+") then
613 local c, d = tostring(b):match("not a valid member of %w+"):find("of ")
614 local class = tostring(b):match("not a valid member of %w+"):sub(d+1)
615 return class..".new(".. tostring(item) ..")"
616 end
617 end
618 else
619 return tostring(item)
620 end
621end
622
623function ReturnArgs(Namecall, Object, ...)
624 local args = {...}
625 local list = "Namecall: ".. tostring(Namecall) .." | Args: ["
626 local max = 0
627 local numb = 1
628 for i,v in pairs(args) do
629 max = max + 1
630 end
631 for i,v in pairs(args) do
632 if numb == max then
633 list = list..GetType(v)
634 else
635 list = list..GetType(v)..", "
636 end
637 numb = numb + 1
638 end
639list=list.."]"
640 return list
641end
642
643function MakeShadow(UI,Index,Amnt,Sizey,starty)
644local tab = {}
645for i = 1,Amnt do
646 tab[i] = Create("Frame",{Name="Shadow",Parent=UI,Size=UDim2.new(1,0,Sizey,0),ZIndex=Index,Position=UDim2.new(0,i,starty,i),BackgroundColor3=Color3.fromRGB(0,0,0),BorderSizePixel=0,Transparency=0.9})
647end
648return tab
649end
650
651--== End ==--
652
653--== Variables ==--
654
655local plr = service.Players.LocalPlayer
656local mouse = plr:GetMouse()
657local colSize = 14
658local SpyArgs = {}
659local Indexs = {
660["BadgeService"] = 76;
661["Humanoid"] = 10;
662["GuiService"] = 48;
663["CylinderHandleAdornment"] = 55;
664["BallSocketConstraint"] = 90;
665["BrickColorValue"] = 5;
666["Accoutrement"] = 33;
667["AdService"] = 74;
668["AssetService"] = 73;
669["GuiMain"] = 48;
670["ImageButton"] = 53;
671["HapticService"] = 85;
672["DialogChoice"] = 64;
673["Handles"] = 54;
674["ReflectionMetadataClasses"] = 87;
675["JointInstance"] = 35;
676["AnimationController"] = 61;
677["RemoteEvent"] = 81;
678["CollectionService"] = 31;
679["Smoke"] = 60;
680["Configuration"] = 59;
681["KeyframeSequenceProvider"] = 61;
682["Accessory"] = 33;
683["SelectionPointLasso"] = 58;
684["GamePassService"] = 20;
685["CFrameValue"] = 5;
686["TextureTrail"] = 5;
687["ImageLabel"] = 50;
688["ReflectionMetadataMember"] = 87;
689["Animation"] = 61;
690["IntConstrainedValue"] = 5;
691["HttpService"] = 77;
692["PointLight"] = 14;
693["Model"] = 3;
694["DoubleConstrainedValue"] = 5;
695["Snap"] = 35;
696["BodyAngularVelocity"] = 15;
697["VelocityMotor"] = 35;
698["RocketPropulsion"] = 15;
699["SurfaceSelection"] = 56;
700["CoreGui"] = 47;
701["Part"] = 2;
702["ReplicatedFirst"] = 73;
703["BindableEvent"] = 68;
704["SelectionPartLasso"] = 58;
705["NegateOperation"] = 79;
706["PyramidPart"] = 2;
707["ArcHandles"] = 57;
708["Hint"] = 34;
709["Players"] = 22;
710["Script"] = 7;
711["ParallelRampPart"] = 2;
712["RayValue"] = 5;
713["LineHandleAdornment"] = 55;
714["Camera"] = 6;
715["RunService"] = 67;
716["BodyForce"] = 15;
717["KeyframeSequence"] = 61;
718["ServerScriptService"] = 1;
719["BillboardGui"] = 65;
720["BodyThrust"] = 15;
721["RemoteFunction"] = 80;
722["Team"] = 25;
723["Sound"] = 12;
724["GuiButton"] = 53;
725["Workspace"] = 20;
726["Lighting"] = 14;
727["JointsService"] = 35;
728["BlurEffect"] = 91;
729["WedgePart"] = 2;
730["BloomEffect"] = 91;
731["ReflectionMetadata"] = 87;
732["Vector3Value"] = 5;
733["PointsService"] = 84;
734["UserInputService"] = 85;
735["Sparkles"] = 43;
736["BodyGyro"] = 15;
737["Rotate"] = 35;
738["HopperBin"] = 23;
739["ForceField"] = 38;
740["Tool"] = 18;
741["Texture"] = 11;
742["Teams"] = 24;
743["ReflectionMetadataFunctions"] = 87;
744["RodConstraint"] = 90;
745["Folder"] = 71;
746["BodyVelocity"] = 15;
747["Shirt"] = 44;
748["SlidingBallConstraint"] = 90;
749["Animator"] = 61;
750["TextButton"] = 52;
751["Color3Value"] = 5;
752["TextBox"] = 52;
753["NetworkReplicator"] = 30;
754["Platform"] = 36;
755["TerrainRegion"] = 66;
756["SkateboardPlatform"] = 36;
757["Seat"] = 36;
758["Terrain"] = 66;
759["Explosion"] = 37;
760["BlockMesh"] = 9;
761["TeleportService"] = 82;
762["PlayerGui"] = 47;
763["TextLabel"] = 51;
764["SurfaceLight"] = 14;
765["SurfaceGui"] = 65;
766["Debris"] = 31;
767["FlagStand"] = 40;
768["StarterPack"] = 21;
769["BindableFunction"] = 67;
770["ReflectionMetadataCallbacks"] = 87;
771["NetworkClient"] = 17;
772["ModuleScript"] = 72;
773["Flag"] = 39;
774["Status"] = 3;
775["ParticleEmitter"] = 70;
776["StarterPlayer"] = 89;
777["StringValue"] = 5;
778["ObjectValue"] = 5;
779["CharacterMesh"] = 61;
780["StarterGui"] = 47;
781["ReplicatedStorage"] = 73;
782["StarterCharacterScripts"] = 83;
783["NetworkServer"] = 16;
784["Backpack"] = 21;
785["ReflectionMetadataEnum"] = 87;
786["StarterPlayerScripts"] = 83;
787["SpotLight"] = 14;
788["CustomEventReceiver"] = 5;
789["SphereHandleAdornment"] = 55;
790["SoundService"] = 32;
791["SpecialMesh"] = 9;
792["SpawnLocation"] = 26;
793["PlayerScripts"] = 83;
794["PartPairLasso"] = 58;
795["ColorCorrectionEffect"] = 91;
796["UnionOperation"] = 78;
797["Sky"] = 29;
798["MoveToConstraint"] = 90;
799["RopeConstraint"] = 90;
800["RightAngleRampPart"] = 2;
801["ShirtGraphic"] = 41;
802["ScreenGui"] = 48;
803["SelectionSphere"] = 55;
804["RotateV"] = 35;
805["SelectionBox"] = 55;
806["VehicleSeat"] = 36;
807["CustomEvent"] = 5;
808["Chat"] = 34;
809["ServerStorage"] = 75;
810["Selection"] = 56;
811["IntValue"] = 5;
812["RotateP"] = 35;
813["FloorWire"] = 5;
814["TrussPart"] = 2;
815["StarterGear"] = 21;
816["ReflectionMetadataYieldFunctions"] = 87;
817["ReflectionMetadataProperties"] = 87;
818["ReflectionMetadataEvents"] = 87;
819["ReflectionMetadataEnums"] = 87;
820["ReflectionMetadataEnumItem"] = 87;
821["ReflectionMetadataClass"] = 87;
822["PrismPart"] = 2;
823["BinaryStringValue"] = 5;
824["Glue"] = 35;
825["PrismaticConstraint"] = 90;
826["TouchTransmitter"] = 38;
827["CornerWedgePart"] = 2;
828["PathfindingService"] = 38;
829["SpringConstraint"] = 90;
830["Fire"] = 62;
831["Pants"] = 45;
832["NumberValue"] = 5;
833["TestService"] = 69;
834["Motor6D"] = 35;
835["Motor"] = 35;
836["CylindricalConstraint"] = 90;
837["MarketplaceService"] = 47;
838["CoreScript"] = 19;
839["CylinderMesh"] = 9;
840["ConeHandleAdornment"] = 55;
841["SunRaysEffect"] = 91;
842["LocalScript"] = 19;
843["Weld"] = 35;
844["Attachment"] = 35;
845["BoolValue"] = 5;
846["Dialog"] = 63;
847["Pose"] = 61;
848["Decal"] = 8;
849["Hat"] = 46;
850["AnimationTrack"] = 61;
851["ClickDetector"] = 42;
852["Frame"] = 49;
853["LogService"] = 88;
854["FileMesh"] = 9;
855["InsertService"] = 73;
856["HingeConstraint"] = 90;
857["Message"] = 34;
858["Player"] = 13;
859["ContextActionService"] = 42;
860["ContentProvider"] = 73;
861["BodyPosition"] = 15;
862["BoxHandleAdornment"] = 55;
863["ScrollingFrame"] = 49;
864["Keyframe"] = 61;
865}
866
867--== End ==--
868
869--== Make UIs ==--
870
871local Main = Create("ScreenGui", {Parent=service.Players.LocalPlayer.PlayerGui,Name="Mr.Spy - Rebug REX/Kurokku",ResetOnSpawn=false})
872local Hub = Create("TextButton", {Name="Hub",Visible=false,Size=UDim2.new(0,600,0,50),Position=UDim2.new(0.5,-300,0.5,-200),Draggable=true,BackgroundTransparency=1,Text="",Parent=Main,ZIndex=1})
873local RealUI = Create("Frame", {Name="Main",Size=UDim2.new(1,0,7,0),Position=UDim2.new(0,0,1,0),BackgroundColor3=Color3.fromRGB(200,200,200),BackgroundTransparency=1,BorderSizePixel=0,Parent=Hub,ZIndex=2})
874local TextureHolder = Create("Frame", {Name="Holder",ClipsDescendants=true,Size=UDim2.new(1,0,1,0),Parent=RealUI,BackgroundTransparency=1,BorderSizePixel=0,ZIndex=3})
875local Texture1 = Create("ImageLabel", {Name="BG",Size=UDim2.new(2,0,2,0),ScaleType="Tile",TileSize=UDim2.new(0,100,0,100),ImageColor3=Color3.fromRGB(44, 44, 44),Image="rbxassetid://585867512",Parent=TextureHolder,BackgroundTransparency=1,BorderSizePixel=0,ZIndex=3})
876local Bar = Create("Frame", {Name="Bar",Size=UDim2.new(1,0,1,0),Position=UDim2.new(0,0,0,0),BackgroundColor3=Color3.fromRGB(63, 63, 63),BackgroundTransparency=0,BorderSizePixel=0,Parent=Hub,ZIndex=6})
877local Credits = Create("TextLabel",{Parent=Bar,ZIndex=7,Font="SourceSansBold",TextSize=20,Size=UDim2.new(.5,0,1,0),Position=UDim2.new(0,10,0,0),TextStrokeTransparency=1,Text="Mr.Spy - Rebug REX/Kurokku",TextColor3=Color3.fromRGB(230,230,230),BackgroundTransparency=1,TextXAlignment="Left",BorderSizePixel=0})
878local Exit = Create("TextButton", {Name="Exit",Size=UDim2.new(0.1,0,.8,0),Position=UDim2.new(0.9,0,0.1,0),BackgroundTransparency=1,TextColor3=Color3.fromRGB(255,255,255),TextWrapped=true,TextScaled=true,Text="x",Parent=Bar,ZIndex=8})
879local Minimize = Create("TextButton", {Name="Minimize",Size=UDim2.new(0.1,0,1,0),Position=UDim2.new(0.8,0,0,0),BackgroundTransparency=1,TextColor3=Color3.fromRGB(255,255,255),TextWrapped=true,TextScaled=true,Text="-",Parent=Bar,ZIndex=8})
880local Open = Create("TextButton", {Name="Open",Font="SourceSansLight",AutoButtonColor=false,Size=UDim2.new(0,60,0,20),ZIndex=2,BackgroundColor3=Color3.fromRGB(63, 63, 63),Position=UDim2.new(.5,-30,.9,-10),BackgroundTransparency=0,BorderSizePixel=0,TextColor3=Color3.fromRGB(255,255,255),TextWrapped=true,TextScaled=true,Text=" Open ",Parent=Main})
881local IconFrame = Create("Frame", {Name="MapHolder",Size=UDim2.new(0,16,0,16),BackgroundTransparency=1,ClipsDescendants=true,ZIndex=100,Parent=nil})
882local IconMap = Create("ImageLabel", {Name="IconMap",Size=UDim2.new(0,256,0,256),Image="rbxassetid://483448923",Parent=IconFrame,BackgroundTransparency=1,BorderSizePixel=0,ZIndex=100})
883local Scroller = Create("ScrollingFrame", {Name="Remotes",Size=UDim2.new(1,0,1,0),CanvasSize=UDim2.new(0,0,0,0),Parent=RealUI,ZIndex=5,BackgroundTransparency=1,BorderSizePixel=0,TopImage="rbxasset://textures/ui/Scroll/scroll-middle.png",BottomImage="rbxasset://textures/ui/Scroll/scroll-middle.png"})
884local RemoteTemplate = Create("Frame",{Name="Template",Size=UDim2.new(1,0,0,40),Parent=nil,ZIndex=6,BackgroundTransparency=1})
885local RemoteName = Create("TextLabel",{Name="RemoteName",Parent=RemoteTemplate,TextColor3=Color3.fromRGB(230,230,230),BackgroundTransparency=1,ZIndex=7,Size=UDim2.new(1,-26,1,0),Position=UDim2.new(0,30,0,0),TextXAlignment="Left"})
886local SpyButton = Create("TextButton", {Name="SpyRemote",Parent=RemoteTemplate,TextColor3=Color3.fromRGB(230,230,230),AutoButtonColor=false,BorderSizePixel=0,BackgroundColor3=Color3.fromRGB(63, 63, 63),Size=UDim2.new(0.075,0,0.45,0),ZIndex=9,Text="Spy"})
887local PathButton = Create("TextButton", {Name="PathButton",Parent=RemoteTemplate,TextColor3=Color3.fromRGB(230,230,230),AutoButtonColor=false,BorderSizePixel=0,BackgroundColor3=Color3.fromRGB(63, 63, 63),Size=UDim2.new(0.1,0,0.45,0),ZIndex=9,Text="Get Path"})
888local OpenSpy = Create("TextButton", {Name="OpenButton",Parent=RemoteTemplate,TextColor3=Color3.fromRGB(230,230,230),AutoButtonColor=false,BorderSizePixel=0,BackgroundColor3=Color3.fromRGB(63, 63, 63),Size=UDim2.new(0.18,0,0.45,0),ZIndex=9,Text="Copy to Clipboard"})
889local spyAll = Create("TextButton", {Name="SpyAll",Parent=RealUI,TextColor3=Color3.fromRGB(230,230,230),AutoButtonColor=false,BorderSizePixel=0,BackgroundColor3=Color3.fromRGB(63, 63, 63),Size=UDim2.new(0.2,0,0.075,0),Position=UDim2.new(0.05,0,1.05,0),ZIndex=9,Text="Spy all Remotes"})
890local UnspyAll = Create("TextButton", {Name="UnSpyAll",Parent=RealUI,TextColor3=Color3.fromRGB(230,230,230),AutoButtonColor=false,BorderSizePixel=0,BackgroundColor3=Color3.fromRGB(63, 63, 63),Size=UDim2.new(0.2,0,0.075,0),Position=UDim2.new(0.3,0,1.05,0),ZIndex=9,Text="Unspy all Remotes"})
891
892local ExplorerWindow = Create("TextButton", {Name="Explorer",Visible=false,Size=UDim2.new(0,200,0,50),Position=UDim2.new(0.8,-75,0.5,-200),Draggable=true,BackgroundTransparency=1,Text="",Parent=Main,ZIndex=1})
893local Bar2 = Create("Frame", {Name="Bar",Size=UDim2.new(1,0,1,0),Position=UDim2.new(0,0,0,0),BackgroundColor3=Color3.fromRGB(63, 63, 63),BackgroundTransparency=0,BorderSizePixel=0,Parent=ExplorerWindow,ZIndex=6})
894local ExplorerName = Create("TextLabel",{Parent=Bar2,ZIndex=7,Font="SourceSansBold",TextSize=20,Size=UDim2.new(.5,0,1,0),Position=UDim2.new(0,10,0,0),TextStrokeTransparency=1,Text="Explorer",TextColor3=Color3.fromRGB(230,230,230),BackgroundTransparency=1,TextXAlignment="Left",BorderSizePixel=0})
895local Minimize2 = Create("TextButton", {Name="Minimize",Size=UDim2.new(0.1,0,1,0),Position=UDim2.new(0.85,0,0,0),BackgroundTransparency=1,TextColor3=Color3.fromRGB(255,255,255),TextWrapped=true,TextScaled=true,Text="-",Parent=Bar2,ZIndex=8})
896local RealExUI = Create("Frame", {Name="ExMain",Size=UDim2.new(1,0,7,0),Position=UDim2.new(0,0,1,0),BackgroundColor3=Color3.fromRGB(200,200,200),BackgroundTransparency=1,BorderSizePixel=0,Parent=ExplorerWindow,ZIndex=2})
897local TextureHolder2 = Create("Frame", {Name="Holder",ClipsDescendants=true,Size=UDim2.new(1,0,1,0),Parent=RealExUI,BackgroundTransparency=1,BorderSizePixel=0,ZIndex=3})
898local Texture2 = Create("ImageLabel", {Name="BG",Size=UDim2.new(2,0,2,0),ScaleType="Tile",TileSize=UDim2.new(0,100,0,100),ImageColor3=Color3.fromRGB(44, 44, 44),Image="rbxassetid://585867512",Parent=TextureHolder2,BackgroundTransparency=1,BorderSizePixel=0,ZIndex=3})
899local Scroller2 = Create("ScrollingFrame", {Name="Path",Size=UDim2.new(1,0,1,0),CanvasSize=UDim2.new(0,0,0,0),Parent=RealExUI,ZIndex=500,BackgroundTransparency=1,BorderSizePixel=0,TopImage="rbxasset://textures/ui/Scroll/scroll-middle.png",BottomImage="rbxasset://textures/ui/Scroll/scroll-middle.png"})
900local PathTemplate = Create("Frame",{Name="PathTemplate",Size=UDim2.new(1,0,0,20),Parent=nil,ZIndex=6,BackgroundTransparency=1})
901local PathName = Create("TextLabel",{Name="PathName",Parent=PathTemplate,TextColor3=Color3.fromRGB(230,230,230),BackgroundTransparency=1,ZIndex=7,Size=UDim2.new(1,0,1,0),Position=UDim2.new(0,20,0,0),TextXAlignment="Left"})
902local IconModeFrame = Create("Frame", {Name="Mode",Size=UDim2.new(0,16,0,16),BackgroundTransparency=1,ClipsDescendants=true,ZIndex=100,Parent=nil})
903local IconModeMap = Create("ImageLabel", {Name="IconMap",Size=UDim2.new(0,256,0,256),Image="rbxassetid://483448923",Parent=IconModeFrame,BackgroundTransparency=1,BorderSizePixel=0,ZIndex=100})
904local ModeBtn = Create("TextButton", {Name="Button",Size=UDim2.new(1,0,1,0),BackgroundTransparency=1,Text="",ZIndex=101,Parent=IconModeFrame})
905local HoverFrame = Create("Frame", {Name="HoverFrame",Size=UDim2.new(1000,0,1,0),Parent=PathTemplate,ZIndex=102,BackgroundTransparency=1,BorderSizePixel=0,BackgroundColor3=Color3.fromRGB(255,255,255)})
906
907local LogWindow = Create("TextButton", {Name="Logs",Visible=false,Size=UDim2.new(0,300,0,50),Position=UDim2.new(0.16,-175,0.5,-200),Draggable=true,BackgroundTransparency=1,Text="",Parent=Main,ZIndex=1})
908local Bar3 = Create("Frame", {Name="Bar",Size=UDim2.new(1,0,1,0),Position=UDim2.new(0,0,0,0),BackgroundColor3=Color3.fromRGB(63, 63, 63),BackgroundTransparency=0,BorderSizePixel=0,Parent=LogWindow,ZIndex=6})
909local LogName = Create("TextLabel",{Parent=Bar3,ZIndex=7,Font="SourceSansBold",TextSize=20,Size=UDim2.new(.5,0,1,0),Position=UDim2.new(0,10,0,0),TextStrokeTransparency=1,Text="Event Logs",TextColor3=Color3.fromRGB(230,230,230),BackgroundTransparency=1,TextXAlignment="Left",BorderSizePixel=0})
910local Minimize3 = Create("TextButton", {Name="Minimize",Size=UDim2.new(0.1,0,1,0),Position=UDim2.new(0.85,0,0,0),BackgroundTransparency=1,TextColor3=Color3.fromRGB(255,255,255),TextWrapped=true,TextScaled=true,Text="-",Parent=Bar3,ZIndex=8})
911local RealLogUI = Create("Frame", {Name="LMain",Size=UDim2.new(1,0,7,0),Position=UDim2.new(0,0,1,0),BackgroundColor3=Color3.fromRGB(200,200,200),BackgroundTransparency=1,BorderSizePixel=0,Parent=LogWindow,ZIndex=2})
912local TextureHolder3 = Create("Frame", {Name="Holder",ClipsDescendants=true,Size=UDim2.new(1,0,1,0),Parent=RealLogUI,BackgroundTransparency=1,BorderSizePixel=0,ZIndex=3})
913local Texture3 = Create("ImageLabel", {Name="BG",Size=UDim2.new(2,0,2,0),ScaleType="Tile",TileSize=UDim2.new(0,100,0,100),ImageColor3=Color3.fromRGB(44, 44, 44),Image="rbxassetid://585867512",Parent=TextureHolder3,BackgroundTransparency=1,BorderSizePixel=0,ZIndex=3})
914local Scroller3 = Create("ScrollingFrame", {Name="Logs",Size=UDim2.new(1,0,1,0),CanvasSize=UDim2.new(0,0,0,0),Parent=RealLogUI,ZIndex=500,BackgroundTransparency=1,BorderSizePixel=0,TopImage="rbxasset://textures/ui/Scroll/scroll-middle.png",BottomImage="rbxasset://textures/ui/Scroll/scroll-middle.png"})
915local LogTemplate = Create("Frame",{Name="LogTemplate",Size=UDim2.new(1,0,0,20),Parent=nil,ZIndex=6,BackgroundTransparency=1})
916local LogName = Create("TextLabel",{Name="LogName",Parent=LogTemplate,TextColor3=Color3.fromRGB(230,230,230),BackgroundTransparency=1,ZIndex=7,Size=UDim2.new(1,0,1,0),Position=UDim2.new(0,20,0,0),TextXAlignment="Left"})
917
918local Removed = false
919Main.ChildRemoved:Connect(function()
920if not Removed then
921Removed = true
922BreakCode()
923end
924end)
925
926--MakeShadows--
927local HubShadows = MakeShadow(Hub,1,3,7,1)
928MakeShadow(Bar,5,3,1,0)
929MakeShadow(Bar2,5,3,1,0)
930MakeShadow(Open,1,3,1,0)
931MakeShadow(Bar3,5,3,1,0)
932MakeShadow(SpyButton,8,3,1,0)
933MakeShadow(PathButton,8,3,1,0)
934MakeShadow(OpenSpy,8,3,1,0)
935MakeShadow(spyAll,8,3,1,0)
936local ExplorerShadows = MakeShadow(ExplorerWindow,1,3,7,1)
937local LogShadows = MakeShadow(LogWindow,1,3,7,1)
938--== End ==--
939
940--== UI Functions ==--
941
942function LoadIcon(service, frame, numb)
943if Indexs[service] or numb then
944local row = 1
945local col = 0
946if numb then
947for i = 1,numb do
948if i > colSize*row then
949col = 1
950row = row+1
951else
952col = col+1
953end
954end
955else
956for i = 1,Indexs[service] do
957if i > colSize*row then
958col = 1
959row = row+1
960else
961col = col+1
962end
963end
964end
965frame.IconMap.Position = UDim2.new(0,(-3+(-18*col))+18,0,(-3+(-18*row))+18)
966end
967end
968
969spawn(function()
970local suc,er = pcall(function()
971while true do
972Texture1:TweenPosition(UDim2.new(-1,0,-1,0),"Out","Linear",30,true)
973wait(30)
974Texture1.Position = UDim2.new(0,0,0,0)
975end
976end)
977end)
978
979spawn(function()
980local suc,er = pcall(function()
981while true do
982Texture2:TweenPosition(UDim2.new(-1,0,-1,0),"Out","Linear",30,true)
983wait(30)
984Texture2.Position = UDim2.new(0,0,0,0)
985end
986end)
987end)
988
989spawn(function()
990local suc,er = pcall(function()
991while true do
992Texture3:TweenPosition(UDim2.new(-1,0,-1,0),"Out","Linear",30,true)
993wait(30)
994Texture3.Position = UDim2.new(0,0,0,0)
995end
996end)
997end)
998
999local ExitDB=false
1000
1001Open.MouseButton1Down:Connect(function()
1002if not ExitDB then
1003ExitDB = true
1004Hub.Position = UDim2.new(0,-600,0.5,-200)
1005ExplorerWindow.Position = UDim2.new(0.875,-75,-0.35,-200)
1006LogWindow.Position = UDim2.new(0.16,-175,1,200)
1007Hub.Visible = true
1008ExplorerWindow.Visible = true
1009LogWindow.Visible = true
1010Open.Visible = false
1011Hub:TweenPosition(UDim2.new(0.535,-300,0.5,-200),"Out","Elastic",0.5,true)
1012wait(0.15)
1013ExplorerWindow:TweenPosition(UDim2.new(0.875,-75,0.5,-200),"Out","Elastic",0.5,true)
1014wait(0.15)
1015LogWindow:TweenPosition(UDim2.new(0.16,-175,0.5,-200),"Out","Elastic",0.5,true)
1016wait()
1017game:GetService("TweenService"):Create(Open,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1018ExitDB = false
1019end
1020end)
1021
1022Bar.MouseEnter:Connect(function()
1023game:GetService("TweenService"):Create(Bar,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1024end)
1025
1026Bar.MouseLeave:Connect(function()
1027game:GetService("TweenService"):Create(Bar,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1028end)
1029
1030Bar2.MouseEnter:Connect(function()
1031game:GetService("TweenService"):Create(Bar2,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1032end)
1033
1034Bar2.MouseLeave:Connect(function()
1035game:GetService("TweenService"):Create(Bar2,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1036end)
1037
1038Bar3.MouseEnter:Connect(function()
1039game:GetService("TweenService"):Create(Bar3,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1040end)
1041
1042Bar3.MouseLeave:Connect(function()
1043game:GetService("TweenService"):Create(Bar3,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1044end)
1045
1046Open.MouseEnter:Connect(function()
1047game:GetService("TweenService"):Create(Open,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1048end)
1049
1050Open.MouseLeave:Connect(function()
1051game:GetService("TweenService"):Create(Open,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1052end)
1053
1054spyAll.MouseEnter:Connect(function()
1055game:GetService("TweenService"):Create(spyAll,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1056end)
1057
1058spyAll.MouseLeave:Connect(function()
1059game:GetService("TweenService"):Create(spyAll,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1060end)
1061
1062UnspyAll.MouseEnter:Connect(function()
1063game:GetService("TweenService"):Create(UnspyAll,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1064end)
1065
1066UnspyAll.MouseLeave:Connect(function()
1067game:GetService("TweenService"):Create(UnspyAll,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1068end)
1069
1070Exit.MouseEnter:Connect(function()
1071game:GetService("TweenService"):Create(Exit,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(170, 46, 46);}):Play()
1072wait()
1073game:GetService("TweenService"):Create(Bar,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1074end)
1075
1076Exit.MouseLeave:Connect(function()
1077game:GetService("TweenService"):Create(Exit,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(255, 255, 255);}):Play()
1078game:GetService("TweenService"):Create(Bar,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1079end)
1080
1081Minimize.MouseEnter:Connect(function()
1082game:GetService("TweenService"):Create(Minimize,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(150, 150, 150);}):Play()
1083wait()
1084game:GetService("TweenService"):Create(Bar,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1085end)
1086
1087Minimize.MouseLeave:Connect(function()
1088game:GetService("TweenService"):Create(Minimize,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(255, 255, 255);}):Play()
1089game:GetService("TweenService"):Create(Bar,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1090end)
1091
1092Minimize2.MouseEnter:Connect(function()
1093game:GetService("TweenService"):Create(Minimize2,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(150, 150, 150);}):Play()
1094wait()
1095game:GetService("TweenService"):Create(Bar2,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1096end)
1097
1098Minimize2.MouseLeave:Connect(function()
1099game:GetService("TweenService"):Create(Minimize2,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(255, 255, 255);}):Play()
1100game:GetService("TweenService"):Create(Bar2,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1101end)
1102
1103Minimize3.MouseEnter:Connect(function()
1104game:GetService("TweenService"):Create(Minimize3,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(150, 150, 150);}):Play()
1105wait()
1106game:GetService("TweenService"):Create(Bar3,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1107end)
1108
1109Minimize3.MouseLeave:Connect(function()
1110game:GetService("TweenService"):Create(Minimize3,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(255, 255, 255);}):Play()
1111game:GetService("TweenService"):Create(Bar3,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1112end)
1113
1114local minDB1 = false
1115Minimize.MouseButton1Down:Connect(function()
1116if not minDB1 then
1117minDB1 = true
1118if RealUI.Visible then
1119RealUI.Visible = false
1120for i,v in pairs(HubShadows) do
1121v.Visible = false
1122end
1123else
1124RealUI.Visible = true
1125for i,v in pairs(HubShadows) do
1126v.Visible = true
1127end
1128end
1129minDB1 = false
1130end
1131end)
1132
1133local minDB2 = false
1134Minimize2.MouseButton1Down:Connect(function()
1135if not minDB2 then
1136minDB2 = true
1137if RealExUI.Visible then
1138RealExUI.Visible = false
1139for i,v in pairs(ExplorerShadows) do
1140v.Visible = false
1141end
1142else
1143RealExUI.Visible = true
1144for i,v in pairs(ExplorerShadows) do
1145v.Visible = true
1146end
1147end
1148minDB2 = false
1149end
1150end)
1151
1152local minDB3 = false
1153Minimize3.MouseButton1Down:Connect(function()
1154if not minDB3 then
1155minDB3 = true
1156if RealLogUI.Visible then
1157RealLogUI.Visible = false
1158for i,v in pairs(LogShadows) do
1159v.Visible = false
1160end
1161else
1162RealLogUI.Visible = true
1163for i,v in pairs(LogShadows) do
1164v.Visible = true
1165end
1166end
1167minDB3 = false
1168end
1169end)
1170
1171Exit.MouseButton1Down:Connect(function()
1172if not ExitDB then
1173ExitDB = true
1174Open.Visible = true
1175Hub:TweenPosition(UDim2.new(-0.2,-600,-1,0),"In","Quart",0.5,true)
1176wait(0.15)
1177ExplorerWindow:TweenPosition(UDim2.new(1,200,-1,0),"In","Quart",0.5,true)
1178wait(0.15)
1179LogWindow:TweenPosition(UDim2.new(-0.5,-300,1,0),"In","Quart",0.5,true)
1180wait(0.5)
1181game:GetService("TweenService"):Create(Bar,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1182game:GetService("TweenService"):Create(Minimize,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(255, 255, 255);}):Play()
1183game:GetService("TweenService"):Create(Exit,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(255, 255, 255);}):Play()
1184Hub.Visible = false
1185ExplorerWindow.Visible = false
1186LogWindow.Visible = false
1187Open.Visible = true
1188ExitDB = false
1189end
1190end)
1191
1192local classMethods = {
1193BindableEvent = "Fire";
1194BindableFunction = "Invoke";
1195RemoteEvent = "FireServer";
1196RemoteFunction = "InvokeServer";
1197}
1198
1199local realMethods = {}
1200local pseudoEnv = {}
1201
1202local Spying = {}
1203local SpyedNumb = 1
1204
1205for i,v in pairs(classMethods) do
1206realMethods[v] = Instance.new(i)[classMethods[i]]
1207end
1208local BiggestX = 0
1209function AddUI(args)
1210local NewUI = LogTemplate:Clone()
1211local mapp = IconFrame:Clone()
1212LoadIcon(args[1].ClassName, mapp)
1213mapp.Position = UDim2.new(0,0,0.5,-8)
1214NewUI.LogName.Text = "Name: \""..args[1].Name .. "\" | "..args[2]
1215NewUI.Position = UDim2.new(0,0,0,SpyedNumb*20)
1216NewUI.Parent = Scroller3
1217mapp.Parent = NewUI
1218SpyedNumb = SpyedNumb + 1
1219if BiggestX < NewUI.LogName.TextBounds.X then
1220BiggestX = NewUI.LogName.TextBounds.X
1221end
1222Scroller3.CanvasSize = UDim2.new(0,BiggestX+20,0,20*#Scroller3:GetChildren()+20)
1223end
1224
1225function GetNameCall(obj)
1226if obj.ClassName == "RemoteEvent" then
1227return "FireServer"
1228elseif obj.ClassName == "RemoteFunction" then
1229return "InvokeServer"
1230elseif obj.ClassName == "BindableEvent" then
1231return "Fire"
1232elseif obj.ClassName == "BindabledFunction" then
1233return "Invoke"
1234end
1235end
1236
1237function LoadRemoteSpy()
1238if tostring(_G.Exploit) == "Synapse" then
1239local function hook(methodname, self, ...)
1240 local args = {...}
1241 local ret = {realMethods[methodname](self,...)}
1242if not realMethods[methodname] then return unpack(ret) end
1243if not Spying[self] then return unpack(ret) end
1244 SpyArgs[SpyedNumb] = {self,ReturnArgs(GetNameCall(self),self,...)}
1245AddUI(SpyArgs[SpyedNumb])
1246 return unpack(ret)
1247end
1248Synapse:SetNamecallHook("FireServer", function(self, ...)
1249 if self:IsA("RemoteEvent") then
1250 hook(GetNameCall(self), self, ...)
1251 end
1252end)
1253Synapse:SetNamecallHook("InvokeServer", function(self, ...)
1254 if self:IsA("RemoteFunction") then
1255 hook(GetNameCall(self), self, ...)
1256 end
1257end)
1258Synapse:SetNamecallHook("Fire", function(self, ...)
1259 if self:IsA("BindableEvent") then
1260 hook(GetNameCall(self), self, ...)
1261 end
1262end)
1263Synapse:SetNamecallHook("Invoke", function(self, ...)
1264 if self:IsA("BindableFunction") then
1265 hook(GetNameCall(self), self, ...)
1266 end
1267end)
1268elseif tostring(_G.Exploit) == "SetWrite" then
1269setreadonly(getrawmetatable(game), false)
1270local pseudoEnv = {}
1271local gameMeta = getrawmetatable(game)
1272for key, value in next, gameMeta do pseudoEnv[key] = value end
1273gameMeta.__index, gameMeta.__namecall = function(self, key)
1274if not realMethods[key] then return pseudoEnv.__index(self, key) end
1275if not Spying[self] then return pseudoEnv.__index(self, key) end
1276return function(_, ...)
1277local returnValues = {realMethods[key](self, ...)}
1278SpyArgs[SpyedNumb] = {self,ReturnArgs(GetNameCall(self),self,...)}
1279AddUI(SpyArgs[SpyedNumb])
1280return unpack(returnValues)
1281end
1282end
1283elseif tostring(_G.Exploit) == "Writeable" then
1284make_writeable(getrawmetatable(game))
1285local pseudoEnv = {}
1286local gameMeta = getrawmetatable(game)
1287for key, value in next, gameMeta do pseudoEnv[key] = value end
1288gameMeta.__index, gameMeta.__namecall = function(self, key)
1289if not realMethods[key] then return pseudoEnv.__index(self, key) end
1290if not Spying[self] then return pseudoEnv.__index(self, key) end
1291return function(_, ...)
1292local returnValues = {realMethods[key](self, ...)}
1293SpyArgs[SpyedNumb] = {self,ReturnArgs(GetNameCall(self),self,...)}
1294AddUI(SpyArgs[SpyedNumb])
1295return unpack(returnValues)
1296end
1297end
1298elseif tostring(_G.Exploit) == "BackUp" then
1299local pseudoEnv = {}
1300local gameMeta = getrawmetatable(game)
1301for key, value in next, gameMeta do pseudoEnv[key] = value end
1302gameMeta.__index, gameMeta.__namecall = function(self, key)
1303if not realMethods[key] then return pseudoEnv.__index(self, key) end
1304if not Spying[self] then return pseudoEnv.__index(self, key) end
1305return function(_, ...)
1306local returnValues = {realMethods[key](self, ...)}
1307SpyArgs[SpyedNumb] = {self,ReturnArgs(GetNameCall(self),self,...)}
1308AddUI(SpyArgs[SpyedNumb])
1309return unpack(returnValues)
1310end
1311end
1312else
1313print("Mr.Spy does not support your script executer due to it might not have a way to run \"getrawmetatable\"")
1314end
1315end
1316LoadRemoteSpy()
1317
1318local RemoteIgnores = {
1319["CharacterSoundEvent"] = true;
1320["MovementUpdate"] = true;
1321["FollowRelationshipChange"] = true;
1322["OnMessageDoneFiltering"] = true;
1323["SendNotification"] = true;
1324["SetDialogInUse"] = true;
1325["OnUnmuted"] = true;
1326["MutePlayerRequested"] = true;
1327["OnChannelJoined"] = true;
1328["OnNewMessage"] = true;
1329["SendNotificationInfo"] = true;
1330["GetFollowRelationships"] = true;
1331["GuiInsetChanged"] = true;
1332["NewFollower"] = true;
1333["OnNewSystemMessage"] = true;
1334["GetServerVersion"] = true;
1335["GetInitDataRequest"] = true;
1336["OnMainChannelSet"] = true;
1337["DefaultServerSoundEvent"] = true;
1338["ChannelNameColorUpdated"] = true;
1339["UnMutePlayerRequest"] = true;
1340["OnChannelLeft"] = true;
1341["SayMessageRequest"] = true;
1342["SetBlockedUserIdsRequest"] = true;
1343["FollowRelationshipChanged"] = true;
1344["GamepadNotifications"] = true;
1345["OnMuted"] = true;
1346["MutePlayerRequest"] = true;
1347}
1348
1349function StartSpy()
1350local Remotes = {}
1351local function MakeItem(v,pos)
1352local temp = RemoteTemplate:Clone()
1353local map = IconFrame:Clone()
1354v[2] = temp
1355LoadIcon(v[1].ClassName,map)
1356map.Position = UDim2.new(0,10,0.5,-8)
1357map.Parent = temp
1358temp.Name = pos/40
1359temp.RemoteName.Text = v[1].Name
1360temp.Parent = Scroller
1361temp.Position = UDim2.new(0,0,0,pos)
1362temp.SpyRemote.TextColor3 = Color3.fromRGB(170, 46, 46)
1363temp.SpyRemote.Position = UDim2.new(0,20+temp.RemoteName.TextBounds.X+15,0.225,0)
1364temp.PathButton.Position = UDim2.new(temp.PathButton.Size.X.Scale,20+temp.RemoteName.TextBounds.X+15,0.225,0)
1365temp.OpenButton.Position = UDim2.new(temp.OpenButton.Size.X.Scale+temp.PathButton.Size.X.Scale,temp.RemoteName.TextBounds.X,0.225,0)
1366if Spying[v[1]] then
1367temp.SpyRemote.TextColor3 = Color3.fromRGB(0, 170, 127)
1368else
1369temp.SpyRemote.TextColor3 = Color3.fromRGB(170, 46, 46)
1370end
1371temp.SpyRemote.MouseEnter:Connect(function()
1372game:GetService("TweenService"):Create(temp.SpyRemote,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1373end)
1374temp.SpyRemote.MouseLeave:Connect(function()
1375game:GetService("TweenService"):Create(temp.SpyRemote,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1376end)
1377temp.SpyRemote.MouseButton1Down:Connect(function()
1378if not Spying[v[1]] then
1379Spying[v[1]] = v[1]
1380game:GetService("TweenService"):Create(temp.SpyRemote,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(0, 170, 127);}):Play()
1381else
1382Spying[v[1]] = nil
1383game:GetService("TweenService"):Create(temp.SpyRemote,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(170, 46, 46);}):Play()
1384end
1385end)
1386temp.PathButton.MouseEnter:Connect(function()
1387game:GetService("TweenService"):Create(temp.PathButton,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1388end)
1389temp.PathButton.MouseLeave:Connect(function()
1390game:GetService("TweenService"):Create(temp.PathButton,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1391end)
1392temp.OpenButton.MouseEnter:Connect(function()
1393game:GetService("TweenService"):Create(temp.OpenButton,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(80, 80, 80);}):Play()
1394end)
1395temp.OpenButton.MouseLeave:Connect(function()
1396game:GetService("TweenService"):Create(temp.OpenButton,TweenInfo.new(0.25),{BackgroundColor3=Color3.fromRGB(63, 63, 63);}):Play()
1397end)
1398temp.OpenButton.MouseButton1Down:Connect(function()
1399local suc,er = pcall(function() setclipboard("game."..v[1]:GetFullName()) end)
1400local suc,er = pcall(function() toclipboard("game."..v[1]:GetFullName()) end)
1401local suc,er = pcall(function() Synapse:CopyString("game."..v[1]:GetFullName()) end)
1402local suc,er = pcall(function() Clipboard.set("game."..v[1]:GetFullName()) end)
1403game:GetService("TweenService"):Create(temp.OpenButton,TweenInfo.new(0.1),{TextColor3=Color3.fromRGB(200, 200, 200);}):Play()
1404wait(0.1)
1405game:GetService("TweenService"):Create(temp.OpenButton,TweenInfo.new(0.1),{TextColor3=Color3.fromRGB(255, 255, 255);}):Play()
1406end)
1407local recurNumb = 1
1408local path = {}
1409local Numb = 0
1410temp.PathButton.MouseButton1Down:Connect(function()
1411recurNumb = 1
1412Numb = 0
1413local function Recur(obj)
1414if obj == game then
1415return
1416else
1417path[recurNumb] = obj
1418end
1419recurNumb = recurNumb + 1
1420Recur(obj.Parent)
1421end
1422Recur(v[1])
1423Scroller2:ClearAllChildren()
1424local OGParent
1425local maxTextX = 0
1426for ii = #path,1,-1 do
1427local obj = path[ii]
1428local UI = PathTemplate:Clone()
1429local Icon = IconFrame:Clone()
1430local mode = IconModeFrame:Clone()
1431if ii > 1 then
1432mode.Parent = UI
1433mode.Position = UDim2.new(0,-20,0.5,-8)
1434LoadIcon(nil,mode,167)
1435end
1436LoadIcon(obj.ClassName,Icon)
1437Icon.Position = UDim2.new(0,0,0.5,-8)
1438Icon.Parent = UI
1439UI.Name = "OBJ"
1440UI.PathName.Text = obj.Name
1441UI.Position = UDim2.new(0,20,0,21)
1442UI.Size = UDim2.new(0,100,0,20)
1443Numb = Numb+1
1444local opened = true
1445mode.MouseEnter:Connect(function()
1446if not opened then
1447LoadIcon(nil,mode,180)
1448else
1449LoadIcon(nil,mode,181)
1450end
1451end)
1452mode.MouseLeave:Connect(function()
1453if not opened then
1454LoadIcon(nil,mode,166)
1455else
1456LoadIcon(nil,mode,167)
1457end
1458end)
1459mode.Button.MouseButton1Down:Connect(function()
1460if not opened then
1461opened = true
1462LoadIcon(nil,mode,181)
1463UI.OBJ.Visible = true
1464else
1465opened = false
1466LoadIcon(nil,mode,180)
1467UI.OBJ.Visible = false
1468end
1469end)
1470UI.HoverFrame.MouseEnter:Connect(function()
1471game:GetService("TweenService"):Create(UI.HoverFrame,TweenInfo.new(0.25),{["BackgroundTransparency"] = 0.9;}):Play()
1472end)
1473UI.HoverFrame.MouseLeave:Connect(function()
1474game:GetService("TweenService"):Create(UI.HoverFrame,TweenInfo.new(0.25),{["BackgroundTransparency"] = 1;}):Play()
1475end)
1476if not OGParent then
1477UI.Position = UDim2.new(0,22,0,4)
1478UI.Parent = Scroller2
1479OGParent = UI
1480else
1481UI.Parent = OGParent
1482OGParent = UI
1483end
1484if maxTextX < UI.PathName.TextBounds.X then
1485maxTextX = UI.PathName.TextBounds.X
1486end
1487end
1488Scroller2.CanvasSize = UDim2.new(0,(maxTextX+(#path*20))+10,0,(Numb*21)+4)
1489game:GetService("TweenService"):Create(temp.PathButton,TweenInfo.new(0.1),{TextColor3=Color3.fromRGB(200, 200, 200);}):Play()
1490wait(0.1)
1491game:GetService("TweenService"):Create(temp.PathButton,TweenInfo.new(0.1),{TextColor3=Color3.fromRGB(255, 255, 255);}):Play()
1492end)
1493end
1494local function LoadUI()
1495Scroller:ClearAllChildren()
1496local pos = 0
1497for i,v in pairs(Remotes) do
1498if v then
1499MakeItem(v, pos)
1500pos = pos+40
1501end
1502end
1503Scroller.CanvasSize = UDim2.new(0,0,0,pos)
1504end
1505local function GetRemotes()
1506local function Recursion(obj)
1507for i,v in pairs(obj:GetChildren()) do
1508local succ,err = pcall(function()
1509if not RemoteIgnores[v.Name] then
1510if v:IsA("RemoteEvent") or v:IsA("RemoteFunction") or v:IsA("BindableEvent") or v:IsA("BindableFunction") then
1511Remotes[v] = {v}
1512end
1513end
1514end)
1515local suc,er = pcall(function()
1516v:GetChildren()
1517end)
1518if suc and #v:GetChildren() > 0 then
1519Recursion(v)
1520end
1521end
1522end
1523Recursion(game)
1524end
1525GetRemotes()
1526LoadUI()
1527for i,v in pairs(game:GetChildren()) do
1528local suc, er = pcall(function()
1529v:GetChildren()
1530end)
1531if suc then
1532v.DescendantAdded:Connect(function(obj)
1533wait(1)
1534if not RemoteIgnores[obj.Name] then
1535if obj:IsA("RemoteEvent") or obj:IsA("RemoteFunction") or obj:IsA("BindableEvent") or obj:IsA("BindableFunction") then
1536Remotes[obj] = {obj}
1537MakeItem(Remotes[obj],((#Scroller:GetChildren())*40))
1538Scroller.CanvasSize = UDim2.new(0,0,0,Scroller.CanvasSize.Y.Offset+40)
1539end
1540end
1541end)
1542v.DescendantRemoving:Connect(function(obj)
1543if not RemoteIgnores[obj.Name] then
1544if obj:IsA("RemoteEvent") or obj:IsA("RemoteFunction") or obj:IsA("BindableEvent") or obj:IsA("BindableFunction") then
1545if Remotes[obj] then
1546for ii = tonumber(Remotes[obj][2].Name),#Scroller:GetChildren() do
1547if ii ~= tonumber(Remotes[obj][2].Name) then
1548local it = Scroller:FindFirstChild(ii)
1549if it then
1550it.Position = UDim2.new(0,0,0,it.Position.Y.Offset-40)
1551it.Name = tonumber(it.Name) - 1
1552end
1553end
1554end
1555Scroller.CanvasSize = UDim2.new(0,0,0,Scroller.CanvasSize.Y.Offset-40)
1556Remotes[obj][2]:Destroy()
1557Remotes[obj] = nil
1558end
1559end
1560end
1561end)
1562end
1563end
1564spyAll.MouseButton1Down:Connect(function()
1565spawn(function()
1566game:GetService("TweenService"):Create(spyAll,TweenInfo.new(0.1),{TextColor3=Color3.fromRGB(200, 200, 200);}):Play()
1567wait(0.1)
1568game:GetService("TweenService"):Create(spyAll,TweenInfo.new(0.1),{TextColor3=Color3.fromRGB(255, 255, 255);}):Play()
1569end)
1570for i,v in pairs(Remotes) do
1571game:GetService("TweenService"):Create(v[2].SpyRemote,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(0, 170, 127);}):Play()
1572Spying[v[1]] = v[1]
1573end
1574end)
1575UnspyAll.MouseButton1Down:Connect(function()
1576spawn(function()
1577game:GetService("TweenService"):Create(UnspyAll,TweenInfo.new(0.1),{TextColor3=Color3.fromRGB(200, 200, 200);}):Play()
1578wait(0.1)
1579game:GetService("TweenService"):Create(UnspyAll,TweenInfo.new(0.1),{TextColor3=Color3.fromRGB(255, 255, 255);}):Play()
1580end)
1581for i,v in pairs(Remotes) do
1582game:GetService("TweenService"):Create(v[2].SpyRemote,TweenInfo.new(0.25),{TextColor3=Color3.fromRGB(170, 46, 46);}):Play()
1583Spying[v[1]] = nil
1584end
1585end)
1586end
1587StartSpy()
1588
1589--== End ==--
1590end
1591
1592button5.MouseButton1Click:connect(clicked)
1593
1594
1595
1596
1597
1598
1599
1600button4 = Dex
1601function clicked()
1602 wait()
1603function CreateInstance(cls,props)
1604 local inst = Instance.new(cls)
1605 for i,v in pairs(props) do
1606 inst[i] = v
1607 end
1608 return inst
1609end
1610
1611function createDexWindow()
1612 local DexWindow = CreateInstance("ScreenGui",{DisplayOrder=0,Enabled=true,ResetOnSpawn=true,Name="Dex",})
1613 local DexWindow2 = CreateInstance("Frame",{Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.10000000149012,BorderColor3=Color3.new(0.74901962280273,0.74901962280273,0.74901962280273),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(1,0,0.5,36),Rotation=0,Selectable=false,Size=UDim2.new(0,300,0.5,-36),SizeConstraint=0,Visible=true,ZIndex=1,Name="PropertiesFrame",Parent = DexWindow})
1614 local DexWindow3 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,-36),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,35),SizeConstraint=0,Visible=true,ZIndex=1,Name="Header",Parent = DexWindow2})
1615 local DexWindow4 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Properties",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,4,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,-4,0.5,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="TextLabel",Parent = DexWindow3})
1616 local DexWindow5 = CreateInstance("TextBox",{ClearTextOnFocus=true,Font=3,FontSize=5,MultiLine=false,Text="Search Properties",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=0.80000001192093,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,4,0.5,0),Rotation=0,Selectable=true,Size=UDim2.new(1,-8,0.5,-3),SizeConstraint=0,Visible=true,ZIndex=1,Name="TextBox",Parent = DexWindow3})
1617 local DexWindow6 = CreateInstance("BindableFunction",{Name="GetApi",Parent = DexWindow2})
1618 local DexWindow7 = CreateInstance("BindableFunction",{Name="GetAwaiting",Parent = DexWindow2})
1619 local DexWindow8 = CreateInstance("BindableEvent",{Name="SetAwaiting",Parent = DexWindow2})
1620 local DexWindow9 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.10000000149012,BorderColor3=Color3.new(0.74901962280273,0.74901962280273,0.74901962280273),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(1,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,300,0.5,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="ExplorerPanel",Parent = DexWindow})
1621 local DexWindow10 = CreateInstance("BindableEvent",{Name="SelectionChanged",Parent = DexWindow9})
1622 local DexWindow11 = CreateInstance("BindableFunction",{Name="SetOption",Parent = DexWindow9})
1623 local DexWindow12 = CreateInstance("BindableFunction",{Name="SetSelection",Parent = DexWindow9})
1624 local DexWindow13 = CreateInstance("BindableFunction",{Name="GetOption",Parent = DexWindow9})
1625 local DexWindow14 = CreateInstance("BindableFunction",{Name="GetSelection",Parent = DexWindow9})
1626 local DexWindow15 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=1,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(1,-330,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,30,0,180),SizeConstraint=0,Visible=false,ZIndex=2,Name="SideMenu",Parent = DexWindow})
1627 local DexWindow16 = CreateInstance("TextButton",{Font=3,FontSize=7,Text=">",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=24,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=1,TextWrapped=true,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=false,Modal=false,Selected=false,Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,60),Rotation=0,Selectable=true,Size=UDim2.new(0,30,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="Toggle",Parent = DexWindow15})
1628 local DexWindow17 = CreateInstance("TextLabel",{Font=4,FontSize=5,Text="DEX",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=true,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,30,0,20),SizeConstraint=0,Visible=true,ZIndex=2,Name="Title",Parent = DexWindow15})
1629 local DexWindow18 = CreateInstance("TextLabel",{Font=4,FontSize=4,Text="V1.0.0",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=12,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=true,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,15),Rotation=0,Selectable=false,Size=UDim2.new(0,30,0,20),SizeConstraint=0,Visible=true,ZIndex=2,Name="Version",Parent = DexWindow15})
1630 local DexWindow19 = CreateInstance("ImageLabel",{Image="rbxassetid://474172996",ImageColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),ImageRectOffset=Vector2.new(0,0),ImageRectSize=Vector2.new(0,0),ImageTransparency=0,ScaleType=0,SliceCenter=Rect.new(0,0,0,0),Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,90),Rotation=180,Selectable=false,Size=UDim2.new(0,30,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="Slant",Parent = DexWindow15})
1631 local DexWindow20 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,30,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="Main",Parent = DexWindow15})
1632 local DexWindow21 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.86274516582489,0.86274516582489,0.86274516582489),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=true,Draggable=false,Position=UDim2.new(0,0,0,30),Rotation=0,Selectable=false,Size=UDim2.new(0,30,0,150),SizeConstraint=0,Visible=true,ZIndex=1,Name="SlideOut",Parent = DexWindow15})
1633 local DexWindow22 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.86274516582489,0.86274516582489,0.86274516582489),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,-150),Rotation=0,Selectable=false,Size=UDim2.new(0,30,0,150),SizeConstraint=0,Visible=true,ZIndex=1,Name="SlideFrame",Parent = DexWindow21})
1634 local DexWindow23 = CreateInstance("TextButton",{Font=3,FontSize=7,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=24,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=false,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,120),Rotation=0,Selectable=true,Size=UDim2.new(0,30,0,30),SizeConstraint=0,Visible=true,ZIndex=2,Name="Explorer",Parent = DexWindow22})
1635 local DexWindow24 = CreateInstance("ImageLabel",{Image="rbxassetid://472635937",ImageColor3=Color3.new(0.27450981736183,0.27450981736183,0.27450981736183),ImageRectOffset=Vector2.new(0,0),ImageRectSize=Vector2.new(0,0),ImageTransparency=0,ScaleType=0,SliceCenter=Rect.new(0,0,0,0),Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,5,0,5),Rotation=0,Selectable=false,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=2,Name="Icon",Parent = DexWindow23})
1636 local DexWindow25 = CreateInstance("TextButton",{Font=3,FontSize=7,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=24,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=false,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,90),Rotation=0,Selectable=true,Size=UDim2.new(0,30,0,30),SizeConstraint=0,Visible=true,ZIndex=2,Name="SaveMap",Parent = DexWindow22})
1637 local DexWindow26 = CreateInstance("ImageLabel",{Image="rbxassetid://472636337",ImageColor3=Color3.new(0.27450981736183,0.27450981736183,0.27450981736183),ImageRectOffset=Vector2.new(0,0),ImageRectSize=Vector2.new(0,0),ImageTransparency=0,ScaleType=0,SliceCenter=Rect.new(0,0,0,0),Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,5,0,5),Rotation=0,Selectable=false,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=2,Name="Icon",Parent = DexWindow25})
1638 local DexWindow27 = CreateInstance("TextButton",{Font=3,FontSize=7,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=24,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=false,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,30),Rotation=0,Selectable=true,Size=UDim2.new(0,30,0,30),SizeConstraint=0,Visible=true,ZIndex=2,Name="Settings",Parent = DexWindow22})
1639 local DexWindow28 = CreateInstance("ImageLabel",{Image="rbxassetid://472635774",ImageColor3=Color3.new(0.27450981736183,0.27450981736183,0.27450981736183),ImageRectOffset=Vector2.new(0,0),ImageRectSize=Vector2.new(0,0),ImageTransparency=0,ScaleType=0,SliceCenter=Rect.new(0,0,0,0),Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,5,0,5),Rotation=0,Selectable=false,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=2,Name="Icon",Parent = DexWindow27})
1640 local DexWindow29 = CreateInstance("TextButton",{Font=3,FontSize=7,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=24,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=false,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,60),Rotation=0,Selectable=true,Size=UDim2.new(0,30,0,30),SizeConstraint=0,Visible=true,ZIndex=2,Name="Remotes",Parent = DexWindow22})
1641 local DexWindow30 = CreateInstance("ImageLabel",{Image="rbxassetid://472636187",ImageColor3=Color3.new(0.27450981736183,0.27450981736183,0.27450981736183),ImageRectOffset=Vector2.new(0,0),ImageRectSize=Vector2.new(0,0),ImageTransparency=0,ScaleType=0,SliceCenter=Rect.new(0,0,0,0),Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,5,0,5),Rotation=0,Selectable=false,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=2,Name="Icon",Parent = DexWindow29})
1642 local DexWindow31 = CreateInstance("TextButton",{Font=3,FontSize=7,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=24,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=false,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=true,Size=UDim2.new(0,30,0,30),SizeConstraint=0,Visible=true,ZIndex=2,Name="About",Parent = DexWindow22})
1643 local DexWindow32 = CreateInstance("ImageLabel",{Image="rbxassetid://476354004",ImageColor3=Color3.new(0.27450981736183,0.27450981736183,0.27450981736183),ImageRectOffset=Vector2.new(0,0),ImageRectSize=Vector2.new(0,0),ImageTransparency=0,ScaleType=0,SliceCenter=Rect.new(0,0,0,0),Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,5,0,5),Rotation=0,Selectable=false,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=2,Name="Icon",Parent = DexWindow31})
1644 local DexWindow33 = CreateInstance("TextButton",{Font=3,FontSize=7,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=24,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=false,Modal=false,Selected=false,Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,30),Rotation=0,Selectable=true,Size=UDim2.new(0,30,0,30),SizeConstraint=0,Visible=true,ZIndex=2,Name="OpenScriptEditor",Parent = DexWindow15})
1645 local DexWindow34 = CreateInstance("ImageLabel",{Image="rbxassetid://475456048",ImageColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),ImageRectOffset=Vector2.new(0,0),ImageRectSize=Vector2.new(0,0),ImageTransparency=1,ScaleType=0,SliceCenter=Rect.new(0,0,0,0),Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,5,0,5),Rotation=0,Selectable=false,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=2,Name="Icon",Parent = DexWindow33})
1646 local DexWindow35 = CreateInstance("TextButton",{Font=3,FontSize=7,Text="<",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=24,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(1,0,0,0),Rotation=0,Selectable=true,Size=UDim2.new(0,30,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="Toggle",Parent = DexWindow})
1647 local DexWindow36 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.10000000149012,BorderColor3=Color3.new(0.74901962280273,0.74901962280273,0.74901962280273),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(1,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,300,1,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="SettingsPanel",Parent = DexWindow})
1648 local DexWindow37 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,17),SizeConstraint=0,Visible=true,ZIndex=1,Name="Header",Parent = DexWindow36})
1649 local DexWindow38 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Settings",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,4,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,-4,1,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="TextLabel",Parent = DexWindow37})
1650 local DexWindow39 = CreateInstance("BindableFunction",{Name="GetSetting",Parent = DexWindow36})
1651 local DexWindow40 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,18),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,60),SizeConstraint=0,Visible=false,ZIndex=1,Name="SettingTemplate",Parent = DexWindow36})
1652 local DexWindow41 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="SettingName",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,10,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,-20,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="SName",Parent = DexWindow40})
1653 local DexWindow42 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="Off",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,60,0,30),Rotation=0,Selectable=false,Size=UDim2.new(0,50,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="Status",Parent = DexWindow40})
1654 local DexWindow43 = CreateInstance("TextButton",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.86274516582489,0.86274516582489,0.86274516582489),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,10,0,30),Rotation=0,Selectable=true,Size=UDim2.new(0,40,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="Change",Parent = DexWindow40})
1655 local DexWindow44 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0,0.57647061347961,0.86274516582489),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,0,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="OnBar",Parent = DexWindow43})
1656 local DexWindow45 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0,0,0),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=true,Draggable=false,Position=UDim2.new(0,-2,0,-2),Rotation=0,Selectable=false,Size=UDim2.new(0,10,0,19),SizeConstraint=0,Visible=true,ZIndex=1,Name="Bar",Parent = DexWindow43})
1657 local DexWindow46 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,17),Rotation=0,Selectable=false,Size=UDim2.new(1,0,1,-17),SizeConstraint=0,Visible=true,ZIndex=1,Name="SettingList",Parent = DexWindow36})
1658 local DexWindow47 = CreateInstance("Frame",{Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=true,Position=UDim2.new(0.30000001192093,0,0.30000001192093,0),Rotation=0,Selectable=false,Size=UDim2.new(0,350,0,20),SizeConstraint=0,Visible=false,ZIndex=2,Name="SaveInstance",Parent = DexWindow})
1659 local DexWindow48 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Save Instance",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,1,0),SizeConstraint=0,Visible=true,ZIndex=2,Name="Title",Parent = DexWindow47})
1660 local DexWindow49 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.10000000149012,BorderColor3=Color3.new(0.74901962280273,0.74901962280273,0.74901962280273),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,200),SizeConstraint=0,Visible=true,ZIndex=1,Name="MainWindow",Parent = DexWindow47})
1661 local DexWindow50 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="Save",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.075000002980232,0,1,-40),Rotation=0,Selectable=true,Size=UDim2.new(0.40000000596046,0,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="Save",Parent = DexWindow49})
1662 local DexWindow51 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="This will save an instance to your PC. Type in the name for your instance. (.rbxmx will be added automatically.)",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=true,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,20),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,40),SizeConstraint=0,Visible=true,ZIndex=1,Name="Desc",Parent = DexWindow49})
1663 local DexWindow52 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="Cancel",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.52499997615814,0,1,-40),Rotation=0,Selectable=true,Size=UDim2.new(0.40000000596046,0,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="Cancel",Parent = DexWindow49})
1664 local DexWindow53 = CreateInstance("TextBox",{ClearTextOnFocus=true,Font=3,FontSize=6,MultiLine=false,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.20000000298023,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.075000002980232,0,0.40000000596046,0),Rotation=0,Selectable=true,Size=UDim2.new(0.85000002384186,0,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="FileName",Parent = DexWindow49})
1665 local DexWindow54 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="",TextColor3=Color3.new(1,1,1),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.60000002384186,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.075000002980232,0,0.625,0),Rotation=0,Selectable=true,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=2,Name="SaveObjects",Parent = DexWindow49})
1666 local DexWindow55 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.38039219379425,0.38039219379425,0.38039219379425),BackgroundTransparency=0.40000000596046,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,3,0,3),Rotation=0,Selectable=false,Size=UDim2.new(0,14,0,14),SizeConstraint=0,Visible=true,ZIndex=1,Name="enabled",Parent = DexWindow54})
1667 local DexWindow56 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Save \"Object\" type values",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.075000002980232,30,0.625,0),Rotation=0,Selectable=false,Size=UDim2.new(0.92500001192093,-30,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="Desc2",Parent = DexWindow49})
1668 local DexWindow57 = CreateInstance("Frame",{Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=true,Position=UDim2.new(0.30000001192093,0,0.34999999403954,0),Rotation=0,Selectable=false,Size=UDim2.new(0,350,0,20),SizeConstraint=0,Visible=false,ZIndex=3,Name="Confirmation",Parent = DexWindow})
1669 local DexWindow58 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Confirm",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,1,0),SizeConstraint=0,Visible=true,ZIndex=3,Name="Title",Parent = DexWindow57})
1670 local DexWindow59 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.10000000149012,BorderColor3=Color3.new(0.74901962280273,0.74901962280273,0.74901962280273),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,150),SizeConstraint=0,Visible=true,ZIndex=2,Name="MainWindow",Parent = DexWindow57})
1671 local DexWindow60 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="Yes",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.075000002980232,0,1,-40),Rotation=0,Selectable=true,Size=UDim2.new(0.40000000596046,0,0,30),SizeConstraint=0,Visible=true,ZIndex=2,Name="Yes",Parent = DexWindow59})
1672 local DexWindow61 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="The file, FILENAME, already exists. Overwrite?",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=true,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,20),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,40),SizeConstraint=0,Visible=true,ZIndex=2,Name="Desc",Parent = DexWindow59})
1673 local DexWindow62 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="No",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.52499997615814,0,1,-40),Rotation=0,Selectable=true,Size=UDim2.new(0.40000000596046,0,0,30),SizeConstraint=0,Visible=true,ZIndex=2,Name="No",Parent = DexWindow59})
1674 local DexWindow63 = CreateInstance("Frame",{Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=true,Position=UDim2.new(0.30000001192093,0,0.30000001192093,0),Rotation=0,Selectable=false,Size=UDim2.new(0,350,0,20),SizeConstraint=0,Visible=false,ZIndex=5,Name="Caution",Parent = DexWindow})
1675 local DexWindow64 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Caution",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,1,0),SizeConstraint=0,Visible=true,ZIndex=5,Name="Title",Parent = DexWindow63})
1676 local DexWindow65 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.10000000149012,BorderColor3=Color3.new(0.74901962280273,0.74901962280273,0.74901962280273),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,150),SizeConstraint=0,Visible=true,ZIndex=4,Name="MainWindow",Parent = DexWindow63})
1677 local DexWindow66 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="The file, FILENAME, already exists. Overwrite?",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=true,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,20),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,42),SizeConstraint=0,Visible=true,ZIndex=4,Name="Desc",Parent = DexWindow65})
1678 local DexWindow67 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="Ok",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.30000001192093,0,1,-40),Rotation=0,Selectable=true,Size=UDim2.new(0.40000000596046,0,0,30),SizeConstraint=0,Visible=true,ZIndex=4,Name="Ok",Parent = DexWindow65})
1679 local DexWindow68 = CreateInstance("Frame",{Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=true,Position=UDim2.new(0.30000001192093,0,0.30000001192093,0),Rotation=0,Selectable=false,Size=UDim2.new(0,350,0,20),SizeConstraint=0,Visible=false,ZIndex=2,Name="CallRemote",Parent = DexWindow})
1680 local DexWindow69 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Call Remote",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,1,0),SizeConstraint=0,Visible=true,ZIndex=2,Name="Title",Parent = DexWindow68})
1681 local DexWindow70 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.10000000149012,BorderColor3=Color3.new(0.74901962280273,0.74901962280273,0.74901962280273),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,200),SizeConstraint=0,Visible=true,ZIndex=1,Name="MainWindow",Parent = DexWindow68})
1682 local DexWindow71 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Arguments",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=true,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,20),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="Desc",Parent = DexWindow70})
1683 local DexWindow72 = CreateInstance("ScrollingFrame",{BottomImage="rbxasset://textures/blackBkg_square.png",CanvasPosition=Vector2.new(0,0),CanvasSize=UDim2.new(0,0,0,0),MidImage="rbxasset://textures/blackBkg_square.png",ScrollBarThickness=12,ScrollingEnabled=true,TopImage="rbxasset://textures/blackBkg_square.png",Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=true,Draggable=false,Position=UDim2.new(0,0,0,40),Rotation=0,Selectable=true,Size=UDim2.new(1,0,0,80),SizeConstraint=0,Visible=true,ZIndex=1,Name="Arguments",Parent = DexWindow70})
1684 local DexWindow73 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="",TextColor3=Color3.new(1,1,1),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.60000002384186,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.075000002980232,0,0.625,0),Rotation=0,Selectable=true,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=2,Name="DisplayReturned",Parent = DexWindow70})
1685 local DexWindow74 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.38039219379425,0.38039219379425,0.38039219379425),BackgroundTransparency=0.40000000596046,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,3,0,3),Rotation=0,Selectable=false,Size=UDim2.new(0,14,0,14),SizeConstraint=0,Visible=false,ZIndex=1,Name="enabled",Parent = DexWindow73})
1686 local DexWindow75 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Display values returned",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.075000002980232,30,0.625,0),Rotation=0,Selectable=false,Size=UDim2.new(0.92500001192093,-30,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="Desc2",Parent = DexWindow70})
1687 local DexWindow76 = CreateInstance("TextButton",{Font=4,FontSize=7,Text="+",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=24,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.80000001192093,0,0.625,0),Rotation=0,Selectable=true,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="Add",Parent = DexWindow70})
1688 local DexWindow77 = CreateInstance("TextButton",{Font=4,FontSize=7,Text="-",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=24,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.89999997615814,0,0.625,0),Rotation=0,Selectable=true,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="Subtract",Parent = DexWindow70})
1689 local DexWindow78 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0.74901962280273,0.74901962280273,0.74901962280273),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,20),SizeConstraint=0,Visible=false,ZIndex=1,Name="ArgumentTemplate",Parent = DexWindow70})
1690 local DexWindow79 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="Script",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.89999997615814,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=true,Size=UDim2.new(0.40000000596046,0,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="Type",Parent = DexWindow78})
1691 local DexWindow80 = CreateInstance("TextBox",{ClearTextOnFocus=true,Font=3,FontSize=5,MultiLine=false,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.89999997615814,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.40000000596046,0,0,0),Rotation=0,Selectable=true,Size=UDim2.new(0.60000002384186,-12,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="Value",Parent = DexWindow78})
1692 local DexWindow81 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="Cancel",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.52499997615814,0,1,-40),Rotation=0,Selectable=true,Size=UDim2.new(0.40000000596046,0,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="Cancel",Parent = DexWindow70})
1693 local DexWindow82 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="Call",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.075000002980232,0,1,-40),Rotation=0,Selectable=true,Size=UDim2.new(0.40000000596046,0,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="Ok",Parent = DexWindow70})
1694 local DexWindow83 = CreateInstance("Frame",{Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=true,Position=UDim2.new(0.30000001192093,0,0.30000001192093,0),Rotation=0,Selectable=false,Size=UDim2.new(0,350,0,20),SizeConstraint=0,Visible=false,ZIndex=2,Name="TableCaution",Parent = DexWindow})
1695 local DexWindow84 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.10000000149012,BorderColor3=Color3.new(0.74901962280273,0.74901962280273,0.74901962280273),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,150),SizeConstraint=0,Visible=true,ZIndex=1,Name="MainWindow",Parent = DexWindow83})
1696 local DexWindow85 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="Ok",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.30000001192093,0,1,-40),Rotation=0,Selectable=true,Size=UDim2.new(0.40000000596046,0,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="Ok",Parent = DexWindow84})
1697 local DexWindow86 = CreateInstance("ScrollingFrame",{BottomImage="rbxasset://textures/blackBkg_square.png",CanvasPosition=Vector2.new(0,0),CanvasSize=UDim2.new(0,0,0,0),MidImage="rbxasset://textures/blackBkg_square.png",ScrollBarThickness=12,ScrollingEnabled=true,TopImage="rbxasset://textures/blackBkg_square.png",Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=true,Draggable=false,Position=UDim2.new(0,0,0,20),Rotation=0,Selectable=true,Size=UDim2.new(1,0,0,80),SizeConstraint=0,Visible=true,ZIndex=1,Name="TableResults",Parent = DexWindow84})
1698 local DexWindow87 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0.74901962280273,0.74901962280273,0.74901962280273),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,20),SizeConstraint=0,Visible=false,ZIndex=1,Name="TableTemplate",Parent = DexWindow84})
1699 local DexWindow88 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="Script",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.89999997615814,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0.40000000596046,0,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="Type",Parent = DexWindow87})
1700 local DexWindow89 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Script",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.89999997615814,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.40000000596046,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0.60000002384186,-12,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="Value",Parent = DexWindow87})
1701 local DexWindow90 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Caution",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,1,0),SizeConstraint=0,Visible=true,ZIndex=2,Name="Title",Parent = DexWindow83})
1702 local DexWindow91 = CreateInstance("Frame",{Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=true,Position=UDim2.new(0.30000001192093,0,0.30000001192093,0),Rotation=0,Selectable=false,Size=UDim2.new(0,516,0,20),SizeConstraint=0,Visible=false,ZIndex=5,Name="ScriptEditor",Parent = DexWindow})
1703 local DexWindow92 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Script Viewer",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,1,0),SizeConstraint=0,Visible=true,ZIndex=5,Name="Title",Parent = DexWindow91})
1704 local DexWindow93 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,3,0),Rotation=0,Selectable=false,Size=UDim2.new(0,516,0,416),SizeConstraint=0,Visible=true,ZIndex=1,Name="Cover",Parent = DexWindow91})
1705 local DexWindow94 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,3,0),Rotation=0,Selectable=false,Size=UDim2.new(0,500,0,400),SizeConstraint=0,Visible=true,ZIndex=1,Name="EditorGrid",Parent = DexWindow91})
1706 local DexWindow95 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.94117653369904,0.94117653369904,0.94117653369904),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,3,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="TopBar",Parent = DexWindow91})
1707 local DexWindow96 = CreateInstance("ImageButton",{Image="",ImageColor3=Color3.new(1,1,1),ImageRectOffset=Vector2.new(0,0),ImageRectSize=Vector2.new(0,0),ImageTransparency=0,ScaleType=0,SliceCenter=Rect.new(0,0,0,0),AutoButtonColor=false,Modal=false,Selected=false,Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.8666667342186,0.8666667342186,0.8666667342186),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(1,-32,0,40),Rotation=0,Selectable=true,Size=UDim2.new(0,16,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="ScriptBarLeft",Parent = DexWindow95})
1708 local DexWindow97 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.5,-4,0.5,-4),Rotation=0,Selectable=false,Size=UDim2.new(0,8,0,8),SizeConstraint=0,Visible=true,ZIndex=1,Name="Arrow Graphic",Parent = DexWindow96})
1709 local DexWindow98 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BackgroundTransparency=0.69999998807907,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.25,0,0.375,0),Rotation=0,Selectable=false,Size=UDim2.new(0.125,0,0.25,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="Graphic",Parent = DexWindow97})
1710 local DexWindow99 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BackgroundTransparency=0.69999998807907,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.375,0,0.25,0),Rotation=0,Selectable=false,Size=UDim2.new(0.125,0,0.5,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="Graphic",Parent = DexWindow97})
1711 local DexWindow100 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BackgroundTransparency=0.69999998807907,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.5,0,0.125,0),Rotation=0,Selectable=false,Size=UDim2.new(0.125,0,0.75,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="Graphic",Parent = DexWindow97})
1712 local DexWindow101 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BackgroundTransparency=0.69999998807907,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.625,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0.125,0,1,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="Graphic",Parent = DexWindow97})
1713 local DexWindow102 = CreateInstance("ImageButton",{Image="",ImageColor3=Color3.new(1,1,1),ImageRectOffset=Vector2.new(0,0),ImageRectSize=Vector2.new(0,0),ImageTransparency=0,ScaleType=0,SliceCenter=Rect.new(0,0,0,0),AutoButtonColor=false,Modal=false,Selected=false,Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.8666667342186,0.8666667342186,0.8666667342186),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(1,-16,0,40),Rotation=0,Selectable=true,Size=UDim2.new(0,16,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="ScriptBarRight",Parent = DexWindow95})
1714 local DexWindow103 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.5,-4,0.5,-4),Rotation=0,Selectable=false,Size=UDim2.new(0,8,0,8),SizeConstraint=0,Visible=true,ZIndex=1,Name="Arrow Graphic",Parent = DexWindow102})
1715 local DexWindow104 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BackgroundTransparency=0.69999998807907,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.625,0,0.375,0),Rotation=0,Selectable=false,Size=UDim2.new(0.125,0,0.25,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="Graphic",Parent = DexWindow103})
1716 local DexWindow105 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BackgroundTransparency=0.69999998807907,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.5,0,0.25,0),Rotation=0,Selectable=false,Size=UDim2.new(0.125,0,0.5,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="Graphic",Parent = DexWindow103})
1717 local DexWindow106 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BackgroundTransparency=0.69999998807907,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.375,0,0.125,0),Rotation=0,Selectable=false,Size=UDim2.new(0.125,0,0.75,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="Graphic",Parent = DexWindow103})
1718 local DexWindow107 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BackgroundTransparency=0.69999998807907,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0.25,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0.125,0,1,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="Graphic",Parent = DexWindow103})
1719 local DexWindow108 = CreateInstance("TextButton",{Font=3,FontSize=5,Text="To Clipboard",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.5,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,20),Rotation=0,Selectable=true,Size=UDim2.new(0,80,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="Clipboard",Parent = DexWindow95})
1720 local DexWindow109 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.82352948188782,0.82352948188782,0.82352948188782),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=true,Draggable=false,Position=UDim2.new(0,0,0,40),Rotation=0,Selectable=false,Size=UDim2.new(1,-32,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="ScriptBar",Parent = DexWindow95})
1721 local DexWindow110 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,100,1,0),SizeConstraint=0,Visible=false,ZIndex=1,Name="Entry",Parent = DexWindow95})
1722 local DexWindow111 = CreateInstance("TextButton",{Font=3,FontSize=4,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=12,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.60000002384186,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=true,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=true,Size=UDim2.new(1,0,1,0),SizeConstraint=0,Visible=true,ZIndex=4,Name="Button",Parent = DexWindow110})
1723 local DexWindow112 = CreateInstance("TextButton",{Font=3,FontSize=5,Text="X",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(1,-20,0,0),Rotation=0,Selectable=true,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=4,Name="Close",Parent = DexWindow110})
1724 local DexWindow113 = CreateInstance("BindableEvent",{Name="OpenScript",Parent = DexWindow91})
1725 local DexWindow114 = CreateInstance("TextButton",{Font=3,FontSize=5,Text="X",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(1,-20,0,0),Rotation=0,Selectable=true,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=5,Name="Close",Parent = DexWindow91})
1726 local DexWindow115 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.96078437566757,0.96078437566757,0.96078437566757),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(1,30,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,300,1,0),SizeConstraint=0,Visible=true,ZIndex=2,Name="IntroFrame",Parent = DexWindow})
1727 local DexWindow116 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.96078437566757,0.96078437566757,0.96078437566757),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,-30,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,30,0,90),SizeConstraint=0,Visible=true,ZIndex=2,Name="Main",Parent = DexWindow115})
1728 local DexWindow117 = CreateInstance("TextLabel",{Font=4,FontSize=13,Text="DEX",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=60,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=true,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,100,0,150),Rotation=0,Selectable=false,Size=UDim2.new(0,100,0,60),SizeConstraint=0,Visible=true,ZIndex=2,Name="Title",Parent = DexWindow115})
1729 local DexWindow118 = CreateInstance("TextLabel",{Font=4,FontSize=10,Text="V1.0.0",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=28,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=true,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,100,0,210),Rotation=0,Selectable=false,Size=UDim2.new(0,100,0,30),SizeConstraint=0,Visible=true,ZIndex=2,Name="Version",Parent = DexWindow115})
1730 local DexWindow119 = CreateInstance("TextLabel",{Font=4,FontSize=10,Text="Raspberry Pi & Moon",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=28,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,80,0,300),Rotation=0,Selectable=true,Size=UDim2.new(0,140,0,50),SizeConstraint=0,Visible=true,ZIndex=2,Name="Creator",Parent = DexWindow115})
1731 local DexWindow120 = CreateInstance("ImageLabel",{Image="rbxassetid://474172996",ImageColor3=Color3.new(0.96078437566757,0.96078437566757,0.96078437566757),ImageRectOffset=Vector2.new(0,0),ImageRectSize=Vector2.new(0,0),ImageTransparency=0,ScaleType=0,SliceCenter=Rect.new(0,0,0,0),Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,-30,0,90),Rotation=180,Selectable=false,Size=UDim2.new(0,30,0,30),SizeConstraint=0,Visible=true,ZIndex=2,Name="Slant",Parent = DexWindow115})
1732 local DexWindow121 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.10000000149012,BorderColor3=Color3.new(0.74901962280273,0.74901962280273,0.74901962280273),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(1,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,300,1,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="SaveMapWindow",Parent = DexWindow})
1733 local DexWindow122 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,17),SizeConstraint=0,Visible=true,ZIndex=1,Name="Header",Parent = DexWindow121})
1734 local DexWindow123 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Map Downloader",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,4,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,-4,1,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="TextLabel",Parent = DexWindow122})
1735 local DexWindow124 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,200),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,240),SizeConstraint=0,Visible=true,ZIndex=1,Name="MapSettings",Parent = DexWindow121})
1736 local DexWindow125 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,60),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,60),SizeConstraint=0,Visible=true,ZIndex=1,Name="Terrain",Parent = DexWindow124})
1737 local DexWindow126 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="Save Terrain",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,10,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,-20,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="SName",Parent = DexWindow125})
1738 local DexWindow127 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="Off",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,60,0,30),Rotation=0,Selectable=false,Size=UDim2.new(0,50,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="Status",Parent = DexWindow125})
1739 local DexWindow128 = CreateInstance("TextButton",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.86274516582489,0.86274516582489,0.86274516582489),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,10,0,30),Rotation=0,Selectable=true,Size=UDim2.new(0,40,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="Change",Parent = DexWindow125})
1740 local DexWindow129 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0,0.57647061347961,0.86274516582489),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,0,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="OnBar",Parent = DexWindow128})
1741 local DexWindow130 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0,0,0),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=true,Draggable=false,Position=UDim2.new(0,-2,0,-2),Rotation=0,Selectable=false,Size=UDim2.new(0,10,0,19),SizeConstraint=0,Visible=true,ZIndex=1,Name="Bar",Parent = DexWindow128})
1742 local DexWindow131 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,120),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,60),SizeConstraint=0,Visible=true,ZIndex=1,Name="Lighting",Parent = DexWindow124})
1743 local DexWindow132 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="Lighting Properties",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,10,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,-20,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="SName",Parent = DexWindow131})
1744 local DexWindow133 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="Off",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,60,0,30),Rotation=0,Selectable=false,Size=UDim2.new(0,50,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="Status",Parent = DexWindow131})
1745 local DexWindow134 = CreateInstance("TextButton",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.86274516582489,0.86274516582489,0.86274516582489),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,10,0,30),Rotation=0,Selectable=true,Size=UDim2.new(0,40,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="Change",Parent = DexWindow131})
1746 local DexWindow135 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0,0.57647061347961,0.86274516582489),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,0,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="OnBar",Parent = DexWindow134})
1747 local DexWindow136 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0,0,0),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=true,Draggable=false,Position=UDim2.new(0,-2,0,-2),Rotation=0,Selectable=false,Size=UDim2.new(0,10,0,19),SizeConstraint=0,Visible=true,ZIndex=1,Name="Bar",Parent = DexWindow134})
1748 local DexWindow137 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,180),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,60),SizeConstraint=0,Visible=true,ZIndex=1,Name="CameraInstances",Parent = DexWindow124})
1749 local DexWindow138 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="Camera Instances",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,10,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,-20,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="SName",Parent = DexWindow137})
1750 local DexWindow139 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="Off",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,60,0,30),Rotation=0,Selectable=false,Size=UDim2.new(0,50,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="Status",Parent = DexWindow137})
1751 local DexWindow140 = CreateInstance("TextButton",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.86274516582489,0.86274516582489,0.86274516582489),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,10,0,30),Rotation=0,Selectable=true,Size=UDim2.new(0,40,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="Change",Parent = DexWindow137})
1752 local DexWindow141 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0,0.57647061347961,0.86274516582489),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,0,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="OnBar",Parent = DexWindow140})
1753 local DexWindow142 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0,0,0),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=true,Draggable=false,Position=UDim2.new(0,-2,0,-2),Rotation=0,Selectable=false,Size=UDim2.new(0,10,0,19),SizeConstraint=0,Visible=true,ZIndex=1,Name="Bar",Parent = DexWindow140})
1754 local DexWindow143 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,60),SizeConstraint=0,Visible=true,ZIndex=1,Name="Scripts",Parent = DexWindow124})
1755 local DexWindow144 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="Save Scripts",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,10,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,-20,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="SName",Parent = DexWindow143})
1756 local DexWindow145 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="Off",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,60,0,30),Rotation=0,Selectable=false,Size=UDim2.new(0,50,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="Status",Parent = DexWindow143})
1757 local DexWindow146 = CreateInstance("TextButton",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.86274516582489,0.86274516582489,0.86274516582489),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,10,0,30),Rotation=0,Selectable=true,Size=UDim2.new(0,40,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="Change",Parent = DexWindow143})
1758 local DexWindow147 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0,0.57647061347961,0.86274516582489),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,0,0,15),SizeConstraint=0,Visible=true,ZIndex=1,Name="OnBar",Parent = DexWindow146})
1759 local DexWindow148 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0,0,0),BackgroundTransparency=0,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=true,Draggable=false,Position=UDim2.new(0,-2,0,-2),Rotation=0,Selectable=false,Size=UDim2.new(0,10,0,19),SizeConstraint=0,Visible=true,ZIndex=1,Name="Bar",Parent = DexWindow146})
1760 local DexWindow149 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="To Save",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,17),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,20),SizeConstraint=0,Visible=true,ZIndex=1,Name="ToSave",Parent = DexWindow121})
1761 local DexWindow150 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.80000001192093,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,37),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,163),SizeConstraint=0,Visible=true,ZIndex=1,Name="CopyList",Parent = DexWindow121})
1762 local DexWindow151 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,1,-50),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,50),SizeConstraint=0,Visible=true,ZIndex=1,Name="Bottom",Parent = DexWindow121})
1763 local DexWindow152 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="After the map saves, open a new place on studio, then right click Lighting and \"Insert from file...\", then select your file and run the unpacker script inside the folder.",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=true,TextXAlignment=0,TextYAlignment=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,4,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,-4,1,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="TextLabel",Parent = DexWindow151})
1764 local DexWindow153 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="Save",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.94117653369904,0.94117653369904,0.94117653369904),BackgroundTransparency=0.80000001192093,BorderColor3=Color3.new(0,0,0),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,1,-80),Rotation=0,Selectable=true,Size=UDim2.new(1,0,0,30),SizeConstraint=0,Visible=true,ZIndex=1,Name="Save",Parent = DexWindow121})
1765 local DexWindow154 = CreateInstance("TextBox",{ClearTextOnFocus=true,Font=3,FontSize=6,MultiLine=false,Text="PlaceName",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.94117653369904,0.94117653369904,0.94117653369904),BackgroundTransparency=0.60000002384186,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,1,-105),Rotation=0,Selectable=true,Size=UDim2.new(1,0,0,25),SizeConstraint=0,Visible=true,ZIndex=1,Name="FileName",Parent = DexWindow121})
1766 local DexWindow155 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,22),SizeConstraint=0,Visible=false,ZIndex=1,Name="Entry",Parent = DexWindow121})
1767 local DexWindow156 = CreateInstance("TextButton",{Font=3,FontSize=6,Text="",TextColor3=Color3.new(1,1,1),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,AutoButtonColor=true,Modal=false,Selected=false,Style=0,Active=true,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.60000002384186,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,10,0,1),Rotation=0,Selectable=true,Size=UDim2.new(0,20,0,20),SizeConstraint=0,Visible=true,ZIndex=2,Name="Change",Parent = DexWindow155})
1768 local DexWindow157 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.38039219379425,0.38039219379425,0.38039219379425),BackgroundTransparency=0.40000000596046,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=0,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,3,0,3),Rotation=0,Selectable=false,Size=UDim2.new(0,14,0,14),SizeConstraint=0,Visible=true,ZIndex=1,Name="enabled",Parent = DexWindow156})
1769 local DexWindow158 = CreateInstance("TextLabel",{Font=3,FontSize=6,Text="Workspace",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=18,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,40,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,-40,0,22),SizeConstraint=0,Visible=true,ZIndex=1,Name="Info",Parent = DexWindow155})
1770 local DexWindow159 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=0.10000000149012,BorderColor3=Color3.new(0.74901962280273,0.74901962280273,0.74901962280273),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(1,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(0,300,1,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="RemoteDebugWindow",Parent = DexWindow})
1771 local DexWindow160 = CreateInstance("Frame",{Style=0,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.91372555494308,0.91372555494308,0.91372555494308),BackgroundTransparency=0,BorderColor3=Color3.new(0.58431375026703,0.58431375026703,0.58431375026703),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,17),SizeConstraint=0,Visible=true,ZIndex=1,Name="Header",Parent = DexWindow159})
1772 local DexWindow161 = CreateInstance("TextLabel",{Font=3,FontSize=5,Text="Remote Debugger",TextColor3=Color3.new(0,0,0),TextScaled=false,TextSize=14,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=false,TextXAlignment=0,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(0.63921570777893,0.63529413938522,0.64705884456635),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,4,0,0),Rotation=0,Selectable=false,Size=UDim2.new(1,-4,1,0),SizeConstraint=0,Visible=true,ZIndex=1,Name="TextLabel",Parent = DexWindow160})
1773 local DexWindow162 = CreateInstance("BindableFunction",{Name="GetSetting",Parent = DexWindow159})
1774 local DexWindow163 = CreateInstance("TextLabel",{Font=3,FontSize=11,Text="Have fun with remotes",TextColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),TextScaled=false,TextSize=32,TextStrokeColor3=Color3.new(0,0,0),TextStrokeTransparency=1,TextTransparency=0,TextWrapped=true,TextXAlignment=2,TextYAlignment=1,Active=false,AnchorPoint=Vector2.new(0,0),BackgroundColor3=Color3.new(1,1,1),BackgroundTransparency=1,BorderColor3=Color3.new(0.10588236153126,0.16470588743687,0.20784315466881),BorderSizePixel=1,ClipsDescendants=false,Draggable=false,Position=UDim2.new(0,0,0,20),Rotation=0,Selectable=false,Size=UDim2.new(1,0,0,40),SizeConstraint=0,Visible=true,ZIndex=1,Name="Desc",Parent = DexWindow159})
1775 return DexWindow
1776end
1777
1778function placeGui()
1779 if pcall(function() local d = game:GetService("CoreGui").Name end) then
1780 return game:GetService("CoreGui")
1781 else
1782 return game:GetService("Players").LocalPlayer:FindFirstChildOfClass("PlayerGui")
1783 end
1784end
1785
1786local D_E_X = createDexWindow()
1787D_E_X.ResetOnSpawn = false
1788D_E_X.Parent = placeGui()
1789
1790spawn(function()
1791 local Gui = D_E_X
1792
1793local IntroFrame = Gui:WaitForChild("IntroFrame")
1794
1795local SideMenu = Gui:WaitForChild("SideMenu")
1796local OpenToggleButton = Gui:WaitForChild("Toggle")
1797local CloseToggleButton = SideMenu:WaitForChild("Toggle")
1798local OpenScriptEditorButton = SideMenu:WaitForChild("OpenScriptEditor")
1799
1800local ScriptEditor = Gui:WaitForChild("ScriptEditor")
1801
1802local SlideOut = SideMenu:WaitForChild("SlideOut")
1803local SlideFrame = SlideOut:WaitForChild("SlideFrame")
1804local Slant = SideMenu:WaitForChild("Slant")
1805
1806local ExplorerButton = SlideFrame:WaitForChild("Explorer")
1807local SettingsButton = SlideFrame:WaitForChild("Settings")
1808
1809local SelectionBox = Instance.new("SelectionBox")
1810SelectionBox.Parent = Gui
1811
1812local ExplorerPanel = Gui:WaitForChild("ExplorerPanel")
1813local PropertiesFrame = Gui:WaitForChild("PropertiesFrame")
1814local SaveMapWindow = Gui:WaitForChild("SaveMapWindow")
1815local RemoteDebugWindow = Gui:WaitForChild("RemoteDebugWindow")
1816
1817local SettingsPanel = Gui:WaitForChild("SettingsPanel")
1818local SettingsListener = SettingsPanel:WaitForChild("GetSetting")
1819local SettingTemplate = SettingsPanel:WaitForChild("SettingTemplate")
1820local SettingList = SettingsPanel:WaitForChild("SettingList")
1821
1822local SaveMapCopyList = SaveMapWindow:WaitForChild("CopyList")
1823local SaveMapSettingFrame = SaveMapWindow:WaitForChild("MapSettings")
1824local SaveMapName = SaveMapWindow:WaitForChild("FileName")
1825local SaveMapButton = SaveMapWindow:WaitForChild("Save")
1826local SaveMapCopyTemplate = SaveMapWindow:WaitForChild("Entry")
1827local SaveMapSettings = {
1828 CopyWhat = {
1829 Workspace = true,
1830 Lighting = true,
1831 ReplicatedStorage = true,
1832 ReplicatedFirst = true,
1833 StarterPack = true,
1834 StarterGui = true,
1835 StarterPlayer = true
1836 },
1837 SaveScripts = true,
1838 SaveTerrain = true,
1839 LightingProperties = true,
1840 CameraInstances = true
1841}
1842
1843--[[
1844local ClickSelectOption = SettingsPanel:WaitForChild("ClickSelect"):WaitForChild("Change")
1845local SelectionBoxOption = SettingsPanel:WaitForChild("SelectionBox"):WaitForChild("Change")
1846local ClearPropsOption = SettingsPanel:WaitForChild("ClearProperties"):WaitForChild("Change")
1847local SelectUngroupedOption = SettingsPanel:WaitForChild("SelectUngrouped"):WaitForChild("Change")
1848--]]
1849
1850local SelectionChanged = ExplorerPanel:WaitForChild("SelectionChanged")
1851local GetSelection = ExplorerPanel:WaitForChild("GetSelection")
1852local SetSelection = ExplorerPanel:WaitForChild("SetSelection")
1853
1854local Player = game:GetService("Players").LocalPlayer
1855local Mouse = Player:GetMouse()
1856
1857local CurrentWindow = "Nothing c:"
1858local Windows = {
1859 Explorer = {
1860 ExplorerPanel,
1861 PropertiesFrame
1862 },
1863 Settings = {SettingsPanel},
1864 SaveMap = {SaveMapWindow},
1865 Remotes = {RemoteDebugWindow}
1866}
1867
1868function switchWindows(wName,over)
1869 if CurrentWindow == wName and not over then return end
1870
1871 local count = 0
1872
1873 for i,v in pairs(Windows) do
1874 count = 0
1875 if i ~= wName then
1876 for _,c in pairs(v) do c:TweenPosition(UDim2.new(1, 30, count * 0.5, count * 36), "Out", "Quad", 0.5, true) count = count + 1 end
1877 end
1878 end
1879
1880 count = 0
1881
1882 if Windows[wName] then
1883 for _,c in pairs(Windows[wName]) do c:TweenPosition(UDim2.new(1, -300, count * 0.5, count * 36), "Out", "Quad", 0.5, true) count = count + 1 end
1884 end
1885
1886 if wName ~= "Nothing c:" then
1887 CurrentWindow = wName
1888 for i,v in pairs(SlideFrame:GetChildren()) do
1889 v.BackgroundTransparency = 1
1890 v.Icon.ImageColor3 = Color3.new(70/255, 70/255, 70/255)
1891 end
1892 if SlideFrame:FindFirstChild(wName) then
1893 SlideFrame[wName].BackgroundTransparency = 0.5
1894 SlideFrame[wName].Icon.ImageColor3 = Color3.new(0,0,0)
1895 end
1896 end
1897end
1898
1899function toggleDex(on)
1900 if on then
1901 SideMenu:TweenPosition(UDim2.new(1, -330, 0, 0), "Out", "Quad", 0.5, true)
1902 OpenToggleButton:TweenPosition(UDim2.new(1,0,0,0), "Out", "Quad", 0.5, true)
1903 switchWindows(CurrentWindow,true)
1904 else
1905 SideMenu:TweenPosition(UDim2.new(1, 0, 0, 0), "Out", "Quad", 0.5, true)
1906 OpenToggleButton:TweenPosition(UDim2.new(1,-30,0,0), "Out", "Quad", 0.5, true)
1907 switchWindows("Nothing c:")
1908 end
1909end
1910
1911local Settings = {
1912 ClickSelect = false,
1913 SelBox = false,
1914 ClearProps = false,
1915 SelectUngrouped = true,
1916 SaveInstanceScripts = true
1917}
1918
1919function ReturnSetting(set)
1920 if set == "ClearProps" then
1921 return Settings.ClearProps
1922 elseif set == "SelectUngrouped" then
1923 return Settings.SelectUngrouped
1924 end
1925end
1926
1927OpenToggleButton.MouseButton1Up:connect(function()
1928 toggleDex(true)
1929end)
1930
1931OpenScriptEditorButton.MouseButton1Up:connect(function()
1932 if OpenScriptEditorButton.Active then
1933 ScriptEditor.Visible = true
1934 end
1935end)
1936
1937CloseToggleButton.MouseButton1Up:connect(function()
1938 if CloseToggleButton.Active then
1939 toggleDex(false)
1940 end
1941end)
1942
1943--[[
1944OpenToggleButton.MouseButton1Up:connect(function()
1945 SideMenu:TweenPosition(UDim2.new(1, -330, 0, 0), "Out", "Quad", 0.5, true)
1946
1947 if CurrentWindow == "Explorer" then
1948 ExplorerPanel:TweenPosition(UDim2.new(1, -300, 0, 0), "Out", "Quad", 0.5, true)
1949 PropertiesFrame:TweenPosition(UDim2.new(1, -300, 0.5, 36), "Out", "Quad", 0.5, true)
1950 else
1951 SettingsPanel:TweenPosition(UDim2.new(1, -300, 0, 0), "Out", "Quad", 0.5, true)
1952 end
1953
1954 OpenToggleButton:TweenPosition(UDim2.new(1,0,0,0), "Out", "Quad", 0.5, true)
1955end)
1956
1957CloseToggleButton.MouseButton1Up:connect(function()
1958 SideMenu:TweenPosition(UDim2.new(1, 0, 0, 0), "Out", "Quad", 0.5, true)
1959
1960 ExplorerPanel:TweenPosition(UDim2.new(1, 30, 0, 0), "Out", "Quad", 0.5, true)
1961 PropertiesFrame:TweenPosition(UDim2.new(1, 30, 0.5, 36), "Out", "Quad", 0.5, true)
1962 SettingsPanel:TweenPosition(UDim2.new(1, 30, 0, 0), "Out", "Quad", 0.5, true)
1963
1964 OpenToggleButton:TweenPosition(UDim2.new(1,-30,0,0), "Out", "Quad", 0.5, true)
1965end)
1966--]]
1967
1968--[[
1969ExplorerButton.MouseButton1Up:connect(function()
1970 switchWindows("Explorer")
1971end)
1972
1973SettingsButton.MouseButton1Up:connect(function()
1974 switchWindows("Settings")
1975end)
1976--]]
1977
1978for i,v in pairs(SlideFrame:GetChildren()) do
1979 v.MouseButton1Click:connect(function()
1980 switchWindows(v.Name)
1981 end)
1982
1983 v.MouseEnter:connect(function()v.BackgroundTransparency = 0.5 end)
1984 v.MouseLeave:connect(function()if CurrentWindow~=v.Name then v.BackgroundTransparency = 1 end end)
1985end
1986
1987--[[
1988ExplorerButton.MouseButton1Up:connect(function()
1989 if CurrentWindow ~= "Explorer" then
1990 CurrentWindow = "Explorer"
1991
1992 ExplorerPanel:TweenPosition(UDim2.new(1, -300, 0, 0), "Out", "Quad", 0.5, true)
1993 PropertiesFrame:TweenPosition(UDim2.new(1, -300, 0.5, 36), "Out", "Quad", 0.5, true)
1994 SettingsPanel:TweenPosition(UDim2.new(1, 0, 0, 0), "Out", "Quad", 0.5, true)
1995 end
1996end)
1997
1998SettingsButton.MouseButton1Up:connect(function()
1999 if CurrentWindow ~= "Settings" then
2000 CurrentWindow = "Settings"
2001
2002 ExplorerPanel:TweenPosition(UDim2.new(1, 0, 0, 0), "Out", "Quad", 0.5, true)
2003 PropertiesFrame:TweenPosition(UDim2.new(1, 0, 0.5, 36), "Out", "Quad", 0.5, true)
2004 SettingsPanel:TweenPosition(UDim2.new(1, -300, 0, 0), "Out", "Quad", 0.5, true)
2005 end
2006end)
2007--]]
2008
2009function createSetting(name,interName,defaultOn)
2010 local newSetting = SettingTemplate:Clone()
2011 newSetting.Position = UDim2.new(0,0,0,#SettingList:GetChildren() * 60)
2012 newSetting.SName.Text = name
2013
2014 local function toggle(on)
2015 if on then
2016 newSetting.Change.Bar:TweenPosition(UDim2.new(0,32,0,-2),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.25,true)
2017 newSetting.Change.OnBar:TweenSize(UDim2.new(0,34,0,15),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.25,true)
2018 newSetting.Status.Text = "On"
2019 Settings[interName] = true
2020 else
2021 newSetting.Change.Bar:TweenPosition(UDim2.new(0,-2,0,-2),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.25,true)
2022 newSetting.Change.OnBar:TweenSize(UDim2.new(0,0,0,15),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.25,true)
2023 newSetting.Status.Text = "Off"
2024 Settings[interName] = false
2025 end
2026 end
2027
2028 newSetting.Change.MouseButton1Click:connect(function()
2029 toggle(not Settings[interName])
2030 end)
2031
2032 newSetting.Visible = true
2033 newSetting.Parent = SettingList
2034
2035 if defaultOn then
2036 toggle(true)
2037 end
2038end
2039
2040createSetting("Click part to select","ClickSelect",false)
2041createSetting("Selection Box","SelBox",false)
2042createSetting("Clear property value on focus","ClearProps",false)
2043createSetting("Select ungrouped models","SelectUngrouped",true)
2044createSetting("SaveInstance decompiles scripts","SaveInstanceScripts",true)
2045
2046--[[
2047ClickSelectOption.MouseButton1Up:connect(function()
2048 if Settings.ClickSelect then
2049 Settings.ClickSelect = false
2050 ClickSelectOption.Text = "OFF"
2051 else
2052 Settings.ClickSelect = true
2053 ClickSelectOption.Text = "ON"
2054 end
2055end)
2056
2057SelectionBoxOption.MouseButton1Up:connect(function()
2058 if Settings.SelBox then
2059 Settings.SelBox = false
2060 SelectionBox.Adornee = nil
2061 SelectionBoxOption.Text = "OFF"
2062 else
2063 Settings.SelBox = true
2064 SelectionBoxOption.Text = "ON"
2065 end
2066end)
2067
2068ClearPropsOption.MouseButton1Up:connect(function()
2069 if Settings.ClearProps then
2070 Settings.ClearProps = false
2071 ClearPropsOption.Text = "OFF"
2072 else
2073 Settings.ClearProps = true
2074 ClearPropsOption.Text = "ON"
2075 end
2076end)
2077
2078SelectUngroupedOption.MouseButton1Up:connect(function()
2079 if Settings.SelectUngrouped then
2080 Settings.SelectUngrouped = false
2081 SelectUngroupedOption.Text = "OFF"
2082 else
2083 Settings.SelectUngrouped = true
2084 SelectUngroupedOption.Text = "ON"
2085 end
2086end)
2087--]]
2088
2089local function getSelection()
2090 local t = GetSelection:Invoke()
2091 if t and #t > 0 then
2092 return t[1]
2093 else
2094 return nil
2095 end
2096end
2097
2098Mouse.Button1Down:connect(function()
2099 if CurrentWindow == "Explorer" and Settings.ClickSelect then
2100 local target = Mouse.Target
2101 if target then
2102 SetSelection:Invoke({target})
2103 end
2104 end
2105end)
2106
2107SelectionChanged.Event:connect(function()
2108 if Settings.SelBox then
2109 local success = pcall(function()
2110 local selection = getSelection()
2111 SelectionBox.Adornee = selection
2112 end)
2113 if not success then
2114 SelectionBox.Adornee = nil
2115 end
2116 end
2117end)
2118
2119SettingsListener.OnInvoke = ReturnSetting
2120
2121-- Map Copier
2122
2123function createMapSetting(obj,interName,defaultOn)
2124 local function toggle(on)
2125 if on then
2126 obj.Change.Bar:TweenPosition(UDim2.new(0,32,0,-2),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.25,true)
2127 obj.Change.OnBar:TweenSize(UDim2.new(0,34,0,15),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.25,true)
2128 obj.Status.Text = "On"
2129 SaveMapSettings[interName] = true
2130 else
2131 obj.Change.Bar:TweenPosition(UDim2.new(0,-2,0,-2),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.25,true)
2132 obj.Change.OnBar:TweenSize(UDim2.new(0,0,0,15),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.25,true)
2133 obj.Status.Text = "Off"
2134 SaveMapSettings[interName] = false
2135 end
2136 end
2137
2138 obj.Change.MouseButton1Click:connect(function()
2139 toggle(not SaveMapSettings[interName])
2140 end)
2141
2142 obj.Visible = true
2143 obj.Parent = SaveMapSettingFrame
2144
2145 if defaultOn then
2146 toggle(true)
2147 end
2148end
2149
2150function createCopyWhatSetting(serv)
2151 if SaveMapSettings.CopyWhat[serv] then
2152 local newSetting = SaveMapCopyTemplate:Clone()
2153 newSetting.Position = UDim2.new(0,0,0,#SaveMapCopyList:GetChildren() * 22 + 5)
2154 newSetting.Info.Text = serv
2155
2156 local function toggle(on)
2157 if on then
2158 newSetting.Change.enabled.Visible = true
2159 SaveMapSettings.CopyWhat[serv] = true
2160 else
2161 newSetting.Change.enabled.Visible = false
2162 SaveMapSettings.CopyWhat[serv] = false
2163 end
2164 end
2165
2166 newSetting.Change.MouseButton1Click:connect(function()
2167 toggle(not SaveMapSettings.CopyWhat[serv])
2168 end)
2169
2170 newSetting.Visible = true
2171 newSetting.Parent = SaveMapCopyList
2172 end
2173end
2174
2175createMapSetting(SaveMapSettingFrame.Scripts,"SaveScripts",true)
2176createMapSetting(SaveMapSettingFrame.Terrain,"SaveTerrain",true)
2177createMapSetting(SaveMapSettingFrame.Lighting,"LightingProperties",true)
2178createMapSetting(SaveMapSettingFrame.CameraInstances,"CameraInstances",true)
2179
2180createCopyWhatSetting("Workspace")
2181createCopyWhatSetting("Lighting")
2182createCopyWhatSetting("ReplicatedStorage")
2183createCopyWhatSetting("ReplicatedFirst")
2184createCopyWhatSetting("StarterPack")
2185createCopyWhatSetting("StarterGui")
2186createCopyWhatSetting("StarterPlayer")
2187
2188SaveMapName.Text = tostring(game.PlaceId).."MapCopy"
2189
2190SaveMapButton.MouseButton1Click:connect(function()
2191 local copyWhat = {}
2192
2193 local copyGroup = Instance.new("Model",game.ReplicatedStorage)
2194
2195 local copyScripts = SaveMapSettings.SaveScripts
2196
2197 local copyTerrain = SaveMapSettings.SaveTerrain
2198
2199 local lightingProperties = SaveMapSettings.LightingProperties
2200
2201 local cameraInstances = SaveMapSettings.CameraInstances
2202
2203 -----------------------------------------------------------------------------------
2204
2205 for i,v in pairs(SaveMapSettings.CopyWhat) do
2206 if v then
2207 table.insert(copyWhat,i)
2208 end
2209 end
2210
2211 local consoleFunc = printconsole or writeconsole
2212
2213 if consoleFunc then
2214 consoleFunc("Raspberry Pi's place copier loaded.")
2215 consoleFunc("Copying map of game "..tostring(game.PlaceId)..".")
2216 end
2217
2218 function archivable(root)
2219 for i,v in pairs(root:GetChildren()) do
2220 if not game.Players:GetPlayerFromCharacter(v) then
2221 v.Archivable = true
2222 archivable(v)
2223 end
2224 end
2225 end
2226
2227 function decompileS(root)
2228 for i,v in pairs(root:GetChildren()) do
2229 pcall(function()
2230 if v:IsA("LocalScript") then
2231 local isDisabled = v.Disabled
2232 v.Disabled = true
2233 v.Source = decompile(v)
2234 v.Disabled = isDisabled
2235
2236 if v.Source == "" then
2237 if consoleFunc then consoleFunc("LocalScript "..v.Name.." had a problem decompiling.") end
2238 else
2239 if consoleFunc then consoleFunc("LocalScript "..v.Name.." decompiled.") end
2240 end
2241 elseif v:IsA("ModuleScript") then
2242 v.Source = decompile(v)
2243
2244 if v.Source == "" then
2245 if consoleFunc then consoleFunc("ModuleScript "..v.Name.." had a problem decompiling.") end
2246 else
2247 if consoleFunc then consoleFunc("ModuleScript "..v.Name.." decompiled.") end
2248 end
2249 end
2250 end)
2251 decompileS(v)
2252 end
2253 end
2254
2255 for i,v in pairs(copyWhat) do archivable(game[v]) end
2256
2257 for j,obj in pairs(copyWhat) do
2258 if obj ~= "StarterPlayer" then
2259 local newFolder = Instance.new("Folder",copyGroup)
2260 newFolder.Name = obj
2261 for i,v in pairs(game[obj]:GetChildren()) do
2262 if v ~= copyGroup then
2263 pcall(function()
2264 v:Clone().Parent = newFolder
2265 end)
2266 end
2267 end
2268 else
2269 local newFolder = Instance.new("Model",copyGroup)
2270 newFolder.Name = "StarterPlayer"
2271 for i,v in pairs(game[obj]:GetChildren()) do
2272 local newObj = Instance.new("Folder",newFolder)
2273 newObj.Name = v.Name
2274 for _,c in pairs(v:GetChildren()) do
2275 if c.Name ~= "ControlScript" and c.Name ~= "CameraScript" then
2276 c:Clone().Parent = newObj
2277 end
2278 end
2279 end
2280 end
2281 end
2282
2283 if workspace.CurrentCamera and cameraInstances then
2284 local cameraFolder = Instance.new("Model",copyGroup)
2285 cameraFolder.Name = "CameraItems"
2286 for i,v in pairs(workspace.CurrentCamera:GetChildren()) do v:Clone().Parent = cameraFolder end
2287 end
2288
2289 if copyTerrain then
2290 local myTerrain = workspace.Terrain:CopyRegion(workspace.Terrain.MaxExtents)
2291 myTerrain.Parent = copyGroup
2292 end
2293
2294 function saveProp(obj,prop,par)
2295 local myProp = obj[prop]
2296 if type(myProp) == "boolean" then
2297 local newProp = Instance.new("BoolValue",par)
2298 newProp.Name = prop
2299 newProp.Value = myProp
2300 elseif type(myProp) == "number" then
2301 local newProp = Instance.new("IntValue",par)
2302 newProp.Name = prop
2303 newProp.Value = myProp
2304 elseif type(myProp) == "string" then
2305 local newProp = Instance.new("StringValue",par)
2306 newProp.Name = prop
2307 newProp.Value = myProp
2308 elseif type(myProp) == "userdata" then -- Assume Color3
2309 pcall(function()
2310 local newProp = Instance.new("Color3Value",par)
2311 newProp.Name = prop
2312 newProp.Value = myProp
2313 end)
2314 end
2315 end
2316
2317 if lightingProperties then
2318 local lightingProps = Instance.new("Model",copyGroup)
2319 lightingProps.Name = "LightingProperties"
2320
2321 saveProp(game.Lighting,"Ambient",lightingProps)
2322 saveProp(game.Lighting,"Brightness",lightingProps)
2323 saveProp(game.Lighting,"ColorShift_Bottom",lightingProps)
2324 saveProp(game.Lighting,"ColorShift_Top",lightingProps)
2325 saveProp(game.Lighting,"GlobalShadows",lightingProps)
2326 saveProp(game.Lighting,"OutdoorAmbient",lightingProps)
2327 saveProp(game.Lighting,"Outlines",lightingProps)
2328 saveProp(game.Lighting,"GeographicLatitude",lightingProps)
2329 saveProp(game.Lighting,"TimeOfDay",lightingProps)
2330 saveProp(game.Lighting,"FogColor",lightingProps)
2331 saveProp(game.Lighting,"FogEnd",lightingProps)
2332 saveProp(game.Lighting,"FogStart",lightingProps)
2333 end
2334
2335 if decompile and copyScripts then
2336 decompileS(copyGroup)
2337 end
2338
2339 if SaveInstance then
2340 SaveInstance(copyGroup,SaveMapName.Text..".rbxm")
2341 elseif saveinstance then
2342 saveinstance(getelysianpath()..SaveMapName.Text..".rbxm",copyGroup)
2343 end
2344 --print("Saved!")
2345 if consoleFunc then
2346 consoleFunc("The map has been copied.")
2347 end
2348 SaveMapButton.Text = "The map has been saved"
2349 wait(5)
2350 SaveMapButton.Text = "Save"
2351end)
2352
2353-- End Copier
2354
2355wait()
2356
2357IntroFrame:TweenPosition(UDim2.new(1,-300,0,0),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.5,true)
2358
2359switchWindows("Explorer")
2360
2361wait(1)
2362
2363SideMenu.Visible = true
2364
2365for i = 0,1,0.1 do
2366 IntroFrame.BackgroundTransparency = i
2367 IntroFrame.Main.BackgroundTransparency = i
2368 IntroFrame.Slant.ImageTransparency = i
2369 IntroFrame.Title.TextTransparency = i
2370 IntroFrame.Version.TextTransparency = i
2371 IntroFrame.Creator.TextTransparency = i
2372 wait()
2373end
2374
2375IntroFrame.Visible = false
2376
2377SlideFrame:TweenPosition(UDim2.new(0,0,0,0),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.5,true)
2378OpenScriptEditorButton:TweenPosition(UDim2.new(0,0,0,180),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.5,true)
2379CloseToggleButton:TweenPosition(UDim2.new(0,0,0,210),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.5,true)
2380Slant:TweenPosition(UDim2.new(0,0,0,240),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.5,true)
2381
2382wait(0.5)
2383
2384for i = 1,0,-0.1 do
2385 OpenScriptEditorButton.Icon.ImageTransparency = i
2386 CloseToggleButton.TextTransparency = i
2387 wait()
2388end
2389
2390CloseToggleButton.Active = true
2391CloseToggleButton.AutoButtonColor = true
2392
2393OpenScriptEditorButton.Active = true
2394OpenScriptEditorButton.AutoButtonColor = true
2395end)
2396
2397spawn(function()
2398 -- initial states
2399local Option = {
2400 -- can modify object parents in the hierarchy
2401 Modifiable = false;
2402 -- can select objects
2403 Selectable = true;
2404}
2405
2406-- MERELY
2407
2408Option.Modifiable = true
2409
2410-- END MERELY
2411
2412-- general size of GUI objects, in pixels
2413local GUI_SIZE = 16
2414-- padding between items within each entry
2415local ENTRY_PADDING = 1
2416-- padding between each entry
2417local ENTRY_MARGIN = 1
2418
2419local Input = game:GetService("UserInputService")
2420local HoldingCtrl = false
2421local HoldingShift = false
2422
2423--[[
2424
2425# Explorer Panel
2426
2427A GUI panel that displays the game hierarchy.
2428
2429
2430## Selection Bindables
2431
2432- `Function GetSelection ( )`
2433
2434 Returns an array of objects representing the objects currently
2435 selected in the panel.
2436
2437- `Function SetSelection ( Objects selection )`
2438
2439 Sets the objects that are selected in the panel. `selection` is an array
2440 of objects.
2441
2442- `Event SelectionChanged ( )`
2443
2444 Fired after the selection changes.
2445
2446
2447## Option Bindables
2448
2449- `Function GetOption ( string optionName )`
2450
2451 If `optionName` is given, returns the value of that option. Otherwise,
2452 returns a table of options and their current values.
2453
2454- `Function SetOption ( string optionName, bool value )`
2455
2456 Sets `optionName` to `value`.
2457
2458 Options:
2459
2460 - Modifiable
2461
2462 Whether objects can be modified by the panel.
2463
2464 Note that modifying objects depends on being able to select them. If
2465 Selectable is false, then Actions will not be available. Reparenting
2466 is still possible, but only for the dragged object.
2467
2468 - Selectable
2469
2470 Whether objects can be selected.
2471
2472 If Modifiable is false, then left-clicking will perform a drag
2473 selection.
2474
2475## Updates
2476
2477- 2013-09-18
2478 - Fixed explorer icons to match studio explorer.
2479
2480- 2013-09-14
2481 - Added GetOption and SetOption bindables.
2482 - Option: Modifiable; sets whether objects can be modified by the panel.
2483 - Option: Selectable; sets whether objects can be selected.
2484 - Slight modification to left-click selection behavior.
2485 - Improved layout and scaling.
2486
2487- 2013-09-13
2488 - Added drag to reparent objects.
2489 - Left-click to select/deselect object.
2490 - Left-click and drag unselected object to reparent single object.
2491 - Left-click and drag selected object to move reparent entire selection.
2492 - Right-click while dragging to cancel.
2493
2494- 2013-09-11
2495 - Added explorer panel header with actions.
2496 - Added Cut action.
2497 - Added Copy action.
2498 - Added Paste action.
2499 - Added Delete action.
2500 - Added drag selection.
2501 - Left-click: Add to selection on drag.
2502 - Right-click: Add to or remove from selection on drag.
2503 - Ensured SelectionChanged fires only when the selection actually changes.
2504 - Added documentation and change log.
2505 - Fixed thread issue.
2506
2507- 2013-09-09
2508 - Added basic multi-selection.
2509 - Left-click to set selection.
2510 - Right-click to add to or remove from selection.
2511 - Removed "Selection" ObjectValue.
2512 - Added GetSelection BindableFunction.
2513 - Added SetSelection BindableFunction.
2514 - Added SelectionChanged BindableEvent.
2515 - Changed font to SourceSans.
2516
2517- 2013-08-31
2518 - Improved GUI sizing based off of `GUI_SIZE` constant.
2519 - Automatic font size detection.
2520
2521- 2013-08-27
2522 - Initial explorer panel.
2523
2524
2525## Todo
2526
2527- Sorting
2528 - by ExplorerOrder
2529 - by children
2530 - by name
2531- Drag objects to reparent
2532
2533]]
2534
2535local ENTRY_SIZE = GUI_SIZE + ENTRY_PADDING*2
2536local ENTRY_BOUND = ENTRY_SIZE + ENTRY_MARGIN
2537local HEADER_SIZE = ENTRY_SIZE*2
2538
2539local FONT = 'SourceSans'
2540local FONT_SIZE do
2541 local size = {8,9,10,11,12,14,18,24,36,48}
2542 local s
2543 local n = math.huge
2544 for i = 1,#size do
2545 if size[i] <= GUI_SIZE then
2546 FONT_SIZE = i - 1
2547 end
2548 end
2549end
2550
2551local GuiColor = {
2552 Background = Color3.new(233/255, 233/255, 233/255);
2553 Border = Color3.new(149/255, 149/255, 149/255);
2554 Selected = Color3.new( 96/255, 140/255, 211/255);
2555 BorderSelected = Color3.new( 86/255, 125/255, 188/255);
2556 Text = Color3.new( 0/255, 0/255, 0/255);
2557 TextDisabled = Color3.new(128/255, 128/255, 128/255);
2558 TextSelected = Color3.new(255/255, 255/255, 255/255);
2559 Button = Color3.new(221/255, 221/255, 221/255);
2560 ButtonBorder = Color3.new(149/255, 149/255, 149/255);
2561 ButtonSelected = Color3.new(255/255, 0/255, 0/255);
2562 Field = Color3.new(255/255, 255/255, 255/255);
2563 FieldBorder = Color3.new(191/255, 191/255, 191/255);
2564 TitleBackground = Color3.new(178/255, 178/255, 178/255);
2565}
2566
2567----------------------------------------------------------------
2568----------------------------------------------------------------
2569----------------------------------------------------------------
2570----------------------------------------------------------------
2571---- Icon map constants
2572
2573local MAP_ID = 483448923
2574
2575-- Indices based on implementation of Icon function.
2576local ACTION_CUT = 160
2577local ACTION_COPY = 161
2578local ACTION_PASTE = 162
2579local ACTION_DELETE = 163
2580local ACTION_SORT = 164
2581local ACTION_CUT_OVER = 174
2582local ACTION_COPY_OVER = 175
2583local ACTION_PASTE_OVER = 176
2584local ACTION_DELETE_OVER = 177
2585local ACTION_SORT_OVER = 178
2586local ACTION_EDITQUICKACCESS = 190
2587local ACTION_FREEZE = 188
2588local ACTION_STARRED = 189
2589local ACTION_ADDSTAR = 184
2590local ACTION_ADDSTAR_OVER = 187
2591
2592local NODE_COLLAPSED = 165
2593local NODE_EXPANDED = 166
2594local NODE_COLLAPSED_OVER = 179
2595local NODE_EXPANDED_OVER = 180
2596
2597local ExplorerIndex = {
2598 ["Accessory"] = 32;
2599 ["Accoutrement"] = 32;
2600 ["AdService"] = 73;
2601 ["Animation"] = 60;
2602 ["AnimationController"] = 60;
2603 ["AnimationTrack"] = 60;
2604 ["Animator"] = 60;
2605 ["ArcHandles"] = 56;
2606 ["AssetService"] = 72;
2607 ["Attachment"] = 34;
2608 ["Backpack"] = 20;
2609 ["BadgeService"] = 75;
2610 ["BallSocketConstraint"] = 89;
2611 ["BillboardGui"] = 64;
2612 ["BinaryStringValue"] = 4;
2613 ["BindableEvent"] = 67;
2614 ["BindableFunction"] = 66;
2615 ["BlockMesh"] = 8;
2616 ["BloomEffect"] = 90;
2617 ["BlurEffect"] = 90;
2618 ["BodyAngularVelocity"] = 14;
2619 ["BodyForce"] = 14;
2620 ["BodyGyro"] = 14;
2621 ["BodyPosition"] = 14;
2622 ["BodyThrust"] = 14;
2623 ["BodyVelocity"] = 14;
2624 ["BoolValue"] = 4;
2625 ["BoxHandleAdornment"] = 54;
2626 ["BrickColorValue"] = 4;
2627 ["Camera"] = 5;
2628 ["CFrameValue"] = 4;
2629 ["CharacterMesh"] = 60;
2630 ["Chat"] = 33;
2631 ["ClickDetector"] = 41;
2632 ["CollectionService"] = 30;
2633 ["Color3Value"] = 4;
2634 ["ColorCorrectionEffect"] = 90;
2635 ["ConeHandleAdornment"] = 54;
2636 ["Configuration"] = 58;
2637 ["ContentProvider"] = 72;
2638 ["ContextActionService"] = 41;
2639 ["CoreGui"] = 46;
2640 ["CoreScript"] = 18;
2641 ["CornerWedgePart"] = 1;
2642 ["CustomEvent"] = 4;
2643 ["CustomEventReceiver"] = 4;
2644 ["CylinderHandleAdornment"] = 54;
2645 ["CylinderMesh"] = 8;
2646 ["CylindricalConstraint"] = 89;
2647 ["Debris"] = 30;
2648 ["Decal"] = 7;
2649 ["Dialog"] = 62;
2650 ["DialogChoice"] = 63;
2651 ["DoubleConstrainedValue"] = 4;
2652 ["Explosion"] = 36;
2653 ["FileMesh"] = 8;
2654 ["Fire"] = 61;
2655 ["Flag"] = 38;
2656 ["FlagStand"] = 39;
2657 ["FloorWire"] = 4;
2658 ["Folder"] = 70;
2659 ["ForceField"] = 37;
2660 ["Frame"] = 48;
2661 ["GamePassService"] = 19;
2662 ["Glue"] = 34;
2663 ["GuiButton"] = 52;
2664 ["GuiMain"] = 47;
2665 ["GuiService"] = 47;
2666 ["Handles"] = 53;
2667 ["HapticService"] = 84;
2668 ["Hat"] = 45;
2669 ["HingeConstraint"] = 89;
2670 ["Hint"] = 33;
2671 ["HopperBin"] = 22;
2672 ["HttpService"] = 76;
2673 ["Humanoid"] = 9;
2674 ["ImageButton"] = 52;
2675 ["ImageLabel"] = 49;
2676 ["InsertService"] = 72;
2677 ["IntConstrainedValue"] = 4;
2678 ["IntValue"] = 4;
2679 ["JointInstance"] = 34;
2680 ["JointsService"] = 34;
2681 ["Keyframe"] = 60;
2682 ["KeyframeSequence"] = 60;
2683 ["KeyframeSequenceProvider"] = 60;
2684 ["Lighting"] = 13;
2685 ["LineHandleAdornment"] = 54;
2686 ["LocalScript"] = 18;
2687 ["LogService"] = 87;
2688 ["MarketplaceService"] = 46;
2689 ["Message"] = 33;
2690 ["Model"] = 2;
2691 ["ModuleScript"] = 71;
2692 ["Motor"] = 34;
2693 ["Motor6D"] = 34;
2694 ["MoveToConstraint"] = 89;
2695 ["NegateOperation"] = 78;
2696 ["NetworkClient"] = 16;
2697 ["NetworkReplicator"] = 29;
2698 ["NetworkServer"] = 15;
2699 ["NumberValue"] = 4;
2700 ["ObjectValue"] = 4;
2701 ["Pants"] = 44;
2702 ["ParallelRampPart"] = 1;
2703 ["Part"] = 1;
2704 ["ParticleEmitter"] = 69;
2705 ["PartPairLasso"] = 57;
2706 ["PathfindingService"] = 37;
2707 ["Platform"] = 35;
2708 ["Player"] = 12;
2709 ["PlayerGui"] = 46;
2710 ["Players"] = 21;
2711 ["PlayerScripts"] = 82;
2712 ["PointLight"] = 13;
2713 ["PointsService"] = 83;
2714 ["Pose"] = 60;
2715 ["PrismaticConstraint"] = 89;
2716 ["PrismPart"] = 1;
2717 ["PyramidPart"] = 1;
2718 ["RayValue"] = 4;
2719 ["ReflectionMetadata"] = 86;
2720 ["ReflectionMetadataCallbacks"] = 86;
2721 ["ReflectionMetadataClass"] = 86;
2722 ["ReflectionMetadataClasses"] = 86;
2723 ["ReflectionMetadataEnum"] = 86;
2724 ["ReflectionMetadataEnumItem"] = 86;
2725 ["ReflectionMetadataEnums"] = 86;
2726 ["ReflectionMetadataEvents"] = 86;
2727 ["ReflectionMetadataFunctions"] = 86;
2728 ["ReflectionMetadataMember"] = 86;
2729 ["ReflectionMetadataProperties"] = 86;
2730 ["ReflectionMetadataYieldFunctions"] = 86;
2731 ["RemoteEvent"] = 80;
2732 ["RemoteFunction"] = 79;
2733 ["ReplicatedFirst"] = 72;
2734 ["ReplicatedStorage"] = 72;
2735 ["RightAngleRampPart"] = 1;
2736 ["RocketPropulsion"] = 14;
2737 ["RodConstraint"] = 89;
2738 ["RopeConstraint"] = 89;
2739 ["Rotate"] = 34;
2740 ["RotateP"] = 34;
2741 ["RotateV"] = 34;
2742 ["RunService"] = 66;
2743 ["ScreenGui"] = 47;
2744 ["Script"] = 6;
2745 ["ScrollingFrame"] = 48;
2746 ["Seat"] = 35;
2747 ["Selection"] = 55;
2748 ["SelectionBox"] = 54;
2749 ["SelectionPartLasso"] = 57;
2750 ["SelectionPointLasso"] = 57;
2751 ["SelectionSphere"] = 54;
2752 ["ServerScriptService"] = 0;
2753 ["ServerStorage"] = 74;
2754 ["Shirt"] = 43;
2755 ["ShirtGraphic"] = 40;
2756 ["SkateboardPlatform"] = 35;
2757 ["Sky"] = 28;
2758 ["SlidingBallConstraint"] = 89;
2759 ["Smoke"] = 59;
2760 ["Snap"] = 34;
2761 ["Sound"] = 11;
2762 ["SoundService"] = 31;
2763 ["Sparkles"] = 42;
2764 ["SpawnLocation"] = 25;
2765 ["SpecialMesh"] = 8;
2766 ["SphereHandleAdornment"] = 54;
2767 ["SpotLight"] = 13;
2768 ["SpringConstraint"] = 89;
2769 ["StarterCharacterScripts"] = 82;
2770 ["StarterGear"] = 20;
2771 ["StarterGui"] = 46;
2772 ["StarterPack"] = 20;
2773 ["StarterPlayer"] = 88;
2774 ["StarterPlayerScripts"] = 82;
2775 ["Status"] = 2;
2776 ["StringValue"] = 4;
2777 ["SunRaysEffect"] = 90;
2778 ["SurfaceGui"] = 64;
2779 ["SurfaceLight"] = 13;
2780 ["SurfaceSelection"] = 55;
2781 ["Team"] = 24;
2782 ["Teams"] = 23;
2783 ["TeleportService"] = 81;
2784 ["Terrain"] = 65;
2785 ["TerrainRegion"] = 65;
2786 ["TestService"] = 68;
2787 ["TextBox"] = 51;
2788 ["TextButton"] = 51;
2789 ["TextLabel"] = 50;
2790 ["Texture"] = 10;
2791 ["TextureTrail"] = 4;
2792 ["Tool"] = 17;
2793 ["TouchTransmitter"] = 37;
2794 ["TrussPart"] = 1;
2795 ["UnionOperation"] = 77;
2796 ["UserInputService"] = 84;
2797 ["Vector3Value"] = 4;
2798 ["VehicleSeat"] = 35;
2799 ["VelocityMotor"] = 34;
2800 ["WedgePart"] = 1;
2801 ["Weld"] = 34;
2802 ["Workspace"] = 19;
2803}
2804
2805----------------------------------------------------------------
2806----------------------------------------------------------------
2807----------------------------------------------------------------
2808----------------------------------------------------------------
2809----------------------------------------------------------------
2810
2811function Create(ty,data)
2812 local obj
2813 if type(ty) == 'string' then
2814 obj = Instance.new(ty)
2815 else
2816 obj = ty
2817 end
2818 for k, v in pairs(data) do
2819 if type(k) == 'number' then
2820 v.Parent = obj
2821 else
2822 obj[k] = v
2823 end
2824 end
2825 return obj
2826end
2827
2828local barActive = false
2829local activeOptions = {}
2830
2831function createDDown(dBut, callback,...)
2832 if barActive then
2833 for i,v in pairs(activeOptions) do
2834 v:Destroy()
2835 end
2836 activeOptions = {}
2837 barActive = false
2838 return
2839 else
2840 barActive = true
2841 end
2842 local slots = {...}
2843 local base = dBut
2844 for i,v in pairs(slots) do
2845 local newOption = base:Clone()
2846 newOption.ZIndex = 5
2847 newOption.Name = "Option "..tostring(i)
2848 newOption.Parent = base.Parent.Parent.Parent
2849 newOption.BackgroundTransparency = 0
2850 newOption.ZIndex = 2
2851 table.insert(activeOptions,newOption)
2852 newOption.Position = UDim2.new(-0.4, dBut.Position.X.Offset, dBut.Position.Y.Scale, dBut.Position.Y.Offset + (#activeOptions * dBut.Size.Y.Offset))
2853 newOption.Text = slots[i]
2854 newOption.MouseButton1Down:connect(function()
2855 dBut.Text = slots[i]
2856 callback(slots[i])
2857 for i,v in pairs(activeOptions) do
2858 v:Destroy()
2859 end
2860 activeOptions = {}
2861 barActive = false
2862 end)
2863 end
2864end
2865
2866-- Connects a function to an event such that it fires asynchronously
2867function Connect(event,func)
2868 return event:connect(function(...)
2869 local a = {...}
2870 spawn(function() func(unpack(a)) end)
2871 end)
2872end
2873
2874-- returns the ascendant ScreenGui of an object
2875function GetScreen(screen)
2876 if screen == nil then return nil end
2877 while not screen:IsA("ScreenGui") do
2878 screen = screen.Parent
2879 if screen == nil then return nil end
2880 end
2881 return screen
2882end
2883
2884do
2885 local ZIndexLock = {}
2886 -- Sets the ZIndex of an object and its descendants. Objects are locked so
2887 -- that SetZIndexOnChanged doesn't spawn multiple threads that set the
2888 -- ZIndex of the same object.
2889 function SetZIndex(object,z)
2890 if not ZIndexLock[object] then
2891 ZIndexLock[object] = true
2892 if object:IsA'GuiObject' then
2893 object.ZIndex = z
2894 end
2895 local children = object:GetChildren()
2896 for i = 1,#children do
2897 SetZIndex(children[i],z)
2898 end
2899 ZIndexLock[object] = nil
2900 end
2901 end
2902
2903 function SetZIndexOnChanged(object)
2904 return object.Changed:connect(function(p)
2905 if p == "ZIndex" then
2906 SetZIndex(object,object.ZIndex)
2907 end
2908 end)
2909 end
2910end
2911
2912---- IconMap ----
2913-- Image size: 256px x 256px
2914-- Icon size: 16px x 16px
2915-- Padding between each icon: 2px
2916-- Padding around image edge: 1px
2917-- Total icons: 14 x 14 (196)
2918local Icon do
2919 local iconMap = 'http://www.roblox.com/asset/?id=' .. MAP_ID
2920 game:GetService('ContentProvider'):Preload(iconMap)
2921 local iconDehash do
2922 -- 14 x 14, 0-based input, 0-based output
2923 local f=math.floor
2924 function iconDehash(h)
2925 return f(h/14%14),f(h%14)
2926 end
2927 end
2928
2929 function Icon(IconFrame,index)
2930 local row,col = iconDehash(index)
2931 local mapSize = Vector2.new(256,256)
2932 local pad,border = 2,1
2933 local iconSize = 16
2934
2935 local class = 'Frame'
2936 if type(IconFrame) == 'string' then
2937 class = IconFrame
2938 IconFrame = nil
2939 end
2940
2941 if not IconFrame then
2942 IconFrame = Create(class,{
2943 Name = "Icon";
2944 BackgroundTransparency = 1;
2945 ClipsDescendants = true;
2946 Create('ImageLabel',{
2947 Name = "IconMap";
2948 Active = false;
2949 BackgroundTransparency = 1;
2950 Image = iconMap;
2951 Size = UDim2.new(mapSize.x/iconSize,0,mapSize.y/iconSize,0);
2952 });
2953 })
2954 end
2955
2956 IconFrame.IconMap.Position = UDim2.new(-col - (pad*(col+1) + border)/iconSize,0,-row - (pad*(row+1) + border)/iconSize,0)
2957 return IconFrame
2958 end
2959end
2960
2961----------------------------------------------------------------
2962----------------------------------------------------------------
2963----------------------------------------------------------------
2964----------------------------------------------------------------
2965---- ScrollBar
2966do
2967 -- AutoButtonColor doesn't always reset properly
2968 local function ResetButtonColor(button)
2969 local active = button.Active
2970 button.Active = not active
2971 button.Active = active
2972 end
2973
2974 local function ArrowGraphic(size,dir,scaled,template)
2975 local Frame = Create('Frame',{
2976 Name = "Arrow Graphic";
2977 BorderSizePixel = 0;
2978 Size = UDim2.new(0,size,0,size);
2979 Transparency = 1;
2980 })
2981 if not template then
2982 template = Instance.new("Frame")
2983 template.BorderSizePixel = 0
2984 end
2985
2986 local transform
2987 if dir == nil or dir == 'Up' then
2988 function transform(p,s) return p,s end
2989 elseif dir == 'Down' then
2990 function transform(p,s) return UDim2.new(0,p.X.Offset,0,size-p.Y.Offset-1),s end
2991 elseif dir == 'Left' then
2992 function transform(p,s) return UDim2.new(0,p.Y.Offset,0,p.X.Offset),UDim2.new(0,s.Y.Offset,0,s.X.Offset) end
2993 elseif dir == 'Right' then
2994 function transform(p,s) return UDim2.new(0,size-p.Y.Offset-1,0,p.X.Offset),UDim2.new(0,s.Y.Offset,0,s.X.Offset) end
2995 end
2996
2997 local scale
2998 if scaled then
2999 function scale(p,s) return UDim2.new(p.X.Offset/size,0,p.Y.Offset/size,0),UDim2.new(s.X.Offset/size,0,s.Y.Offset/size,0) end
3000 else
3001 function scale(p,s) return p,s end
3002 end
3003
3004 local o = math.floor(size/4)
3005 if size%2 == 0 then
3006 local n = size/2-1
3007 for i = 0,n do
3008 local t = template:Clone()
3009 local p,s = scale(transform(
3010 UDim2.new(0,n-i,0,o+i),
3011 UDim2.new(0,(i+1)*2,0,1)
3012 ))
3013 t.Position = p
3014 t.Size = s
3015 t.Parent = Frame
3016 end
3017 else
3018 local n = (size-1)/2
3019 for i = 0,n do
3020 local t = template:Clone()
3021 local p,s = scale(transform(
3022 UDim2.new(0,n-i,0,o+i),
3023 UDim2.new(0,i*2+1,0,1)
3024 ))
3025 t.Position = p
3026 t.Size = s
3027 t.Parent = Frame
3028 end
3029 end
3030 if size%4 > 1 then
3031 local t = template:Clone()
3032 local p,s = scale(transform(
3033 UDim2.new(0,0,0,size-o-1),
3034 UDim2.new(0,size,0,1)
3035 ))
3036 t.Position = p
3037 t.Size = s
3038 t.Parent = Frame
3039 end
3040 return Frame
3041 end
3042
3043
3044 local function GripGraphic(size,dir,spacing,scaled,template)
3045 local Frame = Create('Frame',{
3046 Name = "Grip Graphic";
3047 BorderSizePixel = 0;
3048 Size = UDim2.new(0,size.x,0,size.y);
3049 Transparency = 1;
3050 })
3051 if not template then
3052 template = Instance.new("Frame")
3053 template.BorderSizePixel = 0
3054 end
3055
3056 spacing = spacing or 2
3057
3058 local scale
3059 if scaled then
3060 function scale(p) return UDim2.new(p.X.Offset/size.x,0,p.Y.Offset/size.y,0) end
3061 else
3062 function scale(p) return p end
3063 end
3064
3065 if dir == 'Vertical' then
3066 for i=0,size.x-1,spacing do
3067 local t = template:Clone()
3068 t.Size = scale(UDim2.new(0,1,0,size.y))
3069 t.Position = scale(UDim2.new(0,i,0,0))
3070 t.Parent = Frame
3071 end
3072 elseif dir == nil or dir == 'Horizontal' then
3073 for i=0,size.y-1,spacing do
3074 local t = template:Clone()
3075 t.Size = scale(UDim2.new(0,size.x,0,1))
3076 t.Position = scale(UDim2.new(0,0,0,i))
3077 t.Parent = Frame
3078 end
3079 end
3080
3081 return Frame
3082 end
3083
3084 local mt = {
3085 __index = {
3086 GetScrollPercent = function(self)
3087 return self.ScrollIndex/(self.TotalSpace-self.VisibleSpace)
3088 end;
3089 CanScrollDown = function(self)
3090 return self.ScrollIndex + self.VisibleSpace < self.TotalSpace
3091 end;
3092 CanScrollUp = function(self)
3093 return self.ScrollIndex > 0
3094 end;
3095 ScrollDown = function(self)
3096 self.ScrollIndex = self.ScrollIndex + self.PageIncrement
3097 self:Update()
3098 end;
3099 ScrollUp = function(self)
3100 self.ScrollIndex = self.ScrollIndex - self.PageIncrement
3101 self:Update()
3102 end;
3103 ScrollTo = function(self,index)
3104 self.ScrollIndex = index
3105 self:Update()
3106 end;
3107 SetScrollPercent = function(self,percent)
3108 self.ScrollIndex = math.floor((self.TotalSpace - self.VisibleSpace)*percent + 0.5)
3109 self:Update()
3110 end;
3111 };
3112 }
3113 mt.__index.CanScrollRight = mt.__index.CanScrollDown
3114 mt.__index.CanScrollLeft = mt.__index.CanScrollUp
3115 mt.__index.ScrollLeft = mt.__index.ScrollUp
3116 mt.__index.ScrollRight = mt.__index.ScrollDown
3117
3118 function ScrollBar(horizontal)
3119 -- create row scroll bar
3120 local ScrollFrame = Create('Frame',{
3121 Name = "ScrollFrame";
3122 Position = horizontal and UDim2.new(0,0,1,-GUI_SIZE) or UDim2.new(1,-GUI_SIZE,0,0);
3123 Size = horizontal and UDim2.new(1,0,0,GUI_SIZE) or UDim2.new(0,GUI_SIZE,1,0);
3124 BackgroundTransparency = 1;
3125 Create('ImageButton',{
3126 Name = "ScrollDown";
3127 Position = horizontal and UDim2.new(1,-GUI_SIZE,0,0) or UDim2.new(0,0,1,-GUI_SIZE);
3128 Size = UDim2.new(0, GUI_SIZE, 0, GUI_SIZE);
3129 BackgroundColor3 = GuiColor.Button;
3130 BorderColor3 = GuiColor.Border;
3131 --BorderSizePixel = 0;
3132 });
3133 Create('ImageButton',{
3134 Name = "ScrollUp";
3135 Size = UDim2.new(0, GUI_SIZE, 0, GUI_SIZE);
3136 BackgroundColor3 = GuiColor.Button;
3137 BorderColor3 = GuiColor.Border;
3138 --BorderSizePixel = 0;
3139 });
3140 Create('ImageButton',{
3141 Name = "ScrollBar";
3142 Size = horizontal and UDim2.new(1,-GUI_SIZE*2,1,0) or UDim2.new(1,0,1,-GUI_SIZE*2);
3143 Position = horizontal and UDim2.new(0,GUI_SIZE,0,0) or UDim2.new(0,0,0,GUI_SIZE);
3144 AutoButtonColor = false;
3145 BackgroundColor3 = Color3.new(0.94902, 0.94902, 0.94902);
3146 BorderColor3 = GuiColor.Border;
3147 --BorderSizePixel = 0;
3148 Create('ImageButton',{
3149 Name = "ScrollThumb";
3150 AutoButtonColor = false;
3151 Size = UDim2.new(0, GUI_SIZE, 0, GUI_SIZE);
3152 BackgroundColor3 = GuiColor.Button;
3153 BorderColor3 = GuiColor.Border;
3154 --BorderSizePixel = 0;
3155 });
3156 });
3157 })
3158
3159 local graphicTemplate = Create('Frame',{
3160 Name="Graphic";
3161 BorderSizePixel = 0;
3162 BackgroundColor3 = GuiColor.Border;
3163 })
3164 local graphicSize = GUI_SIZE/2
3165
3166 local ScrollDownFrame = ScrollFrame.ScrollDown
3167 local ScrollDownGraphic = ArrowGraphic(graphicSize,horizontal and 'Right' or 'Down',true,graphicTemplate)
3168 ScrollDownGraphic.Position = UDim2.new(0.5,-graphicSize/2,0.5,-graphicSize/2)
3169 ScrollDownGraphic.Parent = ScrollDownFrame
3170 local ScrollUpFrame = ScrollFrame.ScrollUp
3171 local ScrollUpGraphic = ArrowGraphic(graphicSize,horizontal and 'Left' or 'Up',true,graphicTemplate)
3172 ScrollUpGraphic.Position = UDim2.new(0.5,-graphicSize/2,0.5,-graphicSize/2)
3173 ScrollUpGraphic.Parent = ScrollUpFrame
3174 local ScrollBarFrame = ScrollFrame.ScrollBar
3175 local ScrollThumbFrame = ScrollBarFrame.ScrollThumb
3176 do
3177 local size = GUI_SIZE*3/8
3178 local Decal = GripGraphic(Vector2.new(size,size),horizontal and 'Vertical' or 'Horizontal',2,graphicTemplate)
3179 Decal.Position = UDim2.new(0.5,-size/2,0.5,-size/2)
3180 Decal.Parent = ScrollThumbFrame
3181 end
3182
3183 local Class = setmetatable({
3184 GUI = ScrollFrame;
3185 ScrollIndex = 0;
3186 VisibleSpace = 0;
3187 TotalSpace = 0;
3188 PageIncrement = 1;
3189 },mt)
3190
3191 local UpdateScrollThumb
3192 if horizontal then
3193 function UpdateScrollThumb()
3194 ScrollThumbFrame.Size = UDim2.new(Class.VisibleSpace/Class.TotalSpace,0,0,GUI_SIZE)
3195 if ScrollThumbFrame.AbsoluteSize.x < GUI_SIZE then
3196 ScrollThumbFrame.Size = UDim2.new(0,GUI_SIZE,0,GUI_SIZE)
3197 end
3198 local barSize = ScrollBarFrame.AbsoluteSize.x
3199 ScrollThumbFrame.Position = UDim2.new(Class:GetScrollPercent()*(barSize - ScrollThumbFrame.AbsoluteSize.x)/barSize,0,0,0)
3200 end
3201 else
3202 function UpdateScrollThumb()
3203 ScrollThumbFrame.Size = UDim2.new(0,GUI_SIZE,Class.VisibleSpace/Class.TotalSpace,0)
3204 if ScrollThumbFrame.AbsoluteSize.y < GUI_SIZE then
3205 ScrollThumbFrame.Size = UDim2.new(0,GUI_SIZE,0,GUI_SIZE)
3206 end
3207 local barSize = ScrollBarFrame.AbsoluteSize.y
3208 ScrollThumbFrame.Position = UDim2.new(0,0,Class:GetScrollPercent()*(barSize - ScrollThumbFrame.AbsoluteSize.y)/barSize,0)
3209 end
3210 end
3211
3212 local lastDown
3213 local lastUp
3214 local scrollStyle = {BackgroundColor3=GuiColor.Border,BackgroundTransparency=0}
3215 local scrollStyle_ds = {BackgroundColor3=GuiColor.Border,BackgroundTransparency=0.7}
3216
3217 local function Update()
3218 local t = Class.TotalSpace
3219 local v = Class.VisibleSpace
3220 local s = Class.ScrollIndex
3221 if v <= t then
3222 if s > 0 then
3223 if s + v > t then
3224 Class.ScrollIndex = t - v
3225 end
3226 else
3227 Class.ScrollIndex = 0
3228 end
3229 else
3230 Class.ScrollIndex = 0
3231 end
3232
3233 if Class.UpdateCallback then
3234 if Class.UpdateCallback(Class) == false then
3235 return
3236 end
3237 end
3238
3239 local down = Class:CanScrollDown()
3240 local up = Class:CanScrollUp()
3241 if down ~= lastDown then
3242 lastDown = down
3243 ScrollDownFrame.Active = down
3244 ScrollDownFrame.AutoButtonColor = down
3245 local children = ScrollDownGraphic:GetChildren()
3246 local style = down and scrollStyle or scrollStyle_ds
3247 for i = 1,#children do
3248 Create(children[i],style)
3249 end
3250 end
3251 if up ~= lastUp then
3252 lastUp = up
3253 ScrollUpFrame.Active = up
3254 ScrollUpFrame.AutoButtonColor = up
3255 local children = ScrollUpGraphic:GetChildren()
3256 local style = up and scrollStyle or scrollStyle_ds
3257 for i = 1,#children do
3258 Create(children[i],style)
3259 end
3260 end
3261 ScrollThumbFrame.Visible = down or up
3262 UpdateScrollThumb()
3263 end
3264 Class.Update = Update
3265
3266 SetZIndexOnChanged(ScrollFrame)
3267
3268 local MouseDrag = Create('ImageButton',{
3269 Name = "MouseDrag";
3270 Position = UDim2.new(-0.25,0,-0.25,0);
3271 Size = UDim2.new(1.5,0,1.5,0);
3272 Transparency = 1;
3273 AutoButtonColor = false;
3274 Active = true;
3275 ZIndex = 10;
3276 })
3277
3278 local scrollEventID = 0
3279 ScrollDownFrame.MouseButton1Down:connect(function()
3280 scrollEventID = tick()
3281 local current = scrollEventID
3282 local up_con
3283 up_con = MouseDrag.MouseButton1Up:connect(function()
3284 scrollEventID = tick()
3285 MouseDrag.Parent = nil
3286 ResetButtonColor(ScrollDownFrame)
3287 up_con:disconnect(); drag = nil
3288 end)
3289 MouseDrag.Parent = GetScreen(ScrollFrame)
3290 Class:ScrollDown()
3291 wait(0.2) -- delay before auto scroll
3292 while scrollEventID == current do
3293 Class:ScrollDown()
3294 if not Class:CanScrollDown() then break end
3295 wait()
3296 end
3297 end)
3298
3299 ScrollDownFrame.MouseButton1Up:connect(function()
3300 scrollEventID = tick()
3301 end)
3302
3303 ScrollUpFrame.MouseButton1Down:connect(function()
3304 scrollEventID = tick()
3305 local current = scrollEventID
3306 local up_con
3307 up_con = MouseDrag.MouseButton1Up:connect(function()
3308 scrollEventID = tick()
3309 MouseDrag.Parent = nil
3310 ResetButtonColor(ScrollUpFrame)
3311 up_con:disconnect(); drag = nil
3312 end)
3313 MouseDrag.Parent = GetScreen(ScrollFrame)
3314 Class:ScrollUp()
3315 wait(0.2)
3316 while scrollEventID == current do
3317 Class:ScrollUp()
3318 if not Class:CanScrollUp() then break end
3319 wait()
3320 end
3321 end)
3322
3323 ScrollUpFrame.MouseButton1Up:connect(function()
3324 scrollEventID = tick()
3325 end)
3326
3327 if horizontal then
3328 ScrollBarFrame.MouseButton1Down:connect(function(x,y)
3329 scrollEventID = tick()
3330 local current = scrollEventID
3331 local up_con
3332 up_con = MouseDrag.MouseButton1Up:connect(function()
3333 scrollEventID = tick()
3334 MouseDrag.Parent = nil
3335 ResetButtonColor(ScrollUpFrame)
3336 up_con:disconnect(); drag = nil
3337 end)
3338 MouseDrag.Parent = GetScreen(ScrollFrame)
3339 if x > ScrollThumbFrame.AbsolutePosition.x then
3340 Class:ScrollTo(Class.ScrollIndex + Class.VisibleSpace)
3341 wait(0.2)
3342 while scrollEventID == current do
3343 if x < ScrollThumbFrame.AbsolutePosition.x + ScrollThumbFrame.AbsoluteSize.x then break end
3344 Class:ScrollTo(Class.ScrollIndex + Class.VisibleSpace)
3345 wait()
3346 end
3347 else
3348 Class:ScrollTo(Class.ScrollIndex - Class.VisibleSpace)
3349 wait(0.2)
3350 while scrollEventID == current do
3351 if x > ScrollThumbFrame.AbsolutePosition.x then break end
3352 Class:ScrollTo(Class.ScrollIndex - Class.VisibleSpace)
3353 wait()
3354 end
3355 end
3356 end)
3357 else
3358 ScrollBarFrame.MouseButton1Down:connect(function(x,y)
3359 scrollEventID = tick()
3360 local current = scrollEventID
3361 local up_con
3362 up_con = MouseDrag.MouseButton1Up:connect(function()
3363 scrollEventID = tick()
3364 MouseDrag.Parent = nil
3365 ResetButtonColor(ScrollUpFrame)
3366 up_con:disconnect(); drag = nil
3367 end)
3368 MouseDrag.Parent = GetScreen(ScrollFrame)
3369 if y > ScrollThumbFrame.AbsolutePosition.y then
3370 Class:ScrollTo(Class.ScrollIndex + Class.VisibleSpace)
3371 wait(0.2)
3372 while scrollEventID == current do
3373 if y < ScrollThumbFrame.AbsolutePosition.y + ScrollThumbFrame.AbsoluteSize.y then break end
3374 Class:ScrollTo(Class.ScrollIndex + Class.VisibleSpace)
3375 wait()
3376 end
3377 else
3378 Class:ScrollTo(Class.ScrollIndex - Class.VisibleSpace)
3379 wait(0.2)
3380 while scrollEventID == current do
3381 if y > ScrollThumbFrame.AbsolutePosition.y then break end
3382 Class:ScrollTo(Class.ScrollIndex - Class.VisibleSpace)
3383 wait()
3384 end
3385 end
3386 end)
3387 end
3388
3389 if horizontal then
3390 ScrollThumbFrame.MouseButton1Down:connect(function(x,y)
3391 scrollEventID = tick()
3392 local mouse_offset = x - ScrollThumbFrame.AbsolutePosition.x
3393 local drag_con
3394 local up_con
3395 drag_con = MouseDrag.MouseMoved:connect(function(x,y)
3396 local bar_abs_pos = ScrollBarFrame.AbsolutePosition.x
3397 local bar_drag = ScrollBarFrame.AbsoluteSize.x - ScrollThumbFrame.AbsoluteSize.x
3398 local bar_abs_one = bar_abs_pos + bar_drag
3399 x = x - mouse_offset
3400 x = x < bar_abs_pos and bar_abs_pos or x > bar_abs_one and bar_abs_one or x
3401 x = x - bar_abs_pos
3402 Class:SetScrollPercent(x/(bar_drag))
3403 end)
3404 up_con = MouseDrag.MouseButton1Up:connect(function()
3405 scrollEventID = tick()
3406 MouseDrag.Parent = nil
3407 ResetButtonColor(ScrollThumbFrame)
3408 drag_con:disconnect(); drag_con = nil
3409 up_con:disconnect(); drag = nil
3410 end)
3411 MouseDrag.Parent = GetScreen(ScrollFrame)
3412 end)
3413 else
3414 ScrollThumbFrame.MouseButton1Down:connect(function(x,y)
3415 scrollEventID = tick()
3416 local mouse_offset = y - ScrollThumbFrame.AbsolutePosition.y
3417 local drag_con
3418 local up_con
3419 drag_con = MouseDrag.MouseMoved:connect(function(x,y)
3420 local bar_abs_pos = ScrollBarFrame.AbsolutePosition.y
3421 local bar_drag = ScrollBarFrame.AbsoluteSize.y - ScrollThumbFrame.AbsoluteSize.y
3422 local bar_abs_one = bar_abs_pos + bar_drag
3423 y = y - mouse_offset
3424 y = y < bar_abs_pos and bar_abs_pos or y > bar_abs_one and bar_abs_one or y
3425 y = y - bar_abs_pos
3426 Class:SetScrollPercent(y/(bar_drag))
3427 end)
3428 up_con = MouseDrag.MouseButton1Up:connect(function()
3429 scrollEventID = tick()
3430 MouseDrag.Parent = nil
3431 ResetButtonColor(ScrollThumbFrame)
3432 drag_con:disconnect(); drag_con = nil
3433 up_con:disconnect(); drag = nil
3434 end)
3435 MouseDrag.Parent = GetScreen(ScrollFrame)
3436 end)
3437 end
3438
3439 function Class:Destroy()
3440 ScrollFrame:Destroy()
3441 MouseDrag:Destroy()
3442 for k in pairs(Class) do
3443 Class[k] = nil
3444 end
3445 setmetatable(Class,nil)
3446 end
3447
3448 Update()
3449
3450 return Class
3451 end
3452end
3453
3454----------------------------------------------------------------
3455----------------------------------------------------------------
3456----------------------------------------------------------------
3457----------------------------------------------------------------
3458---- Explorer panel
3459
3460local explorerPanel = D_E_X.ExplorerPanel
3461Create(explorerPanel,{
3462 BackgroundColor3 = GuiColor.Field;
3463 BorderColor3 = GuiColor.Border;
3464 Active = true;
3465})
3466
3467local SettingsRemote = explorerPanel.Parent:WaitForChild("SettingsPanel"):WaitForChild("GetSetting")
3468local GetApiRemote = explorerPanel.Parent:WaitForChild("PropertiesFrame"):WaitForChild("GetApi")
3469local GetAwaitRemote = explorerPanel.Parent:WaitForChild("PropertiesFrame"):WaitForChild("GetAwaiting")
3470local bindSetAwaiting = explorerPanel.Parent:WaitForChild("PropertiesFrame"):WaitForChild("SetAwaiting")
3471
3472local SaveInstanceWindow = explorerPanel.Parent:WaitForChild("SaveInstance")
3473local ConfirmationWindow = explorerPanel.Parent:WaitForChild("Confirmation")
3474local CautionWindow = explorerPanel.Parent:WaitForChild("Caution")
3475local TableCautionWindow = explorerPanel.Parent:WaitForChild("TableCaution")
3476
3477local RemoteWindow = explorerPanel.Parent:WaitForChild("CallRemote")
3478
3479local ScriptEditor = explorerPanel.Parent:WaitForChild("ScriptEditor")
3480local ScriptEditorEvent = ScriptEditor:WaitForChild("OpenScript")
3481
3482local CurrentSaveInstanceWindow
3483local CurrentRemoteWindow
3484
3485local lastSelectedNode
3486
3487local DexStorage
3488local DexStorageMain
3489local DexStorageEnabled
3490
3491if saveinstance then DexStorageEnabled = true end
3492
3493if DexStorageEnabled then
3494 DexStorage = Instance.new("Folder")
3495 DexStorage.Name = "Dex"
3496 DexStorageMain = Instance.new("Folder",DexStorage)
3497 DexStorageMain.Name = "DexStorage"
3498end
3499
3500local NilStorage
3501local NilStorageMain
3502local NilStorageEnabled
3503
3504if get_nil_instances and IfThisFunctionWasStableEnough then NilStorageEnabled = true end
3505
3506if NilStorageEnabled then
3507 NilStorage = Instance.new("Folder")
3508 NilStorage.Name = "Dex Internal Storage"
3509 NilStorageMain = Instance.new("Folder",NilStorage)
3510 NilStorageMain.Name = "Nil Instances"
3511end
3512
3513local listFrame = Create('Frame',{
3514 Name = "List";
3515 BackgroundTransparency = 1;
3516 ClipsDescendants = true;
3517 Position = UDim2.new(0,0,0,HEADER_SIZE);
3518 Size = UDim2.new(1,-GUI_SIZE,1,-HEADER_SIZE);
3519 Parent = explorerPanel;
3520})
3521
3522local scrollBar = ScrollBar(false)
3523scrollBar.PageIncrement = 1
3524Create(scrollBar.GUI,{
3525 Position = UDim2.new(1,-GUI_SIZE,0,HEADER_SIZE);
3526 Size = UDim2.new(0,GUI_SIZE,1,-HEADER_SIZE);
3527 Parent = explorerPanel;
3528})
3529
3530local scrollBarH = ScrollBar(true)
3531scrollBarH.PageIncrement = GUI_SIZE
3532Create(scrollBarH.GUI,{
3533 Position = UDim2.new(0,0,1,-GUI_SIZE);
3534 Size = UDim2.new(1,-GUI_SIZE,0,GUI_SIZE);
3535 Visible = false;
3536 Parent = explorerPanel;
3537})
3538
3539local headerFrame = Create('Frame',{
3540 Name = "Header";
3541 BackgroundColor3 = GuiColor.Background;
3542 BorderColor3 = GuiColor.Border;
3543 Position = UDim2.new(0,0,0,0);
3544 Size = UDim2.new(1,0,0,HEADER_SIZE);
3545 Parent = explorerPanel;
3546 Create('TextLabel',{
3547 Text = "Explorer";
3548 BackgroundTransparency = 1;
3549 TextColor3 = GuiColor.Text;
3550 TextXAlignment = 'Left';
3551 Font = FONT;
3552 FontSize = FONT_SIZE;
3553 Position = UDim2.new(0,4,0,0);
3554 Size = UDim2.new(1,-4,0.5,0);
3555 });
3556})
3557
3558local explorerFilter = Create('TextBox',{
3559 Text = "Filter Workspace";
3560 BackgroundTransparency = 0.8;
3561 TextColor3 = GuiColor.Text;
3562 TextXAlignment = 'Left';
3563 Font = FONT;
3564 FontSize = FONT_SIZE;
3565 Position = UDim2.new(0,4,0.5,0);
3566 Size = UDim2.new(1,-8,0.5,-2);
3567});
3568explorerFilter.Parent = headerFrame
3569
3570SetZIndexOnChanged(explorerPanel)
3571
3572local function CreateColor3(r, g, b) return Color3.new(r/255,g/255,b/255) end
3573
3574local Styles = {
3575 Font = Enum.Font.Arial;
3576 Margin = 5;
3577 Black = CreateColor3(0,0,0);
3578 White = CreateColor3(255,255,255);
3579}
3580
3581local DropDown = {
3582 Font = Styles.Font;
3583 FontSize = Enum.FontSize.Size14;
3584 TextColor = CreateColor3(0,0,0);
3585 TextColorOver = Styles.White;
3586 TextXAlignment = Enum.TextXAlignment.Left;
3587 Height = 20;
3588 BackColor = Styles.White;
3589 BackColorOver = CreateColor3(86,125,188);
3590 BorderColor = CreateColor3(216,216,216);
3591 BorderSizePixel = 2;
3592 ArrowColor = CreateColor3(160,160,160);
3593 ArrowColorOver = Styles.Black;
3594}
3595
3596local Row = {
3597 Font = Styles.Font;
3598 FontSize = Enum.FontSize.Size14;
3599 TextXAlignment = Enum.TextXAlignment.Left;
3600 TextColor = Styles.Black;
3601 TextColorOver = Styles.White;
3602 TextLockedColor = CreateColor3(120,120,120);
3603 Height = 24;
3604 BorderColor = CreateColor3(216,216,216);
3605 BackgroundColor = Styles.White;
3606 BackgroundColorAlternate = CreateColor3(246,246,246);
3607 BackgroundColorMouseover = CreateColor3(211,224,244);
3608 TitleMarginLeft = 15;
3609}
3610
3611local currentRightClickMenu
3612local CurrentInsertObjectWindow
3613local CurrentFunctionCallerWindow
3614
3615local RbxApi
3616
3617function ClassCanCreate(IName)
3618 local success = pcall(function() Instance.new(IName) end)
3619 if not success then
3620 return false
3621 else
3622 return true
3623 end
3624end
3625
3626function GetClasses()
3627 if RbxApi == nil then return {} end
3628 local classTable = {}
3629 for i,v in pairs(RbxApi.Classes) do
3630 if ClassCanCreate(v.Name) then
3631 table.insert(classTable,v.Name)
3632 end
3633 end
3634 return classTable
3635end
3636
3637local function sortAlphabetic(t, property)
3638 table.sort(t,
3639 function(x,y) return x[property] < y[property]
3640 end)
3641end
3642
3643local function FunctionIsHidden(functionData)
3644 local tags = functionData["tags"]
3645 for _,name in pairs(tags) do
3646 if name == "deprecated"
3647 or name == "hidden"
3648 or name == "writeonly" then
3649 return true
3650 end
3651 end
3652 return false
3653end
3654
3655local function GetAllFunctions(className)
3656 local class = RbxApi.Classes[className]
3657 local functions = {}
3658
3659 if not class then return functions end
3660
3661 while class do
3662 if class.Name == "Instance" then break end
3663 for _,nextFunction in pairs(class.Functions) do
3664 if not FunctionIsHidden(nextFunction) then
3665 table.insert(functions, nextFunction)
3666 end
3667 end
3668 class = RbxApi.Classes[class.Superclass]
3669 end
3670
3671 sortAlphabetic(functions, "Name")
3672
3673 return functions
3674end
3675
3676function GetFunctions()
3677 if RbxApi == nil then return {} end
3678 local List = SelectionVar():Get()
3679
3680 if #List == 0 then return end
3681
3682 local MyObject = List[1]
3683
3684 local functionTable = {}
3685 for i,v in pairs(GetAllFunctions(MyObject.ClassName)) do
3686 table.insert(functionTable,v)
3687 end
3688 return functionTable
3689end
3690
3691function CreateInsertObjectMenu(choices, currentChoice, readOnly, onClick)
3692 local mouse = game.Players.LocalPlayer:GetMouse()
3693 local totalSize = explorerPanel.Parent.AbsoluteSize.y
3694 if #choices == 0 then return end
3695
3696 table.sort(choices, function(a,b) return a < b end)
3697
3698 local frame = Instance.new("Frame")
3699 frame.Name = "InsertObject"
3700 frame.Size = UDim2.new(0, 200, 1, 0)
3701 frame.BackgroundTransparency = 1
3702 frame.Active = true
3703
3704 local menu = nil
3705 local arrow = nil
3706 local expanded = false
3707 local margin = DropDown.BorderSizePixel;
3708
3709 --[[
3710 local button = Instance.new("TextButton")
3711 button.Font = Row.Font
3712 button.FontSize = Row.FontSize
3713 button.TextXAlignment = Row.TextXAlignment
3714 button.BackgroundTransparency = 1
3715 button.TextColor3 = Row.TextColor
3716 if readOnly then
3717 button.TextColor3 = Row.TextLockedColor
3718 end
3719 button.Text = currentChoice
3720 button.Size = UDim2.new(1, -2 * Styles.Margin, 1, 0)
3721 button.Position = UDim2.new(0, Styles.Margin, 0, 0)
3722 button.Parent = frame
3723 --]]
3724
3725 local function hideMenu()
3726 expanded = false
3727 --showArrow(DropDown.ArrowColor)
3728 if frame then
3729 --frame:Destroy()
3730 CurrentInsertObjectWindow.Visible = false
3731 end
3732 end
3733
3734 local function showMenu()
3735 expanded = true
3736 menu = Instance.new("ScrollingFrame")
3737 menu.Size = UDim2.new(0,200,1,0)
3738 menu.CanvasSize = UDim2.new(0, 200, 0, #choices * DropDown.Height)
3739 menu.Position = UDim2.new(0, margin, 0, 0)
3740 menu.BackgroundTransparency = 0
3741 menu.BackgroundColor3 = DropDown.BackColor
3742 menu.BorderColor3 = DropDown.BorderColor
3743 menu.BorderSizePixel = DropDown.BorderSizePixel
3744 menu.TopImage = "rbxasset://textures/blackBkg_square.png"
3745 menu.MidImage = "rbxasset://textures/blackBkg_square.png"
3746 menu.BottomImage = "rbxasset://textures/blackBkg_square.png"
3747 menu.Active = true
3748 menu.ZIndex = 5
3749 menu.Parent = frame
3750
3751 --local parentFrameHeight = script.Parent.List.Size.Y.Offset
3752 --local rowHeight = mouse.Y
3753 --if (rowHeight + menu.Size.Y.Offset) > parentFrameHeight then
3754 -- menu.Position = UDim2.new(0, margin, 0, -1 * (#choices * DropDown.Height) - margin)
3755 --end
3756
3757 local function choice(name)
3758 onClick(name)
3759 hideMenu()
3760 end
3761
3762 for i,name in pairs(choices) do
3763 local option = CreateRightClickMenuItem(name, function()
3764 choice(name)
3765 end,1)
3766 option.Size = UDim2.new(1, 0, 0, 20)
3767 option.Position = UDim2.new(0, 0, 0, (i - 1) * DropDown.Height)
3768 option.ZIndex = menu.ZIndex
3769 option.Parent = menu
3770 end
3771 end
3772
3773
3774 showMenu()
3775
3776
3777 return frame
3778end
3779
3780function CreateFunctionCallerMenu(choices, currentChoice, readOnly, onClick)
3781 local mouse = game.Players.LocalPlayer:GetMouse()
3782 local totalSize = explorerPanel.Parent.AbsoluteSize.y
3783 if #choices == 0 then return end
3784
3785 table.sort(choices, function(a,b) return a.Name < b.Name end)
3786
3787 local frame = Instance.new("Frame")
3788 frame.Name = "InsertObject"
3789 frame.Size = UDim2.new(0, 200, 1, 0)
3790 frame.BackgroundTransparency = 1
3791 frame.Active = true
3792
3793 local menu = nil
3794 local arrow = nil
3795 local expanded = false
3796 local margin = DropDown.BorderSizePixel;
3797
3798 local function hideMenu()
3799 expanded = false
3800 --showArrow(DropDown.ArrowColor)
3801 if frame then
3802 --frame:Destroy()
3803 CurrentInsertObjectWindow.Visible = false
3804 end
3805 end
3806
3807 local function showMenu()
3808 expanded = true
3809 menu = Instance.new("ScrollingFrame")
3810 menu.Size = UDim2.new(0,300,1,0)
3811 menu.CanvasSize = UDim2.new(0, 300, 0, #choices * DropDown.Height)
3812 menu.Position = UDim2.new(0, margin, 0, 0)
3813 menu.BackgroundTransparency = 0
3814 menu.BackgroundColor3 = DropDown.BackColor
3815 menu.BorderColor3 = DropDown.BorderColor
3816 menu.BorderSizePixel = DropDown.BorderSizePixel
3817 menu.TopImage = "rbxasset://textures/blackBkg_square.png"
3818 menu.MidImage = "rbxasset://textures/blackBkg_square.png"
3819 menu.BottomImage = "rbxasset://textures/blackBkg_square.png"
3820 menu.Active = true
3821 menu.ZIndex = 5
3822 menu.Parent = frame
3823
3824 --local parentFrameHeight = script.Parent.List.Size.Y.Offset
3825 --local rowHeight = mouse.Y
3826 --if (rowHeight + menu.Size.Y.Offset) > parentFrameHeight then
3827 -- menu.Position = UDim2.new(0, margin, 0, -1 * (#choices * DropDown.Height) - margin)
3828 --end
3829
3830 local function GetParameters(functionData)
3831 local paraString = ""
3832 paraString = paraString.."("
3833 for i,v in pairs(functionData.Arguments) do
3834 paraString = paraString..v.Type.." "..v.Name
3835 if i < #functionData.Arguments then
3836 paraString = paraString..", "
3837 end
3838 end
3839 paraString = paraString..")"
3840 return paraString
3841 end
3842
3843 local function choice(name)
3844 onClick(name)
3845 hideMenu()
3846 end
3847
3848 for i,name in pairs(choices) do
3849 local option = CreateRightClickMenuItem(name.ReturnType.." "..name.Name..GetParameters(name), function()
3850 choice(name)
3851 end,2)
3852 option.Size = UDim2.new(1, 0, 0, 20)
3853 option.Position = UDim2.new(0, 0, 0, (i - 1) * DropDown.Height)
3854 option.ZIndex = menu.ZIndex
3855 option.Parent = menu
3856 end
3857 end
3858
3859
3860 showMenu()
3861
3862
3863 return frame
3864end
3865
3866function CreateInsertObject()
3867 if not CurrentInsertObjectWindow then return end
3868 CurrentInsertObjectWindow.Visible = true
3869 if currentRightClickMenu and CurrentInsertObjectWindow.Visible then
3870 CurrentInsertObjectWindow.Position = UDim2.new(0,currentRightClickMenu.Position.X.Offset-currentRightClickMenu.Size.X.Offset-2,0,0)
3871 end
3872 if CurrentInsertObjectWindow.Visible then
3873 CurrentInsertObjectWindow.Parent = explorerPanel.Parent
3874 end
3875end
3876
3877function CreateFunctionCaller()
3878 if CurrentFunctionCallerWindow then
3879 CurrentFunctionCallerWindow:Destroy()
3880 CurrentFunctionCallerWindow = nil
3881 end
3882 CurrentFunctionCallerWindow = CreateFunctionCallerMenu(
3883 GetFunctions(),
3884 "",
3885 false,
3886 function(option)
3887 CurrentFunctionCallerWindow:Destroy()
3888 CurrentFunctionCallerWindow = nil
3889 local list = SelectionVar():Get()
3890 for i = 1,#list do
3891 pcall(function() Instance.new(option,list[i]) end)
3892 end
3893 print(option.Name .. " selected to be called. Function caller being added soon, please wait!")
3894 --CallFunction()
3895 DestroyRightClick()
3896 end
3897 )
3898 if currentRightClickMenu and CurrentFunctionCallerWindow then
3899 CurrentFunctionCallerWindow.Position = UDim2.new(0,currentRightClickMenu.Position.X.Offset-currentRightClickMenu.Size.X.Offset*1.5-2,0,0)
3900 end
3901 if CurrentFunctionCallerWindow then
3902 CurrentFunctionCallerWindow.Parent = explorerPanel.Parent
3903 end
3904end
3905
3906function CreateRightClickMenuItem(text, onClick, insObj)
3907 local button = Instance.new("TextButton")
3908 button.Font = DropDown.Font
3909 button.FontSize = DropDown.FontSize
3910 button.TextColor3 = DropDown.TextColor
3911 button.TextXAlignment = DropDown.TextXAlignment
3912 button.BackgroundColor3 = DropDown.BackColor
3913 button.AutoButtonColor = false
3914 button.BorderSizePixel = 0
3915 button.Active = true
3916 button.Text = text
3917
3918 if insObj == 1 then
3919 local newIcon = Icon(nil,ExplorerIndex[text] or 0)
3920 newIcon.Position = UDim2.new(0,0,0,2)
3921 newIcon.Size = UDim2.new(0,16,0,16)
3922 newIcon.IconMap.ZIndex = 5
3923 newIcon.Parent = button
3924 button.Text = "\t\t"..button.Text
3925 elseif insObj == 2 then
3926 button.FontSize = Enum.FontSize.Size11
3927 end
3928
3929 button.MouseEnter:connect(function()
3930 button.TextColor3 = DropDown.TextColorOver
3931 button.BackgroundColor3 = DropDown.BackColorOver
3932 if not insObj and CurrentInsertObjectWindow then
3933 if CurrentInsertObjectWindow.Visible == false and button.Text == "Insert Object" then
3934 CreateInsertObject()
3935 elseif CurrentInsertObjectWindow.Visible and button.Text ~= "Insert Object" then
3936 CurrentInsertObjectWindow.Visible = false
3937 end
3938 end
3939 if not insObj then
3940 if CurrentFunctionCallerWindow and button.Text ~= "Call Function" then
3941 CurrentFunctionCallerWindow:Destroy()
3942 CurrentFunctionCallerWindow = nil
3943 elseif button.Text == "Call Function" then
3944 CreateFunctionCaller()
3945 end
3946 end
3947 end)
3948 button.MouseLeave:connect(function()
3949 button.TextColor3 = DropDown.TextColor
3950 button.BackgroundColor3 = DropDown.BackColor
3951 end)
3952 button.MouseButton1Click:connect(function()
3953 button.TextColor3 = DropDown.TextColor
3954 button.BackgroundColor3 = DropDown.BackColor
3955 onClick(text)
3956 end)
3957 return button
3958end
3959
3960function CreateRightClickMenu(choices, currentChoice, readOnly, onClick)
3961 local mouse = game.Players.LocalPlayer:GetMouse()
3962
3963 local frame = Instance.new("Frame")
3964 frame.Name = "DropDown"
3965 frame.Size = UDim2.new(0, 200, 1, 0)
3966 frame.BackgroundTransparency = 1
3967 frame.Active = true
3968
3969 local menu = nil
3970 local arrow = nil
3971 local expanded = false
3972 local margin = DropDown.BorderSizePixel;
3973
3974 --[[
3975 local button = Instance.new("TextButton")
3976 button.Font = Row.Font
3977 button.FontSize = Row.FontSize
3978 button.TextXAlignment = Row.TextXAlignment
3979 button.BackgroundTransparency = 1
3980 button.TextColor3 = Row.TextColor
3981 if readOnly then
3982 button.TextColor3 = Row.TextLockedColor
3983 end
3984 button.Text = currentChoice
3985 button.Size = UDim2.new(1, -2 * Styles.Margin, 1, 0)
3986 button.Position = UDim2.new(0, Styles.Margin, 0, 0)
3987 button.Parent = frame
3988 --]]
3989
3990 local function hideMenu()
3991 expanded = false
3992 --showArrow(DropDown.ArrowColor)
3993 if frame then
3994 frame:Destroy()
3995 DestroyRightClick()
3996 end
3997 end
3998
3999 local function showMenu()
4000 expanded = true
4001 menu = Instance.new("Frame")
4002 menu.Size = UDim2.new(0, 200, 0, #choices * DropDown.Height)
4003 menu.Position = UDim2.new(0, margin, 0, 5)
4004 menu.BackgroundTransparency = 0
4005 menu.BackgroundColor3 = DropDown.BackColor
4006 menu.BorderColor3 = DropDown.BorderColor
4007 menu.BorderSizePixel = DropDown.BorderSizePixel
4008 menu.Active = true
4009 menu.ZIndex = 5
4010 menu.Parent = frame
4011
4012 --local parentFrameHeight = script.Parent.List.Size.Y.Offset
4013 --local rowHeight = mouse.Y
4014 --if (rowHeight + menu.Size.Y.Offset) > parentFrameHeight then
4015 -- menu.Position = UDim2.new(0, margin, 0, -1 * (#choices * DropDown.Height) - margin)
4016 --end
4017
4018 local function choice(name)
4019 onClick(name)
4020 hideMenu()
4021 end
4022
4023 for i,name in pairs(choices) do
4024 local option = CreateRightClickMenuItem(name, function()
4025 choice(name)
4026 end)
4027 option.Size = UDim2.new(1, 0, 0, 20)
4028 option.Position = UDim2.new(0, 0, 0, (i - 1) * DropDown.Height)
4029 option.ZIndex = menu.ZIndex
4030 option.Parent = menu
4031 end
4032 end
4033
4034
4035 showMenu()
4036
4037
4038 return frame
4039end
4040
4041function checkMouseInGui(gui)
4042 if gui == nil then return false end
4043 local plrMouse = game.Players.LocalPlayer:GetMouse()
4044 local guiPosition = gui.AbsolutePosition
4045 local guiSize = gui.AbsoluteSize
4046
4047 if plrMouse.X >= guiPosition.x and plrMouse.X <= guiPosition.x + guiSize.x and plrMouse.Y >= guiPosition.y and plrMouse.Y <= guiPosition.y + guiSize.y then
4048 return true
4049 else
4050 return false
4051 end
4052end
4053
4054local clipboard = {}
4055local function delete(o)
4056 o.Parent = nil
4057end
4058
4059local getTextWidth do
4060 local text = Create('TextLabel',{
4061 Name = "TextWidth";
4062 TextXAlignment = 'Left';
4063 TextYAlignment = 'Center';
4064 Font = FONT;
4065 FontSize = FONT_SIZE;
4066 Text = "";
4067 Position = UDim2.new(0,0,0,0);
4068 Size = UDim2.new(1,0,1,0);
4069 Visible = false;
4070 Parent = explorerPanel;
4071 })
4072 function getTextWidth(s)
4073 text.Text = s
4074 return text.TextBounds.x
4075 end
4076end
4077
4078local nameScanned = false
4079-- Holds the game tree converted to a list.
4080local TreeList = {}
4081-- Matches objects to their tree node representation.
4082local NodeLookup = {}
4083
4084local nodeWidth = 0
4085
4086local QuickButtons = {}
4087
4088function filteringWorkspace()
4089 if explorerFilter.Text ~= "" and explorerFilter.Text ~= "Filter Workspace" then
4090 return true
4091 end
4092 return false
4093end
4094
4095function lookForAName(obj,name)
4096 for i,v in pairs(obj:GetChildren()) do
4097 if string.find(string.lower(v.Name),string.lower(name)) then nameScanned = true end
4098 lookForAName(v,name)
4099 end
4100end
4101
4102function scanName(obj)
4103 nameScanned = false
4104 if string.find(string.lower(obj.Name),string.lower(explorerFilter.Text)) then
4105 nameScanned = true
4106 else
4107 lookForAName(obj,explorerFilter.Text)
4108 end
4109 return nameScanned
4110end
4111
4112function updateActions()
4113 for i,v in pairs(QuickButtons) do
4114 if v.Cond() then
4115 v.Toggle(true)
4116 else
4117 v.Toggle(false)
4118 end
4119 end
4120end
4121
4122local updateList,rawUpdateList,updateScroll,rawUpdateSize do
4123 local function r(t)
4124 for i = 1,#t do
4125 if not filteringWorkspace() or scanName(t[i].Object) then
4126 TreeList[#TreeList+1] = t[i]
4127
4128 local w = (t[i].Depth)*(2+ENTRY_PADDING+GUI_SIZE) + 2 + ENTRY_SIZE + 4 + getTextWidth(t[i].Object.Name) + 4
4129 if w > nodeWidth then
4130 nodeWidth = w
4131 end
4132 if t[i].Expanded or filteringWorkspace() then
4133 r(t[i])
4134 end
4135 end
4136 end
4137 end
4138
4139 function rawUpdateSize()
4140 scrollBarH.TotalSpace = nodeWidth
4141 scrollBarH.VisibleSpace = listFrame.AbsoluteSize.x
4142 scrollBarH:Update()
4143 local visible = scrollBarH:CanScrollDown() or scrollBarH:CanScrollUp()
4144 scrollBarH.GUI.Visible = visible
4145
4146 listFrame.Size = UDim2.new(1,-GUI_SIZE,1,-GUI_SIZE*(visible and 1 or 0) - HEADER_SIZE)
4147
4148 scrollBar.VisibleSpace = math.ceil(listFrame.AbsoluteSize.y/ENTRY_BOUND)
4149 scrollBar.GUI.Size = UDim2.new(0,GUI_SIZE,1,-GUI_SIZE*(visible and 1 or 0) - HEADER_SIZE)
4150
4151 scrollBar.TotalSpace = #TreeList+1
4152 scrollBar:Update()
4153 end
4154
4155 function rawUpdateList()
4156 -- Clear then repopulate the entire list. It appears to be fast enough.
4157 TreeList = {}
4158 nodeWidth = 0
4159 r(NodeLookup[workspace.Parent:GetDebugId(10)])
4160 if DexStorageEnabled then
4161 r(NodeLookup[DexStorage:GetDebugId(10)])
4162 end
4163 if NilStorageEnabled then
4164 r(NodeLookup[NilStorage:GetDebugId(10)])
4165 end
4166 rawUpdateSize()
4167 updateActions()
4168 end
4169
4170 -- Adding or removing large models will cause many updates to occur. We
4171 -- can reduce the number of updates by creating a delay, then dropping any
4172 -- updates that occur during the delay.
4173 local updatingList = false
4174 function updateList()
4175 if updatingList then return end
4176 updatingList = true
4177 wait(0.25)
4178 updatingList = false
4179 rawUpdateList()
4180 end
4181
4182 local updatingScroll = false
4183 function updateScroll()
4184 if updatingScroll then return end
4185 updatingScroll = true
4186 wait(0.25)
4187 updatingScroll = false
4188 scrollBar:Update()
4189 end
4190end
4191
4192local Selection do
4193 local bindGetSelection = explorerPanel:FindFirstChild("GetSelection")
4194 if not bindGetSelection then
4195 bindGetSelection = Create('BindableFunction',{Name = "GetSelection"})
4196 bindGetSelection.Parent = explorerPanel
4197 end
4198
4199 local bindSetSelection = explorerPanel:FindFirstChild("SetSelection")
4200 if not bindSetSelection then
4201 bindSetSelection = Create('BindableFunction',{Name = "SetSelection"})
4202 bindSetSelection.Parent = explorerPanel
4203 end
4204
4205 local bindSelectionChanged = explorerPanel:FindFirstChild("SelectionChanged")
4206 if not bindSelectionChanged then
4207 bindSelectionChanged = Create('BindableEvent',{Name = "SelectionChanged"})
4208 bindSelectionChanged.Parent = explorerPanel
4209 end
4210
4211 local SelectionList = {}
4212 local SelectionSet = {}
4213 local Updates = true
4214 Selection = {
4215 Selected = SelectionSet;
4216 List = SelectionList;
4217 }
4218
4219 local function addObject(object)
4220 -- list update
4221 local lupdate = false
4222 -- scroll update
4223 local supdate = false
4224
4225 if not SelectionSet[object] then
4226 local node = NodeLookup[object:GetDebugId(10)]
4227 if node then
4228 table.insert(SelectionList,object)
4229 SelectionSet[object] = true
4230 node.Selected = true
4231
4232 -- expand all ancestors so that selected node becomes visible
4233 node = node.Parent
4234 while node do
4235 if not node.Expanded then
4236 node.Expanded = true
4237 lupdate = true
4238 end
4239 node = node.Parent
4240 end
4241 supdate = true
4242 end
4243 end
4244 return lupdate,supdate
4245 end
4246
4247 function Selection:Set(objects)
4248 local lupdate = false
4249 local supdate = false
4250
4251 if #SelectionList > 0 then
4252 for i = 1,#SelectionList do
4253 local object = SelectionList[i]
4254 local node = NodeLookup[object:GetDebugId(10)]
4255 if node then
4256 node.Selected = false
4257 SelectionSet[object] = nil
4258 end
4259 end
4260
4261 SelectionList = {}
4262 Selection.List = SelectionList
4263 supdate = true
4264 end
4265
4266 for i = 1,#objects do
4267 local l,s = addObject(objects[i])
4268 lupdate = l or lupdate
4269 supdate = s or supdate
4270 end
4271
4272 if lupdate then
4273 rawUpdateList()
4274 supdate = true
4275 elseif supdate then
4276 scrollBar:Update()
4277 end
4278
4279 if supdate then
4280 bindSelectionChanged:Fire()
4281 updateActions()
4282 end
4283 end
4284
4285 function Selection:Add(object)
4286 local l,s = addObject(object)
4287 if l then
4288 rawUpdateList()
4289 if Updates then
4290 bindSelectionChanged:Fire()
4291 updateActions()
4292 end
4293 elseif s then
4294 scrollBar:Update()
4295 if Updates then
4296 bindSelectionChanged:Fire()
4297 updateActions()
4298 end
4299 end
4300 end
4301
4302 function Selection:StopUpdates()
4303 Updates = false
4304 end
4305
4306 function Selection:ResumeUpdates()
4307 Updates = true
4308 bindSelectionChanged:Fire()
4309 updateActions()
4310 end
4311
4312 function Selection:Remove(object,noupdate)
4313 if SelectionSet[object] then
4314 local node = NodeLookup[object:GetDebugId(10)]
4315 if node then
4316 node.Selected = false
4317 SelectionSet[object] = nil
4318 for i = 1,#SelectionList do
4319 if SelectionList[i] == object then
4320 table.remove(SelectionList,i)
4321 break
4322 end
4323 end
4324
4325 if not noupdate then
4326 scrollBar:Update()
4327 end
4328 bindSelectionChanged:Fire()
4329 updateActions()
4330 end
4331 end
4332 end
4333
4334 function Selection:Get()
4335 local list = {}
4336 for i = 1,#SelectionList do
4337 list[i] = SelectionList[i]
4338 end
4339 return list
4340 end
4341
4342 bindSetSelection.OnInvoke = function(...)
4343 Selection:Set(...)
4344 end
4345
4346 bindGetSelection.OnInvoke = function()
4347 return Selection:Get()
4348 end
4349end
4350
4351function CreateCaution(title,msg)
4352 local newCaution = CautionWindow:Clone()
4353 newCaution.Title.Text = title
4354 newCaution.MainWindow.Desc.Text = msg
4355 newCaution.Parent = explorerPanel.Parent
4356 newCaution.Visible = true
4357 newCaution.MainWindow.Ok.MouseButton1Up:connect(function()
4358 newCaution:Destroy()
4359 end)
4360end
4361
4362function CreateTableCaution(title,msg)
4363 if type(msg) ~= "table" then return CreateCaution(title,tostring(msg)) end
4364 local newCaution = TableCautionWindow:Clone()
4365 newCaution.Title.Text = title
4366
4367 local TableList = newCaution.MainWindow.TableResults
4368 local TableTemplate = newCaution.MainWindow.TableTemplate
4369
4370 for i,v in pairs(msg) do
4371 local newResult = TableTemplate:Clone()
4372 newResult.Type.Text = type(v)
4373 newResult.Value.Text = tostring(v)
4374 newResult.Position = UDim2.new(0,0,0,#TableList:GetChildren() * 20)
4375 newResult.Parent = TableList
4376 TableList.CanvasSize = UDim2.new(0,0,0,#TableList:GetChildren() * 20)
4377 newResult.Visible = true
4378 end
4379 newCaution.Parent = explorerPanel.Parent
4380 newCaution.Visible = true
4381 newCaution.MainWindow.Ok.MouseButton1Up:connect(function()
4382 newCaution:Destroy()
4383 end)
4384end
4385
4386local function Split(str, delimiter)
4387 local start = 1
4388 local t = {}
4389 while true do
4390 local pos = string.find (str, delimiter, start, true)
4391 if not pos then
4392 break
4393 end
4394 table.insert (t, string.sub (str, start, pos - 1))
4395 start = pos + string.len (delimiter)
4396 end
4397 table.insert (t, string.sub (str, start))
4398 return t
4399end
4400
4401local function ToValue(value,type)
4402 if type == "Vector2" then
4403 local list = Split(value,",")
4404 if #list < 2 then return nil end
4405 local x = tonumber(list[1]) or 0
4406 local y = tonumber(list[2]) or 0
4407 return Vector2.new(x,y)
4408 elseif type == "Vector3" then
4409 local list = Split(value,",")
4410 if #list < 3 then return nil end
4411 local x = tonumber(list[1]) or 0
4412 local y = tonumber(list[2]) or 0
4413 local z = tonumber(list[3]) or 0
4414 return Vector3.new(x,y,z)
4415 elseif type == "Color3" then
4416 local list = Split(value,",")
4417 if #list < 3 then return nil end
4418 local r = tonumber(list[1]) or 0
4419 local g = tonumber(list[2]) or 0
4420 local b = tonumber(list[3]) or 0
4421 return Color3.new(r/255,g/255, b/255)
4422 elseif type == "UDim2" then
4423 local list = Split(string.gsub(string.gsub(value, "{", ""),"}",""),",")
4424 if #list < 4 then return nil end
4425 local xScale = tonumber(list[1]) or 0
4426 local xOffset = tonumber(list[2]) or 0
4427 local yScale = tonumber(list[3]) or 0
4428 local yOffset = tonumber(list[4]) or 0
4429 return UDim2.new(xScale, xOffset, yScale, yOffset)
4430 elseif type == "Number" then
4431 return tonumber(value)
4432 elseif type == "String" then
4433 return value
4434 elseif type == "NumberRange" then
4435 local list = Split(value,",")
4436 if #list == 1 then
4437 if tonumber(list[1]) == nil then return nil end
4438 local newVal = tonumber(list[1]) or 0
4439 return NumberRange.new(newVal)
4440 end
4441 if #list < 2 then return nil end
4442 local x = tonumber(list[1]) or 0
4443 local y = tonumber(list[2]) or 0
4444 return NumberRange.new(x,y)
4445 elseif type == "Script" then
4446 local success,err = ypcall(function()
4447 _G.D_E_X_DONOTUSETHISPLEASE = nil
4448 loadstring(
4449 "_G.D_E_X_DONOTUSETHISPLEASE = "..value
4450 )()
4451 return _G.D_E_X_DONOTUSETHISPLEASE
4452 end)
4453 if err then
4454 return nil
4455 end
4456 else
4457 return nil
4458 end
4459end
4460
4461local function ToPropValue(value,type)
4462 if type == "Vector2" then
4463 local list = Split(value,",")
4464 if #list < 2 then return nil end
4465 local x = tonumber(list[1]) or 0
4466 local y = tonumber(list[2]) or 0
4467 return Vector2.new(x,y)
4468 elseif type == "Vector3" then
4469 local list = Split(value,",")
4470 if #list < 3 then return nil end
4471 local x = tonumber(list[1]) or 0
4472 local y = tonumber(list[2]) or 0
4473 local z = tonumber(list[3]) or 0
4474 return Vector3.new(x,y,z)
4475 elseif type == "Color3" then
4476 local list = Split(value,",")
4477 if #list < 3 then return nil end
4478 local r = tonumber(list[1]) or 0
4479 local g = tonumber(list[2]) or 0
4480 local b = tonumber(list[3]) or 0
4481 return Color3.new(r/255,g/255, b/255)
4482 elseif type == "UDim2" then
4483 local list = Split(string.gsub(string.gsub(value, "{", ""),"}",""),",")
4484 if #list < 4 then return nil end
4485 local xScale = tonumber(list[1]) or 0
4486 local xOffset = tonumber(list[2]) or 0
4487 local yScale = tonumber(list[3]) or 0
4488 local yOffset = tonumber(list[4]) or 0
4489 return UDim2.new(xScale, xOffset, yScale, yOffset)
4490 elseif type == "Content" then
4491 return value
4492 elseif type == "float" or type == "int" or type == "double" then
4493 return tonumber(value)
4494 elseif type == "string" then
4495 return value
4496 elseif type == "NumberRange" then
4497 local list = Split(value,",")
4498 if #list == 1 then
4499 if tonumber(list[1]) == nil then return nil end
4500 local newVal = tonumber(list[1]) or 0
4501 return NumberRange.new(newVal)
4502 end
4503 if #list < 2 then return nil end
4504 local x = tonumber(list[1]) or 0
4505 local y = tonumber(list[2]) or 0
4506 return NumberRange.new(x,y)
4507 elseif string.sub(value,1,4) == "Enum" then
4508 local getEnum = value
4509 while true do
4510 local x,y = string.find(getEnum,".")
4511 if y then
4512 getEnum = string.sub(getEnum,y+1)
4513 else
4514 break
4515 end
4516 end
4517 print(getEnum)
4518 return getEnum
4519 else
4520 return nil
4521 end
4522end
4523
4524function PromptRemoteCaller(inst)
4525 if CurrentRemoteWindow then
4526 CurrentRemoteWindow:Destroy()
4527 CurrentRemoteWindow = nil
4528 end
4529 CurrentRemoteWindow = RemoteWindow:Clone()
4530 CurrentRemoteWindow.Parent = explorerPanel.Parent
4531 CurrentRemoteWindow.Visible = true
4532
4533 local displayValues = false
4534
4535 local ArgumentList = CurrentRemoteWindow.MainWindow.Arguments
4536 local ArgumentTemplate = CurrentRemoteWindow.MainWindow.ArgumentTemplate
4537
4538 if inst:IsA("RemoteEvent") then
4539 CurrentRemoteWindow.Title.Text = "Fire Event"
4540 CurrentRemoteWindow.MainWindow.Ok.Text = "Fire"
4541 CurrentRemoteWindow.MainWindow.DisplayReturned.Visible = false
4542 CurrentRemoteWindow.MainWindow.Desc2.Visible = false
4543 end
4544
4545 local newArgument = ArgumentTemplate:Clone()
4546 newArgument.Parent = ArgumentList
4547 newArgument.Visible = true
4548 newArgument.Type.MouseButton1Down:connect(function()
4549 createDDown(newArgument.Type,function(choice)
4550 newArgument.Type.Text = choice
4551 end,"Script","Number","String","Color3","Vector3","Vector2","UDim2","NumberRange")
4552 end)
4553
4554 CurrentRemoteWindow.MainWindow.Ok.MouseButton1Up:connect(function()
4555 if CurrentRemoteWindow and inst.Parent ~= nil then
4556 local MyArguments = {}
4557 for i,v in pairs(ArgumentList:GetChildren()) do
4558 table.insert(MyArguments,ToValue(v.Value.Text,v.Type.Text))
4559 end
4560 if inst:IsA("RemoteFunction") then
4561 if displayValues then
4562 spawn(function()
4563 local myResults = inst:InvokeServer(unpack(MyArguments))
4564 if myResults then
4565 CreateTableCaution("Remote Caller",myResults)
4566 else
4567 CreateCaution("Remote Caller","This remote did not return anything.")
4568 end
4569 end)
4570 else
4571 spawn(function()
4572 inst:InvokeServer(unpack(MyArguments))
4573 end)
4574 end
4575 else
4576 inst:FireServer(unpack(MyArguments))
4577 end
4578 CurrentRemoteWindow:Destroy()
4579 CurrentRemoteWindow = nil
4580 end
4581 end)
4582
4583 CurrentRemoteWindow.MainWindow.Add.MouseButton1Up:connect(function()
4584 if CurrentRemoteWindow then
4585 local newArgument = ArgumentTemplate:Clone()
4586 newArgument.Position = UDim2.new(0,0,0,#ArgumentList:GetChildren() * 20)
4587 newArgument.Parent = ArgumentList
4588 ArgumentList.CanvasSize = UDim2.new(0,0,0,#ArgumentList:GetChildren() * 20)
4589 newArgument.Visible = true
4590 newArgument.Type.MouseButton1Down:connect(function()
4591 createDDown(newArgument.Type,function(choice)
4592 newArgument.Type.Text = choice
4593 end,"Script","Number","String","Color3","Vector3","Vector2","UDim2","NumberRange")
4594 end)
4595 end
4596 end)
4597
4598 CurrentRemoteWindow.MainWindow.Subtract.MouseButton1Up:connect(function()
4599 if CurrentRemoteWindow then
4600 if #ArgumentList:GetChildren() > 1 then
4601 ArgumentList:GetChildren()[#ArgumentList:GetChildren()]:Destroy()
4602 ArgumentList.CanvasSize = UDim2.new(0,0,0,#ArgumentList:GetChildren() * 20)
4603 end
4604 end
4605 end)
4606
4607 CurrentRemoteWindow.MainWindow.Cancel.MouseButton1Up:connect(function()
4608 if CurrentRemoteWindow then
4609 CurrentRemoteWindow:Destroy()
4610 CurrentRemoteWindow = nil
4611 end
4612 end)
4613
4614 CurrentRemoteWindow.MainWindow.DisplayReturned.MouseButton1Up:connect(function()
4615 if displayValues then
4616 displayValues = false
4617 CurrentRemoteWindow.MainWindow.DisplayReturned.enabled.Visible = false
4618 else
4619 displayValues = true
4620 CurrentRemoteWindow.MainWindow.DisplayReturned.enabled.Visible = true
4621 end
4622 end)
4623end
4624
4625function PromptSaveInstance(inst)
4626 if not SaveInstance and not _G.SaveInstance then CreateCaution("SaveInstance Missing","You do not have the SaveInstance function installed. Please go to RaspberryPi's thread to retrieve it.") return end
4627 if CurrentSaveInstanceWindow then
4628 CurrentSaveInstanceWindow:Destroy()
4629 CurrentSaveInstanceWindow = nil
4630 if explorerPanel.Parent:FindFirstChild("SaveInstanceOverwriteCaution") then
4631 explorerPanel.Parent.SaveInstanceOverwriteCaution:Destroy()
4632 end
4633 end
4634 CurrentSaveInstanceWindow = SaveInstanceWindow:Clone()
4635 CurrentSaveInstanceWindow.Parent = explorerPanel.Parent
4636 CurrentSaveInstanceWindow.Visible = true
4637
4638 local filename = CurrentSaveInstanceWindow.MainWindow.FileName
4639 local saveObjects = true
4640 local overwriteCaution = false
4641
4642 CurrentSaveInstanceWindow.MainWindow.Save.MouseButton1Up:connect(function()
4643 if readfile and getelysianpath then
4644 if readfile(getelysianpath()..filename.Text..".rbxmx") then
4645 if not overwriteCaution then
4646 overwriteCaution = true
4647 local newCaution = ConfirmationWindow:Clone()
4648 newCaution.Name = "SaveInstanceOverwriteCaution"
4649 newCaution.MainWindow.Desc.Text = "The file, "..filename.Text..".rbxmx, already exists. Overwrite?"
4650 newCaution.Parent = explorerPanel.Parent
4651 newCaution.Visible = true
4652 newCaution.MainWindow.Yes.MouseButton1Up:connect(function()
4653 ypcall(function()
4654 SaveInstance(inst,filename.Text..".rbxmx",not saveObjects)
4655 end)
4656 overwriteCaution = false
4657 newCaution:Destroy()
4658 if CurrentSaveInstanceWindow then
4659 CurrentSaveInstanceWindow:Destroy()
4660 CurrentSaveInstanceWindow = nil
4661 end
4662 end)
4663 newCaution.MainWindow.No.MouseButton1Up:connect(function()
4664 overwriteCaution = false
4665 newCaution:Destroy()
4666 end)
4667 end
4668 else
4669 ypcall(function()
4670 SaveInstance(inst,filename.Text..".rbxmx",not saveObjects)
4671 end)
4672 if CurrentSaveInstanceWindow then
4673 CurrentSaveInstanceWindow:Destroy()
4674 CurrentSaveInstanceWindow = nil
4675 if explorerPanel.Parent:FindFirstChild("SaveInstanceOverwriteCaution") then
4676 explorerPanel.Parent.SaveInstanceOverwriteCaution:Destroy()
4677 end
4678 end
4679 end
4680 else
4681 ypcall(function()
4682 if SaveInstance then
4683 SaveInstance(inst,filename.Text..".rbxmx",not saveObjects)
4684 else
4685 _G.SaveInstance(inst,filename.Text,not saveObjects)
4686 end
4687 end)
4688 if CurrentSaveInstanceWindow then
4689 CurrentSaveInstanceWindow:Destroy()
4690 CurrentSaveInstanceWindow = nil
4691 if explorerPanel.Parent:FindFirstChild("SaveInstanceOverwriteCaution") then
4692 explorerPanel.Parent.SaveInstanceOverwriteCaution:Destroy()
4693 end
4694 end
4695 end
4696 end)
4697 CurrentSaveInstanceWindow.MainWindow.Cancel.MouseButton1Up:connect(function()
4698 if CurrentSaveInstanceWindow then
4699 CurrentSaveInstanceWindow:Destroy()
4700 CurrentSaveInstanceWindow = nil
4701 if explorerPanel.Parent:FindFirstChild("SaveInstanceOverwriteCaution") then
4702 explorerPanel.Parent.SaveInstanceOverwriteCaution:Destroy()
4703 end
4704 end
4705 end)
4706 CurrentSaveInstanceWindow.MainWindow.SaveObjects.MouseButton1Up:connect(function()
4707 if saveObjects then
4708 saveObjects = false
4709 CurrentSaveInstanceWindow.MainWindow.SaveObjects.enabled.Visible = false
4710 else
4711 saveObjects = true
4712 CurrentSaveInstanceWindow.MainWindow.SaveObjects.enabled.Visible = true
4713 end
4714 end)
4715end
4716
4717function DestroyRightClick()
4718 if currentRightClickMenu then
4719 currentRightClickMenu:Destroy()
4720 currentRightClickMenu = nil
4721 end
4722 if CurrentInsertObjectWindow and CurrentInsertObjectWindow.Visible then
4723 CurrentInsertObjectWindow.Visible = false
4724 end
4725end
4726
4727function rightClickMenu(sObj)
4728 local mouse = game.Players.LocalPlayer:GetMouse()
4729
4730 currentRightClickMenu = CreateRightClickMenu(
4731 {"Cut","Copy","Paste Into","Duplicate","Delete","Group","Ungroup","Select Children","Teleport To","Insert Part","Insert Object","View Script","Save Instance","Call Function","Call Remote"},
4732 "",
4733 false,
4734 function(option)
4735 if option == "Cut" then
4736 if not Option.Modifiable then return end
4737 clipboard = {}
4738 local list = Selection.List
4739 local cut = {}
4740 for i = 1,#list do
4741 local obj = list[i]:Clone()
4742 if obj then
4743 table.insert(clipboard,obj)
4744 table.insert(cut,list[i])
4745 end
4746 end
4747 for i = 1,#cut do
4748 pcall(delete,cut[i])
4749 end
4750 updateActions()
4751 elseif option == "Copy" then
4752 if not Option.Modifiable then return end
4753 clipboard = {}
4754 local list = Selection.List
4755 for i = 1,#list do
4756 table.insert(clipboard,list[i]:Clone())
4757 end
4758 updateActions()
4759 elseif option == "Paste Into" then
4760 if not Option.Modifiable then return end
4761 local parent = Selection.List[1] or workspace
4762 for i = 1,#clipboard do
4763 clipboard[i]:Clone().Parent = parent
4764 end
4765 elseif option == "Duplicate" then
4766 if not Option.Modifiable then return end
4767 local list = Selection:Get()
4768 for i = 1,#list do
4769 list[i]:Clone().Parent = Selection.List[1].Parent or workspace
4770 end
4771 elseif option == "Delete" then
4772 if not Option.Modifiable then return end
4773 local list = Selection:Get()
4774 for i = 1,#list do
4775 pcall(delete,list[i])
4776 end
4777 Selection:Set({})
4778 elseif option == "Group" then
4779 if not Option.Modifiable then return end
4780 local newModel = Instance.new("Model")
4781 local list = Selection:Get()
4782 newModel.Parent = Selection.List[1].Parent or workspace
4783 for i = 1,#list do
4784 list[i].Parent = newModel
4785 end
4786 Selection:Set({})
4787 elseif option == "Ungroup" then
4788 if not Option.Modifiable then return end
4789 local ungrouped = {}
4790 local list = Selection:Get()
4791 for i = 1,#list do
4792 if list[i]:IsA("Model") then
4793 for i2,v2 in pairs(list[i]:GetChildren()) do
4794 v2.Parent = list[i].Parent or workspace
4795 table.insert(ungrouped,v2)
4796 end
4797 pcall(delete,list[i])
4798 end
4799 end
4800 Selection:Set({})
4801 if SettingsRemote:Invoke("SelectUngrouped") then
4802 for i,v in pairs(ungrouped) do
4803 Selection:Add(v)
4804 end
4805 end
4806 elseif option == "Select Children" then
4807 if not Option.Modifiable then return end
4808 local list = Selection:Get()
4809 Selection:Set({})
4810 Selection:StopUpdates()
4811 for i = 1,#list do
4812 for i2,v2 in pairs(list[i]:GetChildren()) do
4813 Selection:Add(v2)
4814 end
4815 end
4816 Selection:ResumeUpdates()
4817 elseif option == "Teleport To" then
4818 if not Option.Modifiable then return end
4819 local list = Selection:Get()
4820 for i = 1,#list do
4821 if list[i]:IsA("BasePart") then
4822 pcall(function()
4823 game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = list[i].CFrame
4824 end)
4825 break
4826 end
4827 end
4828 elseif option == "Insert Part" then
4829 if not Option.Modifiable then return end
4830 local insertedParts = {}
4831 local list = Selection:Get()
4832 for i = 1,#list do
4833 pcall(function()
4834 local newPart = Instance.new("Part")
4835 newPart.Parent = list[i]
4836 newPart.CFrame = CFrame.new(game.Players.LocalPlayer.Character.Head.Position) + Vector3.new(0,3,0)
4837 table.insert(insertedParts,newPart)
4838 end)
4839 end
4840 elseif option == "Save Instance" then
4841 if not Option.Modifiable then return end
4842 local list = Selection:Get()
4843 if #list == 1 then
4844 list[1].Archivable = true
4845 ypcall(function()PromptSaveInstance(list[1]:Clone())end)
4846 elseif #list > 1 then
4847 local newModel = Instance.new("Model")
4848 newModel.Name = "SavedInstances"
4849 for i = 1,#list do
4850 ypcall(function()
4851 list[i].Archivable = true
4852 list[i]:Clone().Parent = newModel
4853 end)
4854 end
4855 PromptSaveInstance(newModel)
4856 end
4857 elseif option == "Call Remote" then
4858 if not Option.Modifiable then return end
4859 local list = Selection:Get()
4860 for i = 1,#list do
4861 if list[i]:IsA("RemoteFunction") or list[i]:IsA("RemoteEvent") then
4862 PromptRemoteCaller(list[i])
4863 break
4864 end
4865 end
4866 elseif option == "View Script" then
4867 if not Option.Modifiable then return end
4868 local list = Selection:Get()
4869 for i = 1,#list do
4870 if list[i]:IsA("LocalScript") or list[i]:IsA("ModuleScript") then
4871 ScriptEditorEvent:Fire(list[i])
4872 end
4873 end
4874 end
4875 end)
4876 currentRightClickMenu.Parent = explorerPanel.Parent
4877 currentRightClickMenu.Position = UDim2.new(0,mouse.X,0,mouse.Y)
4878 if currentRightClickMenu.AbsolutePosition.X + currentRightClickMenu.AbsoluteSize.X > explorerPanel.AbsolutePosition.X + explorerPanel.AbsoluteSize.X then
4879 currentRightClickMenu.Position = UDim2.new(0, explorerPanel.AbsolutePosition.X + explorerPanel.AbsoluteSize.X - currentRightClickMenu.AbsoluteSize.X, 0, mouse.Y)
4880 end
4881end
4882
4883local function cancelReparentDrag()end
4884local function cancelSelectDrag()end
4885do
4886 local listEntries = {}
4887 local nameConnLookup = {}
4888
4889 local mouseDrag = Create('ImageButton',{
4890 Name = "MouseDrag";
4891 Position = UDim2.new(-0.25,0,-0.25,0);
4892 Size = UDim2.new(1.5,0,1.5,0);
4893 Transparency = 1;
4894 AutoButtonColor = false;
4895 Active = true;
4896 ZIndex = 10;
4897 })
4898 local function dragSelect(last,add,button)
4899 local connDrag
4900 local conUp
4901
4902 conDrag = mouseDrag.MouseMoved:connect(function(x,y)
4903 local pos = Vector2.new(x,y) - listFrame.AbsolutePosition
4904 local size = listFrame.AbsoluteSize
4905 if pos.x < 0 or pos.x > size.x or pos.y < 0 or pos.y > size.y then return end
4906
4907 local i = math.ceil(pos.y/ENTRY_BOUND) + scrollBar.ScrollIndex
4908 -- Mouse may have made a large step, so interpolate between the
4909 -- last index and the current.
4910 for n = i<last and i or last, i>last and i or last do
4911 local node = TreeList[n]
4912 if node then
4913 if add then
4914 Selection:Add(node.Object)
4915 else
4916 Selection:Remove(node.Object)
4917 end
4918 end
4919 end
4920 last = i
4921 end)
4922
4923 function cancelSelectDrag()
4924 mouseDrag.Parent = nil
4925 conDrag:disconnect()
4926 conUp:disconnect()
4927 function cancelSelectDrag()end
4928 end
4929
4930 conUp = mouseDrag[button]:connect(cancelSelectDrag)
4931
4932 mouseDrag.Parent = GetScreen(listFrame)
4933 end
4934
4935 local function dragReparent(object,dragGhost,clickPos,ghostOffset)
4936 local connDrag
4937 local conUp
4938 local conUp2
4939
4940 local parentIndex = nil
4941 local dragged = false
4942
4943 local parentHighlight = Create('Frame',{
4944 Transparency = 1;
4945 Visible = false;
4946 Create('Frame',{
4947 BorderSizePixel = 0;
4948 BackgroundColor3 = Color3.new(0,0,0);
4949 BackgroundTransparency = 0.1;
4950 Position = UDim2.new(0,0,0,0);
4951 Size = UDim2.new(1,0,0,1);
4952 });
4953 Create('Frame',{
4954 BorderSizePixel = 0;
4955 BackgroundColor3 = Color3.new(0,0,0);
4956 BackgroundTransparency = 0.1;
4957 Position = UDim2.new(1,0,0,0);
4958 Size = UDim2.new(0,1,1,0);
4959 });
4960 Create('Frame',{
4961 BorderSizePixel = 0;
4962 BackgroundColor3 = Color3.new(0,0,0);
4963 BackgroundTransparency = 0.1;
4964 Position = UDim2.new(0,0,1,0);
4965 Size = UDim2.new(1,0,0,1);
4966 });
4967 Create('Frame',{
4968 BorderSizePixel = 0;
4969 BackgroundColor3 = Color3.new(0,0,0);
4970 BackgroundTransparency = 0.1;
4971 Position = UDim2.new(0,0,0,0);
4972 Size = UDim2.new(0,1,1,0);
4973 });
4974 })
4975 SetZIndex(parentHighlight,9)
4976
4977 conDrag = mouseDrag.MouseMoved:connect(function(x,y)
4978 local dragPos = Vector2.new(x,y)
4979 if dragged then
4980 local pos = dragPos - listFrame.AbsolutePosition
4981 local size = listFrame.AbsoluteSize
4982
4983 parentIndex = nil
4984 parentHighlight.Visible = false
4985 if pos.x >= 0 and pos.x <= size.x and pos.y >= 0 and pos.y <= size.y + ENTRY_SIZE*2 then
4986 local i = math.ceil(pos.y/ENTRY_BOUND-2)
4987 local node = TreeList[i + scrollBar.ScrollIndex]
4988 if node and node.Object ~= object and not object:IsAncestorOf(node.Object) then
4989 parentIndex = i
4990 local entry = listEntries[i]
4991 if entry then
4992 parentHighlight.Visible = true
4993 parentHighlight.Position = UDim2.new(0,1,0,entry.AbsolutePosition.y-listFrame.AbsolutePosition.y)
4994 parentHighlight.Size = UDim2.new(0,size.x-4,0,entry.AbsoluteSize.y)
4995 end
4996 end
4997 end
4998
4999 dragGhost.Position = UDim2.new(0,dragPos.x+ghostOffset.x,0,dragPos.y+ghostOffset.y)
5000 elseif (clickPos-dragPos).magnitude > 8 then
5001 dragged = true
5002 SetZIndex(dragGhost,9)
5003 dragGhost.IndentFrame.Transparency = 0.25
5004 dragGhost.IndentFrame.EntryText.TextColor3 = GuiColor.TextSelected
5005 dragGhost.Position = UDim2.new(0,dragPos.x+ghostOffset.x,0,dragPos.y+ghostOffset.y)
5006 dragGhost.Parent = GetScreen(listFrame)
5007 parentHighlight.Parent = listFrame
5008 end
5009 end)
5010
5011 function cancelReparentDrag()
5012 mouseDrag.Parent = nil
5013 conDrag:disconnect()
5014 conUp:disconnect()
5015 conUp2:disconnect()
5016 dragGhost:Destroy()
5017 parentHighlight:Destroy()
5018 function cancelReparentDrag()end
5019 end
5020
5021 local wasSelected = Selection.Selected[object]
5022 if not wasSelected and Option.Selectable then
5023 Selection:Set({object})
5024 end
5025
5026 conUp = mouseDrag.MouseButton1Up:connect(function()
5027 cancelReparentDrag()
5028 if dragged then
5029 if parentIndex then
5030 local parentNode = TreeList[parentIndex + scrollBar.ScrollIndex]
5031 if parentNode then
5032 parentNode.Expanded = true
5033
5034 local parentObj = parentNode.Object
5035 local function parent(a,b)
5036 a.Parent = b
5037 end
5038 if Option.Selectable then
5039 local list = Selection.List
5040 for i = 1,#list do
5041 pcall(parent,list[i],parentObj)
5042 end
5043 else
5044 pcall(parent,object,parentObj)
5045 end
5046 end
5047 end
5048 else
5049 -- do selection click
5050 if wasSelected and Option.Selectable then
5051 Selection:Set({})
5052 end
5053 end
5054 end)
5055 conUp2 = mouseDrag.MouseButton2Down:connect(function()
5056 cancelReparentDrag()
5057 end)
5058
5059 mouseDrag.Parent = GetScreen(listFrame)
5060 end
5061
5062 local entryTemplate = Create('ImageButton',{
5063 Name = "Entry";
5064 Transparency = 1;
5065 AutoButtonColor = false;
5066 Position = UDim2.new(0,0,0,0);
5067 Size = UDim2.new(1,0,0,ENTRY_SIZE);
5068 Create('Frame',{
5069 Name = "IndentFrame";
5070 BackgroundTransparency = 1;
5071 BackgroundColor3 = GuiColor.Selected;
5072 BorderColor3 = GuiColor.BorderSelected;
5073 Position = UDim2.new(0,0,0,0);
5074 Size = UDim2.new(1,0,1,0);
5075 Create(Icon('ImageButton',0),{
5076 Name = "Expand";
5077 AutoButtonColor = false;
5078 Position = UDim2.new(0,-GUI_SIZE,0.5,-GUI_SIZE/2);
5079 Size = UDim2.new(0,GUI_SIZE,0,GUI_SIZE);
5080 });
5081 Create(Icon(nil,0),{
5082 Name = "ExplorerIcon";
5083 Position = UDim2.new(0,2+ENTRY_PADDING,0.5,-GUI_SIZE/2);
5084 Size = UDim2.new(0,GUI_SIZE,0,GUI_SIZE);
5085 });
5086 Create('TextLabel',{
5087 Name = "EntryText";
5088 BackgroundTransparency = 1;
5089 TextColor3 = GuiColor.Text;
5090 TextXAlignment = 'Left';
5091 TextYAlignment = 'Center';
5092 Font = FONT;
5093 FontSize = FONT_SIZE;
5094 Text = "";
5095 Position = UDim2.new(0,2+ENTRY_SIZE+4,0,0);
5096 Size = UDim2.new(1,-2,1,0);
5097 });
5098 });
5099 })
5100
5101 function scrollBar.UpdateCallback(self)
5102 for i = 1,self.VisibleSpace do
5103 local node = TreeList[i + self.ScrollIndex]
5104 if node then
5105 local entry = listEntries[i]
5106 if not entry then
5107 entry = Create(entryTemplate:Clone(),{
5108 Position = UDim2.new(0,2,0,ENTRY_BOUND*(i-1)+2);
5109 Size = UDim2.new(0,nodeWidth,0,ENTRY_SIZE);
5110 ZIndex = listFrame.ZIndex;
5111 })
5112 listEntries[i] = entry
5113
5114 local expand = entry.IndentFrame.Expand
5115 expand.MouseEnter:connect(function()
5116 local node = TreeList[i + self.ScrollIndex]
5117 if #node > 0 then
5118 if node.Expanded then
5119 Icon(expand,NODE_EXPANDED_OVER)
5120 else
5121 Icon(expand,NODE_COLLAPSED_OVER)
5122 end
5123 end
5124 end)
5125 expand.MouseLeave:connect(function()
5126 local node = TreeList[i + self.ScrollIndex]
5127 if #node > 0 then
5128 if node.Expanded then
5129 Icon(expand,NODE_EXPANDED)
5130 else
5131 Icon(expand,NODE_COLLAPSED)
5132 end
5133 end
5134 end)
5135 expand.MouseButton1Down:connect(function()
5136 local node = TreeList[i + self.ScrollIndex]
5137 if #node > 0 then
5138 node.Expanded = not node.Expanded
5139 if node.Object == explorerPanel.Parent and node.Expanded then
5140 CreateCaution("Warning","Please be careful when editing instances inside here, this is like the System32 of Dex and modifying objects here can break Dex.")
5141 end
5142 -- use raw update so the list updates instantly
5143 rawUpdateList()
5144 end
5145 end)
5146
5147 entry.MouseButton1Down:connect(function(x,y)
5148 local node = TreeList[i + self.ScrollIndex]
5149 DestroyRightClick()
5150 if GetAwaitRemote:Invoke() then
5151 bindSetAwaiting:Fire(node.Object)
5152 return
5153 end
5154
5155 if not HoldingShift then
5156 lastSelectedNode = i + self.ScrollIndex
5157 end
5158
5159 if HoldingShift and not filteringWorkspace() then
5160 if lastSelectedNode then
5161 if i + self.ScrollIndex - lastSelectedNode > 0 then
5162 Selection:StopUpdates()
5163 for i2 = 1, i + self.ScrollIndex - lastSelectedNode do
5164 local newNode = TreeList[lastSelectedNode + i2]
5165 if newNode then
5166 Selection:Add(newNode.Object)
5167 end
5168 end
5169 Selection:ResumeUpdates()
5170 else
5171 Selection:StopUpdates()
5172 for i2 = i + self.ScrollIndex - lastSelectedNode, 1 do
5173 local newNode = TreeList[lastSelectedNode + i2]
5174 if newNode then
5175 Selection:Add(newNode.Object)
5176 end
5177 end
5178 Selection:ResumeUpdates()
5179 end
5180 end
5181 return
5182 end
5183
5184 if HoldingCtrl then
5185 if Selection.Selected[node.Object] then
5186 Selection:Remove(node.Object)
5187 else
5188 Selection:Add(node.Object)
5189 end
5190 return
5191 end
5192 if Option.Modifiable then
5193 local pos = Vector2.new(x,y)
5194 dragReparent(node.Object,entry:Clone(),pos,entry.AbsolutePosition-pos)
5195 elseif Option.Selectable then
5196 if Selection.Selected[node.Object] then
5197 Selection:Set({})
5198 else
5199 Selection:Set({node.Object})
5200 end
5201 dragSelect(i+self.ScrollIndex,true,'MouseButton1Up')
5202 end
5203 end)
5204
5205 entry.MouseButton2Down:connect(function()
5206 if not Option.Selectable then return end
5207
5208 DestroyRightClick()
5209
5210 curSelect = entry
5211
5212 local node = TreeList[i + self.ScrollIndex]
5213
5214 if GetAwaitRemote:Invoke() then
5215 bindSetAwaiting:Fire(node.Object)
5216 return
5217 end
5218
5219 if not Selection.Selected[node.Object] then
5220 Selection:Set({node.Object})
5221 end
5222 end)
5223
5224
5225 entry.MouseButton2Up:connect(function()
5226 if not Option.Selectable then return end
5227
5228 local node = TreeList[i + self.ScrollIndex]
5229
5230 if checkMouseInGui(curSelect) then
5231 rightClickMenu(node.Object)
5232 end
5233 end)
5234
5235 entry.Parent = listFrame
5236 end
5237
5238 entry.Visible = true
5239
5240 local object = node.Object
5241
5242 -- update expand icon
5243 if #node == 0 then
5244 entry.IndentFrame.Expand.Visible = false
5245 elseif node.Expanded then
5246 Icon(entry.IndentFrame.Expand,NODE_EXPANDED)
5247 entry.IndentFrame.Expand.Visible = true
5248 else
5249 Icon(entry.IndentFrame.Expand,NODE_COLLAPSED)
5250 entry.IndentFrame.Expand.Visible = true
5251 end
5252
5253 -- update explorer icon
5254 Icon(entry.IndentFrame.ExplorerIcon,ExplorerIndex[object.ClassName] or 0)
5255
5256 -- update indentation
5257 local w = (node.Depth)*(2+ENTRY_PADDING+GUI_SIZE)
5258 entry.IndentFrame.Position = UDim2.new(0,w,0,0)
5259 entry.IndentFrame.Size = UDim2.new(1,-w,1,0)
5260
5261 -- update name change detection
5262 if nameConnLookup[entry:GetDebugId(10)] then
5263 nameConnLookup[entry:GetDebugId(10)]:disconnect()
5264 end
5265 local text = entry.IndentFrame.EntryText
5266 text.Text = object.Name
5267 nameConnLookup[entry:GetDebugId(10)] = node.Object.Changed:connect(function(p)
5268 if p == 'Name' then
5269 text.Text = object.Name
5270 end
5271 end)
5272
5273 -- update selection
5274 entry.IndentFrame.Transparency = node.Selected and 0 or 1
5275 text.TextColor3 = GuiColor[node.Selected and 'TextSelected' or 'Text']
5276
5277 entry.Size = UDim2.new(0,nodeWidth,0,ENTRY_SIZE)
5278 elseif listEntries[i] then
5279 listEntries[i].Visible = false
5280 end
5281 end
5282 for i = self.VisibleSpace+1,self.TotalSpace do
5283 local entry = listEntries[i]
5284 if entry then
5285 listEntries[i] = nil
5286 entry:Destroy()
5287 end
5288 end
5289 end
5290
5291 function scrollBarH.UpdateCallback(self)
5292 for i = 1,scrollBar.VisibleSpace do
5293 local node = TreeList[i + scrollBar.ScrollIndex]
5294 if node then
5295 local entry = listEntries[i]
5296 if entry then
5297 entry.Position = UDim2.new(0,2 - scrollBarH.ScrollIndex,0,ENTRY_BOUND*(i-1)+2)
5298 end
5299 end
5300 end
5301 end
5302
5303 Connect(listFrame.Changed,function(p)
5304 if p == 'AbsoluteSize' then
5305 rawUpdateSize()
5306 end
5307 end)
5308
5309 local wheelAmount = 6
5310 explorerPanel.MouseWheelForward:connect(function()
5311 if scrollBar.VisibleSpace - 1 > wheelAmount then
5312 scrollBar:ScrollTo(scrollBar.ScrollIndex - wheelAmount)
5313 else
5314 scrollBar:ScrollTo(scrollBar.ScrollIndex - scrollBar.VisibleSpace)
5315 end
5316 end)
5317 explorerPanel.MouseWheelBackward:connect(function()
5318 if scrollBar.VisibleSpace - 1 > wheelAmount then
5319 scrollBar:ScrollTo(scrollBar.ScrollIndex + wheelAmount)
5320 else
5321 scrollBar:ScrollTo(scrollBar.ScrollIndex + scrollBar.VisibleSpace)
5322 end
5323 end)
5324end
5325
5326----------------------------------------------------------------
5327----------------------------------------------------------------
5328----------------------------------------------------------------
5329----------------------------------------------------------------
5330---- Object detection
5331
5332-- Inserts `v` into `t` at `i`. Also sets `Index` field in `v`.
5333local function insert(t,i,v)
5334 for n = #t,i,-1 do
5335 local v = t[n]
5336 v.Index = n+1
5337 t[n+1] = v
5338 end
5339 v.Index = i
5340 t[i] = v
5341end
5342
5343-- Removes `i` from `t`. Also sets `Index` field in removed value.
5344local function remove(t,i)
5345 local v = t[i]
5346 for n = i+1,#t do
5347 local v = t[n]
5348 v.Index = n-1
5349 t[n-1] = v
5350 end
5351 t[#t] = nil
5352 v.Index = 0
5353 return v
5354end
5355
5356-- Returns how deep `o` is in the tree.
5357local function depth(o)
5358 local d = -1
5359 while o do
5360 o = o.Parent
5361 d = d + 1
5362 end
5363 return d
5364end
5365
5366
5367local connLookup = {}
5368
5369-- Returns whether a node would be present in the tree list
5370local function nodeIsVisible(node)
5371 local visible = true
5372 node = node.Parent
5373 while node and visible do
5374 visible = visible and node.Expanded
5375 node = node.Parent
5376 end
5377 return visible
5378end
5379
5380-- Removes an object's tree node. Called when the object stops existing in the
5381-- game tree.
5382local function removeObject(object)
5383 local objectNode = NodeLookup[object:GetDebugId(10)]
5384 if not objectNode then
5385 return
5386 end
5387
5388 local visible = nodeIsVisible(objectNode)
5389
5390 Selection:Remove(object,true)
5391
5392 local parent = objectNode.Parent
5393 remove(parent,objectNode.Index)
5394 NodeLookup[object:GetDebugId(10)] = nil
5395 connLookup[object:GetDebugId(10)]:disconnect()
5396 connLookup[object:GetDebugId(10)] = nil
5397
5398 if visible then
5399 updateList()
5400 elseif nodeIsVisible(parent) then
5401 updateScroll()
5402 end
5403end
5404
5405-- Moves a tree node to a new parent. Called when an existing object's parent
5406-- changes.
5407local function moveObject(object,parent)
5408 local objectNode = NodeLookup[object:GetDebugId(10)]
5409 if not objectNode then
5410 return
5411 end
5412
5413 local parentNode = NodeLookup[parent:GetDebugId(10)]
5414 if not parentNode then
5415 return
5416 end
5417
5418 local visible = nodeIsVisible(objectNode)
5419
5420 remove(objectNode.Parent,objectNode.Index)
5421 objectNode.Parent = parentNode
5422
5423 objectNode.Depth = depth(object)
5424 local function r(node,d)
5425 for i = 1,#node do
5426 node[i].Depth = d
5427 r(node[i],d+1)
5428 end
5429 end
5430 r(objectNode,objectNode.Depth+1)
5431
5432 insert(parentNode,#parentNode+1,objectNode)
5433
5434 if visible or nodeIsVisible(objectNode) then
5435 updateList()
5436 elseif nodeIsVisible(objectNode.Parent) then
5437 updateScroll()
5438 end
5439end
5440
5441-- ScriptContext['/Libraries/LibraryRegistration/LibraryRegistration']
5442-- This RobloxLocked object lets me index its properties for some reason
5443
5444local function check(object)
5445 return object.AncestryChanged
5446end
5447
5448-- Creates a new tree node from an object. Called when an object starts
5449-- existing in the game tree.
5450local function addObject(object,noupdate)
5451 if script then
5452 -- protect against naughty RobloxLocked objects
5453 local s = pcall(check,object)
5454 if not s then
5455 return
5456 end
5457 end
5458
5459 local parentNode = NodeLookup[object.Parent:GetDebugId(10)]
5460 if not parentNode then
5461 return
5462 end
5463
5464 local objectNode = {
5465 Object = object;
5466 Parent = parentNode;
5467 Index = 0;
5468 Expanded = false;
5469 Selected = false;
5470 Depth = depth(object);
5471 }
5472
5473 connLookup[object:GetDebugId(10)] = Connect(object.AncestryChanged,function(c,p)
5474 if c == object then
5475 if p == nil then
5476 removeObject(c)
5477 else
5478 moveObject(c,p)
5479 end
5480 end
5481 end)
5482
5483 NodeLookup[object:GetDebugId(10)] = objectNode
5484 insert(parentNode,#parentNode+1,objectNode)
5485
5486 if not noupdate then
5487 if nodeIsVisible(objectNode) then
5488 updateList()
5489 elseif nodeIsVisible(objectNode.Parent) then
5490 updateScroll()
5491 end
5492 end
5493end
5494
5495local function makeObject(obj,par)
5496 local newObject = Instance.new(obj.ClassName)
5497 for i,v in pairs(obj.Properties) do
5498 ypcall(function()
5499 local newProp
5500 newProp = ToPropValue(v.Value,v.Type)
5501 newObject[v.Name] = newProp
5502 end)
5503 end
5504 newObject.Parent = par
5505end
5506
5507local function writeObject(obj)
5508 local newObject = {ClassName = obj.ClassName, Properties = {}}
5509 for i,v in pairs(RbxApi.GetProperties(obj.className)) do
5510 if v["Name"] ~= "Parent" then
5511 print("thispassed")
5512 table.insert(newObject.Properties,{Name = v["Name"], Type = v["ValueType"], Value = tostring(obj[v["Name"]])})
5513 end
5514 end
5515 return newObject
5516end
5517
5518local function buildDexStorage()
5519 local localDexStorage
5520
5521 local success,err = ypcall(function()
5522 localDexStorage = game:GetObjects("rbxasset://DexStorage.rbxm")[1]
5523 end)
5524
5525 if success and localDexStorage then
5526 for i,v in pairs(localDexStorage:GetChildren()) do
5527 ypcall(function()
5528 v.Parent = DexStorageMain
5529 end)
5530 end
5531 end
5532
5533 updateDexStorageListeners()
5534 --[[
5535 local localDexStorage = readfile(getelysianpath().."DexStorage.txt")--game:GetService("CookiesService"):GetCookieValue("DexStorage")
5536 --local success,err = pcall(function()
5537 if localDexStorage then
5538 local objTable = game:GetService("HttpService"):JSONDecode(localDexStorage)
5539 for i,v in pairs(objTable) do
5540 makeObject(v,DexStorageMain)
5541 end
5542 end
5543 --end)
5544 --]]
5545end
5546
5547local dexStorageDebounce = false
5548local dexStorageListeners = {}
5549
5550local function updateDexStorage()
5551 if dexStorageDebounce then return end
5552 dexStorageDebounce = true
5553
5554 wait()
5555
5556 pcall(function()
5557 saveinstance("content//DexStorage.rbxm",DexStorageMain)
5558 end)
5559
5560 updateDexStorageListeners()
5561
5562 dexStorageDebounce = false
5563 --[[
5564 local success,err = ypcall(function()
5565 local objs = {}
5566 for i,v in pairs(DexStorageMain:GetChildren()) do
5567 table.insert(objs,writeObject(v))
5568 end
5569 writefile(getelysianpath().."DexStorage.txt",game:GetService("HttpService"):JSONEncode(objs))
5570 --game:GetService("CookiesService"):SetCookieValue("DexStorage",game:GetService("HttpService"):JSONEncode(objs))
5571 end)
5572 if err then
5573 CreateCaution("DexStorage Save Fail!","DexStorage broke! If you see this message, report to Raspberry Pi!")
5574 end
5575 print("hi")
5576 --]]
5577end
5578
5579function updateDexStorageListeners()
5580 for i,v in pairs(dexStorageListeners) do
5581 v:Disconnect()
5582 end
5583 dexStorageListeners = {}
5584 for i,v in pairs(DexStorageMain:GetChildren()) do
5585 pcall(function()
5586 local ev = v.Changed:connect(updateDexStorage)
5587 table.insert(dexStorageListeners,ev)
5588 end)
5589 end
5590end
5591
5592do
5593 NodeLookup[workspace.Parent:GetDebugId(10)] = {
5594 Object = workspace.Parent;
5595 Parent = nil;
5596 Index = 0;
5597 Expanded = true;
5598 }
5599
5600 if DexStorageEnabled then
5601 NodeLookup[DexStorage:GetDebugId(10)] = {
5602 Object = DexStorage;
5603 Parent = nil;
5604 Index = 0;
5605 Expanded = true;
5606 }
5607 end
5608
5609 if NilStorageEnabled then
5610 NodeLookup[NilStorage:GetDebugId(10)] = {
5611 Object = NilStorage;
5612 Parent = nil;
5613 Index = 0;
5614 Expanded = true;
5615 }
5616 end
5617
5618 Connect(game.DescendantAdded,addObject)
5619 Connect(game.DescendantRemoving,removeObject)
5620
5621 if DexStorageEnabled then
5622 --[[
5623 if readfile(getelysianpath().."DexStorage.txt") == nil then
5624 writefile(getelysianpath().."DexStorage.txt","")
5625 end
5626 --]]
5627
5628 buildDexStorage()
5629
5630 Connect(DexStorage.DescendantAdded,addObject)
5631 Connect(DexStorage.DescendantRemoving,removeObject)
5632
5633 Connect(DexStorage.DescendantAdded,updateDexStorage)
5634 Connect(DexStorage.DescendantRemoving,updateDexStorage)
5635 end
5636
5637 if NilStorageEnabled then
5638 Connect(NilStorage.DescendantAdded,addObject)
5639 Connect(NilStorage.DescendantRemoving,removeObject)
5640
5641 local currentTable = get_nil_instances()
5642
5643 spawn(function()
5644 while wait() do
5645 if #currentTable ~= #get_nil_instances() then
5646 currentTable = get_nil_instances()
5647 --NilStorageMain:ClearAllChildren()
5648 for i,v in pairs(get_nil_instances()) do
5649 if v ~= NilStorage and v ~= DexStorage then
5650 pcall(function()
5651 v.Parent = NilStorageMain
5652 end)
5653 --[[
5654 local newNil = v
5655 newNil.Archivable = true
5656 newNil:Clone().Parent = NilStorageMain
5657 --]]
5658 end
5659 end
5660 end
5661 end
5662 end)
5663 end
5664
5665 local function get(o)
5666 return o:GetChildren()
5667 end
5668
5669 local function r(o)
5670 pcall(function()
5671 local children = get(o)
5672 for i = 1,#children do
5673 addObject(children[i],true)
5674 r(children[i])
5675 end
5676 end)
5677 end
5678
5679 r(workspace.Parent)
5680 if DexStorageEnabled then
5681 r(DexStorage)
5682 end
5683 if NilStorageEnabled then
5684 r(NilStorage)
5685 end
5686
5687 scrollBar.VisibleSpace = math.ceil(listFrame.AbsoluteSize.y/ENTRY_BOUND)
5688 updateList()
5689end
5690
5691----------------------------------------------------------------
5692----------------------------------------------------------------
5693----------------------------------------------------------------
5694----------------------------------------------------------------
5695---- Actions
5696
5697local actionButtons do
5698 actionButtons = {}
5699
5700 local totalActions = 1
5701 local currentActions = totalActions
5702 local function makeButton(icon,over,name,vis,cond)
5703 local buttonEnabled = false
5704
5705 local button = Create(Icon('ImageButton',icon),{
5706 Name = name .. "Button";
5707 Visible = Option.Modifiable and Option.Selectable;
5708 Position = UDim2.new(1,-(GUI_SIZE+2)*currentActions+2,0.25,-GUI_SIZE/2);
5709 Size = UDim2.new(0,GUI_SIZE,0,GUI_SIZE);
5710 Parent = headerFrame;
5711 })
5712
5713 local tipText = Create('TextLabel',{
5714 Name = name .. "Text";
5715 Text = name;
5716 Visible = false;
5717 BackgroundTransparency = 1;
5718 TextXAlignment = 'Right';
5719 Font = FONT;
5720 FontSize = FONT_SIZE;
5721 Position = UDim2.new(0,0,0,0);
5722 Size = UDim2.new(1,-(GUI_SIZE+2)*totalActions,1,0);
5723 Parent = headerFrame;
5724 })
5725
5726
5727 button.MouseEnter:connect(function()
5728 if buttonEnabled then
5729 button.BackgroundTransparency = 0.9
5730 end
5731 --Icon(button,over)
5732 --tipText.Visible = true
5733 end)
5734 button.MouseLeave:connect(function()
5735 button.BackgroundTransparency = 1
5736 --Icon(button,icon)
5737 --tipText.Visible = false
5738 end)
5739
5740 currentActions = currentActions + 1
5741 actionButtons[#actionButtons+1] = {Obj = button,Cond = cond}
5742 QuickButtons[#actionButtons+1] = {Obj = button,Cond = cond, Toggle = function(on)
5743 if on then
5744 buttonEnabled = true
5745 Icon(button,over)
5746 else
5747 buttonEnabled = false
5748 Icon(button,icon)
5749 end
5750 end}
5751 return button
5752 end
5753
5754 --local clipboard = {}
5755 local function delete(o)
5756 o.Parent = nil
5757 end
5758
5759 makeButton(ACTION_EDITQUICKACCESS,ACTION_EDITQUICKACCESS,"Options",true,function()return true end).MouseButton1Click:connect(function()
5760
5761 end)
5762
5763
5764 -- DELETE
5765 makeButton(ACTION_DELETE,ACTION_DELETE_OVER,"Delete",true,function() return #Selection:Get() > 0 end).MouseButton1Click:connect(function()
5766 if not Option.Modifiable then return end
5767 local list = Selection:Get()
5768 for i = 1,#list do
5769 pcall(delete,list[i])
5770 end
5771 Selection:Set({})
5772 end)
5773
5774 -- PASTE
5775 makeButton(ACTION_PASTE,ACTION_PASTE_OVER,"Paste",true,function() return #Selection:Get() > 0 and #clipboard > 0 end).MouseButton1Click:connect(function()
5776 if not Option.Modifiable then return end
5777 local parent = Selection.List[1] or workspace
5778 for i = 1,#clipboard do
5779 clipboard[i]:Clone().Parent = parent
5780 end
5781 end)
5782
5783 -- COPY
5784 makeButton(ACTION_COPY,ACTION_COPY_OVER,"Copy",true,function() return #Selection:Get() > 0 end).MouseButton1Click:connect(function()
5785 if not Option.Modifiable then return end
5786 clipboard = {}
5787 local list = Selection.List
5788 for i = 1,#list do
5789 table.insert(clipboard,list[i]:Clone())
5790 end
5791 updateActions()
5792 end)
5793
5794 -- CUT
5795 makeButton(ACTION_CUT,ACTION_CUT_OVER,"Cut",true,function() return #Selection:Get() > 0 end).MouseButton1Click:connect(function()
5796 if not Option.Modifiable then return end
5797 clipboard = {}
5798 local list = Selection.List
5799 local cut = {}
5800 for i = 1,#list do
5801 local obj = list[i]:Clone()
5802 if obj then
5803 table.insert(clipboard,obj)
5804 table.insert(cut,list[i])
5805 end
5806 end
5807 for i = 1,#cut do
5808 pcall(delete,cut[i])
5809 end
5810 updateActions()
5811 end)
5812
5813 -- FREEZE
5814 makeButton(ACTION_FREEZE,ACTION_FREEZE,"Freeze",true,function() return true end)
5815
5816 -- ADD/REMOVE STARRED
5817 makeButton(ACTION_ADDSTAR,ACTION_ADDSTAR_OVER,"Star",true,function() return #Selection:Get() > 0 end)
5818
5819 -- STARRED
5820 makeButton(ACTION_STARRED,ACTION_STARRED,"Starred",true,function() return true end)
5821
5822
5823 -- SORT
5824 -- local actionSort = makeButton(ACTION_SORT,ACTION_SORT_OVER,"Sort")
5825end
5826
5827----------------------------------------------------------------
5828----------------------------------------------------------------
5829----------------------------------------------------------------
5830----------------------------------------------------------------
5831---- Option Bindables
5832
5833do
5834 local optionCallback = {
5835 Modifiable = function(value)
5836 for i = 1,#actionButtons do
5837 actionButtons[i].Obj.Visible = value and Option.Selectable
5838 end
5839 cancelReparentDrag()
5840 end;
5841 Selectable = function(value)
5842 for i = 1,#actionButtons do
5843 actionButtons[i].Obj.Visible = value and Option.Modifiable
5844 end
5845 cancelSelectDrag()
5846 Selection:Set({})
5847 end;
5848 }
5849
5850 local bindSetOption = explorerPanel:FindFirstChild("SetOption")
5851 if not bindSetOption then
5852 bindSetOption = Create('BindableFunction',{Name = "SetOption"})
5853 bindSetOption.Parent = explorerPanel
5854 end
5855
5856 bindSetOption.OnInvoke = function(optionName,value)
5857 if optionCallback[optionName] then
5858 Option[optionName] = value
5859 optionCallback[optionName](value)
5860 end
5861 end
5862
5863 local bindGetOption = explorerPanel:FindFirstChild("GetOption")
5864 if not bindGetOption then
5865 bindGetOption = Create('BindableFunction',{Name = "GetOption"})
5866 bindGetOption.Parent = explorerPanel
5867 end
5868
5869 bindGetOption.OnInvoke = function(optionName)
5870 if optionName then
5871 return Option[optionName]
5872 else
5873 local options = {}
5874 for k,v in pairs(Option) do
5875 options[k] = v
5876 end
5877 return options
5878 end
5879 end
5880end
5881
5882function SelectionVar()
5883 return Selection
5884end
5885
5886Input.InputBegan:connect(function(key)
5887 if key.KeyCode == Enum.KeyCode.LeftControl then
5888 HoldingCtrl = true
5889 end
5890 if key.KeyCode == Enum.KeyCode.LeftShift then
5891 HoldingShift = true
5892 end
5893end)
5894
5895Input.InputEnded:connect(function(key)
5896 if key.KeyCode == Enum.KeyCode.LeftControl then
5897 HoldingCtrl = false
5898 end
5899 if key.KeyCode == Enum.KeyCode.LeftShift then
5900 HoldingShift = false
5901 end
5902end)
5903
5904while RbxApi == nil do
5905 RbxApi = GetApiRemote:Invoke()
5906 wait()
5907end
5908
5909explorerFilter.Changed:connect(function(prop)
5910 if prop == "Text" then
5911 rawUpdateList()
5912 end
5913end)
5914
5915CurrentInsertObjectWindow = CreateInsertObjectMenu(
5916 GetClasses(),
5917 "",
5918 false,
5919 function(option)
5920 CurrentInsertObjectWindow.Visible = false
5921 local list = SelectionVar():Get()
5922 for i = 1,#list do
5923 pcall(function() Instance.new(option,list[i]) end)
5924 end
5925 DestroyRightClick()
5926 end
5927)
5928end)
5929
5930spawn(function()
5931 --[[
5932
5933Change log:
5934
593509/18
5936 Fixed checkbox mouseover sprite
5937 Encapsulated checkbox creation into separate method
5938 Fixed another checkbox issue
5939
594009/15
5941 Invalid input is ignored instead of setting to default of that data type
5942 Consolidated control methods and simplified them
5943 All input goes through ToValue method
5944 Fixed position of BrickColor palette
5945 Made DropDown appear above row if it would otherwise exceed the page height
5946 Cleaned up stylesheets
5947
594809/14
5949 Made properties window scroll when mouse wheel scrolled
5950 Object/Instance and Color3 data types handled properly
5951 Multiple BrickColor controls interfering with each other fixed
5952 Added support for Content data type
5953
5954--]]
5955
5956wait(0.2)
5957
5958local print = function(s)
5959 print(tostring(s))
5960end
5961
5962-- Services
5963local Teams = game:GetService("Teams")
5964local Workspace = game:GetService("Workspace")
5965local Debris = game:GetService("Debris")
5966local ContentProvider = game:GetService("ContentProvider")
5967local Players = game:GetService("Players")
5968local ReplicatedStorage = game:GetService("ReplicatedStorage")
5969
5970-- Functions
5971function httpGet(url)
5972 return game:HttpGet(url,true)
5973end
5974
5975-- RbxApi Stuff
5976
5977local apiUrl = "http://anaminus.github.io/rbx/json/api/latest.json"
5978local maxChunkSize = 100 * 1000
5979local ApiJson = ""
5980
5981function getLocalApiJson()
5982 local rawApiJson = require(ApiJson)()
5983 return rawApiJson
5984end
5985
5986function getCurrentApiJson()
5987 if true then return Synapse:DownloadString("http://anaminus.github.io/rbx/json/api/latest.json") end
5988 local jsonStr = nil
5989 if readfile and getelysianpath then
5990 if readfile(getelysianpath().."Xpl0rerApi.txt") then
5991 print("Api found in folder!")
5992 jsonStr = readfile(getelysianpath().."Xpl0rerApi.txt")
5993 return jsonStr
5994 end
5995 end
5996 local success, err = pcall(function()
5997 jsonStr = httpGet(apiUrl)
5998 print("Fetched json successfully")
5999 end)
6000 if success then
6001 print("Returning json")
6002 --print(jsonStr:sub(1,500))
6003 return jsonStr
6004 else
6005 print("Error fetching json: " .. tostring(err))
6006 print("Falling back to local copy")
6007 return getLocalApiJson()
6008 end
6009end
6010
6011function splitStringIntoChunks(jsonStr)
6012 -- Splits up a string into a table with a given size
6013 local t = {}
6014 for i = 1, math.ceil(string.len(jsonStr)/maxChunkSize) do
6015 local str = jsonStr:sub((i-1)*maxChunkSize+1, i*maxChunkSize)
6016 table.insert(t, str)
6017 end
6018 return t
6019end
6020
6021local jsonToParse = getCurrentApiJson()
6022local apiChunks = splitStringIntoChunks(jsonToParse)
6023
6024function getRbxApi()
6025--[[
6026 Api.Classes
6027 Api.Enums
6028 Api.GetProperties(className)
6029 Api.IsEnum(valueType)
6030--]]
6031
6032-- Services
6033local HttpService = game:GetService("HttpService")
6034local ServerStorage = game:GetService("ServerStorage")
6035local ReplicatedStorage = game:GetService("ReplicatedStorage")
6036
6037-- Remotes
6038--local Remotes = ReplicatedStorage:WaitForChild("OnlineStudio"):WaitForChild("Remotes")
6039--local GetApiJsonFunction = Remotes:WaitForChild("GetApiJson")
6040
6041-- Functions
6042local JsonDecode = function(s) return HttpService:JSONDecode(s) end
6043
6044local function GetApiRemoteFunction(index)
6045 if (apiChunks[index]) then
6046 return apiChunks[index], #apiChunks
6047 else
6048 print("Bad index for GetApiJson")
6049 return nil
6050 end
6051end
6052
6053local function getApiJson()
6054 local apiTable = {}
6055 local firstPage, pageCount = GetApiRemoteFunction(1)
6056 table.insert(apiTable, firstPage)
6057 for i = 2, pageCount do
6058 --print("Fetching API page # " .. tostring(i))
6059 local result = GetApiRemoteFunction(i)
6060 table.insert(apiTable, result)
6061 end
6062 return table.concat(apiTable)
6063end
6064
6065local json = getApiJson()
6066local apiDump = JsonDecode(json)
6067
6068local Classes = {}
6069local Enums = {}
6070
6071local function sortAlphabetic(t, property)
6072 table.sort(t,
6073 function(x,y) return x[property] < y[property]
6074 end)
6075end
6076
6077local function isEnum(name)
6078 return Enums[name] ~= nil
6079end
6080
6081local function getProperties(className)
6082 local class = Classes[className]
6083 local properties = {}
6084
6085 if not class then return properties end
6086
6087 while class do
6088 for _,property in pairs(class.Properties) do
6089 table.insert(properties, property)
6090 end
6091 class = Classes[class.Superclass]
6092 end
6093
6094 sortAlphabetic(properties, "Name")
6095
6096 return properties
6097end
6098
6099for _,item in pairs(apiDump) do
6100 local itemType = item.type
6101-- Classes --
6102 if (itemType == 'Class') then
6103 Classes[item.Name] = item
6104 item.Properties = {}
6105 item.Functions = {}
6106 item.YieldFunctions = {}
6107 item.Events = {}
6108 item.Callbacks = {}
6109-- Members --
6110 elseif (itemType == 'Property') then
6111 table.insert(Classes[item.Class].Properties, item)
6112 elseif (itemType == 'Function') then
6113 table.insert(Classes[item.Class].Functions, item)
6114 elseif (itemType == 'YieldFunction') then
6115 table.insert(Classes[item.Class].YieldFunctions, item)
6116 elseif (itemType == 'Event') then
6117 table.insert(Classes[item.Class].Events, item)
6118 elseif (itemType == 'Callback') then
6119 table.insert(Classes[item.Class].Callbacks, item)
6120-- Enums --
6121 elseif (itemType == 'Enum') then
6122 Enums[item.Name] = item
6123 item.EnumItems = {}
6124 elseif (itemType == 'EnumItem') then
6125 Enums[item.Enum].EnumItems[item.Name] = item
6126 end
6127end
6128
6129return {
6130 Classes = Classes;
6131 Enums = Enums;
6132 GetProperties = getProperties;
6133 IsEnum = isEnum;
6134}
6135end
6136
6137-- Modules
6138local Permissions = {CanEdit = true}
6139local RbxApi = getRbxApi()
6140
6141--[[
6142 RbxApi.Classes
6143 RbxApi.Enums
6144 RbxApi.GetProperties(className)
6145 RbxApi.IsEnum(valueType)
6146--]]
6147
6148-- Styles
6149
6150local function CreateColor3(r, g, b) return Color3.new(r/255,g/255,b/255) end
6151
6152local Styles = {
6153 Font = Enum.Font.Arial;
6154 Margin = 5;
6155 Black = CreateColor3(0,0,0);
6156 White = CreateColor3(255,255,255);
6157}
6158
6159local Row = {
6160 Font = Styles.Font;
6161 FontSize = Enum.FontSize.Size14;
6162 TextXAlignment = Enum.TextXAlignment.Left;
6163 TextColor = Styles.Black;
6164 TextColorOver = Styles.White;
6165 TextLockedColor = CreateColor3(120,120,120);
6166 Height = 24;
6167 BorderColor = CreateColor3(216,216,216);
6168 BackgroundColor = Styles.White;
6169 BackgroundColorAlternate = CreateColor3(246,246,246);
6170 BackgroundColorMouseover = CreateColor3(211,224,244);
6171 TitleMarginLeft = 15;
6172}
6173
6174local DropDown = {
6175 Font = Styles.Font;
6176 FontSize = Enum.FontSize.Size14;
6177 TextColor = CreateColor3(0,0,0);
6178 TextColorOver = Styles.White;
6179 TextXAlignment = Enum.TextXAlignment.Left;
6180 Height = 16;
6181 BackColor = Styles.White;
6182 BackColorOver = CreateColor3(86,125,188);
6183 BorderColor = CreateColor3(216,216,216);
6184 BorderSizePixel = 2;
6185 ArrowColor = CreateColor3(160,160,160);
6186 ArrowColorOver = Styles.Black;
6187}
6188
6189local BrickColors = {
6190 BoxSize = 13;
6191 BorderSizePixel = 1;
6192 BorderColor = CreateColor3(160,160,160);
6193 FrameColor = CreateColor3(160,160,160);
6194 Size = 20;
6195 Padding = 4;
6196 ColorsPerRow = 8;
6197 OuterBorder = 1;
6198 OuterBorderColor = Styles.Black;
6199}
6200
6201wait(1)
6202
6203local Gui = D_E_X
6204local PropertiesFrame = Gui:WaitForChild("PropertiesFrame")
6205local ExplorerFrame = Gui:WaitForChild("ExplorerPanel")
6206
6207local bindGetSelection = ExplorerFrame.GetSelection
6208local bindSelectionChanged = ExplorerFrame.SelectionChanged
6209local bindGetApi = PropertiesFrame.GetApi
6210local bindGetAwait = PropertiesFrame.GetAwaiting
6211local bindSetAwait = PropertiesFrame.SetAwaiting
6212
6213local ContentUrl = ContentProvider.BaseUrl .. "asset/?id="
6214
6215local SettingsRemote = Gui:WaitForChild("SettingsPanel"):WaitForChild("GetSetting")
6216
6217local propertiesSearch = PropertiesFrame.Header.TextBox
6218
6219local AwaitingObjectValue = false
6220local AwaitingObjectObj
6221local AwaitingObjectProp
6222
6223function searchingProperties()
6224 if propertiesSearch.Text ~= "" and propertiesSearch.Text ~= "Search Properties" then
6225 return true
6226 end
6227 return false
6228end
6229
6230local function GetSelection()
6231 local selection = bindGetSelection:Invoke()
6232 if #selection == 0 then
6233 return nil
6234 else
6235 return selection
6236 end
6237end
6238
6239-- Number
6240
6241local function Round(number, decimalPlaces)
6242 return tonumber(string.format("%." .. (decimalPlaces or 0) .. "f", number))
6243end
6244
6245-- Strings
6246
6247local function Split(str, delimiter)
6248 local start = 1
6249 local t = {}
6250 while true do
6251 local pos = string.find (str, delimiter, start, true)
6252 if not pos then
6253 break
6254 end
6255 table.insert (t, string.sub (str, start, pos - 1))
6256 start = pos + string.len (delimiter)
6257 end
6258 table.insert (t, string.sub (str, start))
6259 return t
6260end
6261
6262-- Data Type Handling
6263
6264local function ToString(value, type)
6265 if type == "float" then
6266 return tostring(Round(value,2))
6267 elseif type == "Content" then
6268 if string.find(value,"/asset") then
6269 local match = string.find(value, "=") + 1
6270 local id = string.sub(value, match)
6271 return id
6272 else
6273 return tostring(value)
6274 end
6275 elseif type == "Vector2" then
6276 local x = value.x
6277 local y = value.y
6278 return string.format("%g, %g", x,y)
6279 elseif type == "Vector3" then
6280 local x = value.x
6281 local y = value.y
6282 local z = value.z
6283 return string.format("%g, %g, %g", x,y,z)
6284 elseif type == "Color3" then
6285 local r = value.r
6286 local g = value.g
6287 local b = value.b
6288 return string.format("%d, %d, %d", r*255,g*255,b*255)
6289 elseif type == "UDim2" then
6290 local xScale = value.X.Scale
6291 local xOffset = value.X.Offset
6292 local yScale = value.Y.Scale
6293 local yOffset = value.Y.Offset
6294 return string.format("{%d, %d}, {%d, %d}", xScale, xOffset, yScale, yOffset)
6295 else
6296 return tostring(value)
6297 end
6298end
6299
6300local function ToValue(value,type)
6301 if type == "Vector2" then
6302 local list = Split(value,",")
6303 if #list < 2 then return nil end
6304 local x = tonumber(list[1]) or 0
6305 local y = tonumber(list[2]) or 0
6306 return Vector2.new(x,y)
6307 elseif type == "Vector3" then
6308 local list = Split(value,",")
6309 if #list < 3 then return nil end
6310 local x = tonumber(list[1]) or 0
6311 local y = tonumber(list[2]) or 0
6312 local z = tonumber(list[3]) or 0
6313 return Vector3.new(x,y,z)
6314 elseif type == "Color3" then
6315 local list = Split(value,",")
6316 if #list < 3 then return nil end
6317 local r = tonumber(list[1]) or 0
6318 local g = tonumber(list[2]) or 0
6319 local b = tonumber(list[3]) or 0
6320 return Color3.new(r/255,g/255, b/255)
6321 elseif type == "UDim2" then
6322 local list = Split(string.gsub(string.gsub(value, "{", ""),"}",""),",")
6323 if #list < 4 then return nil end
6324 local xScale = tonumber(list[1]) or 0
6325 local xOffset = tonumber(list[2]) or 0
6326 local yScale = tonumber(list[3]) or 0
6327 local yOffset = tonumber(list[4]) or 0
6328 return UDim2.new(xScale, xOffset, yScale, yOffset)
6329 elseif type == "Content" then
6330 if tonumber(value) ~= nil then
6331 value = ContentUrl .. value
6332 end
6333 return value
6334 elseif type == "float" or type == "int" or type == "double" then
6335 return tonumber(value)
6336 elseif type == "string" then
6337 return value
6338 elseif type == "NumberRange" then
6339 local list = Split(value,",")
6340 if #list == 1 then
6341 if tonumber(list[1]) == nil then return nil end
6342 local newVal = tonumber(list[1]) or 0
6343 return NumberRange.new(newVal)
6344 end
6345 if #list < 2 then return nil end
6346 local x = tonumber(list[1]) or 0
6347 local y = tonumber(list[2]) or 0
6348 return NumberRange.new(x,y)
6349 else
6350 return nil
6351 end
6352end
6353
6354
6355-- Tables
6356
6357local function CopyTable(T)
6358 local t2 = {}
6359 for k,v in pairs(T) do
6360 t2[k] = v
6361 end
6362 return t2
6363end
6364
6365local function SortTable(T)
6366 table.sort(T,
6367 function(x,y) return x.Name < y.Name
6368 end)
6369end
6370
6371-- Spritesheet
6372local Sprite = {
6373 Width = 13;
6374 Height = 13;
6375}
6376
6377local Spritesheet = {
6378 Image = "http://www.roblox.com/asset/?id=128896947";
6379 Height = 256;
6380 Width = 256;
6381}
6382
6383local Images = {
6384 "unchecked",
6385 "checked",
6386 "unchecked_over",
6387 "checked_over",
6388 "unchecked_disabled",
6389 "checked_disabled"
6390}
6391
6392local function SpritePosition(spriteName)
6393 local x = 0
6394 local y = 0
6395 for i,v in pairs(Images) do
6396 if (v == spriteName) then
6397 return {x, y}
6398 end
6399 x = x + Sprite.Height
6400 if (x + Sprite.Width) > Spritesheet.Width then
6401 x = 0
6402 y = y + Sprite.Height
6403 end
6404 end
6405end
6406
6407local function GetCheckboxImageName(checked, readOnly, mouseover)
6408 if checked then
6409 if readOnly then
6410 return "checked_disabled"
6411 elseif mouseover then
6412 return "checked_over"
6413 else
6414 return "checked"
6415 end
6416 else
6417 if readOnly then
6418 return "unchecked_disabled"
6419 elseif mouseover then
6420 return "unchecked_over"
6421 else
6422 return "unchecked"
6423 end
6424 end
6425end
6426
6427local MAP_ID = 418720155
6428
6429-- Gui Controls --
6430
6431---- IconMap ----
6432-- Image size: 256px x 256px
6433-- Icon size: 16px x 16px
6434-- Padding between each icon: 2px
6435-- Padding around image edge: 1px
6436-- Total icons: 14 x 14 (196)
6437local Icon do
6438 local iconMap = 'http://www.roblox.com/asset/?id=' .. MAP_ID
6439 game:GetService('ContentProvider'):Preload(iconMap)
6440 local iconDehash do
6441 -- 14 x 14, 0-based input, 0-based output
6442 local f=math.floor
6443 function iconDehash(h)
6444 return f(h/14%14),f(h%14)
6445 end
6446 end
6447
6448 function Icon(IconFrame,index)
6449 local row,col = iconDehash(index)
6450 local mapSize = Vector2.new(256,256)
6451 local pad,border = 2,1
6452 local iconSize = 16
6453
6454 local class = 'Frame'
6455 if type(IconFrame) == 'string' then
6456 class = IconFrame
6457 IconFrame = nil
6458 end
6459
6460 if not IconFrame then
6461 IconFrame = Create(class,{
6462 Name = "Icon";
6463 BackgroundTransparency = 1;
6464 ClipsDescendants = true;
6465 Create('ImageLabel',{
6466 Name = "IconMap";
6467 Active = false;
6468 BackgroundTransparency = 1;
6469 Image = iconMap;
6470 Size = UDim2.new(mapSize.x/iconSize,0,mapSize.y/iconSize,0);
6471 });
6472 })
6473 end
6474
6475 IconFrame.IconMap.Position = UDim2.new(-col - (pad*(col+1) + border)/iconSize,0,-row - (pad*(row+1) + border)/iconSize,0)
6476 return IconFrame
6477 end
6478end
6479
6480local function CreateCell()
6481 local tableCell = Instance.new("Frame")
6482 tableCell.Size = UDim2.new(0.5, -1, 1, 0)
6483 tableCell.BackgroundColor3 = Row.BackgroundColor
6484 tableCell.BorderColor3 = Row.BorderColor
6485 return tableCell
6486end
6487
6488local function CreateLabel(readOnly)
6489 local label = Instance.new("TextLabel")
6490 label.Font = Row.Font
6491 label.FontSize = Row.FontSize
6492 label.TextXAlignment = Row.TextXAlignment
6493 label.BackgroundTransparency = 1
6494
6495 if readOnly then
6496 label.TextColor3 = Row.TextLockedColor
6497 else
6498 label.TextColor3 = Row.TextColor
6499 end
6500 return label
6501end
6502
6503local function CreateTextButton(readOnly, onClick)
6504 local button = Instance.new("TextButton")
6505 button.Font = Row.Font
6506 button.FontSize = Row.FontSize
6507 button.TextXAlignment = Row.TextXAlignment
6508 button.BackgroundTransparency = 1
6509 if readOnly then
6510 button.TextColor3 = Row.TextLockedColor
6511 else
6512 button.TextColor3 = Row.TextColor
6513 button.MouseButton1Click:connect(function()
6514 onClick()
6515 end)
6516 end
6517 return button
6518end
6519
6520local function CreateObject(readOnly)
6521 local button = Instance.new("TextButton")
6522 button.Font = Row.Font
6523 button.FontSize = Row.FontSize
6524 button.TextXAlignment = Row.TextXAlignment
6525 button.BackgroundTransparency = 1
6526 if readOnly then
6527 button.TextColor3 = Row.TextLockedColor
6528 else
6529 button.TextColor3 = Row.TextColor
6530 end
6531 local cancel = Create(Icon('ImageButton',177),{
6532 Name = "Cancel";
6533 Visible = false;
6534 Position = UDim2.new(1,-20,0,0);
6535 Size = UDim2.new(0,20,0,20);
6536 Parent = button;
6537 })
6538 return button
6539end
6540
6541local function CreateTextBox(readOnly)
6542 if readOnly then
6543 local box = CreateLabel(readOnly)
6544 return box
6545 else
6546 local box = Instance.new("TextBox")
6547 if not SettingsRemote:Invoke("ClearProps") then
6548 box.ClearTextOnFocus = false
6549 end
6550 box.Font = Row.Font
6551 box.FontSize = Row.FontSize
6552 box.TextXAlignment = Row.TextXAlignment
6553 box.BackgroundTransparency = 1
6554 box.TextColor3 = Row.TextColor
6555 return box
6556 end
6557end
6558
6559local function CreateDropDownItem(text, onClick)
6560 local button = Instance.new("TextButton")
6561 button.Font = DropDown.Font
6562 button.FontSize = DropDown.FontSize
6563 button.TextColor3 = DropDown.TextColor
6564 button.TextXAlignment = DropDown.TextXAlignment
6565 button.BackgroundColor3 = DropDown.BackColor
6566 button.AutoButtonColor = false
6567 button.BorderSizePixel = 0
6568 button.Active = true
6569 button.Text = text
6570
6571 button.MouseEnter:connect(function()
6572 button.TextColor3 = DropDown.TextColorOver
6573 button.BackgroundColor3 = DropDown.BackColorOver
6574 end)
6575 button.MouseLeave:connect(function()
6576 button.TextColor3 = DropDown.TextColor
6577 button.BackgroundColor3 = DropDown.BackColor
6578 end)
6579 button.MouseButton1Click:connect(function()
6580 onClick(text)
6581 end)
6582 return button
6583end
6584
6585local function CreateDropDown(choices, currentChoice, readOnly, onClick)
6586 local frame = Instance.new("Frame")
6587 frame.Name = "DropDown"
6588 frame.Size = UDim2.new(1, 0, 1, 0)
6589 frame.BackgroundTransparency = 1
6590 frame.Active = true
6591
6592 local menu = nil
6593 local arrow = nil
6594 local expanded = false
6595 local margin = DropDown.BorderSizePixel;
6596
6597 local button = Instance.new("TextButton")
6598 button.Font = Row.Font
6599 button.FontSize = Row.FontSize
6600 button.TextXAlignment = Row.TextXAlignment
6601 button.BackgroundTransparency = 1
6602 button.TextColor3 = Row.TextColor
6603 if readOnly then
6604 button.TextColor3 = Row.TextLockedColor
6605 end
6606 button.Text = currentChoice
6607 button.Size = UDim2.new(1, -2 * Styles.Margin, 1, 0)
6608 button.Position = UDim2.new(0, Styles.Margin, 0, 0)
6609 button.Parent = frame
6610
6611 local function showArrow(color)
6612 if arrow then arrow:Destroy() end
6613
6614 local graphicTemplate = Create('Frame',{
6615 Name="Graphic";
6616 BorderSizePixel = 0;
6617 BackgroundColor3 = color;
6618 })
6619 local graphicSize = 16/2
6620
6621 arrow = ArrowGraphic(graphicSize,'Down',true,graphicTemplate)
6622 arrow.Position = UDim2.new(1,-graphicSize * 2,0.5,-graphicSize/2)
6623 arrow.Parent = frame
6624 end
6625
6626 local function hideMenu()
6627 expanded = false
6628 showArrow(DropDown.ArrowColor)
6629 if menu then menu:Destroy() end
6630 end
6631
6632 local function showMenu()
6633 expanded = true
6634 menu = Instance.new("Frame")
6635 menu.Size = UDim2.new(1, -2 * margin, 0, #choices * DropDown.Height)
6636 menu.Position = UDim2.new(0, margin, 0, Row.Height + margin)
6637 menu.BackgroundTransparency = 0
6638 menu.BackgroundColor3 = DropDown.BackColor
6639 menu.BorderColor3 = DropDown.BorderColor
6640 menu.BorderSizePixel = DropDown.BorderSizePixel
6641 menu.Active = true
6642 menu.ZIndex = 5
6643 menu.Parent = frame
6644
6645 local parentFrameHeight = menu.Parent.Parent.Parent.Parent.Size.Y.Offset
6646 local rowHeight = menu.Parent.Parent.Parent.Position.Y.Offset
6647 if (rowHeight + menu.Size.Y.Offset) > math.max(parentFrameHeight,PropertiesFrame.AbsoluteSize.y) then
6648 menu.Position = UDim2.new(0, margin, 0, -1 * (#choices * DropDown.Height) - margin)
6649 end
6650
6651 local function choice(name)
6652 onClick(name)
6653 hideMenu()
6654 end
6655
6656 for i,name in pairs(choices) do
6657 local option = CreateDropDownItem(name, function()
6658 choice(name)
6659 end)
6660 option.Size = UDim2.new(1, 0, 0, 16)
6661 option.Position = UDim2.new(0, 0, 0, (i - 1) * DropDown.Height)
6662 option.ZIndex = menu.ZIndex
6663 option.Parent = menu
6664 end
6665 end
6666
6667 showArrow(DropDown.ArrowColor)
6668
6669 if not readOnly then
6670
6671 button.MouseEnter:connect(function()
6672 button.TextColor3 = Row.TextColor
6673 showArrow(DropDown.ArrowColorOver)
6674 end)
6675 button.MouseLeave:connect(function()
6676 button.TextColor3 = Row.TextColor
6677 if not expanded then
6678 showArrow(DropDown.ArrowColor)
6679 end
6680 end)
6681 button.MouseButton1Click:connect(function()
6682 if expanded then
6683 hideMenu()
6684 else
6685 showMenu()
6686 end
6687 end)
6688 end
6689
6690 return frame,button
6691end
6692
6693local function CreateBrickColor(readOnly, onClick)
6694 local frame = Instance.new("Frame")
6695 frame.Size = UDim2.new(1,0,1,0)
6696 frame.BackgroundTransparency = 1
6697
6698 local colorPalette = Instance.new("Frame")
6699 colorPalette.BackgroundTransparency = 0
6700 colorPalette.SizeConstraint = Enum.SizeConstraint.RelativeXX
6701 colorPalette.Size = UDim2.new(1, -2 * BrickColors.OuterBorder, 1, -2 * BrickColors.OuterBorder)
6702 colorPalette.BorderSizePixel = BrickColors.BorderSizePixel
6703 colorPalette.BorderColor3 = BrickColors.BorderColor
6704 colorPalette.Position = UDim2.new(0, BrickColors.OuterBorder, 0, BrickColors.OuterBorder + Row.Height)
6705 colorPalette.ZIndex = 5
6706 colorPalette.Visible = false
6707 colorPalette.BorderSizePixel = BrickColors.OuterBorder
6708 colorPalette.BorderColor3 = BrickColors.OuterBorderColor
6709 colorPalette.Parent = frame
6710
6711 local function show()
6712 colorPalette.Visible = true
6713 end
6714
6715 local function hide()
6716 colorPalette.Visible = false
6717 end
6718
6719 local function toggle()
6720 colorPalette.Visible = not colorPalette.Visible
6721 end
6722
6723 local colorBox = Instance.new("TextButton", frame)
6724 colorBox.Position = UDim2.new(0, Styles.Margin, 0, Styles.Margin)
6725 colorBox.Size = UDim2.new(0, BrickColors.BoxSize, 0, BrickColors.BoxSize)
6726 colorBox.Text = ""
6727 colorBox.MouseButton1Click:connect(function()
6728 if not readOnly then
6729 toggle()
6730 end
6731 end)
6732
6733 if readOnly then
6734 colorBox.AutoButtonColor = false
6735 end
6736
6737 local spacingBefore = (Styles.Margin * 2) + BrickColors.BoxSize
6738
6739 local propertyLabel = CreateTextButton(readOnly, function()
6740 if not readOnly then
6741 toggle()
6742 end
6743 end)
6744 propertyLabel.Size = UDim2.new(1, (-1 * spacingBefore) - Styles.Margin, 1, 0)
6745 propertyLabel.Position = UDim2.new(0, spacingBefore, 0, 0)
6746 propertyLabel.Parent = frame
6747
6748 local size = (1 / BrickColors.ColorsPerRow)
6749
6750 for index = 0, 127 do
6751 local brickColor = BrickColor.palette(index)
6752 local color3 = brickColor.Color
6753
6754 local x = size * (index % BrickColors.ColorsPerRow)
6755 local y = size * math.floor(index / BrickColors.ColorsPerRow)
6756
6757 local brickColorBox = Instance.new("TextButton")
6758 brickColorBox.Text = ""
6759 brickColorBox.Size = UDim2.new(size,0,size,0)
6760 brickColorBox.BackgroundColor3 = color3
6761 brickColorBox.Position = UDim2.new(x, 0, y, 0)
6762 brickColorBox.ZIndex = colorPalette.ZIndex
6763 brickColorBox.Parent = colorPalette
6764
6765 brickColorBox.MouseButton1Click:connect(function()
6766 hide()
6767 onClick(brickColor)
6768 end)
6769 end
6770
6771 return frame,propertyLabel,colorBox
6772end
6773
6774local function CreateColor3Control(readOnly, onClick)
6775 local frame = Instance.new("Frame")
6776 frame.Size = UDim2.new(1,0,1,0)
6777 frame.BackgroundTransparency = 1
6778
6779 local colorBox = Instance.new("TextButton", frame)
6780 colorBox.Position = UDim2.new(0, Styles.Margin, 0, Styles.Margin)
6781 colorBox.Size = UDim2.new(0, BrickColors.BoxSize, 0, BrickColors.BoxSize)
6782 colorBox.Text = ""
6783 colorBox.AutoButtonColor = false
6784
6785 local spacingBefore = (Styles.Margin * 2) + BrickColors.BoxSize
6786 local box = CreateTextBox(readOnly)
6787 box.Size = UDim2.new(1, (-1 * spacingBefore) - Styles.Margin, 1, 0)
6788 box.Position = UDim2.new(0, spacingBefore, 0, 0)
6789 box.Parent = frame
6790
6791 return frame,box,colorBox
6792end
6793
6794function CreateCheckbox(value, readOnly, onClick)
6795 local checked = value
6796 local mouseover = false
6797
6798 local checkboxFrame = Instance.new("ImageButton")
6799 checkboxFrame.Size = UDim2.new(0, Sprite.Width, 0, Sprite.Height)
6800 checkboxFrame.BackgroundTransparency = 1
6801 checkboxFrame.ClipsDescendants = true
6802 --checkboxFrame.Position = UDim2.new(0, Styles.Margin, 0, Styles.Margin)
6803
6804 local spritesheetImage = Instance.new("ImageLabel", checkboxFrame)
6805 spritesheetImage.Name = "SpritesheetImageLabel"
6806 spritesheetImage.Size = UDim2.new(0, Spritesheet.Width, 0, Spritesheet.Height)
6807 spritesheetImage.Image = Spritesheet.Image
6808 spritesheetImage.BackgroundTransparency = 1
6809
6810 local function updateSprite()
6811 local spriteName = GetCheckboxImageName(checked, readOnly, mouseover)
6812 local spritePosition = SpritePosition(spriteName)
6813 spritesheetImage.Position = UDim2.new(0, -1 * spritePosition[1], 0, -1 * spritePosition[2])
6814 end
6815
6816 local function setValue(val)
6817 checked = val
6818 updateSprite()
6819 end
6820
6821 if not readOnly then
6822 checkboxFrame.MouseEnter:connect(function() mouseover = true updateSprite() end)
6823 checkboxFrame.MouseLeave:connect(function() mouseover = false updateSprite() end)
6824 checkboxFrame.MouseButton1Click:connect(function()
6825 onClick(checked)
6826 end)
6827 end
6828
6829 updateSprite()
6830
6831 return checkboxFrame, setValue
6832end
6833
6834
6835
6836-- Code for handling controls of various data types --
6837
6838local Controls = {}
6839
6840Controls["default"] = function(object, propertyData, readOnly)
6841 local propertyName = propertyData["Name"]
6842 local propertyType = propertyData["ValueType"]
6843
6844 local box = CreateTextBox(readOnly)
6845 box.Size = UDim2.new(1, -2 * Styles.Margin, 1, 0)
6846 box.Position = UDim2.new(0, Styles.Margin, 0, 0)
6847
6848 local function update()
6849 local value = object[propertyName]
6850 box.Text = ToString(value, propertyType)
6851 end
6852
6853 if not readOnly then
6854 box.FocusLost:connect(function(enterPressed)
6855 Set(object, propertyData, ToValue(box.Text,propertyType))
6856 update()
6857 end)
6858 end
6859
6860 update()
6861
6862 object.Changed:connect(function(property)
6863 if (property == propertyName) then
6864 update()
6865 end
6866 end)
6867
6868 return box
6869end
6870
6871Controls["bool"] = function(object, propertyData, readOnly)
6872 local propertyName = propertyData["Name"]
6873 local checked = object[propertyName]
6874
6875 local checkbox, setValue = CreateCheckbox(checked, readOnly, function(value)
6876 Set(object, propertyData, not checked)
6877 end)
6878 checkbox.Position = UDim2.new(0, Styles.Margin, 0, Styles.Margin)
6879
6880 setValue(checked)
6881
6882 local function update()
6883 checked = object[propertyName]
6884 setValue(checked)
6885 end
6886
6887 object.Changed:connect(function(property)
6888 if (property == propertyName) then
6889 update()
6890 end
6891 end)
6892
6893 if object:IsA("BoolValue") then
6894 object.Changed:connect(function(val)
6895 update()
6896 end)
6897 end
6898
6899 update()
6900
6901 return checkbox
6902end
6903
6904Controls["BrickColor"] = function(object, propertyData, readOnly)
6905 local propertyName = propertyData["Name"]
6906
6907 local frame,label,brickColorBox = CreateBrickColor(readOnly, function(brickColor)
6908 Set(object, propertyData, brickColor)
6909 end)
6910
6911 local function update()
6912 local value = object[propertyName]
6913 brickColorBox.BackgroundColor3 = value.Color
6914 label.Text = tostring(value)
6915 end
6916
6917 update()
6918
6919 object.Changed:connect(function(property)
6920 if (property == propertyName) then
6921 update()
6922 end
6923 end)
6924
6925 return frame
6926end
6927
6928Controls["Color3"] = function(object, propertyData, readOnly)
6929 local propertyName = propertyData["Name"]
6930
6931 local frame,textBox,colorBox = CreateColor3Control(readOnly)
6932
6933 textBox.FocusLost:connect(function(enterPressed)
6934 Set(object, propertyData, ToValue(textBox.Text,"Color3"))
6935 local value = object[propertyName]
6936 colorBox.BackgroundColor3 = value
6937 textBox.Text = ToString(value, "Color3")
6938 end)
6939
6940 local function update()
6941 local value = object[propertyName]
6942 colorBox.BackgroundColor3 = value
6943 textBox.Text = ToString(value, "Color3")
6944 end
6945
6946 update()
6947
6948 object.Changed:connect(function(property)
6949 if (property == propertyName) then
6950 update()
6951 end
6952 end)
6953
6954 return frame
6955end
6956
6957Controls["Enum"] = function(object, propertyData, readOnly)
6958 local propertyName = propertyData["Name"]
6959 local propertyType = propertyData["ValueType"]
6960
6961 local enumName = object[propertyName].Name
6962
6963 local enumNames = {}
6964 for _,enum in pairs(Enum[tostring(propertyType)]:GetEnumItems()) do
6965 table.insert(enumNames, enum.Name)
6966 end
6967
6968 local dropdown, propertyLabel = CreateDropDown(enumNames, enumName, readOnly, function(value)
6969 Set(object, propertyData, value)
6970 end)
6971 --dropdown.Parent = frame
6972
6973 local function update()
6974 local value = object[propertyName].Name
6975 propertyLabel.Text = tostring(value)
6976 end
6977
6978 update()
6979
6980 object.Changed:connect(function(property)
6981 if (property == propertyName) then
6982 update()
6983 end
6984 end)
6985
6986 return dropdown
6987end
6988
6989Controls["Object"] = function(object, propertyData, readOnly)
6990 local propertyName = propertyData["Name"]
6991 local propertyType = propertyData["ValueType"]
6992
6993 local box = CreateObject(readOnly,function()end)
6994 box.Size = UDim2.new(1, -2 * Styles.Margin, 1, 0)
6995 box.Position = UDim2.new(0, Styles.Margin, 0, 0)
6996
6997 local function update()
6998 if AwaitingObjectObj == object then
6999 if AwaitingObjectValue == true then
7000 box.Text = "Select an Object"
7001 return
7002 end
7003 end
7004 local value = object[propertyName]
7005 box.Text = ToString(value, propertyType)
7006 end
7007
7008 if not readOnly then
7009 box.MouseButton1Click:connect(function()
7010 if AwaitingObjectValue then
7011 AwaitingObjectValue = false
7012 update()
7013 return
7014 end
7015 AwaitingObjectValue = true
7016 AwaitingObjectObj = object
7017 AwaitingObjectProp = propertyData
7018 box.Text = "Select an Object"
7019 end)
7020
7021 box.Cancel.Visible = true
7022 box.Cancel.MouseButton1Click:connect(function()
7023 object[propertyName] = nil
7024 end)
7025 end
7026
7027 update()
7028
7029 object.Changed:connect(function(property)
7030 if (property == propertyName) then
7031 update()
7032 end
7033 end)
7034
7035 if object:IsA("ObjectValue") then
7036 object.Changed:connect(function(val)
7037 update()
7038 end)
7039 end
7040
7041 return box
7042end
7043
7044function GetControl(object, propertyData, readOnly)
7045 local propertyType = propertyData["ValueType"]
7046 local control = nil
7047
7048 if Controls[propertyType] then
7049 control = Controls[propertyType](object, propertyData, readOnly)
7050 elseif RbxApi.IsEnum(propertyType) then
7051 control = Controls["Enum"](object, propertyData, readOnly)
7052 else
7053 control = Controls["default"](object, propertyData, readOnly)
7054 end
7055 return control
7056end
7057-- Permissions
7058
7059function CanEditObject(object)
7060 local player = Players.LocalPlayer
7061 local character = player.Character
7062 return Permissions.CanEdit
7063end
7064
7065function CanEditProperty(object,propertyData)
7066 local tags = propertyData["tags"]
7067 for _,name in pairs(tags) do
7068 if name == "readonly" then
7069 return false
7070 end
7071 end
7072 return CanEditObject(object)
7073end
7074
7075--RbxApi
7076local function PropertyIsHidden(propertyData)
7077 local tags = propertyData["tags"]
7078 for _,name in pairs(tags) do
7079 if name == "deprecated"
7080 or name == "hidden"
7081 or name == "writeonly" then
7082 return true
7083 end
7084 end
7085 return false
7086end
7087
7088function Set(object, propertyData, value)
7089 local propertyName = propertyData["Name"]
7090 local propertyType = propertyData["ValueType"]
7091
7092 if value == nil then return end
7093
7094 for i,v in pairs(GetSelection()) do
7095 if CanEditProperty(v,propertyData) then
7096 pcall(function()
7097 --print("Setting " .. propertyName .. " to " .. tostring(value))
7098 v[propertyName] = value
7099 end)
7100 end
7101 end
7102end
7103
7104function CreateRow(object, propertyData, isAlternateRow)
7105 local propertyName = propertyData["Name"]
7106 local propertyType = propertyData["ValueType"]
7107 local propertyValue = object[propertyName]
7108 --rowValue, rowValueType, isAlternate
7109 local backColor = Row.BackgroundColor;
7110 if (isAlternateRow) then
7111 backColor = Row.BackgroundColorAlternate
7112 end
7113
7114 local readOnly = not CanEditProperty(object, propertyData)
7115 if propertyType == "Instance" or propertyName == "Parent" then readOnly = true end
7116
7117 local rowFrame = Instance.new("Frame")
7118 rowFrame.Size = UDim2.new(1,0,0,Row.Height)
7119 rowFrame.BackgroundTransparency = 1
7120 rowFrame.Name = 'Row'
7121
7122 local propertyLabelFrame = CreateCell()
7123 propertyLabelFrame.Parent = rowFrame
7124 propertyLabelFrame.ClipsDescendants = true
7125
7126 local propertyLabel = CreateLabel(readOnly)
7127 propertyLabel.Text = propertyName
7128 propertyLabel.Size = UDim2.new(1, -1 * Row.TitleMarginLeft, 1, 0)
7129 propertyLabel.Position = UDim2.new(0, Row.TitleMarginLeft, 0, 0)
7130 propertyLabel.Parent = propertyLabelFrame
7131
7132 local propertyValueFrame = CreateCell()
7133 propertyValueFrame.Size = UDim2.new(0.5, -1, 1, 0)
7134 propertyValueFrame.Position = UDim2.new(0.5, 0, 0, 0)
7135 propertyValueFrame.Parent = rowFrame
7136
7137 local control = GetControl(object, propertyData, readOnly)
7138 control.Parent = propertyValueFrame
7139
7140 rowFrame.MouseEnter:connect(function()
7141 propertyLabelFrame.BackgroundColor3 = Row.BackgroundColorMouseover
7142 propertyValueFrame.BackgroundColor3 = Row.BackgroundColorMouseover
7143 end)
7144 rowFrame.MouseLeave:connect(function()
7145 propertyLabelFrame.BackgroundColor3 = backColor
7146 propertyValueFrame.BackgroundColor3 = backColor
7147 end)
7148
7149 propertyLabelFrame.BackgroundColor3 = backColor
7150 propertyValueFrame.BackgroundColor3 = backColor
7151
7152 return rowFrame
7153end
7154
7155function ClearPropertiesList()
7156 for _,instance in pairs(ContentFrame:GetChildren()) do
7157 instance:Destroy()
7158 end
7159end
7160
7161local selection = Gui:FindFirstChild("Selection", 1)
7162print(selection)
7163
7164function displayProperties(props)
7165 for i,v in pairs(props) do
7166 pcall(function()
7167 local a = CreateRow(v.object, v.propertyData, ((numRows % 2) == 0))
7168 a.Position = UDim2.new(0,0,0,numRows*Row.Height)
7169 a.Parent = ContentFrame
7170 numRows = numRows + 1
7171 end)
7172 end
7173end
7174
7175function checkForDupe(prop,props)
7176 for i,v in pairs(props) do
7177 if v.propertyData.Name == prop.Name and v.propertyData.ValueType == prop.ValueType then
7178 return true
7179 end
7180 end
7181 return false
7182end
7183
7184function sortProps(t)
7185 table.sort(t,
7186 function(x,y) return x.propertyData.Name < y.propertyData.Name
7187 end)
7188end
7189
7190function showProperties(obj)
7191 ClearPropertiesList()
7192 if obj == nil then return end
7193 local propHolder = {}
7194 local foundProps = {}
7195 numRows = 0
7196 for _,nextObj in pairs(obj) do
7197 if not foundProps[nextObj.className] then
7198 foundProps[nextObj.className] = true
7199 for i,v in pairs(RbxApi.GetProperties(nextObj.className)) do
7200 local suc, err = pcall(function()
7201 if not (PropertyIsHidden(v)) and not checkForDupe(v,propHolder) then
7202 if string.find(string.lower(v.Name),string.lower(propertiesSearch.Text)) or not searchingProperties() then
7203 table.insert(propHolder,{propertyData = v, object = nextObj})
7204 end
7205 end
7206 end)
7207 --[[if not suc then
7208 warn("Problem getting the value of property " .. v.Name .. " | " .. err)
7209 end --]]
7210 end
7211 end
7212 end
7213 sortProps(propHolder)
7214 displayProperties(propHolder)
7215 ContentFrame.Size = UDim2.new(1, 0, 0, numRows * Row.Height)
7216 scrollBar.ScrollIndex = 0
7217 scrollBar.TotalSpace = numRows * Row.Height
7218 scrollBar.Update()
7219end
7220
7221----------------------------------------------------------------
7222-----------------------SCROLLBAR STUFF--------------------------
7223----------------------------------------------------------------
7224----------------------------------------------------------------
7225local ScrollBarWidth = 16
7226
7227local ScrollStyles = {
7228 Background = Color3.new(233/255, 233/255, 233/255);
7229 Border = Color3.new(149/255, 149/255, 149/255);
7230 Selected = Color3.new( 63/255, 119/255, 189/255);
7231 BorderSelected = Color3.new( 55/255, 106/255, 167/255);
7232 Text = Color3.new( 0/255, 0/255, 0/255);
7233 TextDisabled = Color3.new(128/255, 128/255, 128/255);
7234 TextSelected = Color3.new(255/255, 255/255, 255/255);
7235 Button = Color3.new(221/255, 221/255, 221/255);
7236 ButtonBorder = Color3.new(149/255, 149/255, 149/255);
7237 ButtonSelected = Color3.new(255/255, 0/255, 0/255);
7238 Field = Color3.new(255/255, 255/255, 255/255);
7239 FieldBorder = Color3.new(191/255, 191/255, 191/255);
7240 TitleBackground = Color3.new(178/255, 178/255, 178/255);
7241}
7242do
7243 local ZIndexLock = {}
7244 function SetZIndex(object,z)
7245 if not ZIndexLock[object] then
7246 ZIndexLock[object] = true
7247 if object:IsA'GuiObject' then
7248 object.ZIndex = z
7249 end
7250 local children = object:GetChildren()
7251 for i = 1,#children do
7252 SetZIndex(children[i],z)
7253 end
7254 ZIndexLock[object] = nil
7255 end
7256 end
7257end
7258function SetZIndexOnChanged(object)
7259 return object.Changed:connect(function(p)
7260 if p == "ZIndex" then
7261 SetZIndex(object,object.ZIndex)
7262 end
7263 end)
7264end
7265function Create(ty,data)
7266 local obj
7267 if type(ty) == 'string' then
7268 obj = Instance.new(ty)
7269 else
7270 obj = ty
7271 end
7272 for k, v in pairs(data) do
7273 if type(k) == 'number' then
7274 v.Parent = obj
7275 else
7276 obj[k] = v
7277 end
7278 end
7279 return obj
7280end
7281-- returns the ascendant ScreenGui of an object
7282function GetScreen(screen)
7283 if screen == nil then return nil end
7284 while not screen:IsA("ScreenGui") do
7285 screen = screen.Parent
7286 if screen == nil then return nil end
7287 end
7288 return screen
7289end
7290-- AutoButtonColor doesn't always reset properly
7291function ResetButtonColor(button)
7292 local active = button.Active
7293 button.Active = not active
7294 button.Active = active
7295end
7296
7297function ArrowGraphic(size,dir,scaled,template)
7298 local Frame = Create('Frame',{
7299 Name = "Arrow Graphic";
7300 BorderSizePixel = 0;
7301 Size = UDim2.new(0,size,0,size);
7302 Transparency = 1;
7303 })
7304 if not template then
7305 template = Instance.new("Frame")
7306 template.BorderSizePixel = 0
7307 end
7308
7309 local transform
7310 if dir == nil or dir == 'Up' then
7311 function transform(p,s) return p,s end
7312 elseif dir == 'Down' then
7313 function transform(p,s) return UDim2.new(0,p.X.Offset,0,size-p.Y.Offset-1),s end
7314 elseif dir == 'Left' then
7315 function transform(p,s) return UDim2.new(0,p.Y.Offset,0,p.X.Offset),UDim2.new(0,s.Y.Offset,0,s.X.Offset) end
7316 elseif dir == 'Right' then
7317 function transform(p,s) return UDim2.new(0,size-p.Y.Offset-1,0,p.X.Offset),UDim2.new(0,s.Y.Offset,0,s.X.Offset) end
7318 end
7319
7320 local scale
7321 if scaled then
7322 function scale(p,s) return UDim2.new(p.X.Offset/size,0,p.Y.Offset/size,0),UDim2.new(s.X.Offset/size,0,s.Y.Offset/size,0) end
7323 else
7324 function scale(p,s) return p,s end
7325 end
7326
7327 local o = math.floor(size/4)
7328 if size%2 == 0 then
7329 local n = size/2-1
7330 for i = 0,n do
7331 local t = template:Clone()
7332 local p,s = scale(transform(
7333 UDim2.new(0,n-i,0,o+i),
7334 UDim2.new(0,(i+1)*2,0,1)
7335 ))
7336 t.Position = p
7337 t.Size = s
7338 t.Parent = Frame
7339 end
7340 else
7341 local n = (size-1)/2
7342 for i = 0,n do
7343 local t = template:Clone()
7344 local p,s = scale(transform(
7345 UDim2.new(0,n-i,0,o+i),
7346 UDim2.new(0,i*2+1,0,1)
7347 ))
7348 t.Position = p
7349 t.Size = s
7350 t.Parent = Frame
7351 end
7352 end
7353 if size%4 > 1 then
7354 local t = template:Clone()
7355 local p,s = scale(transform(
7356 UDim2.new(0,0,0,size-o-1),
7357 UDim2.new(0,size,0,1)
7358 ))
7359 t.Position = p
7360 t.Size = s
7361 t.Parent = Frame
7362 end
7363 return Frame
7364end
7365
7366function GripGraphic(size,dir,spacing,scaled,template)
7367 local Frame = Create('Frame',{
7368 Name = "Grip Graphic";
7369 BorderSizePixel = 0;
7370 Size = UDim2.new(0,size.x,0,size.y);
7371 Transparency = 1;
7372 })
7373 if not template then
7374 template = Instance.new("Frame")
7375 template.BorderSizePixel = 0
7376 end
7377
7378 spacing = spacing or 2
7379
7380 local scale
7381 if scaled then
7382 function scale(p) return UDim2.new(p.X.Offset/size.x,0,p.Y.Offset/size.y,0) end
7383 else
7384 function scale(p) return p end
7385 end
7386
7387 if dir == 'Vertical' then
7388 for i=0,size.x-1,spacing do
7389 local t = template:Clone()
7390 t.Size = scale(UDim2.new(0,1,0,size.y))
7391 t.Position = scale(UDim2.new(0,i,0,0))
7392 t.Parent = Frame
7393 end
7394 elseif dir == nil or dir == 'Horizontal' then
7395 for i=0,size.y-1,spacing do
7396 local t = template:Clone()
7397 t.Size = scale(UDim2.new(0,size.x,0,1))
7398 t.Position = scale(UDim2.new(0,0,0,i))
7399 t.Parent = Frame
7400 end
7401 end
7402
7403 return Frame
7404end
7405
7406do
7407 local mt = {
7408 __index = {
7409 GetScrollPercent = function(self)
7410 return self.ScrollIndex/(self.TotalSpace-self.VisibleSpace)
7411 end;
7412 CanScrollDown = function(self)
7413 return self.ScrollIndex + self.VisibleSpace < self.TotalSpace
7414 end;
7415 CanScrollUp = function(self)
7416 return self.ScrollIndex > 0
7417 end;
7418 ScrollDown = function(self)
7419 self.ScrollIndex = self.ScrollIndex + self.PageIncrement
7420 self:Update()
7421 end;
7422 ScrollUp = function(self)
7423 self.ScrollIndex = self.ScrollIndex - self.PageIncrement
7424 self:Update()
7425 end;
7426 ScrollTo = function(self,index)
7427 self.ScrollIndex = index
7428 self:Update()
7429 end;
7430 SetScrollPercent = function(self,percent)
7431 self.ScrollIndex = math.floor((self.TotalSpace - self.VisibleSpace)*percent + 0.5)
7432 self:Update()
7433 end;
7434 };
7435 }
7436 mt.__index.CanScrollRight = mt.__index.CanScrollDown
7437 mt.__index.CanScrollLeft = mt.__index.CanScrollUp
7438 mt.__index.ScrollLeft = mt.__index.ScrollUp
7439 mt.__index.ScrollRight = mt.__index.ScrollDown
7440
7441 function ScrollBar(horizontal)
7442 -- create row scroll bar
7443 local ScrollFrame = Create('Frame',{
7444 Name = "ScrollFrame";
7445 Position = horizontal and UDim2.new(0,0,1,-ScrollBarWidth) or UDim2.new(1,-ScrollBarWidth,0,0);
7446 Size = horizontal and UDim2.new(1,0,0,ScrollBarWidth) or UDim2.new(0,ScrollBarWidth,1,0);
7447 BackgroundTransparency = 1;
7448 Create('ImageButton',{
7449 Name = "ScrollDown";
7450 Position = horizontal and UDim2.new(1,-ScrollBarWidth,0,0) or UDim2.new(0,0,1,-ScrollBarWidth);
7451 Size = UDim2.new(0, ScrollBarWidth, 0, ScrollBarWidth);
7452 BackgroundColor3 = ScrollStyles.Button;
7453 BorderColor3 = ScrollStyles.Border;
7454 --BorderSizePixel = 0;
7455 });
7456 Create('ImageButton',{
7457 Name = "ScrollUp";
7458 Size = UDim2.new(0, ScrollBarWidth, 0, ScrollBarWidth);
7459 BackgroundColor3 = ScrollStyles.Button;
7460 BorderColor3 = ScrollStyles.Border;
7461 --BorderSizePixel = 0;
7462 });
7463 Create('ImageButton',{
7464 Name = "ScrollBar";
7465 Size = horizontal and UDim2.new(1,-ScrollBarWidth*2,1,0) or UDim2.new(1,0,1,-ScrollBarWidth*2);
7466 Position = horizontal and UDim2.new(0,ScrollBarWidth,0,0) or UDim2.new(0,0,0,ScrollBarWidth);
7467 AutoButtonColor = false;
7468 BackgroundColor3 = Color3.new(0.94902, 0.94902, 0.94902);
7469 BorderColor3 = ScrollStyles.Border;
7470 --BorderSizePixel = 0;
7471 Create('ImageButton',{
7472 Name = "ScrollThumb";
7473 AutoButtonColor = false;
7474 Size = UDim2.new(0, ScrollBarWidth, 0, ScrollBarWidth);
7475 BackgroundColor3 = ScrollStyles.Button;
7476 BorderColor3 = ScrollStyles.Border;
7477 --BorderSizePixel = 0;
7478 });
7479 });
7480 })
7481
7482 local graphicTemplate = Create('Frame',{
7483 Name="Graphic";
7484 BorderSizePixel = 0;
7485 BackgroundColor3 = ScrollStyles.Border;
7486 })
7487 local graphicSize = ScrollBarWidth/2
7488
7489 local ScrollDownFrame = ScrollFrame.ScrollDown
7490 local ScrollDownGraphic = ArrowGraphic(graphicSize,horizontal and 'Right' or 'Down',true,graphicTemplate)
7491 ScrollDownGraphic.Position = UDim2.new(0.5,-graphicSize/2,0.5,-graphicSize/2)
7492 ScrollDownGraphic.Parent = ScrollDownFrame
7493 local ScrollUpFrame = ScrollFrame.ScrollUp
7494 local ScrollUpGraphic = ArrowGraphic(graphicSize,horizontal and 'Left' or 'Up',true,graphicTemplate)
7495 ScrollUpGraphic.Position = UDim2.new(0.5,-graphicSize/2,0.5,-graphicSize/2)
7496 ScrollUpGraphic.Parent = ScrollUpFrame
7497 local ScrollBarFrame = ScrollFrame.ScrollBar
7498 local ScrollThumbFrame = ScrollBarFrame.ScrollThumb
7499 do
7500 local size = ScrollBarWidth*3/8
7501 local Decal = GripGraphic(Vector2.new(size,size),horizontal and 'Vertical' or 'Horizontal',2,graphicTemplate)
7502 Decal.Position = UDim2.new(0.5,-size/2,0.5,-size/2)
7503 Decal.Parent = ScrollThumbFrame
7504 end
7505
7506 local MouseDrag = Create('ImageButton',{
7507 Name = "MouseDrag";
7508 Position = UDim2.new(-0.25,0,-0.25,0);
7509 Size = UDim2.new(1.5,0,1.5,0);
7510 Transparency = 1;
7511 AutoButtonColor = false;
7512 Active = true;
7513 ZIndex = 10;
7514 })
7515
7516 local Class = setmetatable({
7517 GUI = ScrollFrame;
7518 ScrollIndex = 0;
7519 VisibleSpace = 0;
7520 TotalSpace = 0;
7521 PageIncrement = 1;
7522 },mt)
7523
7524 local UpdateScrollThumb
7525 if horizontal then
7526 function UpdateScrollThumb()
7527 ScrollThumbFrame.Size = UDim2.new(Class.VisibleSpace/Class.TotalSpace,0,0,ScrollBarWidth)
7528 if ScrollThumbFrame.AbsoluteSize.x < ScrollBarWidth then
7529 ScrollThumbFrame.Size = UDim2.new(0,ScrollBarWidth,0,ScrollBarWidth)
7530 end
7531 local barSize = ScrollBarFrame.AbsoluteSize.x
7532 ScrollThumbFrame.Position = UDim2.new(Class:GetScrollPercent()*(barSize - ScrollThumbFrame.AbsoluteSize.x)/barSize,0,0,0)
7533 end
7534 else
7535 function UpdateScrollThumb()
7536 ScrollThumbFrame.Size = UDim2.new(0,ScrollBarWidth,Class.VisibleSpace/Class.TotalSpace,0)
7537 if ScrollThumbFrame.AbsoluteSize.y < ScrollBarWidth then
7538 ScrollThumbFrame.Size = UDim2.new(0,ScrollBarWidth,0,ScrollBarWidth)
7539 end
7540 local barSize = ScrollBarFrame.AbsoluteSize.y
7541 ScrollThumbFrame.Position = UDim2.new(0,0,Class:GetScrollPercent()*(barSize - ScrollThumbFrame.AbsoluteSize.y)/barSize,0)
7542 end
7543 end
7544
7545 local lastDown
7546 local lastUp
7547 local scrollStyle = {BackgroundColor3=ScrollStyles.Border,BackgroundTransparency=0}
7548 local scrollStyle_ds = {BackgroundColor3=ScrollStyles.Border,BackgroundTransparency=0.7}
7549
7550 local function Update()
7551 local t = Class.TotalSpace
7552 local v = Class.VisibleSpace
7553 local s = Class.ScrollIndex
7554 if v <= t then
7555 if s > 0 then
7556 if s + v > t then
7557 Class.ScrollIndex = t - v
7558 end
7559 else
7560 Class.ScrollIndex = 0
7561 end
7562 else
7563 Class.ScrollIndex = 0
7564 end
7565
7566 if Class.UpdateCallback then
7567 if Class.UpdateCallback(Class) == false then
7568 return
7569 end
7570 end
7571
7572 local down = Class:CanScrollDown()
7573 local up = Class:CanScrollUp()
7574 if down ~= lastDown then
7575 lastDown = down
7576 ScrollDownFrame.Active = down
7577 ScrollDownFrame.AutoButtonColor = down
7578 local children = ScrollDownGraphic:GetChildren()
7579 local style = down and scrollStyle or scrollStyle_ds
7580 for i = 1,#children do
7581 Create(children[i],style)
7582 end
7583 end
7584 if up ~= lastUp then
7585 lastUp = up
7586 ScrollUpFrame.Active = up
7587 ScrollUpFrame.AutoButtonColor = up
7588 local children = ScrollUpGraphic:GetChildren()
7589 local style = up and scrollStyle or scrollStyle_ds
7590 for i = 1,#children do
7591 Create(children[i],style)
7592 end
7593 end
7594 ScrollThumbFrame.Visible = down or up
7595 UpdateScrollThumb()
7596 end
7597 Class.Update = Update
7598
7599 SetZIndexOnChanged(ScrollFrame)
7600
7601 local scrollEventID = 0
7602 ScrollDownFrame.MouseButton1Down:connect(function()
7603 scrollEventID = tick()
7604 local current = scrollEventID
7605 local up_con
7606 up_con = MouseDrag.MouseButton1Up:connect(function()
7607 scrollEventID = tick()
7608 MouseDrag.Parent = nil
7609 ResetButtonColor(ScrollDownFrame)
7610 up_con:disconnect(); drag = nil
7611 end)
7612 MouseDrag.Parent = GetScreen(ScrollFrame)
7613 Class:ScrollDown()
7614 wait(0.2) -- delay before auto scroll
7615 while scrollEventID == current do
7616 Class:ScrollDown()
7617 if not Class:CanScrollDown() then break end
7618 wait()
7619 end
7620 end)
7621
7622 ScrollDownFrame.MouseButton1Up:connect(function()
7623 scrollEventID = tick()
7624 end)
7625
7626 ScrollUpFrame.MouseButton1Down:connect(function()
7627 scrollEventID = tick()
7628 local current = scrollEventID
7629 local up_con
7630 up_con = MouseDrag.MouseButton1Up:connect(function()
7631 scrollEventID = tick()
7632 MouseDrag.Parent = nil
7633 ResetButtonColor(ScrollUpFrame)
7634 up_con:disconnect(); drag = nil
7635 end)
7636 MouseDrag.Parent = GetScreen(ScrollFrame)
7637 Class:ScrollUp()
7638 wait(0.2)
7639 while scrollEventID == current do
7640 Class:ScrollUp()
7641 if not Class:CanScrollUp() then break end
7642 wait()
7643 end
7644 end)
7645
7646 ScrollUpFrame.MouseButton1Up:connect(function()
7647 scrollEventID = tick()
7648 end)
7649
7650 if horizontal then
7651 ScrollBarFrame.MouseButton1Down:connect(function(x,y)
7652 scrollEventID = tick()
7653 local current = scrollEventID
7654 local up_con
7655 up_con = MouseDrag.MouseButton1Up:connect(function()
7656 scrollEventID = tick()
7657 MouseDrag.Parent = nil
7658 ResetButtonColor(ScrollUpFrame)
7659 up_con:disconnect(); drag = nil
7660 end)
7661 MouseDrag.Parent = GetScreen(ScrollFrame)
7662 if x > ScrollThumbFrame.AbsolutePosition.x then
7663 Class:ScrollTo(Class.ScrollIndex + Class.VisibleSpace)
7664 wait(0.2)
7665 while scrollEventID == current do
7666 if x < ScrollThumbFrame.AbsolutePosition.x + ScrollThumbFrame.AbsoluteSize.x then break end
7667 Class:ScrollTo(Class.ScrollIndex + Class.VisibleSpace)
7668 wait()
7669 end
7670 else
7671 Class:ScrollTo(Class.ScrollIndex - Class.VisibleSpace)
7672 wait(0.2)
7673 while scrollEventID == current do
7674 if x > ScrollThumbFrame.AbsolutePosition.x then break end
7675 Class:ScrollTo(Class.ScrollIndex - Class.VisibleSpace)
7676 wait()
7677 end
7678 end
7679 end)
7680 else
7681 ScrollBarFrame.MouseButton1Down:connect(function(x,y)
7682 scrollEventID = tick()
7683 local current = scrollEventID
7684 local up_con
7685 up_con = MouseDrag.MouseButton1Up:connect(function()
7686 scrollEventID = tick()
7687 MouseDrag.Parent = nil
7688 ResetButtonColor(ScrollUpFrame)
7689 up_con:disconnect(); drag = nil
7690 end)
7691 MouseDrag.Parent = GetScreen(ScrollFrame)
7692 if y > ScrollThumbFrame.AbsolutePosition.y then
7693 Class:ScrollTo(Class.ScrollIndex + Class.VisibleSpace)
7694 wait(0.2)
7695 while scrollEventID == current do
7696 if y < ScrollThumbFrame.AbsolutePosition.y + ScrollThumbFrame.AbsoluteSize.y then break end
7697 Class:ScrollTo(Class.ScrollIndex + Class.VisibleSpace)
7698 wait()
7699 end
7700 else
7701 Class:ScrollTo(Class.ScrollIndex - Class.VisibleSpace)
7702 wait(0.2)
7703 while scrollEventID == current do
7704 if y > ScrollThumbFrame.AbsolutePosition.y then break end
7705 Class:ScrollTo(Class.ScrollIndex - Class.VisibleSpace)
7706 wait()
7707 end
7708 end
7709 end)
7710 end
7711
7712 if horizontal then
7713 ScrollThumbFrame.MouseButton1Down:connect(function(x,y)
7714 scrollEventID = tick()
7715 local mouse_offset = x - ScrollThumbFrame.AbsolutePosition.x
7716 local drag_con
7717 local up_con
7718 drag_con = MouseDrag.MouseMoved:connect(function(x,y)
7719 local bar_abs_pos = ScrollBarFrame.AbsolutePosition.x
7720 local bar_drag = ScrollBarFrame.AbsoluteSize.x - ScrollThumbFrame.AbsoluteSize.x
7721 local bar_abs_one = bar_abs_pos + bar_drag
7722 x = x - mouse_offset
7723 x = x < bar_abs_pos and bar_abs_pos or x > bar_abs_one and bar_abs_one or x
7724 x = x - bar_abs_pos
7725 Class:SetScrollPercent(x/(bar_drag))
7726 end)
7727 up_con = MouseDrag.MouseButton1Up:connect(function()
7728 scrollEventID = tick()
7729 MouseDrag.Parent = nil
7730 ResetButtonColor(ScrollThumbFrame)
7731 drag_con:disconnect(); drag_con = nil
7732 up_con:disconnect(); drag = nil
7733 end)
7734 MouseDrag.Parent = GetScreen(ScrollFrame)
7735 end)
7736 else
7737 ScrollThumbFrame.MouseButton1Down:connect(function(x,y)
7738 scrollEventID = tick()
7739 local mouse_offset = y - ScrollThumbFrame.AbsolutePosition.y
7740 local drag_con
7741 local up_con
7742 drag_con = MouseDrag.MouseMoved:connect(function(x,y)
7743 local bar_abs_pos = ScrollBarFrame.AbsolutePosition.y
7744 local bar_drag = ScrollBarFrame.AbsoluteSize.y - ScrollThumbFrame.AbsoluteSize.y
7745 local bar_abs_one = bar_abs_pos + bar_drag
7746 y = y - mouse_offset
7747 y = y < bar_abs_pos and bar_abs_pos or y > bar_abs_one and bar_abs_one or y
7748 y = y - bar_abs_pos
7749 Class:SetScrollPercent(y/(bar_drag))
7750 end)
7751 up_con = MouseDrag.MouseButton1Up:connect(function()
7752 scrollEventID = tick()
7753 MouseDrag.Parent = nil
7754 ResetButtonColor(ScrollThumbFrame)
7755 drag_con:disconnect(); drag_con = nil
7756 up_con:disconnect(); drag = nil
7757 end)
7758 MouseDrag.Parent = GetScreen(ScrollFrame)
7759 end)
7760 end
7761
7762 function Class:Destroy()
7763 ScrollFrame:Destroy()
7764 MouseDrag:Destroy()
7765 for k in pairs(Class) do
7766 Class[k] = nil
7767 end
7768 setmetatable(Class,nil)
7769 end
7770
7771 Update()
7772
7773 return Class
7774 end
7775end
7776
7777----------------------------------------------------------------
7778----------------------------------------------------------------
7779----------------------------------------------------------------
7780----------------------------------------------------------------
7781
7782local MainFrame = Instance.new("Frame")
7783MainFrame.Name = "MainFrame"
7784MainFrame.Size = UDim2.new(1, -1 * ScrollBarWidth, 1, 0)
7785MainFrame.Position = UDim2.new(0, 0, 0, 0)
7786MainFrame.BackgroundTransparency = 1
7787MainFrame.ClipsDescendants = true
7788MainFrame.Parent = PropertiesFrame
7789
7790ContentFrame = Instance.new("Frame")
7791ContentFrame.Name = "ContentFrame"
7792ContentFrame.Size = UDim2.new(1, 0, 0, 0)
7793ContentFrame.BackgroundTransparency = 1
7794ContentFrame.Parent = MainFrame
7795
7796scrollBar = ScrollBar(false)
7797scrollBar.PageIncrement = 1
7798Create(scrollBar.GUI,{
7799 Position = UDim2.new(1,-ScrollBarWidth,0,0);
7800 Size = UDim2.new(0,ScrollBarWidth,1,0);
7801 Parent = PropertiesFrame;
7802})
7803
7804scrollBarH = ScrollBar(true)
7805scrollBarH.PageIncrement = ScrollBarWidth
7806Create(scrollBarH.GUI,{
7807 Position = UDim2.new(0,0,1,-ScrollBarWidth);
7808 Size = UDim2.new(1,-ScrollBarWidth,0,ScrollBarWidth);
7809 Visible = false;
7810 Parent = PropertiesFrame;
7811})
7812
7813do
7814 local listEntries = {}
7815 local nameConnLookup = {}
7816
7817 function scrollBar.UpdateCallback(self)
7818 scrollBar.TotalSpace = ContentFrame.AbsoluteSize.Y
7819 scrollBar.VisibleSpace = MainFrame.AbsoluteSize.Y
7820 ContentFrame.Position = UDim2.new(ContentFrame.Position.X.Scale,ContentFrame.Position.X.Offset,0,-1*scrollBar.ScrollIndex)
7821 end
7822
7823 function scrollBarH.UpdateCallback(self)
7824
7825 end
7826
7827 MainFrame.Changed:connect(function(p)
7828 if p == 'AbsoluteSize' then
7829 scrollBarH.VisibleSpace = math.ceil(MainFrame.AbsoluteSize.x)
7830 scrollBarH:Update()
7831 scrollBar.VisibleSpace = math.ceil(MainFrame.AbsoluteSize.y)
7832 scrollBar:Update()
7833 end
7834 end)
7835
7836 local wheelAmount = Row.Height
7837 PropertiesFrame.MouseWheelForward:connect(function()
7838 if scrollBar.VisibleSpace - 1 > wheelAmount then
7839 scrollBar:ScrollTo(scrollBar.ScrollIndex - wheelAmount)
7840 else
7841 scrollBar:ScrollTo(scrollBar.ScrollIndex - scrollBar.VisibleSpace)
7842 end
7843 end)
7844 PropertiesFrame.MouseWheelBackward:connect(function()
7845 if scrollBar.VisibleSpace - 1 > wheelAmount then
7846 scrollBar:ScrollTo(scrollBar.ScrollIndex + wheelAmount)
7847 else
7848 scrollBar:ScrollTo(scrollBar.ScrollIndex + scrollBar.VisibleSpace)
7849 end
7850 end)
7851end
7852
7853scrollBar.VisibleSpace = math.ceil(MainFrame.AbsoluteSize.y)
7854scrollBar:Update()
7855
7856showProperties(GetSelection())
7857
7858bindSelectionChanged.Event:connect(function()
7859 showProperties(GetSelection())
7860end)
7861
7862bindSetAwait.Event:connect(function(obj)
7863 if AwaitingObjectValue then
7864 AwaitingObjectValue = false
7865 local mySel = obj
7866 if mySel then
7867 pcall(function()
7868 Set(AwaitingObjectObj, AwaitingObjectProp, mySel)
7869 end)
7870 end
7871 end
7872end)
7873
7874propertiesSearch.Changed:connect(function(prop)
7875 if prop == "Text" then
7876 showProperties(GetSelection())
7877 end
7878end)
7879
7880bindGetApi.OnInvoke = function()
7881 return RbxApi
7882end
7883
7884bindGetAwait.OnInvoke = function()
7885 return AwaitingObjectValue
7886end
7887end)
7888
7889spawn(function()
7890 local top = D_E_X.ScriptEditor
7891
7892local editorGrid = top:WaitForChild("EditorGrid")
7893
7894local currentSource = ""
7895
7896local currentEditor = {
7897 x = 0,
7898 y = 0
7899}
7900
7901local userInput = game:GetService("UserInputService")
7902local mouse = game.Players.LocalPlayer:GetMouse()
7903
7904local topBar = top:WaitForChild("TopBar")
7905local scriptBar = topBar:WaitForChild("ScriptBar")
7906local scriptBarLeft = topBar:WaitForChild("ScriptBarLeft")
7907local scriptBarRight = topBar:WaitForChild("ScriptBarRight")
7908local clipboardButton = topBar:WaitForChild("Clipboard")
7909
7910local entryTemplate = topBar:WaitForChild("Entry")
7911
7912local openEvent = top:WaitForChild("OpenScript")
7913
7914local closeButton = top:WaitForChild("Close")
7915
7916local memoryScripts = {}
7917
7918local editingIndex = 0
7919
7920-- Scrollbar
7921
7922local ScrollBarWidth = 16
7923
7924local ScrollStyles = {
7925 Background = Color3.new(233/255, 233/255, 233/255);
7926 Border = Color3.new(149/255, 149/255, 149/255);
7927 Selected = Color3.new( 63/255, 119/255, 189/255);
7928 BorderSelected = Color3.new( 55/255, 106/255, 167/255);
7929 Text = Color3.new( 0/255, 0/255, 0/255);
7930 TextDisabled = Color3.new(128/255, 128/255, 128/255);
7931 TextSelected = Color3.new(255/255, 255/255, 255/255);
7932 Button = Color3.new(221/255, 221/255, 221/255);
7933 ButtonBorder = Color3.new(149/255, 149/255, 149/255);
7934 ButtonSelected = Color3.new(255/255, 0/255, 0/255);
7935 Field = Color3.new(255/255, 255/255, 255/255);
7936 FieldBorder = Color3.new(191/255, 191/255, 191/255);
7937 TitleBackground = Color3.new(178/255, 178/255, 178/255);
7938}
7939do
7940 local ZIndexLock = {}
7941 function SetZIndex(object,z)
7942 if not ZIndexLock[object] then
7943 ZIndexLock[object] = true
7944 if object:IsA'GuiObject' then
7945 object.ZIndex = z
7946 end
7947 local children = object:GetChildren()
7948 for i = 1,#children do
7949 SetZIndex(children[i],z)
7950 end
7951 ZIndexLock[object] = nil
7952 end
7953 end
7954end
7955function SetZIndexOnChanged(object)
7956 return object.Changed:connect(function(p)
7957 if p == "ZIndex" then
7958 SetZIndex(object,object.ZIndex)
7959 end
7960 end)
7961end
7962function Create(ty,data)
7963 local obj
7964 if type(ty) == 'string' then
7965 obj = Instance.new(ty)
7966 else
7967 obj = ty
7968 end
7969 for k, v in pairs(data) do
7970 if type(k) == 'number' then
7971 v.Parent = obj
7972 else
7973 obj[k] = v
7974 end
7975 end
7976 return obj
7977end
7978-- returns the ascendant ScreenGui of an object
7979function GetScreen(screen)
7980 if screen == nil then return nil end
7981 while not screen:IsA("ScreenGui") do
7982 screen = screen.Parent
7983 if screen == nil then return nil end
7984 end
7985 return screen
7986end
7987-- AutoButtonColor doesn't always reset properly
7988function ResetButtonColor(button)
7989 local active = button.Active
7990 button.Active = not active
7991 button.Active = active
7992end
7993
7994function ArrowGraphic(size,dir,scaled,template)
7995 local Frame = Create('Frame',{
7996 Name = "Arrow Graphic";
7997 BorderSizePixel = 0;
7998 Size = UDim2.new(0,size,0,size);
7999 Transparency = 1;
8000 })
8001 if not template then
8002 template = Instance.new("Frame")
8003 template.BorderSizePixel = 0
8004 end
8005
8006 local transform
8007 if dir == nil or dir == 'Up' then
8008 function transform(p,s) return p,s end
8009 elseif dir == 'Down' then
8010 function transform(p,s) return UDim2.new(0,p.X.Offset,0,size-p.Y.Offset-1),s end
8011 elseif dir == 'Left' then
8012 function transform(p,s) return UDim2.new(0,p.Y.Offset,0,p.X.Offset),UDim2.new(0,s.Y.Offset,0,s.X.Offset) end
8013 elseif dir == 'Right' then
8014 function transform(p,s) return UDim2.new(0,size-p.Y.Offset-1,0,p.X.Offset),UDim2.new(0,s.Y.Offset,0,s.X.Offset) end
8015 end
8016
8017 local scale
8018 if scaled then
8019 function scale(p,s) return UDim2.new(p.X.Offset/size,0,p.Y.Offset/size,0),UDim2.new(s.X.Offset/size,0,s.Y.Offset/size,0) end
8020 else
8021 function scale(p,s) return p,s end
8022 end
8023
8024 local o = math.floor(size/4)
8025 if size%2 == 0 then
8026 local n = size/2-1
8027 for i = 0,n do
8028 local t = template:Clone()
8029 local p,s = scale(transform(
8030 UDim2.new(0,n-i,0,o+i),
8031 UDim2.new(0,(i+1)*2,0,1)
8032 ))
8033 t.Position = p
8034 t.Size = s
8035 t.Parent = Frame
8036 end
8037 else
8038 local n = (size-1)/2
8039 for i = 0,n do
8040 local t = template:Clone()
8041 local p,s = scale(transform(
8042 UDim2.new(0,n-i,0,o+i),
8043 UDim2.new(0,i*2+1,0,1)
8044 ))
8045 t.Position = p
8046 t.Size = s
8047 t.Parent = Frame
8048 end
8049 end
8050 if size%4 > 1 then
8051 local t = template:Clone()
8052 local p,s = scale(transform(
8053 UDim2.new(0,0,0,size-o-1),
8054 UDim2.new(0,size,0,1)
8055 ))
8056 t.Position = p
8057 t.Size = s
8058 t.Parent = Frame
8059 end
8060 return Frame
8061end
8062
8063function GripGraphic(size,dir,spacing,scaled,template)
8064 local Frame = Create('Frame',{
8065 Name = "Grip Graphic";
8066 BorderSizePixel = 0;
8067 Size = UDim2.new(0,size.x,0,size.y);
8068 Transparency = 1;
8069 })
8070 if not template then
8071 template = Instance.new("Frame")
8072 template.BorderSizePixel = 0
8073 end
8074
8075 spacing = spacing or 2
8076
8077 local scale
8078 if scaled then
8079 function scale(p) return UDim2.new(p.X.Offset/size.x,0,p.Y.Offset/size.y,0) end
8080 else
8081 function scale(p) return p end
8082 end
8083
8084 if dir == 'Vertical' then
8085 for i=0,size.x-1,spacing do
8086 local t = template:Clone()
8087 t.Size = scale(UDim2.new(0,1,0,size.y))
8088 t.Position = scale(UDim2.new(0,i,0,0))
8089 t.Parent = Frame
8090 end
8091 elseif dir == nil or dir == 'Horizontal' then
8092 for i=0,size.y-1,spacing do
8093 local t = template:Clone()
8094 t.Size = scale(UDim2.new(0,size.x,0,1))
8095 t.Position = scale(UDim2.new(0,0,0,i))
8096 t.Parent = Frame
8097 end
8098 end
8099
8100 return Frame
8101end
8102
8103do
8104 local mt = {
8105 __index = {
8106 GetScrollPercent = function(self)
8107 return self.ScrollIndex/(self.TotalSpace-self.VisibleSpace)
8108 end;
8109 CanScrollDown = function(self)
8110 return self.ScrollIndex + self.VisibleSpace < self.TotalSpace
8111 end;
8112 CanScrollUp = function(self)
8113 return self.ScrollIndex > 0
8114 end;
8115 ScrollDown = function(self)
8116 self.ScrollIndex = self.ScrollIndex + self.PageIncrement
8117 self:Update()
8118 end;
8119 ScrollUp = function(self)
8120 self.ScrollIndex = self.ScrollIndex - self.PageIncrement
8121 self:Update()
8122 end;
8123 ScrollTo = function(self,index)
8124 self.ScrollIndex = index
8125 self:Update()
8126 end;
8127 SetScrollPercent = function(self,percent)
8128 self.ScrollIndex = math.floor((self.TotalSpace - self.VisibleSpace)*percent + 0.5)
8129 self:Update()
8130 end;
8131 };
8132 }
8133 mt.__index.CanScrollRight = mt.__index.CanScrollDown
8134 mt.__index.CanScrollLeft = mt.__index.CanScrollUp
8135 mt.__index.ScrollLeft = mt.__index.ScrollUp
8136 mt.__index.ScrollRight = mt.__index.ScrollDown
8137
8138 function ScrollBar(horizontal)
8139 -- create row scroll bar
8140 local ScrollFrame = Create('Frame',{
8141 Name = "ScrollFrame";
8142 Position = horizontal and UDim2.new(0,0,1,-ScrollBarWidth) or UDim2.new(1,-ScrollBarWidth,0,0);
8143 Size = horizontal and UDim2.new(1,0,0,ScrollBarWidth) or UDim2.new(0,ScrollBarWidth,1,0);
8144 BackgroundTransparency = 1;
8145 Create('ImageButton',{
8146 Name = "ScrollDown";
8147 Position = horizontal and UDim2.new(1,-ScrollBarWidth,0,0) or UDim2.new(0,0,1,-ScrollBarWidth);
8148 Size = UDim2.new(0, ScrollBarWidth, 0, ScrollBarWidth);
8149 BackgroundColor3 = ScrollStyles.Button;
8150 BorderColor3 = ScrollStyles.Border;
8151 --BorderSizePixel = 0;
8152 });
8153 Create('ImageButton',{
8154 Name = "ScrollUp";
8155 Size = UDim2.new(0, ScrollBarWidth, 0, ScrollBarWidth);
8156 BackgroundColor3 = ScrollStyles.Button;
8157 BorderColor3 = ScrollStyles.Border;
8158 --BorderSizePixel = 0;
8159 });
8160 Create('ImageButton',{
8161 Name = "ScrollBar";
8162 Size = horizontal and UDim2.new(1,-ScrollBarWidth*2,1,0) or UDim2.new(1,0,1,-ScrollBarWidth*2);
8163 Position = horizontal and UDim2.new(0,ScrollBarWidth,0,0) or UDim2.new(0,0,0,ScrollBarWidth);
8164 AutoButtonColor = false;
8165 BackgroundColor3 = Color3.new(0.94902, 0.94902, 0.94902);
8166 BorderColor3 = ScrollStyles.Border;
8167 --BorderSizePixel = 0;
8168 Create('ImageButton',{
8169 Name = "ScrollThumb";
8170 AutoButtonColor = false;
8171 Size = UDim2.new(0, ScrollBarWidth, 0, ScrollBarWidth);
8172 BackgroundColor3 = ScrollStyles.Button;
8173 BorderColor3 = ScrollStyles.Border;
8174 --BorderSizePixel = 0;
8175 });
8176 });
8177 })
8178
8179 local graphicTemplate = Create('Frame',{
8180 Name="Graphic";
8181 BorderSizePixel = 0;
8182 BackgroundColor3 = ScrollStyles.Border;
8183 })
8184 local graphicSize = ScrollBarWidth/2
8185
8186 local ScrollDownFrame = ScrollFrame.ScrollDown
8187 local ScrollDownGraphic = ArrowGraphic(graphicSize,horizontal and 'Right' or 'Down',true,graphicTemplate)
8188 ScrollDownGraphic.Position = UDim2.new(0.5,-graphicSize/2,0.5,-graphicSize/2)
8189 ScrollDownGraphic.Parent = ScrollDownFrame
8190 local ScrollUpFrame = ScrollFrame.ScrollUp
8191 local ScrollUpGraphic = ArrowGraphic(graphicSize,horizontal and 'Left' or 'Up',true,graphicTemplate)
8192 ScrollUpGraphic.Position = UDim2.new(0.5,-graphicSize/2,0.5,-graphicSize/2)
8193 ScrollUpGraphic.Parent = ScrollUpFrame
8194 local ScrollBarFrame = ScrollFrame.ScrollBar
8195 local ScrollThumbFrame = ScrollBarFrame.ScrollThumb
8196 do
8197 local size = ScrollBarWidth*3/8
8198 local Decal = GripGraphic(Vector2.new(size,size),horizontal and 'Vertical' or 'Horizontal',2,graphicTemplate)
8199 Decal.Position = UDim2.new(0.5,-size/2,0.5,-size/2)
8200 Decal.Parent = ScrollThumbFrame
8201 end
8202
8203 local MouseDrag = Create('ImageButton',{
8204 Name = "MouseDrag";
8205 Position = UDim2.new(-0.25,0,-0.25,0);
8206 Size = UDim2.new(1.5,0,1.5,0);
8207 Transparency = 1;
8208 AutoButtonColor = false;
8209 Active = true;
8210 ZIndex = 10;
8211 })
8212
8213 local Class = setmetatable({
8214 GUI = ScrollFrame;
8215 ScrollIndex = 0;
8216 VisibleSpace = 0;
8217 TotalSpace = 0;
8218 PageIncrement = 1;
8219 },mt)
8220
8221 local UpdateScrollThumb
8222 if horizontal then
8223 function UpdateScrollThumb()
8224 ScrollThumbFrame.Size = UDim2.new(Class.VisibleSpace/Class.TotalSpace,0,0,ScrollBarWidth)
8225 if ScrollThumbFrame.AbsoluteSize.x < ScrollBarWidth then
8226 ScrollThumbFrame.Size = UDim2.new(0,ScrollBarWidth,0,ScrollBarWidth)
8227 end
8228 local barSize = ScrollBarFrame.AbsoluteSize.x
8229 ScrollThumbFrame.Position = UDim2.new(Class:GetScrollPercent()*(barSize - ScrollThumbFrame.AbsoluteSize.x)/barSize,0,0,0)
8230 end
8231 else
8232 function UpdateScrollThumb()
8233 ScrollThumbFrame.Size = UDim2.new(0,ScrollBarWidth,Class.VisibleSpace/Class.TotalSpace,0)
8234 if ScrollThumbFrame.AbsoluteSize.y < ScrollBarWidth then
8235 ScrollThumbFrame.Size = UDim2.new(0,ScrollBarWidth,0,ScrollBarWidth)
8236 end
8237 local barSize = ScrollBarFrame.AbsoluteSize.y
8238 ScrollThumbFrame.Position = UDim2.new(0,0,Class:GetScrollPercent()*(barSize - ScrollThumbFrame.AbsoluteSize.y)/barSize,0)
8239 end
8240 end
8241
8242 local lastDown
8243 local lastUp
8244 local scrollStyle = {BackgroundColor3=ScrollStyles.Border,BackgroundTransparency=0}
8245 local scrollStyle_ds = {BackgroundColor3=ScrollStyles.Border,BackgroundTransparency=0.7}
8246
8247 local function Update()
8248 local t = Class.TotalSpace
8249 local v = Class.VisibleSpace
8250 local s = Class.ScrollIndex
8251 if v <= t then
8252 if s > 0 then
8253 if s + v > t then
8254 Class.ScrollIndex = t - v
8255 end
8256 else
8257 Class.ScrollIndex = 0
8258 end
8259 else
8260 Class.ScrollIndex = 0
8261 end
8262
8263 if Class.UpdateCallback then
8264 if Class.UpdateCallback(Class) == false then
8265 return
8266 end
8267 end
8268
8269 local down = Class:CanScrollDown()
8270 local up = Class:CanScrollUp()
8271 if down ~= lastDown then
8272 lastDown = down
8273 ScrollDownFrame.Active = down
8274 ScrollDownFrame.AutoButtonColor = down
8275 local children = ScrollDownGraphic:GetChildren()
8276 local style = down and scrollStyle or scrollStyle_ds
8277 for i = 1,#children do
8278 Create(children[i],style)
8279 end
8280 end
8281 if up ~= lastUp then
8282 lastUp = up
8283 ScrollUpFrame.Active = up
8284 ScrollUpFrame.AutoButtonColor = up
8285 local children = ScrollUpGraphic:GetChildren()
8286 local style = up and scrollStyle or scrollStyle_ds
8287 for i = 1,#children do
8288 Create(children[i],style)
8289 end
8290 end
8291 ScrollThumbFrame.Visible = down or up
8292 UpdateScrollThumb()
8293 end
8294 Class.Update = Update
8295
8296 SetZIndexOnChanged(ScrollFrame)
8297
8298 local scrollEventID = 0
8299 ScrollDownFrame.MouseButton1Down:connect(function()
8300 scrollEventID = tick()
8301 local current = scrollEventID
8302 local up_con
8303 up_con = MouseDrag.MouseButton1Up:connect(function()
8304 scrollEventID = tick()
8305 MouseDrag.Parent = nil
8306 ResetButtonColor(ScrollDownFrame)
8307 up_con:disconnect(); drag = nil
8308 end)
8309 MouseDrag.Parent = GetScreen(ScrollFrame)
8310 Class:ScrollDown()
8311 wait(0.2) -- delay before auto scroll
8312 while scrollEventID == current do
8313 Class:ScrollDown()
8314 if not Class:CanScrollDown() then break end
8315 wait()
8316 end
8317 end)
8318
8319 ScrollDownFrame.MouseButton1Up:connect(function()
8320 scrollEventID = tick()
8321 end)
8322
8323 ScrollUpFrame.MouseButton1Down:connect(function()
8324 scrollEventID = tick()
8325 local current = scrollEventID
8326 local up_con
8327 up_con = MouseDrag.MouseButton1Up:connect(function()
8328 scrollEventID = tick()
8329 MouseDrag.Parent = nil
8330 ResetButtonColor(ScrollUpFrame)
8331 up_con:disconnect(); drag = nil
8332 end)
8333 MouseDrag.Parent = GetScreen(ScrollFrame)
8334 Class:ScrollUp()
8335 wait(0.2)
8336 while scrollEventID == current do
8337 Class:ScrollUp()
8338 if not Class:CanScrollUp() then break end
8339 wait()
8340 end
8341 end)
8342
8343 ScrollUpFrame.MouseButton1Up:connect(function()
8344 scrollEventID = tick()
8345 end)
8346
8347 if horizontal then
8348 ScrollBarFrame.MouseButton1Down:connect(function(x,y)
8349 scrollEventID = tick()
8350 local current = scrollEventID
8351 local up_con
8352 up_con = MouseDrag.MouseButton1Up:connect(function()
8353 scrollEventID = tick()
8354 MouseDrag.Parent = nil
8355 ResetButtonColor(ScrollUpFrame)
8356 up_con:disconnect(); drag = nil
8357 end)
8358 MouseDrag.Parent = GetScreen(ScrollFrame)
8359 if x > ScrollThumbFrame.AbsolutePosition.x then
8360 Class:ScrollTo(Class.ScrollIndex + Class.VisibleSpace)
8361 wait(0.2)
8362 while scrollEventID == current do
8363 if x < ScrollThumbFrame.AbsolutePosition.x + ScrollThumbFrame.AbsoluteSize.x then break end
8364 Class:ScrollTo(Class.ScrollIndex + Class.VisibleSpace)
8365 wait()
8366 end
8367 else
8368 Class:ScrollTo(Class.ScrollIndex - Class.VisibleSpace)
8369 wait(0.2)
8370 while scrollEventID == current do
8371 if x > ScrollThumbFrame.AbsolutePosition.x then break end
8372 Class:ScrollTo(Class.ScrollIndex - Class.VisibleSpace)
8373 wait()
8374 end
8375 end
8376 end)
8377 else
8378 ScrollBarFrame.MouseButton1Down:connect(function(x,y)
8379 scrollEventID = tick()
8380 local current = scrollEventID
8381 local up_con
8382 up_con = MouseDrag.MouseButton1Up:connect(function()
8383 scrollEventID = tick()
8384 MouseDrag.Parent = nil
8385 ResetButtonColor(ScrollUpFrame)
8386 up_con:disconnect(); drag = nil
8387 end)
8388 MouseDrag.Parent = GetScreen(ScrollFrame)
8389 if y > ScrollThumbFrame.AbsolutePosition.y then
8390 Class:ScrollTo(Class.ScrollIndex + Class.VisibleSpace)
8391 wait(0.2)
8392 while scrollEventID == current do
8393 if y < ScrollThumbFrame.AbsolutePosition.y + ScrollThumbFrame.AbsoluteSize.y then break end
8394 Class:ScrollTo(Class.ScrollIndex + Class.VisibleSpace)
8395 wait()
8396 end
8397 else
8398 Class:ScrollTo(Class.ScrollIndex - Class.VisibleSpace)
8399 wait(0.2)
8400 while scrollEventID == current do
8401 if y > ScrollThumbFrame.AbsolutePosition.y then break end
8402 Class:ScrollTo(Class.ScrollIndex - Class.VisibleSpace)
8403 wait()
8404 end
8405 end
8406 end)
8407 end
8408
8409 if horizontal then
8410 ScrollThumbFrame.MouseButton1Down:connect(function(x,y)
8411 scrollEventID = tick()
8412 local mouse_offset = x - ScrollThumbFrame.AbsolutePosition.x
8413 local drag_con
8414 local up_con
8415 drag_con = MouseDrag.MouseMoved:connect(function(x,y)
8416 local bar_abs_pos = ScrollBarFrame.AbsolutePosition.x
8417 local bar_drag = ScrollBarFrame.AbsoluteSize.x - ScrollThumbFrame.AbsoluteSize.x
8418 local bar_abs_one = bar_abs_pos + bar_drag
8419 x = x - mouse_offset
8420 x = x < bar_abs_pos and bar_abs_pos or x > bar_abs_one and bar_abs_one or x
8421 x = x - bar_abs_pos
8422 Class:SetScrollPercent(x/(bar_drag))
8423 end)
8424 up_con = MouseDrag.MouseButton1Up:connect(function()
8425 scrollEventID = tick()
8426 MouseDrag.Parent = nil
8427 ResetButtonColor(ScrollThumbFrame)
8428 drag_con:disconnect(); drag_con = nil
8429 up_con:disconnect(); drag = nil
8430 end)
8431 MouseDrag.Parent = GetScreen(ScrollFrame)
8432 end)
8433 else
8434 ScrollThumbFrame.MouseButton1Down:connect(function(x,y)
8435 scrollEventID = tick()
8436 local mouse_offset = y - ScrollThumbFrame.AbsolutePosition.y
8437 local drag_con
8438 local up_con
8439 drag_con = MouseDrag.MouseMoved:connect(function(x,y)
8440 local bar_abs_pos = ScrollBarFrame.AbsolutePosition.y
8441 local bar_drag = ScrollBarFrame.AbsoluteSize.y - ScrollThumbFrame.AbsoluteSize.y
8442 local bar_abs_one = bar_abs_pos + bar_drag
8443 y = y - mouse_offset
8444 y = y < bar_abs_pos and bar_abs_pos or y > bar_abs_one and bar_abs_one or y
8445 y = y - bar_abs_pos
8446 Class:SetScrollPercent(y/(bar_drag))
8447 end)
8448 up_con = MouseDrag.MouseButton1Up:connect(function()
8449 scrollEventID = tick()
8450 MouseDrag.Parent = nil
8451 ResetButtonColor(ScrollThumbFrame)
8452 drag_con:disconnect(); drag_con = nil
8453 up_con:disconnect(); drag = nil
8454 end)
8455 MouseDrag.Parent = GetScreen(ScrollFrame)
8456 end)
8457 end
8458
8459 function Class:Destroy()
8460 ScrollFrame:Destroy()
8461 MouseDrag:Destroy()
8462 for k in pairs(Class) do
8463 Class[k] = nil
8464 end
8465 setmetatable(Class,nil)
8466 end
8467
8468 Update()
8469
8470 return Class
8471 end
8472end
8473
8474-- End Scrollbar
8475
8476local scrollBar = ScrollBar(false)
8477scrollBar.PageIncrement = 16
8478Create(scrollBar.GUI,{
8479 Position = UDim2.new(1,0,0,0);
8480 Size = UDim2.new(0,ScrollBarWidth,1,0);
8481 Parent = editorGrid;
8482})
8483
8484local scrollBarH = ScrollBar(true)
8485scrollBarH.PageIncrement = 8
8486Create(scrollBarH.GUI,{
8487 Position = UDim2.new(0,0,1,0);
8488 Size = UDim2.new(1,0,0,ScrollBarWidth);
8489 Parent = editorGrid;
8490})
8491
8492local entries = {}
8493
8494local grid = {}
8495
8496local count = 1
8497local xCount = 1
8498
8499local lineSpan = 0
8500
8501for i = 0,490,8 do
8502 local newRow = {}
8503 for j = 0,390,16 do
8504 local cellText = Instance.new("TextLabel",editorGrid)
8505 cellText.BackgroundTransparency = 1
8506 cellText.BorderSizePixel = 0
8507 cellText.Text = ""
8508 cellText.Position = UDim2.new(0,i,0,j)
8509 cellText.Size = UDim2.new(0,8,0,16)
8510 cellText.Font = Enum.Font.SourceSans
8511 cellText.FontSize = Enum.FontSize.Size18
8512 table.insert(newRow,cellText)
8513 xCount = xCount + 1
8514 end
8515 table.insert(grid,newRow)
8516 count = count + 1
8517 xCount = 1
8518end
8519
8520local syntaxHighlightList = {
8521 {["Keyword"] = "for", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8522 {["Keyword"] = "local", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8523 {["Keyword"] = "if", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8524 {["Keyword"] = "then", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8525 {["Keyword"] = "do", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8526 {["Keyword"] = "while", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8527 {["Keyword"] = "end", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8528 {["Keyword"] = "function", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8529 {["Keyword"] = "string", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8530 {["Keyword"] = "table", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8531 {["Keyword"] = "game", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8532 {["Keyword"] = "workspace", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8533 {["Keyword"] = "return", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8534 {["Keyword"] = "break", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8535 {["Keyword"] = "elseif", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8536 {["Keyword"] = "in", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8537 {["Keyword"] = "pairs", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true},
8538 {["Keyword"] = "ipairs", ["Color"] = Color3.new(0, 0, 127/255), ["Independent"] = true}
8539}
8540
8541function checkMouseInGui(gui)
8542 if gui == nil then return false end
8543 local plrMouse = game.Players.LocalPlayer:GetMouse()
8544 local guiPosition = gui.AbsolutePosition
8545 local guiSize = gui.AbsoluteSize
8546
8547 if plrMouse.X >= guiPosition.x and plrMouse.X <= guiPosition.x + guiSize.x and plrMouse.Y >= guiPosition.y and plrMouse.Y <= guiPosition.y + guiSize.y then
8548 return true
8549 else
8550 return false
8551 end
8552end
8553
8554function AddZeros(num,reach)
8555 local toConvert = tostring(num)
8556 while #toConvert < reach do
8557 toConvert = " "..toConvert
8558 end
8559 return toConvert
8560end
8561
8562function buildScript(source,xOff,yOff,override)
8563 local buildingRows = true
8564 local buildScr = source
8565
8566 local totalLines = 0
8567
8568 --print(xOff,yOff)
8569
8570 if currentSource ~= source then
8571 currentSource = source
8572 end
8573
8574 if override then
8575 currentSource = source
8576 entries = {}
8577 while buildingRows do
8578 local x,y = string.find(buildScr,"\n")
8579 if x and y then
8580 table.insert(entries,string.sub(buildScr,1,y))
8581 buildScr = string.sub(buildScr,y+1,string.len(buildScr))
8582 else
8583 buildingRows = false
8584 table.insert(entries,buildScr)
8585 end
8586 end
8587 end
8588
8589 totalLines = #entries
8590 lineSpan = #tostring(totalLines)
8591
8592 if lineSpan == 1 then lineSpan = 2 end
8593
8594 local currentRow = 1
8595 local currentColumn = 2 + lineSpan
8596
8597 local colorTime = 0
8598 local colorReplace = nil
8599
8600 local inString = false
8601
8602 local workingEntries = entries
8603
8604 --[[
8605 for i,v in pairs(entries) do
8606 table.insert(workingEntries,v)
8607 end
8608
8609 for i = 1,yOff do
8610 table.remove(workingEntries,1)
8611 end
8612 --]]
8613
8614 local delayance = xOff
8615
8616 for i = 1,#grid do
8617 for j = 1,#grid[i] do
8618 if i <= lineSpan then
8619 local newNum = AddZeros(yOff + j,lineSpan)
8620 local newDigit = string.sub(newNum,i,i)
8621 if newDigit == " " then
8622 grid[i][j].Text = ""
8623 else
8624 grid[i][j].Text = newDigit
8625 end
8626 grid[i][j].BackgroundTransparency = 0
8627 grid[i][j].BackgroundColor3 = Color3.new(163/255, 162/255, 165/255)
8628 --grid[i][j].Font = Enum.Font.SourceSansBold
8629 elseif i == lineSpan + 1 then
8630 grid[i][j].Text = ""
8631 grid[i][j].BackgroundTransparency = 0
8632 grid[i][j].BackgroundColor3 = Color3.new(200/255, 200/255, 200/255)
8633 --grid[i][j].Font = Enum.Font.SourceSans
8634 else
8635 grid[i][j].Text = ""
8636 grid[i][j].BackgroundTransparency = 1
8637 --grid[i][j].Font = Enum.Font.SourceSans
8638 end
8639 end
8640 end
8641
8642 while true do
8643 if currentRow > #workingEntries or currentRow > #grid[1] then break end
8644 local entry = workingEntries[currentRow+yOff]
8645 while string.len(entry) > 0 do
8646 if string.sub(entry,1,1) == "\t" then entry = " "..string.sub(entry,2) end
8647
8648 if currentColumn > #grid then break end
8649
8650 if delayance == 0 then
8651 grid[currentColumn][currentRow].Text = string.sub(entry,1,1)
8652 end
8653
8654 -- Coloring
8655
8656 if not inString then
8657 for i,v in pairs(syntaxHighlightList) do
8658 if string.sub(entry,1,string.len(v["Keyword"])) == v["Keyword"] then
8659 if v["Independent"] then
8660 local outCheck = string.len(v["Keyword"])+1
8661 local outEntry = string.sub(entry,outCheck,outCheck)
8662 if not string.find(outEntry,"%w") then
8663 colorTime = string.len(v["Keyword"])
8664 colorReplace = v["Color"]
8665 end
8666 else
8667 colorTime = string.len(v["Keyword"])
8668 colorReplace = v["Color"]
8669 end
8670 end
8671 end
8672 end
8673
8674 if string.sub(entry,1,1) == "\"" and string.match(entry,"\".+\"") then
8675 inString = true
8676 colorTime = string.len(string.match(entry,"\".+\""))
8677 colorReplace = Color3.new(170/255, 0, 1)
8678 end
8679
8680 if colorTime > 0 then
8681 colorTime = colorTime - 1
8682 grid[currentColumn][currentRow].TextColor3 = colorReplace
8683 if colorTime == 0 then inString = false end
8684 else
8685 grid[currentColumn][currentRow].TextColor3 = Color3.new(0,0,0)
8686 inString = false
8687 end
8688
8689 if delayance == 0 then
8690 currentColumn = currentColumn + 1
8691 else
8692 delayance = delayance - 1
8693 end
8694 entry = string.sub(entry,2,string.len(entry))
8695 end
8696 currentRow = currentRow + 1
8697 currentColumn = 2 + lineSpan
8698 colorTime = 0
8699 delayance = xOff
8700 inString = false
8701 end
8702end
8703
8704function scrollBar.UpdateCallback(self)
8705 scrollBar.TotalSpace = #entries * 16
8706 scrollBar.VisibleSpace = editorGrid.AbsoluteSize.Y
8707 buildScript(currentSource,math.floor(scrollBarH.ScrollIndex/8),math.floor(scrollBar.ScrollIndex/16))
8708end
8709
8710function scrollBarH.UpdateCallback(self)
8711 scrollBarH.TotalSpace = (getLongestEntry(entries) + 1 + lineSpan) * 8
8712 scrollBarH.VisibleSpace = editorGrid.AbsoluteSize.X
8713 buildScript(currentSource,math.floor(scrollBarH.ScrollIndex/8),math.floor(scrollBar.ScrollIndex/16))
8714end
8715
8716function getLongestEntry(tab)
8717 local longest = 0
8718 for i,v in pairs(tab) do
8719 if string.len(v) > longest then
8720 longest = string.len(v)
8721 end
8722 end
8723 return longest
8724end
8725
8726function openScript(scrObj)
8727 if scrObj:IsA("LocalScript") then
8728 scrObj.Archivable = true
8729 scrObj = scrObj:Clone()
8730 scrObj.Disabled = true
8731 end
8732
8733 local scrName = scrObj.Name
8734 local scrSource = decompile(scrObj)
8735
8736 table.insert(memoryScripts,{Name = scrName,Source = scrSource})
8737
8738 local newTab = entryTemplate:Clone()
8739 newTab.Button.Text = scrName
8740 newTab.Position = UDim2.new(0,#scriptBar:GetChildren() * 100,0,0)
8741 newTab.Visible = true
8742
8743 newTab.Button.MouseButton1Down:connect(function()
8744 for i,v in pairs(scriptBar:GetChildren()) do
8745 if v == newTab then
8746 editingIndex = i
8747 buildScript(memoryScripts[i].Source,0,0,true)
8748 scrollBar:ScrollTo(1)
8749 scrollBar:Update()
8750 scrollBarH:ScrollTo(1)
8751 scrollBarH:Update()
8752 end
8753 end
8754 end)
8755
8756 newTab.Close.MouseButton1Click:connect(function()
8757 for i,v in pairs(scriptBar:GetChildren()) do
8758 if v == newTab then
8759 table.remove(memoryScripts,i)
8760 if editingIndex == i then
8761 editingIndex = #memoryScripts
8762 if editingIndex > 0 then
8763 buildScript(memoryScripts[#memoryScripts].Source,0,0,true)
8764 else
8765 buildScript("",0,0,true)
8766 end
8767 end
8768
8769 scrollBar:ScrollTo(1)
8770 scrollBar:Update()
8771 scrollBarH:ScrollTo(1)
8772 scrollBarH:Update()
8773
8774 for i2 = i,#scriptBar:GetChildren() do
8775 scriptBar:GetChildren()[i2].Position = scriptBar:GetChildren()[i2].Position + UDim2.new(0,-100,0,0)
8776 end
8777 if editingIndex > i then
8778 editingIndex = editingIndex - 1
8779 end
8780 newTab:Destroy()
8781 end
8782 end
8783 end)
8784
8785 editingIndex = #memoryScripts
8786 buildScript(scrSource,0,0,true)
8787
8788 newTab.Parent = scriptBar
8789end
8790
8791function updateScriptBar()
8792 local entryCount = 0
8793
8794 scriptBarLeft.Active = false
8795 scriptBarLeft.AutoButtonColor = false
8796 for i,v in pairs(scriptBarLeft["Arrow Graphic"]:GetChildren()) do
8797 v.BackgroundTransparency = 0.7
8798 end
8799 scriptBarRight.Active = false
8800 scriptBarRight.AutoButtonColor = false
8801 for i,v in pairs(scriptBarRight["Arrow Graphic"]:GetChildren()) do
8802 v.BackgroundTransparency = 0.7
8803 end
8804 for i,v in pairs(scriptBar:GetChildren()) do
8805 if v.Position.X.Offset < 0 then
8806 scriptBarLeft.Active = true
8807 scriptBarLeft.AutoButtonColor = true
8808 for i,v in pairs(scriptBarLeft["Arrow Graphic"]:GetChildren()) do
8809 v.BackgroundTransparency = 0
8810 end
8811 elseif v.Position.X.Offset >= 0 then
8812 entryCount = entryCount + 1
8813 if entryCount == 5 then
8814 scriptBarRight.Active = true
8815 scriptBarRight.AutoButtonColor = true
8816 for i,v in pairs(scriptBarRight["Arrow Graphic"]:GetChildren()) do
8817 v.BackgroundTransparency = 0
8818 end
8819 end
8820 end
8821 end
8822end
8823
8824scriptBar.ChildAdded:connect(updateScriptBar)
8825scriptBar.ChildRemoved:connect(updateScriptBar)
8826
8827scriptBarLeft.MouseButton1Click:connect(function()
8828 if scriptBarLeft.Active == false then return end
8829 for i,v in pairs(scriptBar:GetChildren()) do
8830 v.Position = v.Position + UDim2.new(0,100,0,0)
8831 end
8832 updateScriptBar()
8833end)
8834
8835scriptBarRight.MouseButton1Click:connect(function()
8836 if scriptBarRight.Active == false then return end
8837 for i,v in pairs(scriptBar:GetChildren()) do
8838 v.Position = v.Position + UDim2.new(0,-100,0,0)
8839 end
8840 updateScriptBar()
8841end)
8842
8843mouse.Button1Down:connect(function()
8844 if checkMouseInGui(editorGrid) then
8845 --print("LETS EDIT!")
8846 end
8847end)
8848
8849openEvent.Event:connect(function(...)
8850 top.Visible = true
8851 local args = {...}
8852 if #args > 0 then
8853 openScript(args[1])
8854 end
8855end)
8856
8857clipboardButton.MouseButton1Click:connect(function()
8858 if Clipboard and Clipboard.set then
8859 Clipboard.set(currentSource)
8860 elseif CopyString then
8861 CopyString(currentSource)
8862 end
8863end)
8864
8865closeButton.MouseButton1Click:connect(function()
8866 top.Visible = false
8867end)
8868
8869--[[
8870local scr = script.Parent:WaitForChild("Scr")
8871local scr2 = script.Parent:WaitForChild("Scr2")
8872local scr3 = script.Parent:WaitForChild("Scr3")
8873local scr4 = script.Parent:WaitForChild("TOS")
8874local scr5 = script.Parent:WaitForChild("HW")
8875--]]
8876
8877buildScript("",0,0,true)
8878--[[
8879openScript(scr)
8880openScript(scr2)
8881openScript(scr3)
8882openScript(scr4)
8883openScript(scr5)
8884--]]
8885
8886scrollBar:Update()
8887scrollBarH:Update()
8888end)
8889 end
8890button4.MouseButton1Click:connect(clicked)