Advertisement
HEHEJ

Untitled

Mar 19th, 2020
143
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.34 KB | None | 0 0
  1. local ScreenGui = Instance.new("ScreenGui")
  2. ScreenGui.Parent = game.Players.LocalPlayer:WaitForChild("PlayerGui")
  3. ScreenGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
  4. local UIListLayout_2 = Instance.new("UIListLayout")
  5.  
  6. UIListLayout_2.Parent = ScreenGui
  7. UIListLayout_2.FillDirection = Enum.FillDirection.Horizontal
  8. UIListLayout_2.SortOrder = Enum.SortOrder.LayoutOrder
  9. UIListLayout_2.Padding = UDim.new(0.00999999978, 0)
  10.  
  11.  
  12. local library = {}
  13.  
  14. function library:CreateTab(text)
  15. local Frame = Instance.new("Frame")
  16. local UIListLayout = Instance.new("UIListLayout")
  17. local Title = Instance.new("TextLabel")
  18.  
  19.  
  20.  
  21. Frame.Parent = ScreenGui
  22. Frame.BackgroundColor3 = Color3.fromRGB(63, 63, 63)
  23. Frame.Position = UDim2.new(0.0307219662, 0, 0.0197693575, 0)
  24. Frame.Size = UDim2.new(0, 200, 0, 202)
  25.  
  26. UIListLayout.Parent = Frame
  27. UIListLayout.SortOrder = Enum.SortOrder.LayoutOrder
  28.  
  29. Title.Name = text
  30. Title.Parent = Frame
  31. Title.BackgroundColor3 = Color3.fromRGB(107, 107, 107)
  32. Title.BorderColor3 = Color3.fromRGB(0, 0, 0)
  33. Title.BorderSizePixel = 4
  34. Title.Size = UDim2.new(0, 200, 0, 47)
  35. Title.Font = Enum.Font.Highway
  36. Title.Text = text
  37. Title.TextColor3 = Color3.fromRGB(255, 255, 255)
  38. Title.TextSize = 35.000
  39. Title.TextWrapped = true
  40.  
  41.  
  42. local GamerLibrary = {}
  43.  
  44. function GamerLibrary:CreateButton(name, func)
  45. local Button = Instance.new("TextButton")
  46.  
  47. Button.Name = name
  48. Button.Parent = Frame
  49. Button.BackgroundColor3 = Color3.fromRGB(63, 63, 63)
  50. Button.BorderColor3 = Color3.fromRGB(0, 0, 0)
  51. Button.BorderSizePixel = 2
  52. Button.Position = UDim2.new(0, 0, 0.0916179344, 0)
  53. Button.Size = UDim2.new(0, 200, 0, 33)
  54. Button.Font = Enum.Font.Highway
  55. Button.TextColor3 = Color3.fromRGB(255, 255, 255)
  56. Button.TextSize = 30.000
  57. Button.Text = name
  58. Button.MouseButton1Click:Connect(func)
  59. end
  60.  
  61. function GamerLibrary:CreateToggle(name, func)
  62. local ToggleText = Instance.new("TextLabel")
  63. local TextButton = Instance.new("TextButton")
  64.  
  65. ToggleText.Name = name
  66. ToggleText.Parent = Frame
  67. ToggleText.BackgroundColor3 = Color3.fromRGB(107, 107, 107)
  68. ToggleText.BackgroundTransparency = 1.000
  69. ToggleText.BorderColor3 = Color3.fromRGB(0, 0, 0)
  70. ToggleText.BorderSizePixel = 4
  71. ToggleText.Position = UDim2.new(0, 0, 0.15594542, 0)
  72. ToggleText.Size = UDim2.new(0, 136, 0, 38)
  73. ToggleText.Font = Enum.Font.Highway
  74. ToggleText.Text = name
  75. ToggleText.TextColor3 = Color3.fromRGB(255, 255, 255)
  76. ToggleText.TextSize = 30.000
  77. ToggleText.TextWrapped = true
  78.  
  79. TextButton.Parent = ToggleText
  80. TextButton.BackgroundColor3 = Color3.fromRGB(63, 63, 63)
  81. TextButton.BorderColor3 = Color3.fromRGB(0, 0, 0)
  82. TextButton.BorderSizePixel = 3
  83. TextButton.Position = UDim2.new(1.05882359, 0, 0.196881145, 0)
  84. TextButton.Size = UDim2.new(0, 44, 0, 30)
  85. TextButton.Font = Enum.Font.Highway
  86. TextButton.Text = "X"
  87. TextButton.TextColor3 = Color3.fromRGB(255, 255, 255)
  88. TextButton.TextSize = 30.000
  89. TextButton.MouseButton1Click:Connect(function()
  90. if TextButton.Text == "X" then
  91. func(true)
  92. TextButton.Text = "✓"
  93.  
  94. elseif TextButton.Text == "✓" then
  95.  
  96. TextButton.Text = "X"
  97. func(false)
  98. end
  99.  
  100. end)
  101. end
  102.  
  103. function GamerLibrary:CreateTextbox(name, defaulttext, func)
  104. local TextBoxText = Instance.new("TextLabel")
  105. local TextBox = Instance.new("TextBox")
  106.  
  107. TextBoxText.Name = name
  108. TextBoxText.Parent = Frame
  109. TextBoxText.BackgroundColor3 = Color3.fromRGB(107, 107, 107)
  110. TextBoxText.BackgroundTransparency = 1.000
  111. TextBoxText.BorderColor3 = Color3.fromRGB(0, 0, 0)
  112. TextBoxText.BorderSizePixel = 4
  113. TextBoxText.Position = UDim2.new(0, 0, 0.230019495, 0)
  114. TextBoxText.Size = UDim2.new(0, 200, 0, 80)
  115. TextBoxText.Font = Enum.Font.Highway
  116. TextBoxText.Text = name
  117. TextBoxText.TextColor3 = Color3.fromRGB(255, 255, 255)
  118. TextBoxText.TextSize = 30.000
  119. TextBoxText.TextWrapped = true
  120. TextBoxText.TextYAlignment = Enum.TextYAlignment.Top
  121.  
  122. TextBox.Parent = TextBoxText
  123. TextBox.BackgroundColor3 = Color3.fromRGB(43, 43, 43)
  124. TextBox.BorderColor3 = Color3.fromRGB(0, 0, 0)
  125. TextBox.BorderSizePixel = 3
  126. TextBox.Position = UDim2.new(0.0549999997, 0, 0.417582452, 0)
  127. TextBox.Size = UDim2.new(0, 177, 0, 38)
  128. TextBox.Font = Enum.Font.SourceSans
  129. TextBox.PlaceholderText = defaulttext
  130. TextBox.Text = ""
  131. TextBox.TextColor3 = Color3.fromRGB(255, 255, 255)
  132. TextBox.TextSize = 25.000
  133.  
  134. TextBox.FocusLost:Connect(function()
  135. func(TextBox.Text)
  136.  
  137. end)
  138. end
  139.  
  140. return GamerLibrary;
  141.  
  142. end
  143.  
  144. return library;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement