Trace2004tyler

PRISON LIFE 2.0 GUI SCRIPT

Nov 7th, 2017
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.47 KB | None | 0 0
  1. --Made by SWATchief196
  2. wait(1)
  3.  
  4. -- Local Player
  5. local p = game.Players.LocalPlayer
  6.  
  7. -- Instance Objects
  8. local gui = Instance.new('ScreenGui',p.PlayerGui)
  9. local frame = Instance.new('ScrollingFrame',gui)
  10. local open = Instance.new('TextButton',gui)
  11. local name = Instance.new('TextLabel',frame)
  12. local arrest = Instance.new('TextButton',frame)
  13. local btools = Instance.new('TextButton',frame)
  14. local escape = Instance.new('TextButton',frame)
  15. local exit = Instance.new('TextButton',frame)
  16. local killaura = Instance.new('TextButton',frame)
  17. local melee = Instance.new('TextButton',frame)
  18. local removedoors = Instance.new('TextButton',frame)
  19. local tools = Instance.new('TextButton',frame)
  20.  
  21. -- Name object
  22. gui.Name = "Prison Life v2.0 GUI"
  23. frame.Name = "Commands"
  24. open.Name = "Open"
  25. name.Name = "Name"
  26. arrest.Name = "ArrestButton"
  27. btools.Name = "BtoolsButton"
  28. escape.Name = "EscapeButton"
  29. exit.Name = "ExitButton"
  30. killaura.Name = "KillauraButton"
  31. melee.Name = "MeleeButton"
  32. removedoors.Name = "RemoveDoorsButton"
  33. tools.Name = "ToolsButton"
  34.  
  35. -- Object Visible
  36. frame.Visible = true
  37. open.Visible = false
  38. name.Visible = true
  39. arrest.Visible = true
  40. btools.Visible = true
  41. escape.Visible = true
  42. exit.Visible = true
  43. killaura.Visible = true
  44. melee.Visible = true
  45. removedoors.Visible = true
  46. tools.Visible = true
  47.  
  48. -- Background Color
  49. frame.BackgroundColor3 = Color3.new(255,255,255)
  50. open.BackgroundColor3 = Color3.new(0,255,255)
  51. name.BackgroundColor3 = Color3.new(255,255,255)
  52. arrest.BackgroundColor3 = Color3.new(0,0,255)
  53. btools.BackgroundColor3 = Color3.new(0,0,255)
  54. escape.BackgroundColor3 = Color3.new(0,0,255)
  55. exit.BackgroundColor3 = Color3.new(255,0,0)
  56. killaura.BackgroundColor3 = Color3.new(0,0,255)
  57. melee.BackgroundColor3 = Color3.new(0,0,255)
  58. removedoors.BackgroundColor3 = Color3.new(0,0,255)
  59. tools.BackgroundColor3 = Color3.new(0,0,255)
  60.  
  61. -- Background Transparency
  62. frame.BackgroundTransparency = 0.5
  63. open.BackgroundTransparency = 0
  64. name.BackgroundTransparency = 0.6
  65. arrest.BackgroundTransparency = 0
  66. btools.BackgroundTransparency = 0
  67. escape.BackgroundTransparency = 0
  68. exit.BackgroundTransparency = 0
  69. killaura.BackgroundTransparency = 0
  70. melee.BackgroundTransparency = 0
  71. removedoors.BackgroundTransparency = 0
  72. tools.BackgroundTransparency = 0
  73.  
  74. -- Objects Size
  75. frame.Size = UDim2.new(0,250,0,300)
  76. open.Size = UDim2.new(0,80,0,30)
  77. name.Size = UDim2.new(0,180,0,40)
  78. arrest.Size = UDim2.new(0.9,12,0,30)
  79. btools.Size = UDim2.new(0.9,12,0,30)
  80. escape.Size = UDim2.new(0.9,12,0,30)
  81. exit.Size = UDim2.new(0,50,0,40)
  82. killaura.Size = UDim2.new(0.9,12,0,30)
  83. melee.Size = UDim2.new(0.9,12,0,30)
  84. removedoors.Size = UDim2.new(0.9,12,0,30)
  85. tools.Size = UDim2.new(0.9,12,0,30)
  86.  
  87. -- Objects Position
  88. frame.Position = UDim2.new(0,5,0.4,0)
  89. open.Position = UDim2.new(0,0,0,0)
  90. name.Position = UDim2.new(0,0,0,0)
  91. arrest.Position = UDim2.new(0,0,0,320)
  92. btools.Position = UDim2.new(0,0,0,185)
  93. escape.Position = UDim2.new(0,0,0,230)
  94. exit.Position = UDim2.new(0,184,0,0)
  95. killaura.Position = UDim2.new(0,0,0,275)
  96. melee.Position = UDim2.new(0,0,0,140)
  97. removedoors.Position = UDim2.new(0,0,0,50)
  98. tools.Position = UDim2.new(0,0,0,95)
  99.  
  100. -- Objects Text Color
  101. open.TextColor3 = Color3.new(0,0,0)
  102. name.TextColor3 = Color3.new(0,255,255)
  103. arrest.TextColor3 = Color3.new(0,0,0)
  104. btools.TextColor3 = Color3.new(0,0,0)
  105. escape.TextColor3 = Color3.new(0,0,0)
  106. exit.TextColor3 = Color3.new(0,0,0)
  107. killaura.TextColor3 = Color3.new(0,0,0)
  108. melee.TextColor3 = Color3.new(0,0,0)
  109. removedoors.TextColor3 = Color3.new(0,0,0)
  110. tools.TextColor3 = Color3.new(0,0,0)
  111.  
  112. -- Object Font
  113. name.Font = 'Fantasy'
  114.  
  115. -- Object Text
  116. open.Text = 'Open'
  117. name.Text = 'Prison Life v2.0 Commands'
  118. arrest.Text = 'Arrest [Cops Only]'
  119. btools.Text = 'Give Btools'
  120. escape.Text = 'Escape The Prison'
  121. exit.Text = 'Exit'
  122. killaura.Text = 'Kill Aura [Danger]'
  123. melee.Text = 'Give Melee'
  124. removedoors.Text = 'Remove Doors'
  125. tools.Text = 'Give Guns'
  126.  
  127. -- Object Text Scaled
  128. open.TextScaled = true
  129. name.TextScaled = true
  130. arrest.TextScaled = true
  131. btools.TextScaled = true
  132. escape.TextScaled = true
  133. exit.TextScaled = true
  134. killaura.TextScaled = true
  135. melee.TextScaled = true
  136. removedoors.TextScaled = true
  137. tools.TextScaled = true
  138.  
  139. -- Frame Moveable
  140. frame.Active = true
  141. frame.Draggable = true
  142.  
  143. -- Open Function
  144. open.MouseButton1Down:connect(function()
  145. frame.Visible = true
  146. frame:TweenPosition(UDim2.new(0,5,0.4,0), "Out", "Bounce",1 ,true)
  147. open.Visible = false
  148. open.Position = UDim2.new(0,0,0,0)
  149. end)
  150.  
  151. -- Close/Exit Function
  152. exit.MouseButton1Down:connect(function()
  153. frame:TweenPosition(UDim2.new(0.1,-400,0.4,0) , "Out", "Quad", 1, true)
  154. wait(1)
  155. frame.Visible = false
  156. wait(.1)
  157. open.Visible = true
  158. open:TweenPosition(UDim2.new(0,2,0.8,15), "Out", "Bounce",1 ,true)
  159. end)
  160.  
  161. -- Remove Doors Function
  162. removedoors.MouseButton1Down:connect(function()
  163. game.Workspace.Doors:Destroy()
  164. local hint = Instance.new("Hint",game.Players.LocalPlayer.PlayerGui)
  165. hint.Text = "[ Unique'S PRISON LIFE COMMANDS ]: SUCCESSFULLY REMOVED COP DOORS"
  166. hint.Name = game.JobId
  167. wait(3)
  168. hint:Destroy()
  169. end)
  170.  
  171. -- Guns Function
  172. tools.MouseButton1Down:connect(function()
  173. local weapons = {"Remington 870", "M9", "AK-47", "M4A1", "Riot Shield"}
  174. for i, v in pairs(game.Workspace["Prison_ITEMS"].giver:GetChildren()) do
  175. for j, k in pairs(weapons) do
  176. if v.Name == k then
  177. v:MoveTo(game.Players.LocalPlayer.Character.Torso.Position)
  178. end
  179. end
  180. end
  181. local hint = Instance.new("Hint",game.Players.LocalPlayer.PlayerGui)
  182. hint.Text = "[ Unique'S PRISON LIFE COMMANDS ]: SUCCESSFULLY SENT TOOLS TO LOCALPLAYER"
  183. hint.Name = game.JobId
  184. wait(3)
  185. hint:Destroy()
  186. end)
  187.  
  188. -- Melee Function
  189. melee.MouseButton1Down:connect(function()
  190. local weapons = {"Crude Knife", "Sharpened stick", "Extendo mirror"}
  191. for i, v in pairs(game.ReplicatedStorage.Tools:GetChildren()) do
  192. for j, k in pairs(weapons) do
  193. if v.Name == k then
  194. v:Clone().Parent = game.Players.LocalPlayer.Backpack
  195. end
  196. end
  197. end
  198. local hint = Instance.new("Hint",game.Players.LocalPlayer.PlayerGui)
  199. hint.Text = "[ Unique'S PRISON LIFE COMMANDS ]: SUCCESSFULLY SENT MELEE TOOLS TO LOCALPLAYER"
  200. hint.Name = game.JobId
  201. wait(3)
  202. hint:Destroy()
  203. end)
  204.  
  205. -- Btools Function
  206. btools.MouseButton1Down:connect(function()
  207. Instance.new('HopperBin', game.Players.LocalPlayer.Backpack).BinType = 2
  208. Instance.new('HopperBin', game.Players.LocalPlayer.Backpack).BinType = 3
  209. Instance.new('HopperBin', game.Players.LocalPlayer.Backpack).BinType = 4
  210. loadstring(game:GetObjects('rbxassetid://552440069')[1].Source)()
  211. end)
  212.  
  213. -- Escape Function
  214. escape.MouseButton1Down:connect(function()
  215. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = CFrame.new(283, 72, 2213)
  216. local hint = Instance.new("Hint",game.Players.LocalPlayer.PlayerGui)
  217. hint.Text = "[ Unique'S PRISON LIFE COMMANDS ]: SUCCESSFULLY ESCAPED LOCALPLAYER"
  218. hint.Name = game.JobId
  219. wait(3)
  220. hint:Destroy()
  221. end)
  222.  
  223. -- Kill Aura Function
  224. killaura.MouseButton1Down:connect(function()
  225. while wait(0.1) do
  226. for i, plr in pairs(game.Players:GetChildren()) do
  227. if plr.Name ~= game.Players.LocalPlayer.Name then
  228. for i = 1, 10 do
  229. game.ReplicatedStorage.meleeEvent:FireServer(plr)
  230. end
  231. end
  232. end
  233. end
  234. end)
  235.  
  236. -- Arrest Function
  237. local mouse = game.Players.LocalPlayer:GetMouse()
  238. local arrestEvent = game.Workspace.Remote.arrest
  239. mouse.Button1Down:connect(function()
  240. local obj = mouse.Target
  241. local response = arrestEvent:InvokeServer(obj)
  242. end)
Add Comment
Please, Sign In to add comment