Advertisement
clutchHorizon

roblox nerf gun credits:Natural Modder

Aug 18th, 2017
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 9.48 KB | None | 0 0
  1. debounce = 0;
  2.  
  3. local player = game.Players.LocalPlayer
  4. repeat wait() until player.Character.Humanoid
  5. local humanoid = player.Character.Humanoid
  6. local mouse = player:GetMouse()
  7. --game.Players.LocalPlayer.Character.Shirt.ShirtTemplate='rbxassetid:/4/73465498'
  8.  
  9.  
  10. local player=game.Players.LocalPlayer;
  11. local char=game.Players.LocalPlayer.Character;
  12. local humanoid = player.Character.Humanoid;
  13. Tool=Instance.new('Tool', game.Players.LocalPlayer.Backpack);
  14. Tool.GripRight=Vector3.new(0.865, 0.105, -0.49);
  15. Tool.GripUp=Vector3.new(-0.023, 0.985, 0.171);
  16. Tool.GripPos=Vector3.new(0.064, -0.3, 0.9);
  17. Tool.GripForward=Vector3.new(0.485, 0.14, -0.863); --0.485, 0.14, -0.863
  18. Tool.Name='Tec 9';
  19. Handle=Instance.new('Part', Tool);
  20. Handle.Name = 'Handle';
  21. Handle.BrickColor=BrickColor.new('Really black')
  22. Handle.Size=Vector3.new(0.26, 1.11, 4.85);
  23. Handle.Position=Vector3.new(-5.112, 1.837, -3.734)
  24. gunfire=Instance.new('Part', Tool)
  25. gunfire.Name='GunFire'
  26. gunfire.Size=Vector3.new(0.2, 0.2, 0.2)
  27. gunfire.Transparency=1
  28. gunfire.Position=Vector3.new(-5.142, 2.582, -5.059)
  29. gunfirefx=Instance.new('BillboardGui', gunfire)
  30. gunfirefx.Enabled=false
  31. gunfirefx.Adornee = gunfire
  32. gunfirefx.Size=UDim2.new(1.1, 0, 1.1, 0)
  33. gunfirefx2=Instance.new('ImageLabel', gunfirefx)
  34. gunfirefx2.Image='http://www.roblox.com/asset/?id=117472237'
  35. gunfirefx2.BackgroundTransparency=1
  36. gunfirefx2.Size=UDim2.new(1.2, 0, 1.2, 0)
  37.  
  38.  
  39. c4mesh=Instance.new('SpecialMesh', Handle);
  40. c4mesh.MeshType = 'FileMesh';
  41. c4mesh.MeshId='http://www.roblox.com/asset/?id=984988307';
  42. c4mesh.TextureId='http://www.roblox.com/asset/?id=984988604';
  43. c4mesh.Scale=Vector3.new(0.075, 0.075, 0.075);
  44. light=Instance.new('PointLight', Handle);
  45. light.Color = Color3.new(255, 255, 0)
  46. light.Range=10;
  47. light.Enabled=false;
  48.  
  49. --Weld Connector
  50. local prev
  51. local parts = Tool:GetChildren()
  52. for i = 1,#parts do
  53. if (parts[i].className == "Part") then
  54. if (prev ~= nil)then
  55. local weld = Instance.new("Weld")
  56. weld.Part0 = prev
  57. weld.Part1 = parts[i]
  58. weld.C0 = prev.CFrame:inverse()
  59. weld.C1 = parts[i].CFrame:inverse()
  60. weld.Parent = prev
  61. end
  62. prev = parts[i]
  63. end
  64. end
  65. --end
  66. local Prepare=Instance.new("Animation", player.Character);
  67. Prepare.AnimationId="http://www.roblox.com/asset?id=168086975";
  68. local playAnim = humanoid:LoadAnimation(Prepare)
  69.  
  70. local Prepare3=Instance.new("Animation", player.Character);
  71. Prepare3.AnimationId="http://www.roblox.com/asset?id=95383474";
  72. local Prepare2Play = humanoid:LoadAnimation(Prepare3)
  73.  
  74. local Prepare2=Instance.new("Animation", player.Character);
  75. Prepare2.AnimationId="http://www.roblox.com/asset?id=95383474";
  76. local playAnim6 = humanoid:LoadAnimation(Prepare)
  77. standed=true
  78. local shoot=Instance.new("Animation", player.Character);
  79. shoot.AnimationId="http://www.roblox.com/Asset?ID=94332152";
  80. local playAnim2 = humanoid:LoadAnimation(shoot)
  81. local reload=Instance.new("Animation", player.Character);
  82. reload.AnimationId="http://www.roblox.com/Asset?ID=95390631";
  83. local playAnim3 = humanoid:LoadAnimation(reload)
  84. reloadsound=Instance.new('Sound', char.Torso)
  85. reloadsound.Volume=4
  86. reloadsound.SoundId='rbxassetid://266147528'
  87.  
  88. equip=Instance.new('Sound', char.Torso)
  89. equip.Volume=4
  90. equip.SoundId='rbxassetid://131045401'
  91.  
  92. equip2=Instance.new('Sound', char.Torso)
  93. equip2.Volume=4
  94. equip2.SoundId='rbxassetid://131045429'
  95. function equipped(mouse)
  96. function Shoot()
  97. if standed==false then
  98. if debounce == 0 then
  99. debounce = 1
  100. if mouse.Target ~= nil then
  101. if mouse.Target.Parent:findFirstChild("Humanoid") ~= nil and mouse.Target.Name ~= "Head" then
  102. mouse.Target.Parent.Humanoid:TakeDamage(75)
  103. hit=Instance.new('Sound', mouse.Target.Parent.Torso)
  104.  
  105. hit.Volume=7
  106. hit.SoundId='rbxassetid://159970596'
  107. hit:Play()
  108. elseif mouse.Target.Parent.Parent:findFirstChild("Humanoid") ~= nil then
  109. mouse.Target.Parent.Parent.Humanoid:TakeDamage(45)
  110.  
  111. hit=Instance.new('Sound', mouse.Target.Parent.Parent.Torso)
  112. hit.Volume=7
  113. hit.SoundId='rbxassetid://159970596'
  114. hit:Play()
  115. elseif mouse.Target.Name == "Part" then
  116. Hit = mouse.hit
  117. if Hit==nil then return end
  118. I = Instance.new("Part")
  119. I.Parent = game.Workspace
  120. I.CFrame = Hit
  121. I.Anchored=true
  122. I.Transparency=1
  123. I.Anchored=true
  124. I.CanCollide=false
  125. Pa=Instance.new('ParticleEmitter', I)
  126. Pa.Size = NumberSequence.new(0.2)
  127. Pa.Speed = NumberRange.new(40)
  128. Pa.Lifetime=NumberRange.new(0.4)
  129. Pa.RotSpeed = NumberRange.new(-255, 250)
  130. Pa.Texture = 'rbxassetid://316915922'
  131. Pa.LightEmission = 0
  132. Pa.EmissionDirection='Back'
  133. Pa.VelocitySpread = 250
  134. Pa.Rate = 500
  135. --
  136. Pa2=Instance.new('ParticleEmitter', I)
  137. Pa2.Size = NumberSequence.new(0.2)
  138. Pa2.Speed = NumberRange.new(40)
  139. Pa2.Lifetime=NumberRange.new(0.4)
  140. Pa2.RotSpeed = NumberRange.new(-255, 250)
  141. Pa2.Texture = 'rbxassetid://316915922'
  142. Pa2.LightEmission = 0
  143. Pa2.EmissionDirection='Back'
  144. Pa2.VelocitySpread = 250
  145. Pa2.Rate = 1000
  146. --
  147. Pa3=Instance.new('ParticleEmitter', I)
  148. Pa3.Size = NumberSequence.new(0.2)
  149. Pa3.Speed = NumberRange.new(40)
  150. Pa3.Lifetime=NumberRange.new(0.4)
  151. Pa3.RotSpeed = NumberRange.new(-255, 250)
  152. Pa3.Texture = 'rbxassetid://316915922'
  153. Pa3.LightEmission = 0
  154. Pa3.EmissionDirection='Back'
  155. Pa3.VelocitySpread = 250
  156. Pa3.Rate = 1000
  157.  
  158. --
  159. Pa4=Instance.new('ParticleEmitter', I)
  160. Pa4.Size = NumberSequence.new(0.4)
  161. Pa4.Speed = NumberRange.new(40)
  162. Pa4.Lifetime=NumberRange.new(0.4)
  163. Pa4.RotSpeed = NumberRange.new(-255, 250)
  164. Pa4.Texture = 'rbxassetid://316915922'
  165. Pa4.LightEmission = 0
  166. Pa4.EmissionDirection='Back'
  167. Pa4.VelocitySpread = 250
  168. Pa4.Rate = 1000
  169.  
  170. wait(0.1)
  171. Pa.Enabled=false
  172. Pa2.Enabled=false
  173. Pa3.Enabled=false
  174. Pa4.Enabled=false
  175.  
  176. hit=Instance.new('Sound', I)
  177. hit.Volume=5
  178. hit.SoundId='rbxassetid://159970596'
  179. hit:Play()
  180.  
  181. hit2=Instance.new('Sound', I)
  182. hit2.Volume=14
  183. hit2.SoundId='rbxassetid://516789356'
  184. hit2:Play()
  185. end
  186. end
  187.  
  188. playAnim2:Play()
  189. Prepare2Play:Stop()
  190. light.Enabled=true;
  191. gunfirefx.Enabled=true
  192. shootsound=Instance.new('Sound', char.Torso)
  193. shootsound.Volume=3
  194. shootsound.SoundId='rbxassetid://149355375'
  195. shootsound:Play()
  196. wait(0.01)
  197. light.Enabled=false;
  198. gunfirefx.Enabled=false
  199.  
  200. wait(0.001)
  201. Prepare2Play:Play()
  202. debounce = 0
  203. end
  204. end end
  205. mouse.Button1Down:connect(Shoot)
  206. end
  207.  
  208. Tool.Equipped:connect(equipped)
  209.  
  210. local player = game.Players.LocalPlayer
  211. repeat wait() until player.Character.Humanoid
  212. local humanoid = player.Character.Humanoid
  213. local mouse = player:GetMouse()
  214.  
  215. local reload=Instance.new("Animation", player.Character);
  216. reload.AnimationId="http://www.roblox.com/Asset?ID=95384819";
  217. local playAnim3 = humanoid:LoadAnimation(reload)
  218. reloading=false
  219. mouse.KeyDown:connect(function(key)
  220. if key == "r" then
  221. if reloading==true then
  222. playAnim3:Play()
  223. reloadsound:Play()
  224. wait(2)
  225. playAnim3:Stop()
  226. end end
  227. end)
  228. mouse.KeyDown:connect(function(key)
  229. if key == "q" then
  230. if reloading==true then
  231. if standed==false then
  232. standed=true
  233. Prepare2Play:Stop()
  234. equip2:Play()
  235. wait()
  236. playAnim:Play()
  237. Tool.GripForward=Vector3.new(0.485, 0.14, -0.863); --0.485, 0.14, -0.863
  238. elseif standed==true then
  239. standed=false
  240. playAnim:Stop()
  241. wait()
  242. Prepare2Play:Play()
  243. equip:Play()
  244. Tool.GripForward=Vector3.new(-0.501, 0.137, -0.855);
  245. end end end
  246. end)
  247. stfu=false
  248. function equipped()
  249. wait()
  250. stfu=true
  251. wait()
  252. playAnim:Play()
  253. equip:Play()
  254. reloading=true
  255. end
  256.  
  257. function unequipped()
  258. wait()
  259. playAnim:Stop()
  260. reloading=false
  261. Prepare2Play:Stop()
  262. stfu=false
  263. end
  264.  
  265. Tool.Equipped:connect(equipped)
  266. Tool.Unequipped:connect(unequipped)
  267.  
  268.  
  269. --STFU
  270. stfuu=Instance.new('Sound', char.Torso)
  271. stfuu.Volume=3
  272. stfuu.Pitch=6.8
  273. stfuu.SoundId='rbxassetid://261303790'
  274. mouse.KeyDown:connect(function(key)
  275. if key == "z" then
  276. if stfu==true then
  277. stfuu:Play()
  278. game:GetService("Chat"):Chat(char.Head, "SHUT THE FUCK UP U CUNT", Enum.ChatColor.Red)
  279. wait(2)
  280. end end
  281. end)
  282.  
  283.  
  284. ---
  285.  
  286. --Masked
  287. local player = game.Players.LocalPlayer
  288. repeat wait() until player.Character.Humanoid
  289. local humanoid = player.Character.Humanoid
  290. local mouse = player:GetMouse()
  291. equipsound = Instance.new('Sound', player.Character.Torso)
  292. equipsound.Volume=3
  293. equipsound.SoundId='rbxassetid://153647514'
  294.  
  295. local anim5 = Instance.new("Animation", player.Character)
  296. anim5.AnimationId = "http://www.roblox.com/asset/?id=28492456"
  297. local playAnim10 = humanoid:LoadAnimation(anim5)
  298. plyr = player
  299. --p = game:GetService("InsertService"):LoadAsset(304085055)
  300. --p.Name='IsMasked'
  301. --p.Parent = game.Workspace
  302. ismasked=false
  303. maskhat=Instance.new('Hat', game.Workspace)
  304. maskhat.Name='IsMasked'
  305. maskhat.AttachmentForward=Vector3.new(0, 0, 0.1);
  306. maskhat.AttachmentPos=Vector3.new(0, 0.8, -0.05);
  307. maskhat.AttachmentRight=Vector3.new(1, 0, 0);
  308. maskhat.AttachmentUp=Vector3.new(0, 1, 0);
  309. maskhandle=Instance.new('Part', maskhat)
  310. maskhandle.Name='Handle';
  311. maskhandle.Anchored=false
  312. maskhandle.Size=Vector3.new(1.33, 1, 1.7)
  313. maskmeshh=Instance.new('SpecialMesh', maskhandle)
  314. maskmeshh.MeshType='FileMesh'
  315. maskmeshh.MeshId='http://www.roblox.com/asset/?id=304084512'
  316. maskmeshh.TextureId='http://www.roblox.com/asset/?id=304083165'
  317. wait(0.001)
  318. game.Workspace.IsMasked.Parent = plyr.Character
  319.  
  320. maskhandle.Transparency=1
  321. mouse.KeyDown:connect(function(key)
  322. if key == "f" then
  323. if ismasked==false then
  324. ismasked=true
  325. Handle.Transparency=1
  326. playAnim10:Play()
  327. wait(0.5)
  328. playAnim10:Stop()
  329. equipsound:Play()
  330. Handle.Transparency=0
  331. player.Character.Humanoid.DisplayDistanceType='None'
  332. maskhandle.Transparency=0
  333.  
  334. elseif ismasked==true then
  335. ismasked=false
  336. Handle.Transparency=1
  337. playAnim10:Play()
  338. wait(0.5)
  339. playAnim10:Stop()
  340. equipsound:Play()
  341. player.Character.Humanoid.DisplayDistanceType='Viewer'
  342. maskhandle.Transparency=1
  343. Handle.Transparency=0
  344. end
  345. end
  346.  
  347. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement