Advertisement
JacksoMykalJunior

Untitled

Mar 6th, 2019
158
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 10.57 KB | None | 0 0
  1. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  2. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  3. do
  4. print("FE Covered By Red_Jack142 | FE Made By Red_Jack142")
  5. print("Have Fun!")
  6. script.Parent = Player.Character
  7.  
  8. --RemoteEvent for communicating
  9. local Event = Instance.new("RemoteEvent")
  10. Event.Name = "UserInput_Event"
  11.  
  12. --Fake event to make stuff like Mouse.KeyDown work
  13. local function fakeEvent()
  14. local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
  15. t.connect = t.Connect
  16. return t
  17. end
  18.  
  19. --Creating fake input objects with fake variables
  20. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  21. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  22. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  23. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  24. end}
  25. --Merged 2 functions into one by checking amount of arguments
  26. CAS.UnbindAction = CAS.BindAction
  27.  
  28. --This function will trigger the events that have been :Connect()'ed
  29. local function te(self,ev,...)
  30. local t = m[ev]
  31. if t and t._fakeEvent and t.Function then
  32. t.Function(...)
  33. end
  34. end
  35. m.TrigEvent = te
  36. UIS.TrigEvent = te
  37.  
  38. Event.OnServerEvent:Connect(function(plr,io)
  39. if plr~=Player then return end
  40. if io.isMouse then
  41. m.Target = io.Target
  42. m.Hit = io.Hit
  43. else
  44. local b = io.UserInputState == Enum.UserInputState.Begin
  45. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  46. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  47. end
  48. for _,t in pairs(CAS.Actions) do
  49. for _,k in pairs(t.Keys) do
  50. if k==io.KeyCode then
  51. t.Function(t.Name,io.UserInputState,io)
  52. end
  53. end
  54. end
  55. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  56. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  57. end
  58. end)
  59. Event.Parent = NLS([==[
  60. local Player = owner
  61. local Event = script:WaitForChild("UserInput_Event")
  62.  
  63. local UIS = game:GetService("UserInputService")
  64. local input = function(io,a)
  65. if a then return end
  66. --Since InputObject is a client-side instance, we create and pass table instead
  67. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
  68. end
  69. UIS.InputBegan:Connect(input)
  70. UIS.InputEnded:Connect(input)
  71.  
  72. local Mouse = Player:GetMouse()
  73. local h,t
  74. --Give the server mouse data 30 times every second, but only if the values changed
  75. --If player is not moving their mouse, client won't fire events
  76. while wait(1/30) do
  77. if h~=Mouse.Hit or t~=Mouse.Target then
  78. h,t=Mouse.Hit,Mouse.Target
  79. Event:FireServer({isMouse=true,Target=t,Hit=h})
  80. end
  81. end]==],Player.Character)
  82. Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
  83. end
  84.  
  85.  
  86.  
  87. -- made by naser2018 ---
  88. Parts={}
  89. function GetDiscoColor(hue)
  90. local section = hue % 1 * 3
  91. local secondary = 0.5 * math.pi * (section % 1)
  92. if section < 1 then
  93. return Vector3.new(1, 1 - math.cos(secondary), 1 - math.sin(secondary))
  94. elseif section < 2 then
  95. return Vector3.new(1 - math.sin(secondary), 1, 1 - math.cos(secondary))
  96. else
  97. return Vector3.new(1 - math.cos(secondary), 1 - math.sin(secondary), 1)
  98. end
  99. end
  100. Part = function(x,y,z,color,tr,cc,an,parent)
  101. local p = Instance.new('Part',parent or Weapon)
  102. p.formFactor = 'Custom'
  103. p.Size = Vector3.new(x,y,z)
  104. p.BrickColor = BrickColor.new(color)
  105. p.CanCollide = cc
  106. p.Transparency = tr
  107. p.Anchored = an
  108. p.TopSurface,p.BottomSurface = 0,0
  109. p:BreakJoints''
  110. table.insert(Parts,p)
  111. return p
  112. end
  113. Weld = function(p0,p1)
  114. local w = Instance.new('Motor',p0)
  115. w.Part0 = p0
  116. w.Part1 = p1
  117. return w
  118. end
  119. Mesh = function(par,num,x,y,z)
  120. local msh = 0
  121. if num == 1 then
  122. msh = Instance.new("SpecialMesh",par)
  123. msh.MeshId='rbxasset://fonts/torso.mesh'
  124. msh.TextureId='rbxasset://25701026'
  125. end
  126. if num == 2 then
  127. msh = Instance.new("SpecialMesh",par)
  128. msh.MeshId='rbxasset://fonts/head.mesh'
  129. msh.TextureId='rbxassetid://25701026'
  130. end
  131. msh.Scale = Vector3.new(x,y,z)
  132. return msh
  133. end
  134. plr=owner
  135. char=plr.Character
  136. for _,v in pairs(char:GetChildren()) do
  137. if v.ClassName=="Part" then
  138. v.Transparency=1
  139. elseif v.ClassName=="Hat" then
  140. v.Handle.Mesh.TextureId='rbxassetid://25701026'
  141. table.insert(Parts,v.Handle)
  142. end
  143. end
  144. t=Part(1,1,1,'',0,false,false,char)
  145. Mesh(t,1,1,1,1)
  146. Weld(char.Torso,t)
  147. a=Part(1,1,1,'',0,false,false,char)
  148. Mesh(a,1,.5,1,1)
  149. Weld(char['Right Arm'],a)
  150. a=Part(1,1,1,'',0,false,false,char)
  151. Mesh(a,1,.5,1,1)
  152. Weld(char['Left Arm'],a)
  153. l=Part(1,1,1,'',0,false,false,char)
  154. Mesh(l,1,.5,1,1)
  155. Weld(char['Right Leg'],l)
  156. l=Part(1,1,1,'',0,false,false,char)
  157. Mesh(l,1,.5,1,1)
  158. Weld(char['Left Leg'],l)
  159. h=Part(1,1,1,'',0,false,false,char)
  160. Mesh(h,2,1,1,1)
  161. Weld(char.Head,h)
  162. Spawn(function()
  163. while(coroutine.yield())do
  164. for i=1,#Parts do
  165. Parts[i].Mesh.VertexColor=GetDiscoColor(tick()*.5)--vertex 4 lyfe plr = owner
  166. part = nil
  167. bp = nil
  168. particles = nil
  169. function clerp(a,b,c,d)
  170. for i = 0,d,.01 do
  171. a.CFrame = CFrame.new(b:lerp(c,i))
  172. wait()
  173. end
  174. end
  175. function slerp(a2,b2,c2,d2)
  176. for i2 = 0,d2,.01 do
  177. a2.CFrame = CFrame.new(b2:lerp(c2,i2))
  178. wait()
  179. end
  180. end
  181. mouse.KeyDown:connect(function(key)
  182. if key == "e" and plr.Character.Parent == workspace then
  183. plr.Character.Parent = workspace.Camera
  184. plr.Character.Archivable = true
  185. Instance.new("ForceField",plr.Character).Visible = false
  186. for y,t in pairs(plr.Character:GetChildren()) do
  187. if t:IsA("Part") and t.Name ~= "HumanoidRootPart" then
  188. t.Transparency = 1
  189. if t.Name == "Head" and t:FindFirstChild("face") then
  190. t.face.Transparency = 1
  191. end
  192. elseif t:IsA("Accessory") and t:FindFirstChild("Handle") then
  193. t.Handle.Transparency = 1
  194. end
  195. end
  196. elseif key == "z" and plr.Character.Parent == workspace.Camera and part == nil then
  197. plr.Character.Torso.CFrame = CFrame.new(Vector3.new(mouse.hit.p.X,mouse.hit.p.Y+1.5,mouse.hit.p.Z),plr.Character.Torso.CFrame.p)
  198. elseif key == "x" and plr.Character.Parent == workspace.Camera and part == nil then
  199. if plr.Character.Torso.Anchored == true then
  200. for y,t in pairs(plr.Character:GetChildren()) do
  201. if t:IsA("Part") then
  202. t.Anchored = false
  203. end
  204. end
  205. else
  206. for y,t in pairs(plr.Character:GetChildren()) do
  207. if t:IsA("Part") then
  208. t.Anchored = true
  209. end
  210. end
  211. end
  212. elseif key == "c" and plr.Character.Parent == workspace.Camera and part ~= nil then
  213. local clone = part:Clone()
  214. clone.Parent = workspace
  215. clone.Anchored = false
  216. clone:ClearAllChildren()
  217. clone.CanCollide = true
  218. bp.Parent = clone
  219. particles.Parent = clone
  220. if part.Parent:FindFirstChildOfClass("Humanoid") then
  221. part.Parent:FindFirstChildOfClass("Humanoid").PlatformStand = false
  222. end
  223. part:Destroy()
  224. part = clone
  225. elseif key == "t" and plr.Character.Parent == workspace.Camera and part == nil then
  226. plr.Character.Parent = workspace
  227. plr.Character.Archivable = false
  228. plr.Character:FindFirstChildOfClass("ForceField"):Remove()
  229. for y,t in pairs(plr.Character:GetChildren()) do
  230. if t:IsA("Part") and t.Name ~= "HumanoidRootPart" then
  231. t.Transparency = 0
  232. if t.Name == "Head" and t:FindFirstChild("face") then
  233. t.face.Transparency = 0
  234. end
  235. elseif t:IsA("Accessory") and t:FindFirstChild("Handle") then
  236. t.Handle.Transparency = 0
  237. end
  238. end
  239. end
  240. end)
  241. mouse.Button1Down:connect(function()
  242. if plr.Character.Parent == workspace.Camera then
  243. if mouse ~= nil then
  244. if mouse.Target ~= nil then
  245. part = mouse.Target
  246. bp = Instance.new("BodyPosition",part)
  247. bp.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  248. bp.Position = part.Position
  249. particles = Instance.new("ParticleEmitter",part)
  250. particles.Color = ColorSequence.new(Color3.new(0,0,0))
  251. particles.Size = NumberSequence.new(1)
  252. particles.Texture = "rbxassetid://292289455"
  253. particles.VelocitySpread = 360
  254. particles.Speed = NumberRange.new(0)
  255. particles.RotSpeed = NumberRange.new(0)
  256. particles.Rotation = NumberRange.new(0)
  257. particles.Rate = 250
  258. particles.Lifetime = NumberRange.new(.2,.4)
  259. particles.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,1,0),NumberSequenceKeypoint.new(.12,.688,0),NumberSequenceKeypoint.new(.891,.887,0),NumberSequenceKeypoint.new(1,1,0)})
  260. dwn = true
  261. end
  262. end
  263. while dwn == true do
  264. wait()
  265. bp.Position = mouse.hit.p
  266. if part then
  267. if part.Parent:FindFirstChildOfClass("Humanoid") then
  268. part.Parent:FindFirstChildOfClass("Humanoid").PlatformStand = true
  269. end
  270. end
  271. end
  272. end
  273. end)
  274. mouse.Button1Up:connect(function()
  275. dwn = false
  276. if part then if part.Parent:FindFirstChildOfClass("Humanoid") then part.Parent:FindFirstChildOfClass("Humanoid").PlatformStand = false end part = nil end
  277. if bp then bp:Destroy() end
  278. if particles then particles:Destroy() end
  279. end)
  280. base = Instance.new("ScreenGui",plr.PlayerGui)
  281. bbg = Instance.new("BillboardGui",plr.Character.Head)
  282. bbg.Size = UDim2.new(0,200,0,50)
  283. bbg.StudsOffset = Vector3.new(0,3,0)
  284. bbgTl = Instance.new("TextLabel",bbg)
  285. bbgTl.BackgroundTransparency = 1
  286. bbgTl.Size = UDim2.new(10,0,1,0)
  287. bbgTl.Position = UDim2.new(-4.5,0,0,0)
  288. bbgTl.Font = "Code"
  289. bbgTl.Text = " "
  290. bbgTl.TextSize = 25
  291. bbgTl.TextStrokeColor3 = Color3.new(1,1,1)
  292. bbgTl.TextColor3 = Color3.new(0,0,0)
  293. bbgTl.TextStrokeTransparency = 0
  294. bbgTl.TextWrapped = true
  295. plr.Chatted:connect(function(msg)
  296. bbgTl.Text = msg
  297. wait(5)
  298. if bbgTl.Text == msg then
  299. bbgTl.Text = " "
  300. end
  301. end)
  302. touchCounter = 0
  303. while wait() do
  304. if plr.Character.Parent == workspace.Camera then
  305. local c = plr.Character:Clone()
  306. c:MakeJoints()
  307. for y,t in pairs(c:GetChildren()) do
  308. if t:IsA("Part") then
  309. t.CanCollide = false
  310. t.Anchored = true
  311. t.Transparency = .5
  312. t.TopSurface = "Smooth"
  313. t.BottomSurface = "Smooth"
  314. t.RightSurface = "Smooth"
  315. t.LeftSurface = "Smooth"
  316. t.FrontSurface = "Smooth"
  317. t.BackSurface = "Smooth"
  318. t.BrickColor = BrickColor.new("Really black")
  319. if t.Name == "Head" and t:FindFirstChild("face") then
  320. t.face:Remove()
  321. elseif t.Name == "Torso" and t:FindFirstChild("roblox") then
  322. t.roblox:Remove()
  323. elseif t.Name == "HumanoidRootPart" then
  324. t:Remove()
  325. end
  326. else
  327. t:Remove()
  328. end
  329. end
  330. c.Parent = workspace
  331. game.Debris:AddItem(c,.05)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement