Advertisement
hjkook

aaaaaa

Jan 10th, 2020
473
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 12.22 KB | None | 0 0
  1. local SurfaceGui = Instance.new("SurfaceGui")
  2. local Frame_2 = Instance.new("Frame")
  3. local ImageLabel = Instance.new("ImageLabel")
  4.  
  5. local ScreenGui = Instance.new("ScreenGui")
  6. local Frame = Instance.new("Frame")
  7. local NAME = Instance.new("TextLabel")
  8. local TextButton = Instance.new("TextButton")
  9.  
  10. --https://github.com/Mokiros/roblox-FE-compatibility
  11. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  12. local Player,game,owner = owner,game
  13. local RealPlayer = Player
  14. do
  15. print("FE Compatibility code V2 by Mokiros")
  16. local RealPlayer = RealPlayer
  17. script.Parent = RealPlayer.Character
  18.  
  19. --Fake event to make stuff like Mouse.KeyDown work
  20. local Disconnect_Function = function(this)
  21. this[1].Functions[this[2]] = nil
  22. end
  23. local Disconnect_Metatable = {__index={disconnect=Disconnect_Function,Disconnect=Disconnect_Function}}
  24. local FakeEvent_Metatable = {__index={
  25. Connect = function(this,f)
  26. local i = tostring(math.random(0,10000))
  27. while this.Functions[i] do
  28. i = tostring(math.random(0,10000))
  29. end
  30. this.Functions[i] = f
  31. return setmetatable({this,i},Disconnect_Metatable)
  32. end
  33. }}
  34. FakeEvent_Metatable.__index.connect = FakeEvent_Metatable.__index.Connect
  35. local function fakeEvent()
  36. return setmetatable({Functions={}},FakeEvent_Metatable)
  37. end
  38.  
  39. --Creating fake input objects with fake variables
  40. local FakeMouse = {Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent(),Button2Up=fakeEvent(),Button2Down=fakeEvent()}
  41. FakeMouse.keyUp = FakeMouse.KeyUp
  42. FakeMouse.keyDown = FakeMouse.KeyDown
  43. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  44. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  45. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  46. end}
  47. --Merged 2 functions into one by checking amount of arguments
  48. CAS.UnbindAction = CAS.BindAction
  49.  
  50. --This function will trigger the events that have been :Connect()'ed
  51. local function TriggerEvent(self,ev,...)
  52. for _,f in pairs(self[ev].Functions) do
  53. f(...)
  54. end
  55. end
  56. FakeMouse.TriggerEvent = TriggerEvent
  57. UIS.TriggerEvent = TriggerEvent
  58.  
  59. --Client communication
  60. local Event = Instance.new("RemoteEvent")
  61. Event.Name = "UserInput_Event"
  62. Event.OnServerEvent:Connect(function(plr,io)
  63. if plr~=RealPlayer then return end
  64. FakeMouse.Target = io.Target
  65. FakeMouse.Hit = io.Hit
  66. if not io.isMouse then
  67. local b = io.UserInputState == Enum.UserInputState.Begin
  68. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  69. return FakeMouse:TriggerEvent(b and "Button1Down" or "Button1Up")
  70. end
  71. if io.UserInputType == Enum.UserInputType.MouseButton2 then
  72. return FakeMouse:TriggerEvent(b and "Button2Down" or "Button2Up")
  73. end
  74. for _,t in pairs(CAS.Actions) do
  75. for _,k in pairs(t.Keys) do
  76. if k==io.KeyCode then
  77. t.Function(t.Name,io.UserInputState,io)
  78. end
  79. end
  80. end
  81. FakeMouse:TriggerEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  82. UIS:TriggerEvent(b and "InputBegan" or "InputEnded",io,false)
  83. end
  84. end)
  85. Event.Parent = NLS([==[local Event = script:WaitForChild("UserInput_Event")
  86. local Mouse = owner:GetMouse()
  87. local UIS = game:GetService("UserInputService")
  88. local input = function(io,RobloxHandled)
  89. if RobloxHandled then return end
  90. --Since InputObject is a client-side instance, we create and pass table instead
  91. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target})
  92. end
  93. UIS.InputBegan:Connect(input)
  94. UIS.InputEnded:Connect(input)
  95. local h,t
  96. --Give the server mouse data every second frame, but only if the values changed
  97. --If player is not moving their mouse, client won't fire events
  98. local HB = game:GetService("RunService").Heartbeat
  99. while true do
  100. if h~=Mouse.Hit or t~=Mouse.Target then
  101. h,t=Mouse.Hit,Mouse.Target
  102. Event:FireServer({isMouse=true,Target=t,Hit=h})
  103. end
  104. --Wait 2 frames
  105. for i=1,2 do
  106. HB:Wait()
  107. end
  108. end]==],script)
  109.  
  110. ----Sandboxed game object that allows the usage of client-side methods and services
  111. --Real game object
  112. local RealGame = game
  113.  
  114. --Metatable for fake service
  115. local FakeService_Metatable = {
  116. __index = function(self,k)
  117. local s = rawget(self,"_RealService")
  118. if s then
  119. return typeof(s[k])=="function"
  120. and function(_,...)return s[k](s,...)end or s[k]
  121. end
  122. end,
  123. __newindex = function(self,k,v)
  124. local s = rawget(self,"_RealService")
  125. if s then s[k]=v end
  126. end
  127. }
  128. local function FakeService(t,RealService)
  129. t._RealService = typeof(RealService)=="string" and RealGame:GetService(RealService) or RealService
  130. return setmetatable(t,FakeService_Metatable)
  131. end
  132.  
  133. --Fake game object
  134. local FakeGame = {
  135. GetService = function(self,s)
  136. return rawget(self,s) or RealGame:GetService(s)
  137. end,
  138. Players = FakeService({
  139. LocalPlayer = FakeService({GetMouse=function(self)return FakeMouse end},Player)
  140. },"Players"),
  141. UserInputService = FakeService(UIS,"UserInputService"),
  142. ContextActionService = FakeService(CAS,"ContextActionService"),
  143. RunService = FakeService({
  144. _btrs = {},
  145. RenderStepped = RealGame:GetService("RunService").Heartbeat,
  146. BindToRenderStep = function(self,name,_,fun)
  147. self._btrs[name] = self.Heartbeat:Connect(fun)
  148. end,
  149. UnbindFromRenderStep = function(self,name)
  150. self._btrs[name]:Disconnect()
  151. end,
  152. },"RunService")
  153. }
  154. rawset(FakeGame.Players,"localPlayer",FakeGame.Players.LocalPlayer)
  155. FakeGame.service = FakeGame.GetService
  156. FakeService(FakeGame,game)
  157. --Changing owner to fake player object to support owner:GetMouse()
  158. game,owner = FakeGame,FakeGame.Players.LocalPlayer
  159. end
  160. local Player = owner
  161. local Character = Player.Character
  162. local Torso = Character.Torso
  163. local Torso2 = Character.Head
  164.  
  165. local function Smooth(Part)
  166. Part.TopSurface = Enum.SurfaceType.SmoothNoOutlines
  167. Part.BottomSurface = Enum.SurfaceType.SmoothNoOutlines
  168. Part.LeftSurface = Enum.SurfaceType.SmoothNoOutlines
  169. Part.RightSurface = Enum.SurfaceType.SmoothNoOutlines
  170. Part.FrontSurface = Enum.SurfaceType.SmoothNoOutlines
  171. Part.BackSurface = Enum.SurfaceType.SmoothNoOutlines
  172. end
  173.  
  174. local Keyboard = Instance.new("Part")
  175. Keyboard.BrickColor = BrickColor.new("Lsvender")
  176. Keyboard.Transparency = 0.6
  177. Keyboard.Size = Vector3.new(2.24, 0.24, 2.89)
  178. Keyboard.CanCollide = false
  179. Keyboard.Locked = true
  180.  
  181. local Keyboard2 = Instance.new("Part")
  182. Keyboard2.BrickColor = BrickColor.new("Lsvender")
  183. Keyboard2.Material = Enum.Material.Neon
  184. Keyboard2.Transparency = 0.6
  185. Keyboard2.Size = Vector3.new(12.38, 0.24, 6.97)
  186. Keyboard2.CanCollide = false
  187. Keyboard2.Locked = true
  188.  
  189.  
  190. Smooth(Keyboard) --주석
  191. Smooth(Keyboard2)
  192.  
  193. local KeyboardWeld = Instance.new("Weld")
  194. KeyboardWeld.Part0 = Torso
  195. KeyboardWeld.Part1 = Keyboard
  196. KeyboardWeld.C0 = CFrame.new(1, 0.4, -2) * CFrame.Angles(0.5, 0, 0)
  197.  
  198. SurfaceGui.Parent = Keyboard2
  199. SurfaceGui.Face = "Top"
  200.  
  201. Frame_2.Parent = SurfaceGui
  202. Frame_2.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  203. Frame_2.BackgroundTransparency = 1.000
  204. Frame_2.Size = UDim2.new(0, 385, 0, 331)
  205.  
  206. ImageLabel.Parent = Frame_2
  207. ImageLabel.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  208. ImageLabel.BackgroundTransparency = 1.000
  209. ImageLabel.Size = UDim2.new(0, 385, 0, 389)
  210. ImageLabel.Image = "http://www.roblox.com/asset/?id=2698871607"
  211.  
  212. --스크린gui
  213.  
  214. ScreenGui.Parent = game.Players.LocalPlayer.PlayerGui
  215. ScreenGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
  216.  
  217. Frame.Parent = ScreenGui
  218. Frame.BackgroundColor3 = Color3.fromRGB(39, 39, 39)
  219. Frame.Position = UDim2.new(0, 0, 0.24539879, 0)
  220. Frame.Size = UDim2.new(0, 250, 0, 312)
  221.  
  222. NAME.Name = "NAME"
  223. NAME.Parent = Frame
  224. NAME.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  225. NAME.BackgroundTransparency = 1.000
  226. NAME.Size = UDim2.new(0, 250, 0, 32)
  227. NAME.Font = Enum.Font.SourceSans
  228. NAME.Text = "TUBRO"
  229. NAME.TextColor3 = Color3.fromRGB(255, 255, 255)
  230. NAME.TextScaled = true
  231. NAME.TextSize = 14.000
  232. NAME.TextWrapped = true
  233.  
  234. TextButton.Parent = Frame
  235. TextButton.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  236. TextButton.Position = UDim2.new(0, 0, 0.102564104, 0)
  237. TextButton.Size = UDim2.new(0, 250, 0, 25)
  238. TextButton.Font = Enum.Font.SourceSans
  239. TextButton.Text = "music"
  240. TextButton.TextColor3 = Color3.fromRGB(0, 0, 0)
  241. TextButton.TextScaled = true
  242. TextButton.TextSize = 14.000
  243. TextButton.TextWrapped = true
  244.  
  245. TextButton.MouseButton1Click:connect(function()
  246. local s = Instance.new("ScreenGui", game.Players.LocalPlayer.PlayerGui)
  247. local f = Instance.new("Frame", s)
  248. local mselect = Instance.new("TextButton", f)
  249. local mbox = Instance.new("TextBox", f)
  250. local toggle = false
  251. local Character = Player.Character
  252.  
  253. f.Size = UDim2.new(0,300,0,250)
  254. f.BorderSizePixel = 0
  255. f.BackgroundColor3 = Color3.new(0.301961, 0.301961, 0.301961)
  256. f.Position = UDim2.new(0.5,-150,0.5,-125)
  257. f.Active = true
  258. f.Draggable = true
  259.  
  260. mbox.Size = UDim2.new(0,250,0,50)
  261. mbox.Position = UDim2.new(0,25,0.1,0)
  262. mbox.BorderSizePixel = 0
  263. mbox.Text = "Music ID Here:"
  264. mbox.Font = "SourceSansBold"
  265. mbox.TextColor3 = Color3.new(255, 255,255)
  266. mbox.BackgroundColor3 = Color3.new(1, 0.666667, 0)
  267. mbox.FontSize = "Size18"
  268. mbox.ZIndex = 10
  269.  
  270. mselect.Size = UDim2.new(0,250,0,50)
  271. mselect.Position = UDim2.new(0,25,0.6,0)
  272. mselect.BorderSizePixel = 0
  273. mselect.Text = "Play Music"
  274. mselect.Font = "SourceSansBold"
  275. mselect.TextColor3 = Color3.new(255,255,255)
  276. mselect.BackgroundColor3 = Color3.new(0.333333, 0.666667, 1)
  277. mselect.FontSize = "Size18"
  278. mselect.ZIndex = 10
  279.  
  280. mselect.MouseButton1Click:connect(function()
  281. Character.Humanoid.MaxHealth = math.huge -- this is god
  282. if toggle == false then
  283. loadPart()
  284. toggle = true
  285. elseif toggle == true then
  286. loadPart()
  287. toggle = false
  288. end
  289. end)
  290.  
  291. function loadPart()
  292. for i,v in pairs(Character:GetChildren()) do
  293. if v.Name == "MusicItem" and v.ClassName == "Part" then
  294. v:Remove()
  295. end
  296. end
  297. local Part = Instance.new("Part", Character)
  298. Part.CanCollide = false
  299. Part.Shape = "Block"
  300. Part.Anchored = false
  301. Part.Locked = true
  302. Part.Name = "MusicItem"
  303. Part.Transparency = 0
  304. Part.Material = "Neon"
  305. Part.BrickColor = BrickColor.new("Royal purple") --Cool Colors CGA brown and Royal purple
  306. local CylinderMesh = Instance.new("CylinderMesh", Part)
  307. CylinderMesh.Scale = Vector3.new(1.5,.2,1.5)
  308.  
  309.  
  310. local Sound = Instance.new("Sound", Part)
  311. Sound.SoundId = "https://www.roblox.com/asset/?id="..mbox.Text
  312. Sound.EmitterSize = math.huge
  313. Sound.MaxDistance = math.huge
  314. Sound.Looped = true
  315. Sound.Pitch = 1
  316. Sound.Name = "Sound"
  317. Sound.Volume = 10
  318. Sound:Play()
  319.  
  320. Part.CFrame = CFrame.new
  321. (Character.HumanoidRootPart.Position) * CFrame.new(0,-2.9,0)
  322. local bp = Instance.new("BodyPosition", Part)
  323. bp.Position = Character:FindFirstChild("Torso").CFrame * CFrame.new(0, -2.9, 0).p
  324. bp.MaxForce = Vector3.new(10000,10000,10000)
  325. bp.P = 100000
  326.  
  327. while true do wait()
  328. bp.Position = Character:FindFirstChild("Torso").CFrame * CFrame.new(0, -2.9, 0).p
  329. local alg = math.floor(Sound.PlaybackLoudness)/50
  330. CylinderMesh.Scale = Vector3.new(.6+alg,.2,.6+alg)
  331. end
  332. end
  333. end)
  334.  
  335. local KeyboardWeld2 = Instance.new("Weld")
  336. KeyboardWeld2.Part0 = Torso2
  337. KeyboardWeld2.Part1 = Keyboard2
  338. KeyboardWeld2.C0 = CFrame.new(1, 0.4, -3) * CFrame.Angles(2, 0, 0)
  339.  
  340. KeyboardWeld.Parent = Keyboard
  341. Keyboard.Parent = Torso
  342.  
  343. KeyboardWeld2.Parent = Keyboard2
  344. Keyboard2.Parent = Torso2
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement