Advertisement
Remour

Untitled

Feb 18th, 2017
116
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 15.06 KB | None | 0 0
  1. local Asset = "http://www.roblox.com/asset/?id="
  2. local Provider = game:service("ContentProvider")
  3. local Seen = 20
  4.  
  5. local C3 = Color3.new
  6. local UD = UDim2.new
  7. local V2 = Vector2.new
  8.  
  9. local Icons = {
  10. PreviousPage = Asset..(57411555),
  11. NextPage = Asset..(57411520),
  12. Previous = Asset..(57375309),
  13. Home = Asset..(57375258),
  14. Refresh = Asset..(57376869),
  15. Properties = Asset..(57475029),
  16. Delete = Asset..(57474956),
  17. Copy = Asset..(57474905),
  18. Paste = Asset..(57474999),
  19. Cut = Asset..(57474927),
  20. Exit = Asset..(57510854),
  21. }
  22.  
  23. local Images = {
  24. {{"IntValue", "BrickColorValue", "Color3Value", "Vector3Value", "CFrameValue", "NumberValue", "ObjectValue", "StringValue", "BoolValue", "RayValue"}, Asset..(57403779)},
  25. {{"BasePart", "Part", "WedgePart"}, Asset..(57403711)},
  26. {{"ForceField"}, Asset..(57404473)},
  27. {{"Weld", "Rotate", "Glue"}, Asset..(57403808)},
  28. {{"BodyVelocity", "BodyPosition", "BodyForce", "BodyGyro", "BodyThrust", "BodyAngularVelocity", "BodyPosition", "RocketPropulsion"}, Asset..(57403610)},
  29. {{"Animation", "AnimationTrack"}, Asset..(57403557)},
  30. {{"Model"}, Asset..(57403668)},
  31. {{"Player", "Players"}, Asset..(57403743)},
  32. {{"BlockMesh", "SpecialMesh", "CylinderMesh", "FileMesh", "CharacterMesh"}, Asset..(57403643)},
  33. {{"TextButton", "TextLabel", "ImageLabel", "ImageButton", "Frame"}, Asset..(57403587)},
  34. {{"Camera"}, Asset..(57406901)},
  35. {{"Hat", "Accoutrement"}, Asset..(57406931)},
  36. {{"LocalScript"}, Asset..(57406954)},
  37. {{"HopperBin"}, Asset..(57406984)},
  38. {{"Tool"}, Asset..(57407105)},
  39. {{"Humanoid"}, Asset..(57407016)},
  40. {{"Script"}, Asset..(57407071)},
  41. {{"Message", "Hint"}, Asset..(57407564)},
  42. {{"Decal"}, Asset..(57583116)},
  43. {{"Pants"}, Asset..(57583183)},
  44. {{"Seat", "VehicleSeat", "SkateboardPlatform"}, Asset..(57583240)},
  45. {{"Shirt"}, Asset..(57583288)},
  46. {{"SpawnLocation"}, Asset..(57583329)},
  47. {{"Texture"}, Asset..(57583364)},
  48. }
  49.  
  50. for _,v in pairs(Images) do
  51. Provider:Preload(v[2])
  52. end
  53.  
  54. wait(0.5)
  55.  
  56. function Find(Object)
  57. local Img = Asset..(57403690)
  58. for _,v in pairs(Images) do
  59. for _,k in pairs(v[1]) do
  60. if Object.className == k then
  61. Img = v[2]
  62. end
  63. end
  64. end
  65. return Img
  66. end
  67.  
  68. local Classes = {"Frame", "ImageLabel", "ImageButton", "TextLabel", "TextButton", "TextBox"}
  69. function Make(Class, Par, Size, Pos, Color, Trans, Border, Borderc, Txt, TxtC, Img)
  70. local Mk = "Frame"
  71. for _,v in pairs(Classes) do
  72. if Class == v then
  73. Mk = v
  74. end
  75. end
  76. local g = Instance.new(Mk)
  77. g.Size = Size
  78. g.Position = Pos
  79. g.BackgroundColor3 = Color
  80. g.Transparency = Trans
  81. g.BorderSizePixel = Border
  82. g.BorderColor3 = Borderc
  83. if Mk == "TextButton" or Mk == "TextLabel" or Mk == "TextBox" then
  84. g.Text = Txt
  85. g.TextColor3 = TxtC
  86. elseif Mk == "ImageLabel" or Mk == "ImageButton" then
  87. g.Image = Img
  88. end
  89. g.Parent = Par
  90. return g
  91. end
  92.  
  93. function Give(Player)
  94. local Place = workspace
  95. local From = 0
  96. local gui = Player:findFirstChild("PlayerGui")
  97. if gui then
  98. for _,v in pairs(gui:children()) do if v.Name == "GuiText" then v:remove() end end
  99. end
  100. local Sc = Instance.new("ScreenGui")
  101. Sc.Name = "GuiText"
  102. local Options = nil
  103. local Copied = nil
  104. local Number = (50-32)
  105. local Resolution = V2(1028, 768)
  106. local Main = Make("Frame", Sc, UD(1, 0, 1, 1), UD(0, 0, 0, -1), C3(0.92, 0.92, 0.96), 1, 0, C3())
  107. coroutine.resume(coroutine.create(function()
  108. wait(0.04)
  109. Resolution = V2(Main.AbsoluteSize.X, Main.AbsoluteSize.Y)
  110. end))
  111. local ExplorerDec = Make("Frame", Main, UD(0, 155, 0, 360), UD(0, 0, 0.5, -175), C3(0.75, 0.75, 0.9), 0, 0, C3())
  112. local Explorer = Make("Frame", ExplorerDec, UD(1, -5, 1, -10), UD(0, 0, 0, 5), C3(0.9, 0.9, 0.95), 0, 0, C3())
  113. local Bar = Make("Frame", Explorer, UD(1, 0, 0, 32), UD(), C3(0.75, 0.75, 0.9), 0, 0, C3())
  114. local Previous = Make("ImageButton", Bar, UD(0, 32, 0, 32), UD(0, 9, 0, 0), C3(0.75, 0.75, 0.9), 0, 0, C3(), nil, nil, Icons.Previous)
  115. local Home = Make("ImageButton", Bar, UD(0, 32, 0, 32), UD(0, 59, 0, 0), C3(0.75, 0.75, 0.9), 0, 0, C3(), nil, nil, Icons.Home)
  116. local Refresh = Make("ImageButton", Bar, UD(0, 32, 0, 32), UD(0, 109, 0, 0), C3(0.75, 0.75, 0.9), 0, 0, C3(), nil, nil, Icons.Refresh)
  117. local List = Make("Frame", Explorer, UD(1, -10, 1, -32-4), UD(0, 5, 0, 32), C3(0.7, 0.7, 0.85), 0, 0, C3())
  118. local NextPage = Make("ImageButton", ExplorerDec, UD(0.5, 0, 0, 30), UD(0.5, 0, 1, 0), C3(0.75, 0.75, 0.9), 0, 0, C3(), nil, nil, Icons.NextPage)
  119. local PreviousPage = Make("ImageButton", ExplorerDec, UD(0.5, 0, 0, 30), UD(0, 0, 1, 0), C3(0.75, 0.75, 0.9), 0, 0, C3(), nil, nil, Icons.PreviousPage)
  120.  
  121. local BackTool = Make("Frame", ExplorerDec, UD(0, 36, 0, (32+4)*4+4), UD(1, 0, 0, 0), C3(0.75, 0.75, 0.9), 0, 0, C3())
  122. local Properties = Make("ImageButton", BackTool, UD(0, 32, 0, 32), UD(0, 0, 0, 4), C3(0.82, 0.82, 0.93), 0, 0, C3(), nil, nil, Icons.Properties)
  123. local CopyP = Make("ImageButton", BackTool, UD(0, 32, 0, 32), UD(0, 0, 0, (32+4)*1+4), C3(0.82, 0.82, 0.93), 0, 0, C3(), nil, nil, Icons.Copy)
  124. local PasteP = Make("ImageButton", BackTool, UD(0, 32, 0, 32), UD(0, 0, 0, (32+4)*2+4), C3(0.82, 0.82, 0.93), 0, 0, C3(), nil, nil, Icons.Paste)
  125. local DeleteP = Make("ImageButton", BackTool, UD(0, 32, 0, 32), UD(0, 0, 0, (32+4)*3+4), C3(0.82, 0.82, 0.93), 0, 0, C3(), nil, nil, Icons.Delete)
  126.  
  127. local Name = Make("TextLabel", ExplorerDec, UD(1, 0, 0, 25), UD(0, 0, 0, -25), C3(0.8, 0.8, 0.95), 0, 0, C3(), "nil", C3())
  128. Name.FontSize = "Size14"
  129. Name.Font = "Arial"
  130. local Size = 350-36
  131. local Buttons = {}
  132. local SeenSize = (Size/Seen)
  133. for i = 0, Size-SeenSize, SeenSize do
  134. local Txt = Make("TextButton", List, UD(1, -SeenSize, 0, SeenSize), UD(0, SeenSize, 0, i), C3(0.8, 0.8, 0.9), 0, 0, C3(), "-", C3())
  135. Txt.Font = "Arial"
  136. Txt.FontSize = "Size12"
  137. Txt.TextWrap = true
  138. Txt.TextXAlignment = "Left"
  139. local Im = Make("ImageLabel", Txt, UD(0, SeenSize, 1, 0), UD(0, -SeenSize, 0, 0), C3(0.76, 0.76, 0.9), 0, 0, C3(), nil, nil, "")
  140. local Button = {Go = nil, Gui = Txt, Img = Im}
  141. table.insert(Buttons, Button)
  142. end
  143. local function Update(P)
  144. if Options then Options:remove() end
  145. if P ~= nil then
  146. Place = P
  147. Name.Text = tostring(Place)
  148.  
  149. local Items = Place:children()
  150. local Amount = #Items
  151. for i = 1, #Buttons do
  152. pcall(function()
  153. local Item = Items[i+From]
  154. if Item then
  155. local img = Find(Item)
  156. Buttons[i].Go = Item
  157. Buttons[i].Gui.Text = Item.Name
  158. Buttons[i].Img.Image = img
  159. else
  160. Buttons[i].Go = nil
  161. Buttons[i].Gui.Text = "-"
  162. Buttons[i].Img.Image = ""
  163. end
  164. end)
  165. end
  166. end
  167. end
  168. local function OpenOptions(P, x, y)
  169. if Options then Options:remove() end
  170. if P ~= nil then
  171. local Pos = 87
  172. local Siz = 112
  173. if P:IsA("StringValue") then
  174. Siz = 132
  175. Pos = 107
  176. end
  177. local Back = Make("Frame", Main, UD(0, 150, 0, Siz), UD(0, x+3, 0, y+4), C3(0.65, 0.65, 0., 0, 0, C3())
  178. local Copy = Make("TextButton", Back, UD(1, -10, 0, 20), UD(0, 5, 0, 5), C3(0.85, 0.85, 0.95), 0, 0, C3(), "Copy", C3())
  179. local Paste = Make("TextButton", Back, UD(1, -10, 0, 20), UD(0, 5, 0, 25), C3(0.85, 0.85, 0.95), 0, 0, C3(), "Paste", C3())
  180. local Delete = Make("TextButton", Back, UD(1, -10, 0, 20), UD(0, 5, 0, 45), C3(0.85, 0.85, 0.95), 0, 0, C3(), "Delete", C3())
  181. local Rename = Make("TextButton", Back, UD(1, -10, 0, 20), UD(0, 5, 0, 65), C3(0.85, 0.85, 0.95), 0, 0, C3(), "Rename", C3())
  182. if P:IsA("StringValue") then
  183. local Read = Make("TextButton", Back, UD(1, -10, 0, 20), UD(0, 5, 0, 85), C3(0.85, 0.85, 0.95), 0, 0, C3(), "Read", C3())
  184. Read.Font = "Arial"
  185. Read.FontSize = "Size12"
  186. Read.TextXAlignment = "Left"
  187. Read.MouseButton1Down:connect(function()
  188. if Options then Options:remove() end
  189. local Text = P.Value
  190. local Lines = {}
  191. local Last = 1
  192. for i = 1, #Text, 1 do
  193. if Text:sub(i,i) == string.char(10) then
  194. local asd = Text:sub(Last, i-1)
  195. asd = asd:gsub(string.char(9), " ")
  196. table.insert(Lines, asd)
  197. Last = i+1
  198. end
  199. end
  200. local asd = Text:sub(Last, #Text)
  201. asd = asd:gsub(string.char(9), " ")
  202. table.insert(Lines, asd)
  203. local MainT = Make("Frame", Main, UD(1, -200, 0, 0), UD(0, 0, 0.5, 0), C3(1, 1, 1), 1, 0, C3())
  204. local DerpGui = Make("ImageButton", Main, UD(1, 0, 1, 0), UD(0, 0, 0, 0), C3(), 1, 0, C3(), nil, nil, "")
  205. DerpGui.Visible = false
  206. local Scroll = Make("Frame", Main, UD(0, 20, 0, Resolution.Y-40), UD(1, -220, 0, 20), C3(0.97, 0.97, 1), 0, 0, C3())
  207. local ButtonUp = Make("ImageButton", Scroll, UD(0, 20, 0, 20), UD(0, 0, 0, -20), C3(0.85, 0.85, 0.9), 0, 0, C3(), nil, nil, "")
  208. local ButtonDown = Make("ImageButton", Scroll, UD(0, 20, 0, 20), UD(0, 0, 1, 0), C3(0.85, 0.85, 0.9), 0, 0, C3(), nil, nil, "")
  209. local ScrollBar = Make("ImageButton", Scroll, UD(1, 0, 0, 150), UD(0, 0, 0, 0), C3(0.75, 0.75, 0.85), 0, 0, C3(), nil, nil, "")
  210. local Texts = {}
  211. for i = 0, Resolution.Y-13, 13 do
  212. local Txt = Make("TextLabel", MainT, UD(1, 0, 0, 13), UD(0, 0, i/Resolution.Y, 0), C3(1, 1, 1), 0, 1, C3(0.9, 0.9, 0.9), "", C3())
  213. Txt.Font = "Arial"
  214. Txt.FontSize = "Size12"
  215. Txt.TextXAlignment = "Left"
  216. table.insert(Texts, Txt)
  217. end
  218. for i, v in pairs(Texts) do
  219. local line = Lines[i]
  220. if line then
  221. v.Text = tostring(line)
  222. end
  223. end
  224. local Normal = UD(0, 0, 0.5, -175)
  225. ExplorerDec:TweenPosition(UD(0, -200, 0.5, -175), nil, nil, 0.5)
  226. MainT:TweenSize(UD(1, -200, 0, Resolution.Y+1))
  227. MainT:TweenPosition(UD(0, 0, 0, -1))
  228. local ScrollPos = 20
  229. local ScrollSize = Resolution.Y-40
  230. local SlideSize = 150
  231. local Point = ScrollPos + ScrollSize
  232. local AllPoint = Point-SlideSize-ScrollPos
  233. ScrollBar.MouseButton1Down:connect(function(x, y)
  234. local pos2 = ScrollBar.Position.Y.Offset-y
  235. DerpGui.Visible = true
  236. local Conn = DerpGui.MouseMoved:connect(function(X, Y)
  237. local pos = Y+pos2
  238. if pos < 0 then pos = 0 end
  239. if pos+SlideSize+ScrollPos > Point then pos = AllPoint end
  240. ScrollBar.Position = UD(0, 0, 0, pos)
  241. local Division = (pos/AllPoint)
  242. local Asd = #Lines-#Texts+5
  243. if Asd > #Lines then Asd = #Lines end
  244. local Placement = math.floor((Asd)*Division)
  245. for i, v in pairs(Texts) do
  246. local Line = Lines[i+Placement]
  247. if Line then
  248. v.Text = Line
  249. else
  250. v.Text = ""
  251. end
  252. end
  253. end)
  254. local co = DerpGui.MouseButton1Up:connect(function()
  255. DerpGui.Visible = false
  256. Conn:disconnect()
  257. co:disconnect()
  258. end)
  259. end)
  260. local Exit = Make("ImageButton", MainT, UD(0, 35, 0, 35), UD(1, -75, 0, 25), C3(), 1, 0, C3(), nil, nil, Icons.Exit)
  261. local c = Exit.MouseButton1Down:connect(function()
  262. Scroll:remove()
  263. Exit:remove()
  264. for _,v in pairs(Texts) do v.Text = "" end
  265. ExplorerDec:TweenPosition(Normal, nil, nil, 0.7)
  266. MainT:TweenSize(UD(0, 0, 0, 0), nil, nil, 0.5)
  267. MainT:TweenPosition(UD(0.5, 0, 0.5, 0), nil, nil, 0.5)
  268. wait(0.5)
  269. MainT:remove()
  270. end)
  271. end)
  272. end
  273. local Cancel = Make("TextButton", Back, UD(1, -10, 0, 20), UD(0, 5, 0, Pos), C3(0.85, 0.85, 0.95), 0, 0, C3(), "Cancel", C3())
  274. Copy.Font = "Arial"
  275. Paste.Font = "Arial"
  276. Delete.Font = "Arial"
  277. Rename.Font = "Arial"
  278. Cancel.Font = "Arial"
  279. Copy.FontSize = "Size12"
  280. Paste.FontSize = "Size12"
  281. Delete.FontSize = "Size12"
  282. Rename.FontSize = "Size12"
  283. Cancel.FontSize = "Size12"
  284. Copy.TextXAlignment = "Left"
  285. Paste.TextXAlignment = "Left"
  286. Delete.TextXAlignment = "Left"
  287. Rename.TextXAlignment = "Left"
  288. Cancel.TextXAlignment = "Left"
  289. Copy.MouseButton1Down:connect(function()
  290. if Options then Options:remove() end
  291. local a = P.archivable
  292. P.archivable = true
  293. Copied = P:clone()
  294. wait()
  295. P.archivable = a
  296. end)
  297. Paste.MouseButton1Down:connect(function()
  298. if Options then Options:remove() end
  299. if Copied then
  300. local clo = Copied:clone()
  301. clo.Parent = P
  302. end
  303. end)
  304. Delete.MouseButton1Down:connect(function()
  305. if Options then Options:remove() end
  306. P:remove()
  307. Update(Place)
  308. end)
  309. Rename.MouseButton1Down:connect(function()
  310. if Options then Options:remove() end
  311. local Sc2 = Instance.new("ScreenGui")
  312. Sc2.Name = "Rename"
  313. Sc2.Parent = gui
  314. local Effect = Make("ImageButton", Sc2, UD(0, 0, 0, 0), UD(0.5, 0, 0.5, 0), C3(0.9, 0.9, 1), 0, 0, C3(), nil, nil, "")
  315. Effect.AutoButtonColor = false
  316. local Writeback = Make("Frame", Sc2, UD(0, 0, 0, 0), UD(0.5, 0, 0.5, 0), C3(0.7, 0.7, 0.9), 0, 0, C3())
  317. local Write = Make("Frame", Writeback, UD(1, -10, 1, -10), UD(0, 5, 0, 5), C3(0.9, 0.9, 0.95), 0, 0, C3())
  318. local TextBar = Make("TextBox", Write, UD(0.8, 0, 0.15, 0), UD(0.1, 0, 0.2, 0), C3(0.5, 0.5, 0., 0, 0, C3(), "", C3(1,1,1))
  319. TextBar.FontSize = "Size14"
  320. TextBar.Font = "Arial"
  321. local Ok = Make("TextButton", Write, UD(0.3, 0, 0.17, 0), UD(0.1, 0, 0.5, 0), C3(0.65, 0.65, 0.85), 0, 0, C3(), "Ok", C3(1,1,1))
  322. local Canc = Make("TextButton", Write, UD(0.3, 0, 0.17, 0), UD(0.6, 0, 0.5, 0), C3(0.65, 0.65, 0.85), 0, 0, C3(), "Cancel", C3(1,1,1))
  323. Ok.Font = "ArialBold"
  324. Ok.FontSize = "Size18"
  325. Canc.Font = "ArialBold"
  326. Canc.FontSize = "Size18"
  327. Effect:TweenPosition(UD(0, 0, 0, -1))
  328. Writeback:TweenPosition(UD(0.5, -150, 0.5, -60))
  329. Writeback:TweenSize(UD(0, 300, 0, 120))
  330. Effect:TweenSize(UD(1, 0, 1, 1))
  331. local Normal = UD(0, 0, 0.5, -175)
  332. ExplorerDec:TweenPosition(UD(0, -200, 0.5, -175), nil, nil, 0.4)
  333. local function TweenBack()
  334. Effect:TweenPosition(UD(1, 0, 0.5, 0), nil, nil, 0.5)
  335. Effect:TweenSize(UD(0, 0, 0, 0), nil, nil, 0.5)
  336. Writeback:TweenPosition(UD(1, 0, 0.5, 0), nil, nil, 0.5)
  337. Writeback:TweenSize(UD(0, 0, 0, 0), nil, nil, 0.5)
  338. ExplorerDec:TweenPosition(Normal, nil, nil, 0.5)
  339. Ok.Text = ""
  340. Canc.Text = ""
  341. TextBar.Text = ""
  342. coroutine.resume(coroutine.create(function()
  343. for i = 0, 1, 0.08 do
  344. wait()
  345. Effect.BackgroundTransparency = 0.4+0.7*i
  346. end
  347. Sc2:remove()
  348. end))
  349. end
  350. coroutine.resume(coroutine.create(function()
  351. for i = 0, 1, 0.035 do
  352. wait()
  353. Effect.BackgroundTransparency = 0.4*i
  354. end
  355. end))
  356. Canc.MouseButton1Down:connect(function()
  357. TweenBack()
  358. end)
  359. Ok.MouseButton1Down:connect(function()
  360. coroutine.resume(coroutine.create(function()
  361. local derp = P.archivable
  362. P.archivable = true
  363. P.Name = TextBar.Text
  364. wait()
  365. P.archivable = derp
  366. end))
  367. TweenBack()
  368. Update(Place)
  369. end)
  370. end)
  371. Cancel.MouseButton1Down:connect(function()
  372. if Options then Options:remove() end
  373. end)
  374. Options = Back
  375. end
  376. end
  377. for i,v in pairs(Buttons) do
  378. v.Gui.MouseButton1Down:connect(function()
  379. if v.Go ~= nil then
  380. From = 0
  381. Update(v.Go)
  382. end
  383. end)
  384. v.Gui.MouseButton2Down:connect(function(x, y)
  385. OpenOptions(v.Go, x, y)
  386. end)
  387. end
  388. Home.MouseButton1Down:connect(function()
  389. pcall(function()
  390. From = 0
  391. Update(workspace)
  392. end)
  393. end)
  394. Previous.MouseButton1Down:connect(function()
  395. pcall(function()
  396. From = 0
  397. Update(Place.Parent)
  398. end)
  399. end)
  400. Refresh.MouseButton1Down:connect(function()
  401. pcall(function()
  402. From = 0
  403. Update(Place)
  404. end)
  405. end)
  406. NextPage.MouseButton1Down:connect(function()
  407. pcall(function()
  408. From = From + Seen
  409. Update(Place)
  410. end)
  411. end)
  412. PreviousPage.MouseButton1Down:connect(function()
  413. pcall(function()
  414. From = From - Seen
  415. if From < 0 then From = 0 end
  416. Update(Place)
  417. end)
  418. end)
  419. CopyP.MouseButton1Down:connect(function()
  420. pcall(function()
  421. if Options then Options:remove() end
  422. if Place ~= workspace then
  423. local a = Place.archivable
  424. Place.archivable = true
  425. Copied = Place:clone()
  426. wait()
  427. Place.archivable = a
  428. end
  429. end)
  430. end)
  431. PasteP.MouseButton1Down:connect(function()
  432. pcall(function()
  433. if Options then Options:remove() end
  434. if Copied and Copied ~= workspace then
  435. local clo = Copied:clone()
  436. clo.Parent = Place
  437. Update(Place)
  438. end
  439. end)
  440. end)
  441. DeleteP.MouseButton1Down:connect(function()
  442. pcall(function()
  443. if Options then Options:remove() end
  444. if Place ~= workspace then
  445. local plaic = Place.Parent
  446. if plaic == nil then plaic = workspace end
  447. Place:remove()
  448. Update(plaic)
  449. end
  450. end)
  451. end)
  452. Update(Place)
  453. Sc.Parent = gui
  454. end
  455.  
  456. Give(game.Players.LocalPlayer)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement