hgh920

Untitled

Mar 31st, 2017
304
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 17.04 KB | None | 0 0
  1. local p = game.Players.X8311
  2. local char = p.Character
  3. local mouse = p:GetMouse()
  4. local larm = char["Left Arm"]
  5. local rarm = char["Right Arm"]
  6. local lleg = char["Left Leg"]
  7. local rleg = char["Right Leg"]
  8. local hed = char.Head
  9. local torso = char.Torso
  10. local hum = char.Humanoid
  11. local cam = game.Workspace.CurrentCamera
  12. local root = char.HumanoidRootPart
  13. local deb = false
  14. local shot = 0
  15. local debris=game:service"Debris"
  16. local l = game:GetService("Lighting")
  17. local rs = game:GetService("RunService").RenderStepped
  18. ptz = {0.8, 0.85, 0.9, 0.95, 1, 1.05, 1.1}
  19. math.randomseed(os.time())
  20. for i,v in pairs(char:children()) do
  21. if v:IsA("Hat") then
  22. v:Destroy()
  23. end
  24. end
  25. for i,v in pairs (hed:GetChildren()) do
  26. if v:IsA("Sound") then
  27. v:Destroy()
  28. end
  29. end
  30. ----------------------------------------------------
  31. Debounces = {
  32. CanAttack = true;
  33. NoIdl = false;
  34. Slashing = false;
  35. Slashed = false;
  36. RPunch = false;
  37. RPunched = false;
  38. LPunch = false;
  39. LPunched = false;
  40. }
  41. local Touche = {char.Name, }
  42. ----------------------------------------------------
  43. hed.face.Texture = "rbxassetid://457885782"
  44. char["Body Colors"].HeadColor = BrickColor.new("Pastel brown")
  45. char["Body Colors"].TorsoColor = BrickColor.new("Pastel brown")
  46. char["Body Colors"].LeftArmColor = BrickColor.new("Pastel brown")
  47. char["Body Colors"].RightArmColor = BrickColor.new("Pastel brown")
  48. ----------------------------------------------------
  49. ypcall(function()
  50. char.Shirt:Destroy()
  51. char.Pants:Destroy()
  52. shirt = Instance.new("Shirt", char)
  53. shirt.Name = "Shirt"
  54. pants = Instance.new("Pants", char)
  55. pants.Name = "Pants"
  56. char.Shirt.ShirtTemplate = "http://www.roblox.com/asset/?id=12899714"
  57. char.Pants.PantsTemplate = "http://www.roblox.com/asset/?id=12900943"
  58. end)
  59. ---------------------------------------------------------
  60. local Target = "X8311"
  61.  
  62. local Character = game.Workspace[Target]
  63.  
  64. local hat = Instance.new('Hat', Character)
  65. hat.AttachmentPos = Vector3.new(.1, .2, -.15)
  66.  
  67. local handle = Instance.new('Part', hat)
  68. handle.Name = 'Handle'
  69.  
  70. local mesh = Instance.new('SpecialMesh')
  71. mesh.Parent = handle
  72. mesh.MeshId = 'rbxassetid://83490415'
  73. mesh.TextureId = 'rbxassetid://23026490'
  74. mesh.Scale = Vector3.new(1,1,1)
  75. ------------------------------------
  76. --MADE BY OneLegend (NOT THE SCRIPT) LOCAL SCRIPT: Go down to line 4 and put your name where it says "YOUR NAME HERE" Leave the "s
  77.  
  78.  
  79. local Name="X8311"
  80. local workspace=Workspace
  81. local player=game.Players[Name]
  82. local char=player.Character
  83. local Color=BrickColor.new("Pastel brown")
  84.  
  85. if script.Parent.className~="HopperBin" then
  86. pcall(function() char.Gourd:remove() end)
  87. Staff=Instance.new("HopperBin")
  88. Staff.Name="Sand"
  89. Staff.Parent=player.Backpack
  90. m=Instance.new("Model")
  91. m.Parent=char
  92. m.Name="Gourd"
  93. p=Instance.new("Part")
  94. p.Locked=true
  95. p.BrickColor=BrickColor:Red()
  96. p.Material="Concrete"
  97. p.Size=Vector3.new(1,1,1)
  98. Cent=p
  99. me=Instance.new("CylinderMesh")
  100. me.Scale=Vector3.new(1.2,0.4,1.2)
  101. me.Parent=p
  102. p.Parent=m
  103. w=Instance.new("Weld")
  104. w.Part1=char.Torso
  105. w.Part0=p
  106. w.Parent=p
  107. w.C0=CFrame.new(0,0.25,-1)*CFrame.Angles(0,0,math.rad(35))
  108. p=Instance.new("Part")
  109. p.Locked=true
  110. p.BrickColor=Color
  111. p.Material="Concrete"
  112. p.Size=Vector3.new(2,2,2)
  113. p.Shape="Ball"
  114. p.Parent=m
  115. w=Instance.new("Weld")
  116. w.Part1=Cent
  117. w.Part0=p
  118. w.Parent=p
  119. w.C0=CFrame.new(0,1,0)
  120. p=Instance.new("Part")
  121. p.Locked=true
  122. p.BrickColor=Color
  123. p.Material="Concrete"
  124. p.Size=Vector3.new(2,2,2)
  125. p.Shape="Ball"
  126. p.Parent=m
  127. w=Instance.new("Weld")
  128. w.Part1=Cent
  129. w.Part0=p
  130. w.Parent=p
  131. w.C0=CFrame.new(0,-1,0)
  132. Top=p
  133. p=Instance.new("Part")
  134. p.Locked=true
  135. p.BrickColor=Color
  136. p.Material="Concrete"
  137. p.Size=Vector3.new(1,1,1)
  138. p.Parent=m
  139. me=Instance.new("CylinderMesh")
  140. me.Scale=Vector3.new(0.5,0.15,0.5)
  141. me.Parent=p
  142. w=Instance.new("Weld")
  143. w.Part1=Top
  144. w.Part0=p
  145. w.Parent=p
  146. w.C0=CFrame.new(0,-1,0)
  147. p=Instance.new("Part")
  148. p.Locked=true
  149. p.BrickColor=BrickColor.new("Black")
  150. p.Material="Concrete"
  151. p.Size=Vector3.new(1,1,1)
  152. p.Parent=m
  153. me=Instance.new("CylinderMesh")
  154. me.Scale=Vector3.new(0.4,0.16,0.4)
  155. me.Parent=p
  156. w=Instance.new("Weld")
  157. w.Part1=Top
  158. w.Part0=p
  159. w.Parent=p
  160. w.C0=CFrame.new(0,-1,0)
  161. p=Instance.new("Part")
  162. p.Locked=true
  163. p.BrickColor=BrickColor:Red()
  164. p.Material="Concrete"
  165. p.Size=Vector3.new(2,1,1)
  166. p.Parent=m
  167. me=Instance.new("BlockMesh")
  168. me.Scale=Vector3.new(1.1,0.15,1.1)
  169. me.Parent=p
  170. w=Instance.new("Weld")
  171. w.Part1=char.Torso
  172. w.Part0=p
  173. w.Parent=p
  174. w.C0=CFrame.new(0,.75,0)
  175. p=Instance.new("Part")
  176. p.Locked=true
  177. p.BrickColor=BrickColor:Red()
  178. p.Material="Concrete"
  179. p.Size=Vector3.new(2,1,1)
  180. p.Parent=m
  181. me=Instance.new("BlockMesh")
  182. me.Scale=Vector3.new(1.29,0.15,1.1)
  183. me.Parent=p
  184. w=Instance.new("Weld")
  185. w.Part1=char.Torso
  186. w.Part0=p
  187. w.Parent=p
  188. w.C1=CFrame.new(0,0.1,0)*CFrame.Angles(0,0,math.rad(-40))
  189. script.Name="Not A QuickScript"
  190. script.Parent=Staff
  191. end
  192. Sword=script.Parent
  193. function hint(msg,de)
  194. for _,v in pairs(player:children()) do
  195. if v:IsA("Message") then
  196. v:remove()
  197. end
  198. end
  199. local h=Instance.new("Hint")
  200. h.Text=tostring(msg)
  201. h.Parent=player
  202. Delay(tonumber(de),function() h:remove() end)
  203. end
  204. ta={}
  205. for _,v in pairs(player.Backpack:GetChildren()) do
  206. if v.Name=="Sand" then
  207. table.insert(ta,v)
  208. end
  209. end
  210. if #ta==2 or #ta>2 then
  211. ta[1]:remove()
  212. end
  213. Hopper=script.Parent
  214. function Stream(mouse)
  215. local b=Instance.new("Part")
  216. b.BrickColor=Color
  217. b.Reflectance=0
  218. b.Transparency=1
  219. b.Size=Vector3.new(2,2,2)
  220. b.Shape="Ball"
  221. b.CanCollide=false
  222. b.TopSurface="Smooth"
  223. b.Position=char.Head.Position
  224. b.BottomSurface="Smooth"
  225. b.Friction=0
  226. b.Touched:connect(function(h) Hit(h) end)
  227. local bo=Instance.new("BodyVelocity")
  228. bo.maxForce=Vector3.new(9999,9999,9999)
  229. bo.velocity=(mouse.Hit.p-char.Head.Position).unit*60
  230. bo.Parent=b
  231. b.Parent=Gourd
  232. local Bo=b
  233. while Bo.Parent and Up==false do
  234. wait()
  235. if mouse.Target and (Bo.Position-mouse.Target.Position).magnitude<7 then
  236. Hit(mouse.Target)
  237. else
  238. Bo.CFrame=b.CFrame --BodyPosition anti-hax
  239. bo.velocity=(mouse.Hit.p-Bo.Position).unit*150
  240. end
  241. local b=Instance.new("Part")
  242. b.BrickColor=Color
  243. b.Reflectance=0
  244. b.Transparency=0.2
  245. b.Touched:connect(Hit)
  246. b.Size=Vector3.new(2,2,2)
  247. b.CanCollide=false
  248. b.Anchored=true
  249. b.TopSurface="Smooth"
  250. b.Parent=Gourd
  251. b.CFrame=Bo.CFrame*CFrame.Angles(math.rad(math.random(0,360)),math.rad(math.random(0,360)),math.rad(math.random(0,360)))
  252. b.BottomSurface="Smooth"
  253. Delay(0,function()
  254. local p=b
  255. for i=1,5 do
  256. wait(0.05)
  257. p.Transparency=i/5
  258. end
  259. p:remove()
  260. end)
  261. end
  262. pcall(function() Bo:remove() end)
  263. end
  264. function Def(mouse)
  265. local b=Instance.new("Part")
  266. b.BrickColor=Color
  267. b.Reflectance=0
  268. b.Transparency=0.6
  269. b.Size=Vector3.new(15,15,15)
  270. b.Anchored=false
  271. b.Shape="Ball"
  272. b.CanCollide=false
  273. p=Instance.new("BodyPosition")
  274. p.Parent=b
  275. p.maxForce=Vector3.new(math.huge,math.huge,math.huge)
  276. p.position=char.Torso.Position
  277. b.TopSurface="Smooth"
  278. b.Position=char.Torso.Position
  279. b.BottomSurface="Smooth"
  280. b.Touched:connect(function(h)
  281. Hit(h)
  282. end)
  283. b.Parent=Gourd
  284. while Up==false and b.Parent do
  285. b.CFrame=char.Torso.CFrame
  286. p.position=char.Torso.Position
  287. local p=Instance.new("Part")
  288. p.Size=Vector3.new(1,1,1)
  289. p.BrickColor=Color
  290. p.Anchored=true
  291. p.CanCollide=false
  292. p.Parent=Gourd
  293. p.CFrame=char.Torso.CFrame*CFrame.new(math.random(-5,5),math.random(-5,5),math.random(-5,5))*CFrame.Angles(math.random(-360,360),math.random(-360,360),math.random(-360,360))
  294. local m=Instance.new("BlockMesh")
  295. m.Scale=Vector3.new(0.5,0.5,0.5)
  296. m.Parent=p
  297. Delay(0,function()
  298. local p=p
  299. for i=1,5 do
  300. wait(0.05)
  301. p.Transparency=i/5
  302. end
  303. p:remove()
  304. end)
  305. wait()
  306. end
  307. pcall(function() b:remove() end)
  308. end
  309. function Bur(mouse)
  310. if mouse.Target and game.Players:getPlayerFromCharacter(mouse.Target.Parent) then
  311. local m=mouse.Target.Parent
  312. m.Torso.Anchored=true
  313. for i=1,15 do
  314. local p=Instance.new("Part")
  315. p.Size=Vector3.new(i,1,i)
  316. p.BrickColor=Color
  317. p.Anchored=true
  318. p.Transparency=i/14
  319. p.CanCollide=false
  320. p.Parent=m
  321. local me=Instance.new("CylinderMesh")
  322. me.Scale=Vector3.new(1,1.1,1)
  323. me.Parent=p
  324. p.CFrame=CFrame.new(m.Torso.CFrame.x,m.Torso.CFrame.y-3.5,m.Torso.CFrame.z)
  325. end
  326. for i=1,10 do
  327. for i=1,6 do
  328. wait()
  329. local p=Instance.new("Part")
  330. p.Size=Vector3.new(1,1,1)
  331. p.BrickColor=Color
  332. p.Anchored=true
  333. p.CanCollide=false
  334. p.Parent=m
  335. p.CFrame=m.Torso.CFrame*CFrame.new(math.random(-5,5),math.random(-5,5),math.random(-5,5))*CFrame.Angles(math.random(-360,360),math.random(-360,360),math.random(-360,360))
  336. local m=Instance.new("BlockMesh")
  337. m.Scale=Vector3.new(0.25,0.25,0.25)
  338. m.Parent=p
  339. Delay(0,function()
  340. local p=p
  341. for i=1,5 do
  342. wait(0.05)
  343. p.Transparency=i/5
  344. end
  345. p:remove()
  346. end)
  347. end
  348. m.Torso.CFrame=CFrame.new(m.Torso.Position)*CFrame.new(0,-0.5,0)
  349. wait()
  350. end
  351. Hit(m.Torso)
  352. Hit(m.Head)
  353. end
  354. end
  355. function Shift(mouse)
  356. if mouse.Target then
  357. local mo=Instance.new("Model",char)
  358. local h=mouse.Hit.p
  359. local m=char
  360. for i=1,15 do
  361. local p=Instance.new("Part")
  362. p.Size=Vector3.new(i,1,i)
  363. p.BrickColor=Color
  364. p.Anchored=true
  365. p.Transparency=i/14
  366. p.CanCollide=false
  367. p.Parent=mo
  368. local me=Instance.new("CylinderMesh")
  369. me.Scale=Vector3.new(1,1.1,1)
  370. me.Parent=p
  371. p.CFrame=CFrame.new(m.Torso.CFrame.x,m.Torso.CFrame.y-3.5,m.Torso.CFrame.z)
  372. end
  373. for i=1,15 do
  374. local p=Instance.new("Part")
  375. p.Size=Vector3.new(i,1,i)
  376. p.BrickColor=Color
  377. p.Anchored=true
  378. p.Transparency=i/14
  379. p.CanCollide=false
  380. p.Parent=mo
  381. local me=Instance.new("CylinderMesh")
  382. me.Scale=Vector3.new(1,1.1,1)
  383. me.Parent=p
  384. p.CFrame=CFrame.new(h)*CFrame.new(0,-0.5,0)
  385. end
  386. m.Torso.Anchored=true
  387. for i=1,15 do
  388. for i=1,6 do
  389. wait()
  390. local p=Instance.new("Part")
  391. p.Size=Vector3.new(1,1,1)
  392. p.BrickColor=Color
  393. p.Anchored=true
  394. p.CanCollide=false
  395. p.Parent=mo
  396. p.CFrame=m.Torso.CFrame*CFrame.new(math.random(-5,5),math.random(-5,5),math.random(-5,5))*CFrame.Angles(math.random(-360,360),math.random(-360,360),math.random(-360,360))
  397. local m=Instance.new("BlockMesh")
  398. m.Scale=Vector3.new(0.25,0.25,0.25)
  399. m.Parent=p
  400. Delay(0,function()
  401. local p=p
  402. for i=1,5 do
  403. wait(0.05)
  404. p.Transparency=i/5
  405. end
  406. p:remove()
  407. end)
  408. end
  409. m.Torso.CFrame=m.Torso.CFrame*CFrame.new(0,-0.6,0)
  410. wait()
  411. end
  412. m.Torso.CFrame=CFrame.new(h)*CFrame.new(0,-1.5,0)
  413. for i=1,11 do
  414. for i=1,6 do
  415. wait()
  416. local p=Instance.new("Part")
  417. p.Size=Vector3.new(1,1,1)
  418. p.BrickColor=Color
  419. p.Anchored=true
  420. p.CanCollide=false
  421. p.Parent=mo
  422. p.CFrame=m.Torso.CFrame*CFrame.new(math.random(-5,5),math.random(-5,5),math.random(-5,5))*CFrame.Angles(math.random(-360,360),math.random(-360,360),math.random(-360,360))
  423. local m=Instance.new("BlockMesh")
  424. m.Scale=Vector3.new(0.25,0.25,0.25)
  425. m.Parent=p
  426. Delay(0,function()
  427. local p=p
  428. for i=1,5 do
  429. wait(0.05)
  430. p.Transparency=i/5
  431. end
  432. p:remove()
  433. end)
  434. end
  435. m.Torso.CFrame=m.Torso.CFrame*CFrame.new(0,0.5,0)
  436. wait()
  437. end
  438. m.Torso.Anchored=false
  439. mo:remove()
  440. end
  441. end
  442.  
  443. function Wave(mouse)
  444. if mouse.Hit.p.x>char.Torso.Position.x then
  445. Deg=-2
  446. Fre=-60
  447. else
  448. Deg=2
  449. Fre=60
  450. end
  451. local X=char.Torso.CFrame.x
  452. for i=0,Fre,Deg do
  453. wait()
  454. local p=Instance.new("Part")
  455. p.Parent=Gourd
  456. p.Size=Vector3.new(2,1,workspace.Base.Size.z)
  457. p.BrickColor=Color
  458. p.Anchored=true
  459. p.CFrame=CFrame.new(X,0,workspace.Base.Position.z)*CFrame.new(-i,0,0)
  460. local m=Instance.new("BlockMesh")
  461. m.Parent=p
  462. m.Scale=Vector3.new(1,1.2,1.005)
  463. Delay(0,function()
  464. local p=p
  465. local m=m
  466. for i=1,9,0.25 do
  467. m.Scale=m.Scale+Vector3.new(0,.25,0)
  468. wait()
  469. end
  470. wait()
  471. for i=1,9,0.25 do
  472. m.Scale=m.Scale+Vector3.new(0,-.25,0)
  473. wait()
  474. end
  475. p:remove()
  476. end)
  477. for _,v in pairs(game.Players:GetPlayers()) do
  478. if v.Character and v.Character:findFirstChild("Head") then
  479. if v.Character.Head.Position.y<(workspace.Base.Position.y+9.5) then
  480. if v.Character.Torso.Position.x<p.Position.x+p.Size.x/2 and v.Character.Torso.Position.x>p.Position.x-p.Size.x/2 then
  481. Hit(v.Character.Head)
  482. end
  483. end
  484. end
  485. end
  486. end
  487. end
  488. function Spike(mouse)
  489. local Pos=char.Torso.Position
  490. for ii=8,25,3 do
  491. wait()
  492. for i=0,360,360/12 do
  493. local x = (ii) * math.sin(i) + Pos.x
  494. local y = Pos.y-4
  495. local z = (ii)* math.cos (i) + Pos.z
  496. local brick = Instance.new("Part")
  497. brick.Size=Vector3.new(1,1,1)
  498. brick.Anchored=true
  499. brick.BrickColor=Color
  500. brick.Parent=Gourd
  501. brick.CFrame = CFrame.new(x,y,z)
  502. brick.Touched:connect(Hit)
  503. local mesh=Instance.new("CylinderMesh")
  504. mesh.Parent=brick
  505. Delay(0,function()
  506. local p=brick
  507. local m=mesh
  508. for i=1,8 do
  509. m.Scale=m.Scale+Vector3.new(0,.25,0)
  510. p.CFrame=p.CFrame*CFrame.new(0,0.25,0)
  511. wait()
  512. end
  513. for i=1,10 do
  514. p.Transparency=i/10
  515. wait(0.05)
  516. end
  517. p:remove()
  518. end)
  519. end
  520. for _,v in pairs(game.Players:GetPlayers()) do
  521. if v.Character and v.Character:findFirstChild("Torso") and (v.Character.Torso.Position-Pos).magnitude<ii then
  522. Hit(v.Character.Torso)
  523. end
  524. end
  525. wait(0.08)
  526. end
  527. end
  528. function Coffin(mouse)
  529. if mouse.Target and game.Players:getPlayerFromCharacter(mouse.Target.Parent) then
  530. me=mouse.Target.Parent
  531. Delay(0,function()
  532. while me:findFirstChild("Torso") do
  533. wait()
  534. local p=Instance.new("Part")
  535. p.Size=Vector3.new(1,1,1)
  536. p.BrickColor=Color
  537. p.Anchored=true
  538. p.CanCollide=false
  539. p.Parent=me
  540. p.CFrame=me.Torso.CFrame*CFrame.new(math.random(-8,8),math.random(-2,5),math.random(-8,8))*CFrame.Angles(math.random(-360,360),math.random(-360,360),math.random(-360,360))
  541. local m=Instance.new("BlockMesh")
  542. m.Scale=Vector3.new(0.35,0.35,0.35)
  543. m.Parent=p
  544. Delay(0,function()
  545. local p=p
  546. for i=1,5 do
  547. wait(0.05)
  548. p.Transparency=i/5
  549. end
  550. p:remove()
  551. end)
  552. end
  553. end)
  554. BP=Instance.new("BodyPosition")
  555. BP.maxForce=Vector3.new(math.huge,math.huge,math.huge)
  556. BP.position=me.Torso.Position+Vector3.new(0,2,0)
  557. BP.Parent=me.Torso
  558. b=Instance.new("Part")
  559. b.Size=Vector3.new(8,1,8)
  560. b.BottomSurface="Smooth"
  561. b.TopSurface="Smooth"
  562. b.BrickColor=Color
  563. b.CanCollide=false
  564. m=Instance.new("BlockMesh")
  565. m.Parent=b
  566. m.Scale=Vector3.new(1,0.5,1)
  567. b.Parent=me
  568. b:BreakJoints()
  569. w=Instance.new("Weld")
  570. w.Parent=b
  571. w.Part0=me.Torso
  572. w.Part1=b
  573. w.C0=CFrame.new(0,-3.5,0)
  574. for i=1,7,0.25 do
  575. wait(0.075)
  576. m.Scale=m.Scale+Vector3.new(0,0.25,0)
  577. w.C0=w.C0*CFrame.new(0,0.25/2,0)
  578. BP.position=BP.position+Vector3.new(0,.75,0)
  579. end
  580. for i=1,2-(0.5/5),0.25/5 do
  581. m.Scale=m.Scale+Vector3.new(-.25/8,0,-.25/8)
  582. wait(0.05)
  583. end
  584. Hit(me.Head)
  585. Hit(me.Torso)
  586. end
  587. end
  588. function Cage(mouse)
  589. if mouse.Target then
  590. pos=mouse.Hit
  591. for ii=0,360,360/6 do
  592. wait()
  593. for i=0,360/10 do
  594. local p=Instance.new("Part")
  595. p.CFrame=pos*CFrame.new(math.cos(i)*8,math.sin(i)*8*3/i,0)*CFrame.Angles(math.rad(360/ii),math.rad(360/ii),0)
  596. p.Anchored=true
  597. p.BrickColor=Color
  598. p.Parent=Gourd
  599. p.Size=Vector3.new(1,4,4)
  600. Delay(5,function()
  601. p:remove()
  602. end)
  603. end
  604. end
  605. end
  606. end
  607.  
  608. wep={Stream,Def,Bur,Shift,Wave,Spike,Coffin,Cage}
  609. name={"Sand Stream","Manual Defence","Sand Burial","Sand Shift","Sand Tsunami","Sand Spikes","Sand Coffin","Sand Cage"}
  610. function CheckAdd()
  611. if (Mode+1)~=(#wep+1) then
  612. Mode=Mode+1
  613. Hopper.Name=name[Mode].."("..Mode..")"
  614. elseif (Mode+1)==(#wep+1) then
  615. Mode=1
  616. Hopper.Name=name[Mode].."("..Mode..")"
  617. end
  618. end
  619. function CheckSub()
  620. if (Mode-1)==0 or (Mode-1)<0 then
  621. Mode=#wep
  622. Hopper.Name=name[Mode].."("..Mode..")"
  623. elseif (Mode-1)~=0 then
  624. Mode=Mode-1
  625. Hopper.Name=name[Mode].."("..Mode..")"
  626. end
  627. end
  628. function KeyDown(key)
  629. if key=="c" then
  630. CheckAdd()
  631. elseif key=="x" then
  632. Mode=1
  633. Hopper.Name=name[1].."("..Mode..")"
  634. elseif key=="z" then
  635. CheckSub()
  636. end
  637. end
  638. Mode=0
  639. Up=false
  640. Sand=true
  641. Hopper.Selected:connect(function(mouse)
  642. Sand=true
  643. Gourd=char.Gourd
  644. mouse.KeyDown:connect(KeyDown)
  645. mouse.Button1Down:connect(function()
  646. Up=false
  647. coroutine.resume(coroutine.create(function() wep[Mode](mouse) end))
  648. end)
  649. mouse.Button1Up:connect(function() Up=true end)
  650. mouse.Icon = "rbxasset://textures\\GunCursor.png"
  651. Kill=char.Humanoid.Died:connect(function()
  652. wait()
  653. if char:findFirstChild("Head") then
  654. m=char.Head
  655. elseif char:findFirstChild("Torso") then
  656. m=char.Torso
  657. else
  658. return
  659. end
  660. local p=Instance.new("Part")
  661. p.Size=Vector3.new(1,1,1)
  662. p.BrickColor=Color
  663. p.Anchored=true
  664. p.Transparency=1
  665. p.CanCollide=false
  666. p.Parent=char
  667. local me=Instance.new("CylinderMesh")
  668. me.Scale=Vector3.new(1,1.1,1)
  669. me.Parent=p
  670. p.CFrame=CFrame.new(m.CFrame.x,workspace.Base.CFrame.y,m.CFrame.z)
  671. for i=1,100 do
  672. local me=me
  673. local p=p
  674. wait()
  675. me.Scale=me.Scale+Vector3.new(.5,0,.5)
  676. p.Transparency=i/200 --100?
  677. end
  678. for _,v in pairs(game.Players:GetPlayers()) do
  679. if v.Character and v.Name~=Name and (v.Character.Torso.Position-p.Position).magnitude<51 then
  680. pcall(function() Hit(v.Character.Head) end)
  681. end
  682. end
  683. p:remove()
  684. end)
  685. while Sand do
  686. wait(0.05)
  687. local p=Instance.new("Part")
  688. p.Size=Vector3.new(1,1,1)
  689. p.BrickColor=Color
  690. p.Anchored=true
  691. p.CanCollide=false
  692. p.Parent=char
  693. p.CFrame=char.Torso.CFrame*CFrame.new(math.random(-7,7),math.random(-2,5),math.random(-7,7))*CFrame.Angles(math.random(-360,360),math.random(-360,360),math.random(-360,360))
  694. p.Touched:connect(Hit)
  695. local m=Instance.new("BlockMesh")
  696. m.Scale=Vector3.new(0.15,0.15,0.15)
  697. m.Parent=p
  698. Delay(0,function()
  699. local p=p
  700. for i=1,5 do
  701. wait(0.05)
  702. p.Transparency=i/5
  703. end
  704. p:remove()
  705. end)
  706. end
  707. end)
  708. Hopper.Deselected:connect(function()
  709. pcall(function()
  710. Sand=false
  711. Kill:disconnect()
  712. end)
  713. end)
  714. function Hit(p)
  715. if p.Parent.Name~=Name and p.Parent.Parent.Name~=Name and p.Name~="Base" and p.Name~="Sand" and p.Parent then
  716. Delay(0,function()
  717. p.Anchored=true
  718. p.Name="Sand"
  719. p.BrickColor=Color
  720. for i=1,5 do
  721. p.Transparency=i/5
  722. wait(0.1)
  723. end
  724. p:remove()
  725. end)
  726. end
  727. end
Add Comment
Please, Sign In to add comment