Advertisement
lafur

Untitled

Dec 15th, 2018
147
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. --https://github.com/Mokiros/roblox-FE-compatibility
  2. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  3. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  4. local RealPlayer = Player
  5. do print("FE Compatibility code by Mokiros")local a=RealPlayer;script.Parent=a.Character;local b=Instance.new("RemoteEvent")b.Name="UserInput_Event"local function c()local d={_fakeEvent=true,Functions={},Connect=function(self,e)table.insert(self.Functions,e)end}d.connect=d.Connect;return d end;local f={Target=nil,Hit=CFrame.new(),KeyUp=c(),KeyDown=c(),Button1Up=c(),Button1Down=c(),Button2Up=c(),Button2Down=c()}local g={InputBegan=c(),InputEnded=c()}local CAS={Actions={},BindAction=function(self,h,i,j,...)CAS.Actions[h]=i and{Name=h,Function=i,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function k(self,l,...)local d=f[l]if d and d._fakeEvent then for m,e in pairs(d.Functions)do e(...)end end end;f.TrigEvent=k;g.TrigEvent=k;b.OnServerEvent:Connect(function(n,o)if n~=a then return end;f.Target=o.Target;f.Hit=o.Hit;if not o.isMouse then local p=o.UserInputState==Enum.UserInputState.Begin;if o.UserInputType==Enum.UserInputType.MouseButton1 then return f:TrigEvent(p and"Button1Down"or"Button1Up")end;if o.UserInputType==Enum.UserInputType.MouseButton2 then return f:TrigEvent(p and"Button2Down"or"Button2Up")end;for m,d in pairs(CAS.Actions)do for m,q in pairs(d.Keys)do if q==o.KeyCode then d.Function(d.Name,o.UserInputState,o)end end end;f:TrigEvent(p and"KeyDown"or"KeyUp",o.KeyCode.Name:lower())g:TrigEvent(p and"InputBegan"or"InputEnded",o,false)end end)b.Parent=NLS([==[local a=game:GetService("Players").LocalPlayer;local b=script:WaitForChild("UserInput_Event")local c=a:GetMouse()local d=game:GetService("UserInputService")local e=function(f,g)if g then return end;b:FireServer({KeyCode=f.KeyCode,UserInputType=f.UserInputType,UserInputState=f.UserInputState,Hit=c.Hit,Target=c.Target})end;d.InputBegan:Connect(e)d.InputEnded:Connect(e)local h,i;while wait(1/30)do if h~=c.Hit or i~=c.Target then h,i=c.Hit,c.Target;b:FireServer({isMouse=true,Target=i,Hit=h})end end]==],Player.Character)local r=game;local s={__index=function(self,q)local t=rawget(self,"_RealService")if t then return typeof(t[q])=="function"and function(m,...)return t[q](t,...)end or t[q]end end,__newindex=function(self,q,u)local t=rawget(self,"_RealService")if t then t[q]=u end end}local function v(d,w)d._RealService=typeof(w)=="string"and r:GetService(w)or w;return setmetatable(d,s)end;local x={GetService=function(self,t)return rawget(self,t)or r:GetService(t)end,Players=v({LocalPlayer=v({GetMouse=function(self)return f end},Player)},"Players"),UserInputService=v(g,"UserInputService"),ContextActionService=v(CAS,"ContextActionService"),RunService=v({_btrs={},RenderStepped=r:GetService("RunService").Heartbeat,BindToRenderStep=function(self,h,m,i)self._btrs[h]=self.Heartbeat:Connect(i)end,UnbindFromRenderStep=function(self,h)self._btrs[h]:Disconnect()end},"RunService")}rawset(x.Players,"localPlayer",x.Players.LocalPlayer)x.service=x.GetService;v(x,game)game,owner=x,x.Players.LocalPlayer end --By Rufus14
  6. --ears: 391268255
  7. --bamalam: 720451528
  8. --columb: 1202637744
  9. music = Instance.new("Sound", game.Players.LocalPlayer.Character.Torso)
  10. music.Volume = 0
  11. music.SoundId = "rbxassetid://0"
  12. music.Looped = true
  13. music:Play()
  14. mouse = game.Players.LocalPlayer:GetMouse()
  15. gun = Instance.new("Part", game.Players.LocalPlayer.Character)
  16. gun:BreakJoints()
  17. gun.CanCollide = false
  18. gun.Name = "Shotgun"
  19. mesh = Instance.new("SpecialMesh", gun)
  20. mesh.MeshId = "rbxassetid://477037714"
  21. mesh.TextureId = "rbxassetid://477037796"
  22. mesh.Scale = Vector3.new(0.03,0.03,0.03)
  23. weld = Instance.new("Weld", gun)
  24. weld.Part0 = game.Players.LocalPlayer.Character["Right Arm"]
  25. weld.Part1 = gun
  26. weld.C0 = weld.C0 * CFrame.Angles(-1.5,0,0) * CFrame.new(0,0,-2.5)
  27. local rhandweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso)
  28. rhandweld.Part0 = game.Players.LocalPlayer.Character.Torso
  29. rhandweld.Part1 = game.Players.LocalPlayer.Character["Right Arm"]
  30. rhandweld.C0 = CFrame.new(1.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  31. local lhandweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso)
  32. lhandweld.Part0 = game.Players.LocalPlayer.Character.Torso
  33. lhandweld.Part1 = game.Players.LocalPlayer.Character["Left Arm"]
  34. lhandweld.C0 = CFrame.new(-1.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  35. shot = Instance.new("Sound", gun)
  36. shot.Volume = 10
  37. shot.SoundId = "rbxassetid://185044507"
  38. pump = Instance.new("Sound", gun)
  39. pump.Volume = 10
  40. pump.SoundId = "rbxassetid://255061173"
  41. pump.PlaybackSpeed = 0.7
  42. function owtheedge()
  43. workspace.CurrentCamera.FieldOfView = 70 + music.PlaybackLoudness / 80
  44. end
  45. game:GetService("RunService").RenderStepped:connect(owtheedge)
  46. for i = 0,0.7 , 0.01 do
  47. weld.C0 = weld.C0:lerp(CFrame.new(-0.342021942, -1.88848877, -0.088739872, 0.978147507, -0.0289359875, -0.205888897, 0.204753578, -0.0378959738, 0.978079677, -0.0361040607, -0.998862624, -0.0311431047),i)
  48. rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(0.917564392, 0.399175882, -0.578536987, 0.978147507, 0.204753578, -0.0361040607, -0.0289359875, -0.0378959738, -0.998862624, -0.205888897, 0.978079677, -0.0311431047),i)
  49. lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-0.472423553, 0.409558296, -1.4746933, 0.939692736, -0.342019886, -2.0985492e-06, 0.0238559935, 0.0655499771, -0.997564137, 0.341186911, 0.937403619, 0.0697560608),i)
  50. game:GetService("RunService").RenderStepped:wait()
  51. end
  52. using = false
  53. ammo = 5
  54. function shoot()
  55. if not using then
  56. using = true
  57. shot:Play()
  58. for i = 1,5 do
  59. local missle = Instance.new("Part", workspace)
  60. missle:BreakJoints()
  61. missle.Name = "bullet"
  62. missle.CanCollide = false
  63. missle.Material = "Neon"
  64. missle.Size = Vector3.new(0.1,0.1,0.1)
  65. missle.CFrame = gun.CFrame * CFrame.new(0,0,2)
  66. missle.Transparency = 1
  67. local vel = Instance.new("BodyVelocity", missle)
  68. vel.Velocity = mouse.Hit.lookVector * math.random(500,500) + Vector3.new(math.random(-50,50),math.random(-50,50),0)
  69. vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  70. local function hit(part)
  71. local hitval = math.random(25,40)
  72. local humanoid = part.Parent:findFirstChildOfClass("Humanoid")
  73. if humanoid then
  74. if humanoid.Health == math.huge or humanoid.Health >= 600 then
  75. humanoid.Health = 100
  76. end
  77. if humanoid.MaxHealth == math.huge or humanoid.MaxHealth >= 600 then
  78. humanoid.MaxHealth = 100
  79. end
  80. if humanoid.Parent.Name == game.Players.LocalPlayer.Name then
  81.  
  82. else
  83. if humanoid.Health < hitval then
  84. humanoid.JumpPower = 0
  85. humanoid.PlatformStand = true
  86. humanoid.WalkSpeed = 0
  87. local findlefthip = humanoid.Parent.Torso:findFirstChild("Left Hip")
  88. if findlefthip then
  89. findlefthip:Remove()
  90. local glue = Instance.new("Glue", humanoid.Parent.Torso)
  91. glue.Part0 = humanoid.Parent.Torso
  92. glue.Part1 = humanoid.Parent["Left Leg"]
  93. glue.Name = "Left leg"
  94. local collider = Instance.new("Part", humanoid.Parent["Left Leg"])
  95. collider.Position = Vector3.new(0,999,0)
  96. collider.Size = Vector3.new(1.5, 1, 1)
  97. collider.Shape = "Cylinder"
  98. local weld = Instance.new("Weld", collider)
  99. weld.Part0 = humanoid.Parent["Left Leg"]
  100. weld.Part1 = collider
  101. weld.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  102. collider.TopSurface = "Smooth"
  103. collider.BottomSurface = "Smooth"
  104. collider.formFactor = "Symmetric"
  105. glue.C0 = CFrame.new(-0.5, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  106. glue.C1 = CFrame.new(-0, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  107. collider.Transparency = 1
  108. end
  109. --
  110. local findrighthip = humanoid.Parent.Torso:findFirstChild("Right Hip")
  111. if findrighthip then
  112. findrighthip:Remove()
  113. local glue = Instance.new("Glue", humanoid.Parent.Torso)
  114. glue.Part0 = humanoid.Parent.Torso
  115. glue.Part1 = humanoid.Parent["Right Leg"]
  116. glue.Name = "Right leg"
  117. local collider = Instance.new("Part", humanoid.Parent["Right Leg"])
  118. collider.Position = Vector3.new(0,999,0)
  119. collider.Size = Vector3.new(1.5, 1, 1)
  120. collider.Shape = "Cylinder"
  121. local weld = Instance.new("Weld", collider)
  122. weld.Part0 = humanoid.Parent["Right Leg"]
  123. weld.Part1 = collider
  124. weld.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  125. collider.TopSurface = "Smooth"
  126. collider.BottomSurface = "Smooth"
  127. collider.formFactor = "Symmetric"
  128. glue.C0 = CFrame.new(0.5, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  129. glue.C1 = CFrame.new(0, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  130. collider.Transparency = 1
  131. end
  132. --
  133. local findrightshoulder = humanoid.Parent.Torso:findFirstChild("Right Shoulder")
  134. if findrightshoulder then
  135. findrightshoulder:Remove()
  136. local glue = Instance.new("Glue", humanoid.Parent.Torso)
  137. glue.Part0 = humanoid.Parent.Torso
  138. glue.Part1 = humanoid.Parent["Right Arm"]
  139. glue.Name = "Right arm"
  140. local collider = Instance.new("Part", humanoid.Parent["Right Arm"])
  141. collider.Position = Vector3.new(0,999,0)
  142. collider.Size = Vector3.new(1.5, 1, 1)
  143. collider.Shape = "Cylinder"
  144. local weld = Instance.new("Weld", collider)
  145. weld.Part0 = humanoid.Parent["Right Arm"]
  146. weld.Part1 = collider
  147. weld.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  148. collider.TopSurface = "Smooth"
  149. collider.BottomSurface = "Smooth"
  150. collider.formFactor = "Symmetric"
  151. glue.C0 = CFrame.new(1.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  152. glue.C1 = CFrame.new(0, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  153. collider.Transparency = 1
  154. end
  155. --
  156. local findleftshoulder = humanoid.Parent.Torso:findFirstChild("Left Shoulder")
  157. if findleftshoulder then
  158. findleftshoulder:Remove()
  159. local glue = Instance.new("Glue", humanoid.Parent.Torso)
  160. glue.Part0 = humanoid.Parent.Torso
  161. glue.Part1 = humanoid.Parent["Left Arm"]
  162. glue.Name = "Left arm"
  163. local collider = Instance.new("Part", humanoid.Parent["Left Arm"])
  164. collider.Position = Vector3.new(0,999,0)
  165. collider.Size = Vector3.new(1.5, 1, 1)
  166. collider.Shape = "Cylinder"
  167. local weld = Instance.new("Weld", collider)
  168. weld.Part0 = humanoid.Parent["Left Arm"]
  169. weld.Part1 = collider
  170. weld.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  171. collider.TopSurface = "Smooth"
  172. collider.BottomSurface = "Smooth"
  173. collider.formFactor = "Symmetric"
  174. glue.C0 = CFrame.new(-1.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  175. glue.C1 = CFrame.new(0, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  176. collider.Transparency = 1
  177. end
  178. local findhead = humanoid.Parent:findFirstChild("Head")
  179. if findhead then
  180. local attachment = Instance.new("Attachment", humanoid.Parent.Head)
  181. attachment.Position = Vector3.new(0, -0.5, 0)
  182. attachment.Name = "lol"
  183. attachment.Visible = false
  184. humanoid.Parent.Torso.NeckAttachment.Visible = false
  185. humanoid.Parent.Torso.NeckAttachment.Position = humanoid.Parent.Torso.NeckAttachment.Position + Vector3.new(0,0,0)
  186. local ball = Instance.new("BallSocketConstraint", humanoid.Parent)
  187. ball.Attachment0 = humanoid.Parent.Torso.NeckAttachment
  188. ball.Attachment1 = attachment
  189. ball.LimitsEnabled = true
  190. ball.TwistLimitsEnabled = true
  191. ball.UpperAngle = 90
  192. ball.Restitution = 0.5
  193. ball.TwistUpperAngle = 90
  194. ball.TwistLowerAngle = -90
  195. local collidepartofleftleg = Instance.new("Part", humanoid.Parent.Torso)
  196. collidepartofleftleg.Name = "Bone"
  197. collidepartofleftleg.Size = Vector3.new(0.7,0.7,0.7)
  198. collidepartofleftleg.Transparency = 1
  199. collidepartofleftleg:BreakJoints()
  200. local weeld = Instance.new("Weld", collidepartofleftleg)
  201. weeld.Part0 = collidepartofleftleg
  202. weeld.Part1 = humanoid.Parent["Head"]
  203. if humanoid.Parent.Torso:findFirstChild("Neck") then
  204. humanoid.Parent.Torso.Neck:destroy()
  205. end
  206. end
  207. wait(10)
  208. humanoid.Health = 0
  209. else
  210. humanoid.Health = humanoid.Health - hitval
  211. end
  212. end
  213. else
  214. if part.Name == "Shotgun" or "bullet" then
  215.  
  216. else
  217. missle:destroy()
  218. end
  219. end
  220. end
  221. missle.Touched:connect(hit)
  222. end
  223. for i = 0,1 , 0.07 do
  224. weld.C0 = weld.C0:lerp(CFrame.new(-0.342021942, -1.88848877, -0.088739872, 0.978147507, -0.0289359875, -0.205888897, 0.204753578, -0.0378959738, 0.978079677, -0.0361040607, -0.998862624, -0.0311431047),i)
  225. rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(0.917564392, 0.491810799, -0.168943405, 0.978147507, 0.204753578, -0.0361040607, 0.0289353225, -0.306021929, -0.951584637, -0.205889001, 0.929745436, -0.305259228),i)
  226. lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-0.472423553, 0.748803854, -1.02752113, 0.939693093, -0.342019022, -2.66768012e-07, -0.0711100101, -0.195373133, -0.978147566, 0.334545016, 0.919158578, -0.207911715),i)
  227. game:GetService("RunService").RenderStepped:wait()
  228. end
  229. for i = 0,1 , 0.05 do
  230. weld.C0 = weld.C0:lerp(CFrame.new(-0.342021942, -1.88848877, -0.088739872, 0.978147507, -0.0289359875, -0.205888897, 0.204753578, -0.0378959738, 0.978079677, -0.0361040607, -0.998862624, -0.0311431047),i)
  231. rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(0.917564392, 0.491810799, -0.168943405, 0.978147507, 0.204753578, -0.0361040607, 0.0289353225, -0.306021929, -0.951584637, -0.205889001, 0.929745436, -0.305259228),i)
  232. lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-0.201648712, 0.903478384, -1.75520706, 0.939693093, -0.342019022, -2.66768012e-07, -0.0711100101, -0.195373133, -0.978147566, 0.334545016, 0.919158578, -0.207911715),i)
  233. game:GetService("RunService").RenderStepped:wait()
  234. end
  235. pump:Play()
  236. for i = 0,1 , 0.05 do
  237. weld.C0 = weld.C0:lerp(CFrame.new(-0.342021942, -1.88848877, -0.088739872, 0.978147507, -0.0289359875, -0.205888897, 0.204753578, -0.0378959738, 0.978079677, -0.0361040607, -0.998862624, -0.0311431047),i)
  238. rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(0.917564392, 0.491810799, -0.168943405, 0.978147507, 0.204753578, -0.0361040607, 0.0289353225, -0.306021929, -0.951584637, -0.205889001, 0.929745436, -0.305259228),i)
  239. lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-0.44393158, 0.765078783, -1.10408783, 0.939693093, -0.342019022, -2.66768012e-07, -0.0711100101, -0.195373133, -0.978147566, 0.334545016, 0.919158578, -0.207911715),i)
  240. game:GetService("RunService").RenderStepped:wait()
  241. end
  242. for i = 0,1 , 0.05 do
  243. weld.C0 = weld.C0:lerp(CFrame.new(-0.342021942, -1.88848877, -0.088739872, 0.978147507, -0.0289359875, -0.205888897, 0.204753578, -0.0378959738, 0.978079677, -0.0361040607, -0.998862624, -0.0311431047),i)
  244. rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(0.917564392, 0.491810799, -0.168943405, 0.978147507, 0.204753578, -0.0361040607, 0.0289353225, -0.306021929, -0.951584637, -0.205889001, 0.929745436, -0.305259228),i)
  245. lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-0.201648712, 0.903478384, -1.75520706, 0.939693093, -0.342019022, -2.66768012e-07, -0.0711100101, -0.195373133, -0.978147566, 0.334545016, 0.919158578, -0.207911715),i)
  246. game:GetService("RunService").RenderStepped:wait()
  247. end
  248. for i = 0,0.7 , 0.04 do
  249. weld.C0 = weld.C0:lerp(CFrame.new(-0.342021942, -1.88848877, -0.088739872, 0.978147507, -0.0289359875, -0.205888897, 0.204753578, -0.0378959738, 0.978079677, -0.0361040607, -0.998862624, -0.0311431047),i)
  250. rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(0.917564392, 0.399175882, -0.578536987, 0.978147507, 0.204753578, -0.0361040607, -0.0289359875, -0.0378959738, -0.998862624, -0.205888897, 0.978079677, -0.0311431047),i)
  251. lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-0.472423553, 0.409558296, -1.4746933, 0.939692736, -0.342019886, -2.0985492e-06, 0.0238559935, 0.0655499771, -0.997564137, 0.341186911, 0.937403619, 0.0697560608),i)
  252. game:GetService("RunService").RenderStepped:wait()
  253. end
  254. using = false
  255. end
  256. end
  257. mouse.Button1Down:connect(shoot)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement