Advertisement
HEHEJ

Untitled

Mar 27th, 2020
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 23.29 KB | None | 0 0
  1. function randomName()
  2. local data = ""
  3. for i=0,20,1 do
  4. data = data .. tostring(string.char(math.ceil(math.random() * 254)))
  5. end
  6. return data
  7. end
  8.  
  9.  
  10.  
  11.  
  12. local DaUiLib = Instance.new("ScreenGui")
  13. DaUiLib.Name = randomName()
  14. DaUiLib.Parent = game:GetService("CoreGui")
  15. DaUiLib.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
  16.  
  17.  
  18. local library = {}
  19.  
  20. local TweenService = game:GetService("TweenService")
  21. local uis = game:GetService("UserInputService")
  22. local tabcount = 0
  23. local rainbow = 0
  24. _G.breatherate = 0.005
  25. local color
  26. local rainbows = {}
  27. local buttoncount = {}
  28.  
  29.  
  30.  
  31. function library:CreateTab(name)
  32.  
  33. tabcount = tabcount+1
  34. buttoncount[tabcount] = 0
  35.  
  36. local topbar = Instance.new("Frame")
  37. local rgbbar = Instance.new("Frame")
  38. local title = Instance.new("TextLabel")
  39. local OpenClose = Instance.new("TextButton")
  40. local container = Instance.new("Frame")
  41. local UIListLayout = Instance.new("UIListLayout")
  42.  
  43. topbar.Name = "topbar"
  44. topbar.Parent = DaUiLib
  45. topbar.BackgroundColor3 = Color3.fromRGB(30, 30, 30)
  46. topbar.BorderSizePixel = 0
  47. topbar.Position = UDim2.new(0, (tabcount)*13+(tabcount-1)*200, 0.0128041022, -500)
  48. wait(0.3)
  49. topbar:TweenPosition(UDim2.new(0, (tabcount)*13+(tabcount-1)*200, 0.0128041022, 0))
  50.  
  51. topbar.Size = UDim2.new(0, 200, 0, 30)
  52.  
  53. rgbbar.Name = "rgbbar"
  54. rgbbar.Parent = topbar
  55. rgbbar.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  56. rgbbar.BorderSizePixel = 0
  57. rgbbar.Position = UDim2.new(0, 0, 1, -3)
  58. rgbbar.Size = UDim2.new(1, 0, 0, 3)
  59.  
  60. title.Name = "title"
  61. title.Parent = topbar
  62. title.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  63. title.BackgroundTransparency = 1.000
  64. title.BorderSizePixel = 0
  65. title.Position = UDim2.new(0, 5, 0, 0)
  66. title.Size = UDim2.new(1, -40, 1, 0)
  67. title.Font = Enum.Font.GothamBold
  68. title.Text = name
  69. title.TextColor3 = Color3.fromRGB(255, 255, 255)
  70. title.TextSize = 16.000
  71. title.TextXAlignment = Enum.TextXAlignment.Left
  72.  
  73. OpenClose.Name = "OpenClose"
  74. OpenClose.Parent = topbar
  75. OpenClose.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  76. OpenClose.BackgroundTransparency = 1.000
  77. OpenClose.Position = UDim2.new(0.861656487, 0, 0.0666666701, 0)
  78. OpenClose.Size = UDim2.new(0, 27, 0, 25)
  79. OpenClose.Font = Enum.Font.GothamBold
  80. OpenClose.Text = "+"
  81. OpenClose.TextColor3 = Color3.fromRGB(255, 255, 255)
  82. OpenClose.TextSize = 20.000
  83.  
  84.  
  85. container.Name = "container"
  86. container.Parent = topbar
  87. container.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
  88. container.BackgroundTransparency = 1.000
  89. container.BorderSizePixel = 0
  90. container.Position = UDim2.new(0, 2, 1, 0)
  91. container.Size = UDim2.new(1, -4, 0, 0)
  92. container.Visible = false
  93.  
  94.  
  95. UIListLayout.Parent = container
  96. UIListLayout.SortOrder = Enum.SortOrder.LayoutOrder
  97.  
  98.  
  99. OpenClose.MouseButton1Click:connect(function()
  100.  
  101. if container.Visible == false then
  102.  
  103.  
  104. container.Visible = true
  105.  
  106. OpenClose.Text = "-"
  107.  
  108.  
  109.  
  110. elseif container.Visible == true then
  111.  
  112.  
  113.  
  114. -- check
  115.  
  116.  
  117. container.Visible = false
  118.  
  119. OpenClose.Text = "+"
  120.  
  121.  
  122. end
  123.  
  124. end)
  125.  
  126.  
  127.  
  128.  
  129.  
  130. local uis = game:GetService("UserInputService")
  131. local dragthing = topbar
  132. dragthing.Active = true
  133.  
  134. local dragging
  135. local draginput
  136. local dragstart
  137. local startpos
  138.  
  139. local function update(input)
  140. local delta = input.Position - dragstart
  141. game:GetService("TweenService"):Create(dragthing, TweenInfo.new(.15), {Position = UDim2.new(startpos.X.Scale, startpos.X.Offset + delta.X, startpos.Y.Scale, startpos.Y.Offset + delta.Y)}):Play()
  142. end
  143.  
  144. dragthing.InputBegan:Connect(function(input)
  145. if input.UserInputType == Enum.UserInputType.MouseButton1 then
  146. dragging = true
  147. dragstart = input.Position
  148. startpos = dragthing.Position
  149.  
  150. input.Changed:Connect(function()
  151. if input.UserInputState == Enum.UserInputState.End then
  152. dragging = false
  153. end
  154. end)
  155. end
  156. end)
  157.  
  158. dragthing.InputChanged:Connect(function(input)
  159. if input.UserInputType == Enum.UserInputType.MouseMovement then
  160. draginput = input
  161. end
  162. end)
  163.  
  164. uis.InputChanged:Connect(function(input)
  165. if input == draginput and dragging then
  166. update(input)
  167. end
  168. end)
  169.  
  170. game:GetService("RunService").RenderStepped:Connect(function()
  171. local r = (math.sin(workspace.DistributedGameTime/2)/2)+0.5
  172. local g = (math.sin(workspace.DistributedGameTime)/2)+0.5
  173. local b = (math.sin(workspace.DistributedGameTime*1.5)/2)+0.5
  174. local color = Color3.new(r, g, b)
  175. rgbbar.BackgroundColor3 = color
  176. end)
  177.  
  178.  
  179. local GamerLibrary = {}
  180.  
  181.  
  182. function GamerLibrary:CreateButton(name,func)
  183. local ButtonFrame = Instance.new("Frame")
  184. local Button = Instance.new("TextButton")
  185.  
  186. ButtonFrame.Name = "ButtonFrame"
  187. ButtonFrame.Parent = container
  188. ButtonFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
  189. ButtonFrame.BorderColor3 = Color3.fromRGB(27, 42, 53)
  190. ButtonFrame.BorderSizePixel = 0
  191. ButtonFrame.Size = UDim2.new(0, 196, 0, 25)
  192.  
  193. Button.Name = "Button"
  194. Button.Parent = ButtonFrame
  195. Button.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  196. Button.BorderSizePixel = 0
  197. Button.Position = UDim2.new(0.0430000164, 0, 0.170000002, 0)
  198. Button.Size = UDim2.new(0, 180, 0, 18)
  199. Button.Font = Enum.Font.GothamBold
  200. Button.TextColor3 = Color3.fromRGB(255, 255, 255)
  201. Button.TextSize = 12.000
  202. Button.TextWrapped = true
  203. Button.Text = name
  204.  
  205. Button.MouseButton1Click:Connect(func);
  206.  
  207.  
  208. end
  209.  
  210. function GamerLibrary:CreateLabel(name)
  211.  
  212. local LabelFrame = Instance.new("Frame")
  213. local LabelTitle = Instance.new("TextLabel")
  214.  
  215. LabelFrame.Name = "LabelFrame"
  216. LabelFrame.Parent = container
  217. LabelFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
  218. LabelFrame.BorderSizePixel = 0
  219. LabelFrame.Position = UDim2.new(0, 0, 0.416666657, 0)
  220. LabelFrame.Size = UDim2.new(0, 196, 0, 20)
  221.  
  222. LabelTitle.Name = "LabelTitle"
  223. LabelTitle.Parent = LabelFrame
  224. LabelTitle.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  225. LabelTitle.BackgroundTransparency = 1.000
  226. LabelTitle.Position = UDim2.new(0.00613496918, 0, 0.25, 0)
  227. LabelTitle.Size = UDim2.new(0, 196, 0, 11)
  228. LabelTitle.Font = Enum.Font.GothamBold
  229. LabelTitle.TextColor3 = Color3.fromRGB(255, 255, 255)
  230. LabelTitle.TextSize = 12.000
  231. LabelTitle.Text = name
  232.  
  233. end
  234.  
  235. function GamerLibrary:CreateToggle(name, func)
  236. local ToggleFrame = Instance.new("Frame")
  237. local ToggleTitle = Instance.new("TextLabel")
  238. local OnOffButton = Instance.new("TextButton")
  239.  
  240.  
  241. ToggleFrame.Name = "ToggleFrame"
  242. ToggleFrame.Parent = container
  243. ToggleFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
  244. ToggleFrame.BorderColor3 = Color3.fromRGB(255, 255, 255)
  245. ToggleFrame.BorderSizePixel = 0
  246. ToggleFrame.Position = UDim2.new(0, 0, 0.223333329, 0)
  247. ToggleFrame.Size = UDim2.new(0, 196, 0, 25)
  248.  
  249. ToggleTitle.Name = "ToggleTitle"
  250. ToggleTitle.Parent = ToggleFrame
  251. ToggleTitle.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  252. ToggleTitle.BackgroundTransparency = 1.000
  253. ToggleTitle.Position = UDim2.new(0.0533092804, 0, 0.129999995, 0)
  254. ToggleTitle.Size = UDim2.new(0, 148, 0, 18)
  255. ToggleTitle.Font = Enum.Font.GothamBold
  256. ToggleTitle.Text = name
  257. ToggleTitle.TextColor3 = Color3.fromRGB(255, 255, 255)
  258. ToggleTitle.TextSize = 12.000
  259. ToggleTitle.TextXAlignment = Enum.TextXAlignment.Left
  260.  
  261. OnOffButton.Name = "OnOffButton"
  262. OnOffButton.Parent = ToggleTitle
  263. OnOffButton.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  264. OnOffButton.BackgroundTransparency = 1.000
  265. OnOffButton.Position = UDim2.new(-0.0470066592, 0, -0.0166659914, 0)
  266. OnOffButton.Size = UDim2.new(0, 186, 0, 18)
  267. OnOffButton.Font = Enum.Font.GothamBold
  268. OnOffButton.Text = "OFF "
  269. OnOffButton.TextColor3 = Color3.fromRGB(255, 0, 0)
  270. OnOffButton.TextSize = 13.000
  271. OnOffButton.TextWrapped = true
  272. OnOffButton.TextXAlignment = Enum.TextXAlignment.Right
  273.  
  274.  
  275.  
  276.  
  277. OnOffButton.MouseButton1Click:Connect(function()
  278. if OnOffButton.Text == "OFF " then
  279. func(true)
  280. OnOffButton.Text = "ON "
  281. OnOffButton.TextColor3 = Color3.fromRGB(0, 255, 0)
  282.  
  283. elseif OnOffButton.Text == "ON " then
  284. func(false)
  285. OnOffButton.TextColor3 = Color3.fromRGB(255, 0, 0)
  286. OnOffButton.Text = "OFF "
  287. end
  288. end)
  289.  
  290. end
  291.  
  292. function GamerLibrary:CreateSlider(name,min,max,func)
  293.  
  294. local SliderFrame = Instance.new("Frame")
  295. local SliderValue = Instance.new("TextLabel")
  296. local Slider = Instance.new("Frame")
  297. local Bar = Instance.new("Frame")
  298. local Knob = Instance.new("TextButton")
  299. local SliderText = Instance.new("TextLabel")
  300.  
  301. SliderFrame.Name = "SliderFrame"
  302. SliderFrame.Parent = container
  303. SliderFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
  304. SliderFrame.BorderSizePixel = 0
  305. SliderFrame.Position = UDim2.new(0, 0, 0.306666672, 0)
  306. SliderFrame.Size = UDim2.new(0, 196, 0, 25)
  307.  
  308. SliderValue.Name = "SliderValue"
  309. SliderValue.Parent = SliderFrame
  310. SliderValue.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  311. SliderValue.BackgroundTransparency = 1.000
  312. SliderValue.Position = UDim2.new(0.247160614, 0, 0.170000002, 0)
  313. SliderValue.Size = UDim2.new(0, 68, 0, 11)
  314. SliderValue.Font = Enum.Font.GothamBold
  315. SliderValue.Text = min
  316. SliderValue.TextColor3 = Color3.fromRGB(255, 255, 255)
  317. SliderValue.TextSize = 12.000
  318. SliderValue.TextXAlignment = Enum.TextXAlignment.Right
  319.  
  320. Slider.Name = "Slider"
  321. Slider.Parent = SliderFrame
  322. Slider.BackgroundColor3 = Color3.fromRGB(255, 0, 0)
  323. Slider.BackgroundTransparency = 1.000
  324. Slider.BorderSizePixel = 0
  325. Slider.Size = UDim2.new(0, 281, 0, 10)
  326.  
  327. Bar.Name = "Bar"
  328. Bar.Parent = Slider
  329. Bar.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  330. Bar.BorderSizePixel = 0
  331. Bar.Position = UDim2.new(0.434163719, 0, 0.692307711, 0)
  332. Bar.Size = UDim2.new(0, 67, 0, 3)
  333.  
  334. Knob.Name = "Knob"
  335. Knob.Parent = Bar
  336. Knob.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
  337. Knob.Position = UDim2.new(0, 0, -2, 0)
  338. Knob.Size = UDim2.new(0, 5, 0, 15)
  339. Knob.Font = Enum.Font.SourceSans
  340. Knob.Text = ""
  341. Knob.TextColor3 = Color3.fromRGB(0, 0, 0)
  342. Knob.TextSize = 14.000
  343.  
  344. SliderText.Name = "SliderText"
  345. SliderText.Parent = SliderFrame
  346. SliderText.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  347. SliderText.BackgroundTransparency = 1.000
  348. SliderText.Position = UDim2.new(0.0522887409, 0, 0, 0)
  349. SliderText.Size = UDim2.new(0, 81, 0, 21)
  350. SliderText.Font = Enum.Font.GothamBold
  351. SliderText.Text = name
  352. SliderText.TextColor3 = Color3.fromRGB(255, 255, 255)
  353. SliderText.TextSize = 12.000
  354. SliderText.TextXAlignment = Enum.TextXAlignment.Left
  355.  
  356.  
  357.  
  358. local knob = Knob;
  359. local valueChangedEvent = Instance.new("BindableEvent")
  360. local startXScale = -.05;
  361. local endXScale = .95;
  362. local MinValue = min
  363. local MaxValue = max
  364. local Valueasd;
  365. local mouse = game:GetService("Players").LocalPlayer:GetMouse()
  366.  
  367. valueChangedEvent.Name = "ValueChanged"
  368. valueChangedEvent.Archivable = true
  369.  
  370. -- Updates the position of the knob as well as the value
  371. local prevValue = nil;
  372. local function Update()
  373. local absPosition = Bar.AbsolutePosition.X;
  374. local absSize = Bar.AbsoluteSize.X;
  375. local mouseDelta = math.min(math.max(0, mouse.X - absPosition), absSize);
  376. local value = MinValue + ((mouseDelta / absSize) * (MaxValue - MinValue));
  377. Valueasd = math.floor(value)
  378. SliderValue.Text = math.floor(value)
  379. knob.Position = UDim2.new((mouseDelta / absSize) - .05, knob.Position.X.Offset, knob.Position.Y.Scale, knob.Position.Y.Offset);
  380. if (prevValue ~= nil and math.floor(prevValue) ~= math.floor(value)) then
  381. valueChangedEvent:Fire(prevValue, math.floor(value));
  382. prevValue = math.floor(value);
  383. else
  384. prevValue = math.floor(value);
  385. end
  386. end
  387.  
  388. -- Coroutine to keep updating
  389. local keepUpdating = false;
  390. local function Updater()
  391. while (true) do
  392. if (keepUpdating) then
  393. Update()
  394. func(Valueasd)
  395. end
  396. wait(.05)
  397. end
  398. end
  399. local taskCoro = coroutine.create(Updater)
  400. coroutine.resume(taskCoro);
  401.  
  402. -- Event Connecting
  403. knob.MouseButton1Down:Connect(function()
  404. keepUpdating = true;
  405.  
  406. end)
  407. local UserInputService = game:GetService("UserInputService")
  408. UserInputService.InputEnded:Connect(function(inputObject)
  409. if inputObject.UserInputType == Enum.UserInputType.MouseButton1 then
  410. keepUpdating = false;
  411.  
  412. end
  413. end)
  414.  
  415.  
  416.  
  417.  
  418.  
  419.  
  420. end
  421.  
  422. function GamerLibrary:CreateTextbox(name, deftext, func)
  423. local TextboxFrame = Instance.new("Frame")
  424. local TextboxTitle = Instance.new("TextLabel")
  425. local TextBoxTextbox = Instance.new("TextBox")
  426.  
  427. TextboxFrame.Name = "TextboxFrame"
  428. TextboxFrame.Parent = container
  429. TextboxFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
  430. TextboxFrame.BorderColor3 = Color3.fromRGB(255, 255, 255)
  431. TextboxFrame.BorderSizePixel = 0
  432. TextboxFrame.Position = UDim2.new(0, 0, 0.25, 0)
  433. TextboxFrame.Size = UDim2.new(0, 196, 0, 25)
  434.  
  435. TextboxTitle.Name = "TextboxTitle"
  436. TextboxTitle.Parent = TextboxFrame
  437. TextboxTitle.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  438. TextboxTitle.BackgroundTransparency = 1.000
  439. TextboxTitle.Position = UDim2.new(0.0535309464, 0, 0.129999995, 0)
  440. TextboxTitle.Size = UDim2.new(0, 94, 0, 18)
  441. TextboxTitle.Font = Enum.Font.GothamBold
  442. TextboxTitle.Text = name
  443. TextboxTitle.TextColor3 = Color3.fromRGB(255, 255, 255)
  444. TextboxTitle.TextSize = 12.000
  445. TextboxTitle.TextXAlignment = Enum.TextXAlignment.Left
  446.  
  447. TextBoxTextbox.Name = "TextBoxTextbox"
  448. TextBoxTextbox.Parent = TextboxTitle
  449. TextBoxTextbox.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  450. TextBoxTextbox.BorderColor3 = Color3.fromRGB(0, 0, 0)
  451. TextBoxTextbox.BorderSizePixel = 0;
  452. TextBoxTextbox.Position = UDim2.new(1, 0, -0.017, 0)
  453. TextBoxTextbox.Size = UDim2.new(0, 88, 0, 18)
  454. TextBoxTextbox.Font = Enum.Font.GothamBold
  455. TextBoxTextbox.PlaceholderText = deftext
  456. TextBoxTextbox.Text = ""
  457. TextBoxTextbox.TextColor3 = Color3.fromRGB(255, 255, 255)
  458. TextBoxTextbox.TextSize = 12.000
  459. TextBoxTextbox.TextWrapped = true
  460.  
  461.  
  462. TextBoxTextbox.FocusLost:Connect(function()
  463. func(TextBoxTextbox.Text)
  464. end)
  465.  
  466.  
  467.  
  468.  
  469.  
  470.  
  471.  
  472.  
  473.  
  474. end
  475.  
  476. function GamerLibrary:CreateKeybind(name,defkey, func)
  477.  
  478.  
  479. local KeybindFrame = Instance.new("Frame")
  480. local KeybindTitle = Instance.new("TextLabel")
  481. local KeybindButton = Instance.new("TextButton")
  482.  
  483.  
  484. KeybindFrame.Name = "KeybindFrame"
  485. KeybindFrame.Parent = container
  486. KeybindFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
  487. KeybindFrame.BorderColor3 = Color3.fromRGB(255, 255, 255)
  488. KeybindFrame.BorderSizePixel = 0
  489. KeybindFrame.Position = UDim2.new(0, 0, 0.25, 0)
  490. KeybindFrame.Size = UDim2.new(0, 196, 0, 25)
  491.  
  492. KeybindTitle.Name = "KeybindTitle"
  493. KeybindTitle.Parent = KeybindFrame
  494. KeybindTitle.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  495. KeybindTitle.BackgroundTransparency = 1.000
  496. KeybindTitle.Position = UDim2.new(0.0535309762, 0, 0.129999995, 0)
  497. KeybindTitle.Size = UDim2.new(0, 142, 0, 18)
  498. KeybindTitle.Font = Enum.Font.GothamBold
  499. KeybindTitle.Text = name
  500. KeybindTitle.TextColor3 = Color3.fromRGB(255, 255, 255)
  501. KeybindTitle.TextSize = 12.000
  502. KeybindTitle.TextXAlignment = Enum.TextXAlignment.Left
  503.  
  504. KeybindButton.Name = "KeybindButton"
  505. KeybindButton.Parent = KeybindTitle
  506. KeybindButton.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  507. KeybindButton.BorderColor3 = Color3.fromRGB(0, 0, 0)
  508. KeybindButton.BorderSizePixel = 0;
  509. KeybindButton.Position = UDim2.new(0.952993333, 0, -0.0166659877, 0)
  510. KeybindButton.Size = UDim2.new(0, 36, 0, 18)
  511. KeybindButton.Font = Enum.Font.GothamBold
  512. KeybindButton.Text = string.upper(defkey)
  513. KeybindButton.TextColor3 = Color3.fromRGB(255, 255, 255)
  514. KeybindButton.TextSize = 12.000
  515. KeybindButton.TextWrapped = true
  516.  
  517. local enabled = false
  518. local mouse = game.Players.LocalPlayer:GetMouse()
  519.  
  520.  
  521. KeybindButton.MouseButton1Click:connect(function()
  522. KeybindButton.Text = "..."
  523. enabled = true
  524.  
  525.  
  526. mouse.KeyDown:Connect(function(key1)
  527. if enabled == true then
  528. KeybindButton.Text = string.upper(key1)
  529. enabled = false
  530. end
  531. end)
  532.  
  533.  
  534. end)
  535.  
  536.  
  537.  
  538. local enabled2 = false
  539.  
  540.  
  541. mouse.KeyDown:Connect(function(key223)
  542. enabled2 = true
  543. if key223 == string.lower(KeybindButton.Text) then
  544. if enabled2 == true then
  545. func()
  546. enabled2 = false
  547. end
  548. end
  549. end)
  550.  
  551.  
  552.  
  553. end
  554.  
  555. function GamerLibrary:CreatePlayerDropdown(name, func)
  556. local DropDownFrame = Instance.new("Frame")
  557. local DropDownTitle = Instance.new("TextLabel")
  558. local DropdownContainer = Instance.new("Frame")
  559. local Player1 = Instance.new("TextButton")
  560. local Player2 = Instance.new("TextButton")
  561. local Player3 = Instance.new("TextButton")
  562. local Player4 = Instance.new("TextButton")
  563. local Player5 = Instance.new("TextButton")
  564. local Player6 = Instance.new("TextButton")
  565. local UIListLayout_2 = Instance.new("UIListLayout")
  566. local DropDownClose = Instance.new("TextButton")
  567.  
  568.  
  569.  
  570. DropDownFrame.Name = "DropDownFrame"
  571. DropDownFrame.Parent = container
  572. DropDownFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
  573. DropDownFrame.BorderSizePixel = 0
  574. DropDownFrame.Position = UDim2.new(0, 0, 0.0833333358, 0)
  575. DropDownFrame.Size = UDim2.new(0, 196, 0, 25)
  576.  
  577. DropDownTitle.Name = "DropDownTitle"
  578. DropDownTitle.Parent = DropDownFrame
  579. DropDownTitle.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  580. DropDownTitle.BorderSizePixel = 0
  581. DropDownTitle.Position = UDim2.new(0.0430000164, 0, 0.170000002, 0)
  582. DropDownTitle.Size = UDim2.new(0, 181, 0, 18)
  583. DropDownTitle.Font = Enum.Font.GothamBold
  584. DropDownTitle.Text = "Select Player"
  585. DropDownTitle.TextColor3 = Color3.fromRGB(255, 255, 255)
  586. DropDownTitle.TextSize = 12.000
  587.  
  588. DropdownContainer.Name = "DropdownContainer"
  589. DropdownContainer.Parent = DropDownTitle
  590. DropdownContainer.Active = true
  591. DropdownContainer.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  592. DropdownContainer.BackgroundTransparency = 0
  593. DropdownContainer.Position = UDim2.new(0.00245944713, 0, 1.19658232, 0)
  594. DropdownContainer.Size = UDim2.new(0, 179, 0, 0)
  595. DropdownContainer.Visible = false
  596. DropdownContainer.LayoutOrder = -214748364
  597.  
  598. Player1.Name = "Player1"
  599. Player1.Parent = DropdownContainer
  600. Player1.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  601. Player1.BorderColor3 = Color3.fromRGB(255, 255, 255)
  602. Player1.BorderSizePixel = 0
  603. Player1.Size = UDim2.new(0, 179, 0, 18)
  604. Player1.Font = Enum.Font.GothamBold
  605. Player1.TextColor3 = Color3.fromRGB(255, 255, 255)
  606. Player1.TextSize = 12.000
  607. Player1.TextWrapped = true
  608. Player1.Text = "***"
  609.  
  610. Player2.Name = "Player2"
  611. Player2.Parent = DropdownContainer
  612. Player2.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  613. Player2.BorderColor3 = Color3.fromRGB(255, 255, 255)
  614. Player2.BorderSizePixel = 0
  615. Player2.Size = UDim2.new(0, 179, 0, 18)
  616. Player2.Font = Enum.Font.GothamBold
  617. Player2.TextColor3 = Color3.fromRGB(255, 255, 255)
  618. Player2.TextSize = 12.000
  619. Player2.TextWrapped = true
  620. Player2.Text = "***"
  621.  
  622. Player3.Name = "Player3"
  623. Player3.Parent = DropdownContainer
  624. Player3.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  625. Player3.BorderColor3 = Color3.fromRGB(255, 255, 255)
  626. Player3.BorderSizePixel = 0
  627. Player3.Size = UDim2.new(0, 179, 0, 18)
  628. Player3.Font = Enum.Font.GothamBold
  629. Player3.TextColor3 = Color3.fromRGB(255, 255, 255)
  630. Player3.TextSize = 12.000
  631. Player3.TextWrapped = true
  632. Player3.Text = "***"
  633.  
  634. Player4.Name = "Player4"
  635. Player4.Parent = DropdownContainer
  636. Player4.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  637. Player4.BorderColor3 = Color3.fromRGB(255, 255, 255)
  638. Player4.BorderSizePixel = 0
  639. Player4.Size = UDim2.new(0, 179, 0, 18)
  640. Player4.Font = Enum.Font.GothamBold
  641. Player4.TextColor3 = Color3.fromRGB(255, 255, 255)
  642. Player4.TextSize = 12.000
  643. Player4.TextWrapped = true
  644. Player4.Text = "***"
  645.  
  646. Player5.Name = "Player5"
  647. Player5.Parent = DropdownContainer
  648. Player5.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  649. Player5.BorderColor3 = Color3.fromRGB(255, 255, 255)
  650. Player5.BorderSizePixel = 0
  651. Player5.Size = UDim2.new(0, 179, 0, 18)
  652. Player5.Font = Enum.Font.GothamBold
  653. Player5.TextColor3 = Color3.fromRGB(255, 255, 255)
  654. Player5.TextSize = 12.000
  655. Player5.TextWrapped = true
  656. Player5.Text = "***"
  657.  
  658. Player6.Name = "Player6"
  659. Player6.Parent = DropdownContainer
  660. Player6.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  661. Player6.BorderColor3 = Color3.fromRGB(255, 255, 255)
  662. Player6.BorderSizePixel = 0
  663. Player6.Size = UDim2.new(0, 179, 0, 18)
  664. Player6.Font = Enum.Font.GothamBold
  665. Player6.TextColor3 = Color3.fromRGB(255, 255, 255)
  666. Player6.TextSize = 12.000
  667. Player6.TextWrapped = true
  668. Player6.Text = "***"
  669.  
  670.  
  671. UIListLayout_2.Parent = DropdownContainer
  672. UIListLayout_2.SortOrder = Enum.SortOrder.LayoutOrder
  673.  
  674. DropDownClose.Name = "OpenClose"
  675. DropDownClose.Parent = DropDownTitle
  676. DropDownClose.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
  677. DropDownClose.BackgroundTransparency = 1.000
  678. DropDownClose.Position = UDim2.new(0, 0, -0.017, 0)
  679. DropDownClose.Size = UDim2.new(0, 180, 0, 18)
  680. DropDownClose.Font = Enum.Font.GothamBold
  681. DropDownClose.Text = "▼ "
  682. DropDownClose.TextColor3 = Color3.fromRGB(255, 255, 255)
  683. DropDownClose.TextSize = 12.000
  684. DropDownClose.TextWrapped = true
  685. DropDownClose.TextXAlignment = Enum.TextXAlignment.Right
  686.  
  687.  
  688.  
  689.  
  690. DropDownClose.MouseButton1Click:Connect(function()
  691. if DropdownContainer.Visible == false then
  692. DropDownTitle.Text = "Select Player"
  693. DropdownContainer.Visible = true
  694. DropDownClose.Text = "▲ "
  695.  
  696. elseif DropdownContainer.Visible == true then
  697.  
  698. DropdownContainer.Visible = false
  699. DropDownClose.Text = "▼ "
  700.  
  701. end
  702. end)
  703.  
  704. Player1.MouseButton1Down:connect(function()
  705. DropDownTitle.Text = Player1.Text
  706. func(DropDownTitle.Text)
  707. DropdownContainer.Visible = false
  708. DropDownClose.Text = "▼ "
  709. if DropDownTitle.Text == "***" then
  710. DropDownTitle.Text = "Select Player"
  711. end
  712. end)
  713. Player2.MouseButton1Down:connect(function()
  714. DropDownTitle.Text = Player2.Text
  715. func(DropDownTitle.Text)
  716. DropdownContainer.Visible = false
  717. DropDownClose.Text = "▼ "
  718. if DropDownTitle.Text == "***" then
  719. DropDownTitle.Text = "Select Player"
  720. end
  721. end)
  722. Player3.MouseButton1Down:connect(function()
  723. DropDownTitle.Text = Player3.Text
  724. func(DropDownTitle.Text)
  725. DropdownContainer.Visible = false
  726. DropDownClose.Text = "▼ "
  727. if DropDownTitle.Text == "***" then
  728. DropDownTitle.Text = "Select Player"
  729. end
  730. end)
  731. Player4.MouseButton1Down:connect(function()
  732. DropDownTitle.Text = Player4.Text
  733. func(DropDownTitle.Text)
  734. DropdownContainer.Visible = false
  735. DropDownClose.Text = "▼ "
  736. if DropDownTitle.Text == "***" then
  737. DropDownTitle.Text = "Select Player"
  738.  
  739. end
  740. end)
  741. Player5.MouseButton1Down:connect(function()
  742. DropDownTitle.Text = Player5.Text
  743. func(DropDownTitle.Text)
  744. DropdownContainer.Visible = false
  745. DropDownClose.Text = "▼ "
  746. if DropDownTitle.Text == "***" then
  747. DropDownTitle.Text = "Select Player"
  748. end
  749. end)
  750. Player6.MouseButton1Down:connect(function()
  751. DropDownTitle.Text = Player6.Text
  752. func(DropDownTitle.Text)
  753. DropdownContainer.Visible = false
  754. DropDownClose.Text = "▼ "
  755. if DropDownTitle.Text == "***" then
  756. DropDownTitle.Text = "Select Player"
  757. end
  758. end)
  759. local buttons = {
  760. Player1,
  761. Player2,
  762. Player3,
  763. Player4,
  764. Player5,
  765. Player6
  766. }
  767.  
  768. for i, v in pairs(game.Players:GetChildren()) do
  769. buttons[i].Text = v.Name
  770. buttons[i].Visible = true
  771. end
  772. game.Players.PlayerRemoving:connect(function()
  773. for i, v in pairs(game.Players:GetChildren()) do
  774. buttons[i].Text = v.Name
  775. buttons[i].Visible = true
  776. end
  777. end)
  778. game.Players.PlayerAdded:connect(function()
  779. for i, v in pairs(game.Players:GetChildren()) do
  780. buttons[i].Text = v.Name
  781. buttons[i].Visible = true
  782. end
  783. end)
  784.  
  785.  
  786. end
  787.  
  788. return GamerLibrary;
  789.  
  790.  
  791.  
  792. end
  793.  
  794. return library;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement