Advertisement
nickster91

Untitled

Jul 1st, 2015
226
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 25.38 KB | None | 0 0
  1. --Sword Gifted by TheRedAngel, Regular Script!
  2.  
  3. me = game.Players.gunkillerguner
  4. char = me.Character
  5. selected = false
  6. selanim = false
  7. attacking = false
  8. hurt = false
  9. normaldmg = 25
  10. jumpdmg = 30
  11. jumpdist = 7
  12. flipdist = 7
  13. linedist = 30
  14. splashdmg = 15
  15. linecolors = {"Bright blue", "Light blue", "Medium blue", "Tr. Blue"}
  16. dmg = normaldmg
  17. function getnoobs(pos,dist)
  18. local stoof = {}
  19. for _,v in pairs(workspace:children()) do
  20. local h,t = v:findFirstChild("Humanoid"), v:findFirstChild("Torso")
  21. if h ~= nil and t ~= nil and v:IsA("Model") and v ~= char then
  22. if (t.Position - pos).magnitude < dist then
  23. table.insert(stoof,v)
  24. end
  25. end
  26. end
  27. return stoof
  28. end
  29. function prop(part, parent, collide, tran, ref, x, y, z, color, anchor, form)
  30. part.Parent = parent
  31. part.formFactor = form
  32. part.CanCollide = collide
  33. part.Transparency = tran
  34. part.Reflectance = ref
  35. part.Size = Vector3.new(x,y,z)
  36. part.BrickColor = BrickColor.new(color)
  37. part.TopSurface = 0
  38. part.BottomSurface = 0
  39. part.Anchored = anchor
  40. part.Locked = true
  41. part:BreakJoints()
  42. end
  43. function weld(w, p, p1, a, b, c, x, y, z)
  44. w.Parent = p
  45. w.Part0 = p
  46. w.Part1 = p1
  47. w.C1 = CFrame.fromEulerAnglesXYZ(a,b,c) * CFrame.new(x,y,z)
  48. end
  49. rarm = char:findFirstChild("Right Arm")
  50. larm = char:findFirstChild("Left Arm")
  51. torso = char:findFirstChild("Torso")
  52. hum = char:findFirstChild("Humanoid")
  53. slash = Instance.new("Sound",torso)
  54. slash.Volume = 1
  55. slash.Pitch = 1
  56. slash.SoundId = "rbxasset://sounds\\swordslash.wav"
  57. charge = Instance.new("Sound",torso)
  58. charge.Volume = 1
  59. charge.Pitch = 0.5
  60. charge.SoundId = "http://www.roblox.com/asset/?id=2101137"
  61. brek = Instance.new("Sound",torso)
  62. brek.Volume = 1
  63. brek.Pitch = 0.5
  64. brek.SoundId = "http://www.roblox.com/asset/?id=2974249"
  65. uns = Instance.new("Sound",torso)
  66. uns.Volume = 1
  67. uns.Pitch = 1
  68. uns.SoundId = "rbxasset://sounds\\unsheath.wav"
  69. absc = Instance.new("Sound",torso)
  70. absc.Volume = 1
  71. absc.Pitch = 0.34
  72. absc.SoundId = "http://www.roblox.com/asset/?id=13775494"
  73. jump = Instance.new("Sound",torso)
  74. jump.Volume = 1
  75. jump.Pitch = 2.4
  76. jump.SoundId = "http://www.roblox.com/asset/?id=12222124"
  77. pwns = Instance.new("Sound",torso)
  78. pwns.Volume = 1
  79. pwns.Pitch = 1.6
  80. pwns.SoundId = "http://www.roblox.com/asset/?id=2974000"
  81. bg = Instance.new("BodyGyro",nil)
  82. bg.maxTorque = Vector3.new(math.huge,math.huge,math.huge)
  83. bg.P = 15000
  84. bp = Instance.new("BodyPosition",nil)
  85. bp.maxForce = Vector3.new(math.huge,math.huge,math.huge)
  86. bp.P = 15000
  87. pcall(function() char.Sword:remove() end)
  88. mod = Instance.new("Model",char)
  89. mod.Name = "Sword"
  90. hold = Instance.new("Part")
  91. prop(hold,mod,false,1,0,0.5,0.5,0.5,1,false,"Custom")
  92. hw = Instance.new("Weld")
  93. weld(hw,rarm,hold,0,0,0,0,1,0)
  94. main = Instance.new("Part")
  95. prop(main,mod,false,0,0.04,0.44,1.7,0.44,"Dark grey",false,"Custom")
  96. Instance.new("CylinderMesh",main)
  97. wewe = Instance.new("Weld")
  98. weld(wewe,hold,nil,math.pi/2,0,math.pi/2,0,0,0)
  99. torsohold = Instance.new("Weld")
  100. weld(torsohold,torso,main,0,0,math.rad(36)+math.pi,-1.1,-1.65,-0.8)
  101. sp = Instance.new("Part")
  102. prop(sp,mod,false,0,0,0.6,0.4,0.6,"Navy blue",false,"Custom")
  103. Instance.new("SpecialMesh",sp).MeshType = "Sphere"
  104. w1 = Instance.new("Weld")
  105. weld(w1,main,sp,0,0,0,0,0.8,0)
  106. heh = Instance.new("Part")
  107. prop(heh,mod,false,0,0.12,0.9,0.3,0.5,"Navy blue",false,"Custom")
  108. w2 = Instance.new("Weld")
  109. weld(w2,main,heh,0,0,0,0,-0.9,0)
  110. Instance.new("BlockMesh",heh)
  111. blade = Instance.new("Part")
  112. prop(blade,mod,false,0,0.1,0.65,4,0.15,"Medium grey",false,"Custom")
  113. w3 = Instance.new("Weld")
  114. weld(w3,heh,blade,0,0,0,0,-blade.Size.Y/2,0)
  115. Instance.new("BlockMesh",blade)
  116. tip = Instance.new("Part")
  117. prop(tip,mod,false,0,0.1,0.46,0.46,0.12,"Medium grey",false,"Custom")
  118. w4 = Instance.new("Weld")
  119. weld(w4,blade,tip,0,0,math.pi/4,0,-blade.Size.Y/2,0)
  120. Instance.new("BlockMesh",tip)
  121. lols = {}
  122. touchs = {}
  123. table.insert(lols,blade)
  124. table.insert(lols,tip)
  125. table.insert(touchs,blade)
  126. table.insert(touchs,tip)
  127. for i=blade.Size.Y/2,-blade.Size.Y/2,-0.2 do
  128. local pf = Instance.new("Part")
  129. prop(pf,mod,false,1,0,0.65,0.1,0.15,1,false,"Custom")
  130. local wa = Instance.new("Weld")
  131. weld(wa,blade,pf,0,0,0,0,i,0)
  132. table.insert(touchs,pf)
  133. end
  134. rb = Instance.new("Part")
  135. prop(rb,mod,false,1,0,0.5,0.5,0.5,1,false,"Custom")
  136. rbw = Instance.new("Weld")
  137. weld(rbw,torso,rb,0,0,0,-1.5,-0.5,0)
  138. lb = Instance.new("Part")
  139. prop(lb,mod,false,1,0,0.5,0.5,0.5,1,false,"Custom")
  140. lbw = Instance.new("Weld")
  141. weld(lbw,torso,lb,0,0,0,1.5,-0.5,0)
  142. rw = Instance.new("Weld")
  143. weld(rw,rb,nil,0,0,0,0,0.5,0)
  144. lw = Instance.new("Weld")
  145. weld(lw,lb,nil,0,0,0,0,0.5,0)
  146. function showdmg(d)
  147. local pa = Instance.new("Part")
  148. prop(pa,mod,false,1,0,1,1,1,1,true,"Symmetric")
  149. pa.CFrame = CFrame.new(blade.Position)
  150. local bill = Instance.new("BillboardGui",pa)
  151. bill.Size = UDim2.new(0,50,0,35)
  152. bill.Adornee = pa
  153. local tx = Instance.new("TextLabel",bill)
  154. tx.Size = bill.Size
  155. tx.Position = UDim2.new(0,0,0,-30)
  156. tx.BackgroundTransparency = 1
  157. tx.Text = d
  158. tx.FontSize = "Size24"
  159. tx.TextColor3 = Color3.new(0,0,0)
  160. local poz = pa.Position
  161. for i=0,7,0.4 do
  162. wait()
  163. pa.CFrame = CFrame.new(poz.X, poz.Y+i, poz.Z)
  164. end
  165. pa:remove()
  166. end
  167. deb = true
  168. function kill(h)
  169. if hurt and deb then
  170. local hu, to = h.Parent:findFirstChild("Humanoid"), h.Parent:findFirstChild("Torso")
  171. if hu ~= nil and to ~= nil and h.Parent ~= char then
  172. if hu.Health > 0 then
  173. deb = false
  174. local damg = math.random(dmg/4,dmg)
  175. local chance = math.random(1,5)
  176. if chance > 2 then
  177. hu.PlatformStand = true
  178. coroutine.resume(coroutine.create(function()
  179. wait()
  180. to.Velocity = CFrame.new(torso.Position, to.Position).lookVector * damg*2
  181. wait(0.1)
  182. hu.PlatformStand = false
  183. end))
  184. else
  185. damg = 0
  186. end
  187. hu.Health = hu.Health - damg
  188. coroutine.resume(coroutine.create(function()
  189. showdmg(damg)
  190. end))
  191. wait(0.25)
  192. deb = true
  193. end
  194. end
  195. end
  196. end
  197. for _,v in pairs(touchs) do
  198. v.Touched:connect(kill)
  199. end
  200. if script.Parent.className ~= "HopperBin" then
  201. h = Instance.new("HopperBin",me.Backpack)
  202. h.Name = "Sword"
  203. script.Parent = h
  204. end
  205. bin = script.Parent
  206. local mw = nil
  207. local meow = nil
  208. local tsah = nil
  209. battleright = nil
  210. battleleft = nil
  211. battlewep = nil
  212. function eff()
  213. for _,v in pairs(lols) do
  214. local ah = v:clone()
  215. ah.Parent = mod
  216. ah.Anchored = true
  217. ah.CFrame = v.CFrame
  218. ah.Transparency = 0.3
  219. ah.Reflectance = 0.3
  220. coroutine.resume(coroutine.create(function()
  221. wait(0.15)
  222. for i=0.3,1,0.12 do
  223. ah.Transparency = i
  224. wait()
  225. end
  226. ah:remove()
  227. end))
  228. end
  229. end
  230. function eff2()
  231. local pa = Instance.new("Part")
  232. prop(pa,mod,false,0.1,0,1,1,1,"Institutional white",true,"Custom")
  233. pa.CFrame = CFrame.new(torso.Position) * CFrame.new(0,-2.9,0) * CFrame.Angles(0,math.random(-320,320)/100,0)
  234. local md = Instance.new("SpecialMesh",pa)
  235. md.Scale = Vector3.new(5.5,4,5.5)
  236. md.MeshId = "http://www.roblox.com/asset/?id=20329976"
  237. coroutine.resume(coroutine.create(function()
  238. for i=5.5,0,-0.6 do
  239. md.Scale = Vector3.new(i,i/1.4,i)
  240. pa.Transparency = pa.Transparency + 0.1
  241. wait()
  242. end
  243. pa:remove()
  244. end))
  245. end
  246. function selmot()
  247. rw.Part1 = rarm
  248. for i=0,140,14 do
  249. rw.C0 = CFrame.Angles(-math.rad(i/1.1),math.rad(i/2.5),math.rad(-i/6))
  250. wait()
  251. end
  252. lo = rw.C0
  253. meow = lo
  254. torsohold.Part1 = nil
  255. wewe.Part1 = main
  256. uns:play()
  257. for i=0,140,17 do
  258. rw.C0 = lo * CFrame.Angles(math.rad(-i),0,0)
  259. wewe.C0 = CFrame.Angles(math.rad(-i/2),0,0)
  260. wait()
  261. end
  262. lo = rw.C0
  263. mw = lo
  264. local hih = wewe.C0
  265. tsah = hih
  266. lw.Part1 = larm
  267. wait()
  268. for i=0,130,17 do
  269. rw.C0 = lo * CFrame.Angles(math.rad(i/4),math.rad(i/4),math.rad(-i/1.8)) * CFrame.new(-i/220,-i/500,0)
  270. lw.C0 = CFrame.new(i/130,-i/600,-i/160) * CFrame.Angles(math.rad(i/1.4),0,math.rad(i/2.6))
  271. wewe.C0 = hih * CFrame.Angles(math.rad(i/1.8),0,0)
  272. wait()
  273. end
  274. if battleright == nil then
  275. battleright = rw.C0
  276. battleleft = lw.C0
  277. battlewep = wewe.C0
  278. end
  279. selected = true
  280. end
  281. function deselmot()
  282. for i=130,0,-17 do
  283. rw.C0 = mw * CFrame.Angles(math.rad(i/4),math.rad(i/4),math.rad(-i/1.8)) * CFrame.new(-i/220,-i/500,0)
  284. lw.C0 = CFrame.new(i/130,-i/600,-i/160) * CFrame.Angles(math.rad(i/1.4),0,math.rad(i/2.6))
  285. wewe.C0 = tsah * CFrame.Angles(math.rad(i/1.8),0,0)
  286. wait()
  287. end
  288. lw.Part1 = nil
  289. for i=140,0,-17 do
  290. rw.C0 = meow * CFrame.Angles(math.rad(-i),0,0)
  291. wewe.C0 = CFrame.Angles(math.rad(-i/2),0,0)
  292. wait()
  293. end
  294. wewe.Part1 = nil
  295. torsohold.Part1 = main
  296. for i=140,0,-14 do
  297. rw.C0 = CFrame.Angles(-math.rad(i/1.1),math.rad(i/2.5),math.rad(-i/6))
  298. wait()
  299. end
  300. rw.Part1 = nil
  301. rw.C0 = CFrame.new(0,0,0)
  302. lw.C0 = CFrame.new(0,0,0)
  303. selected = false
  304. end
  305. function attack()
  306. if attacking == false then
  307. attacking = true
  308. slash.Pitch = 1
  309. slash:play()
  310. for i=0,100,18 do
  311. rw.C0 = battleright * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i/1.5),0,0)
  312. lw.C0 = battleleft * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i/1.5),0,0)
  313. wait()
  314. end
  315. local lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  316. hurt = true
  317. for i=0,120,20 do
  318. rw.C0 = lo * CFrame.new(0,0,0) * CFrame.Angles(math.rad(-i),0,0)
  319. lw.C0 = lo2 * CFrame.new(0,0,0) * CFrame.Angles(math.rad(-i/1.4),0,0)
  320. wewe.C0 = lo3 * CFrame.Angles(math.rad(-i/2.8),0,0)
  321. eff()
  322. wait()
  323. end
  324. hurt = false
  325. lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  326. for i=0,70,15 do
  327. rw.C0 = lo * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i/1.2),0,0)
  328. lw.C0 = lo2 * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i/1.9),0,0)
  329. wewe.C0 = lo3 * CFrame.Angles(math.rad(i/2),0,0)
  330. wait()
  331. end
  332. rw.C0 = battleright
  333. lw.C0 = battleleft
  334. wewe.C0 = battlewep
  335. attacking = false
  336. end
  337. end
  338. function stab()
  339. if attacking == false then
  340. attacking = true
  341. for i=0,100,15 do
  342. rw.C0 = battleright * CFrame.new(0,0,0) * CFrame.Angles(math.rad(-i/1.1),math.rad(-i/7),math.rad(-i/2.6))
  343. lw.C0 = battleleft * CFrame.new(0,0,0) * CFrame.Angles(math.rad(-i/1.1),0,0)
  344. wewe.C0 = battlewep * CFrame.Angles(math.rad(i/2.2),0,0)
  345. wait()
  346. end
  347. local lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  348. hurt = true
  349. slash.Pitch = 1.1
  350. slash:play()
  351. for i=0,100,18 do
  352. rw.C0 = lo * CFrame.new(-i/150,0,-i/150) * CFrame.Angles(math.rad(i/1.4),0,0)
  353. lw.C0 = lo2 * CFrame.new(-i/240,0,i/400) * CFrame.Angles(math.rad(i/1.4),0,0)
  354. wewe.C0 = lo3 * CFrame.Angles(math.rad(-i*1.3),0,0)
  355. eff()
  356. wait()
  357. end
  358. hurt = false
  359. lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  360. for i=0,90,12 do
  361. rw.C0 = lo * CFrame.new(i/150,i/170,i/240) * CFrame.Angles(math.rad(i/5.4),math.rad(i/2.3),0)
  362. lw.C0 = lo2 * CFrame.new(i/240,-i/280,0) * CFrame.Angles(math.rad(i/4),0,0)
  363. wewe.C0 = lo3 * CFrame.Angles(math.rad(i/1.2),0,0)
  364. wait()
  365. end
  366. rw.C0 = battleright
  367. lw.C0 = battleleft
  368. wewe.C0 = battlewep
  369. attacking = false
  370. end
  371. end
  372. function spin()
  373. if attacking == false then
  374. attacking = true
  375. for i=0,90,10 do
  376. rw.C0 = battleright * CFrame.new(i/140,0,0) * CFrame.Angles(math.rad(-i/4),0,math.rad(i))
  377. lw.C0 = battleleft * CFrame.new(0,i/90,0) * CFrame.Angles(0,0,math.rad(-i*1.5))
  378. wewe.C0 = battlewep * CFrame.Angles(math.rad(-i),0,math.rad(-i))
  379. wait()
  380. end
  381. local lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  382. bp.position = torso.Position
  383. bp.Parent = torso
  384. bg.Parent = torso
  385. local cf = torso.CFrame
  386. local ef = Instance.new("Part")
  387. prop(ef,mod,false,1,0,1,1,1,"Light blue",true,"Custom")
  388. ef.CFrame = cf
  389. local mc = Instance.new("SpecialMesh",ef)
  390. mc.MeshType = "Sphere"
  391. local spin = true
  392. charge:play()
  393. coroutine.resume(coroutine.create(function()
  394. while spin do
  395. local d = Instance.new("Part")
  396. prop(d,mod,false,1,0,1,1,1,"Medium blue",true,"Custom")
  397. local poa = cf * CFrame.new(0,-2.3,0)
  398. d.CFrame = poa
  399. local r = Instance.new("SpecialMesh",d)
  400. r.MeshId = "http://www.roblox.com/asset/?id=3270017"
  401. r.Scale = Vector3.new(1,1,1)
  402. coroutine.resume(coroutine.create(function()
  403. for i=3,20,1 do
  404. wait()
  405. r.Scale = Vector3.new(i,i,i/3)
  406. d.CFrame = poa * CFrame.new(0,i/4,0) * CFrame.Angles(math.pi/2,0,0)
  407. d.Transparency = (i/14)-0.5
  408. end
  409. d:remove()
  410. end))
  411. wait(0.4)
  412. end
  413. end))
  414. coroutine.resume(coroutine.create(function()
  415. for o=1,14,0.25 do
  416. wait()
  417. mc.Scale = Vector3.new(o/1.18,o,o/1.18)
  418. ef.Transparency = ef.Transparency - 0.014
  419. ef.CFrame = cf * CFrame.Angles(0,o,0)
  420. end
  421. wait(0.15)
  422. for o=12,0,-1.2 do
  423. wait()
  424. mc.Scale = Vector3.new(o/1.1,o,o/1.1)
  425. end
  426. local e = Instance.new("Part")
  427. prop(e,mod,false,0,0.05,1,1,1,"Medium blue",true,"Custom")
  428. e.CFrame = cf
  429. local ha = Instance.new("SpecialMesh",e)
  430. ha.Scale = Vector3.new(1,1,1)
  431. ha.MeshId = "http://www.roblox.com/asset/?id=20329976"
  432. local nubs = getnoobs(cf.p,10)
  433. brek:play()
  434. for _,v in pairs(nubs) do
  435. v.Humanoid.Health = v.Humanoid.Health - math.random(40,60)
  436. v.Humanoid.PlatformStand = true
  437. coroutine.resume(coroutine.create(function()
  438. wait(0.06)
  439. v.Torso.Velocity = CFrame.new(torso.Position, v.Torso.Position).lookVector * 70
  440. v.Torso.RotVelocity = Vector3.new(math.random(-25,25),math.random(-25,25),math.random(-25,25))
  441. wait(0.6)
  442. v.Humanoid.PlatformStand = false
  443. end))
  444. end
  445. for o=1,18,0.95 do
  446. ha.Scale = Vector3.new(o,o/1.4,o)
  447. e.Transparency = o/15
  448. e.CFrame = cf * CFrame.Angles(0,o/3,0)
  449. ef.Transparency = o/17
  450. mc.Scale = Vector3.new(o*1.2,o/1.4,o*1.2)
  451. wait()
  452. end
  453. spin = false
  454. ef:remove()
  455. e:remove()
  456. end))
  457. local i = 0
  458. repeat
  459. local hj = cf * CFrame.Angles(0,math.rad(i),0) * CFrame.new(0,0,-30)
  460. bg.cframe = CFrame.new(cf.p,hj.p)
  461. i = i + 40
  462. wait()
  463. until spin == false
  464. for i=90,0,-10 do
  465. rw.C0 = battleright * CFrame.new(i/140,0,0) * CFrame.Angles(math.rad(-i/4),0,math.rad(i))
  466. lw.C0 = battleleft * CFrame.new(0,i/90,0) * CFrame.Angles(0,0,math.rad(-i*1.5))
  467. wewe.C0 = battlewep * CFrame.Angles(math.rad(-i),0,math.rad(-i))
  468. wait()
  469. end
  470. bg.Parent = nil
  471. bp.Parent = nil
  472. wait()
  473. rw.C0 = battleright
  474. lw.C0 = battleleft
  475. wewe.C0 = battlewep
  476. attacking = false
  477. end
  478. end
  479. function stoof()
  480. if attacking == false then
  481. attacking = true
  482. bg.cframe = CFrame.new(torso.Position, torso.CFrame * CFrame.new(0,0,-20).p)
  483. bg.Parent = torso
  484. bp.position = torso.Position
  485. bp.Parent = torso
  486. local norm = torso.CFrame
  487. local center = norm * CFrame.new(0,0,-jumpdist)
  488. for i=0,60,15 do
  489. rw.C0 = battleright * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),0,0)
  490. lw.C0 = battleleft * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),0,0)
  491. wewe.C0 = battlewep * CFrame.Angles(0,0,0)
  492. wait()
  493. end
  494. slash.Pitch = 1.7
  495. slash:play()
  496. local lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  497. for i=180,0,-16 do
  498. bp.position = center * CFrame.Angles(math.rad(i),0,0) * CFrame.new(0,0,-jumpdist).p
  499. wait()
  500. end
  501. hurt = true
  502. dmg = jumpdmg
  503. slash.Pitch = 1
  504. slash:play()
  505. for i=0,150,24 do
  506. rw.C0 = lo * CFrame.new(0,0,0) * CFrame.Angles(math.rad(-i/1.1),0,0)
  507. lw.C0 = lo2 * CFrame.new(0,0,0) * CFrame.Angles(math.rad(-i/1.2),0,0)
  508. wewe.C0 = lo3 * CFrame.Angles(math.rad(-i/2.5),0,0)
  509. eff()
  510. wait()
  511. end
  512. lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  513. slash.Pitch = 1.8
  514. slash:play()
  515. hurt = false
  516. dmg = normaldmg
  517. bp.position = norm.p
  518. for i=0,150,24 do
  519. rw.C0 = lo * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i/1.75),0,0)
  520. lw.C0 = lo2 * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i/1.9),0,0)
  521. wewe.C0 = lo3 * CFrame.Angles(math.rad(i/2.5),0,0)
  522. eff()
  523. wait()
  524. end
  525. rw.C0 = battleright
  526. lw.C0 = battleleft
  527. wewe.C0 = battlewep
  528. wait(0.15)
  529. bp.Parent = nil
  530. bg.Parent = nil
  531. wait(0.1)
  532. attacking = false
  533. end
  534. end
  535. function flip()
  536. if attacking == false then
  537. attacking = true
  538. local c = CFrame.new(torso.Position, torso.CFrame * CFrame.new(0,0,-20).p)
  539. bg.cframe = c
  540. bg.Parent = torso
  541. bp.position = torso.Position
  542. bp.Parent = torso
  543. local norm = torso.CFrame
  544. local center = norm * CFrame.new(0,0,-flipdist)
  545. for i=0,60,15 do
  546. rw.C0 = battleright * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),0,0)
  547. lw.C0 = battleleft * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),0,0)
  548. wewe.C0 = battlewep * CFrame.Angles(0,0,0)
  549. wait()
  550. end
  551. local lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  552. hum.PlatformStand = true
  553. hurt = true
  554. jump:play()
  555. for i=180,0,-10 do
  556. bp.position = center * CFrame.Angles(math.rad(i),0,0) * CFrame.new(0,0,-flipdist).p
  557. bg.cframe = c * CFrame.Angles(math.rad(i*2),0,0)
  558. eff()
  559. wait()
  560. end
  561. hum.PlatformStand = false
  562. for i=0,120,20 do
  563. rw.C0 = lo * CFrame.new(0,0,0) * CFrame.Angles(math.rad(-i/1.1),0,0)
  564. lw.C0 = lo2 * CFrame.new(0,0,0) * CFrame.Angles(math.rad(-i/1.5),0,0)
  565. wewe.C0 = lo3 * CFrame.Angles(math.rad(-i/1.6),0,0)
  566. eff()
  567. wait()
  568. end
  569. lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  570. local po = torso.CFrame * CFrame.new(0,-5,0)
  571. local now = 4
  572. dmg = normaldmg*2
  573. absc:play()
  574. coroutine.resume(coroutine.create(function()
  575. repeat
  576. local pa = Instance.new("Part")
  577. prop(pa,mod,false,0.2,0,2,4,2,linecolors[math.random(1,#linecolors)],true,"Custom")
  578. pa.CFrame = po * CFrame.new(math.random(-40,40)/10,0,-now) * CFrame.Angles(math.random(-60,60)/100,math.random(-60,60)/100,math.random(-60,60)/100)
  579. local m = Instance.new("SpecialMesh",pa)
  580. m.MeshType = "Sphere"
  581. m.Scale = Vector3.new(3.5,3,3.5)
  582. local pk = pa.CFrame
  583. local nubs = getnoobs(pa.Position, 5)
  584. for _,v in pairs(nubs) do
  585. v.Humanoid.PlatformStand = true
  586. v.Humanoid.Health = v.Humanoid.Health - math.random(dmg/3,dmg)
  587. v.Torso.Velocity = CFrame.new(pa.Position, v.Torso.Position).lookVector * 60
  588. v.Torso.RotVelocity = Vector3.new(math.random(-30,30),math.random(-30,30),math.random(-30,30))
  589. coroutine.resume(coroutine.create(function()
  590. wait(0.2)
  591. v.Humanoid.PlatformStand = false
  592. end))
  593. end
  594. coroutine.resume(coroutine.create(function()
  595. for i=0,12,1.5 do
  596. wait()
  597. pa.CFrame = pk * CFrame.new(0,i,0)
  598. pa.Transparency = i/10
  599. end
  600. pa:remove()
  601. end))
  602. now = now + 4
  603. wait(0.1)
  604. until now >= linedist
  605. end))
  606. dmg = normaldmg
  607. hurt = false
  608. for i=0,70,15 do
  609. rw.C0 = lo * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i/1.2),0,0)
  610. lw.C0 = lo2 * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i/2.7),0,0)
  611. wewe.C0 = lo3 * CFrame.Angles(math.rad(i*1.25),0,0)
  612. wait()
  613. end
  614. wait(0.1)
  615. rw.C0 = battleright
  616. lw.C0 = battleleft
  617. wewe.C0 = battlewep
  618. wait(0.2)
  619. bp.Parent = nil
  620. bg.Parent = nil
  621. wait(0.15)
  622. attacking = false
  623. end
  624. end
  625. function pwn()
  626. if attacking == false then
  627. attacking = true
  628. local c = CFrame.new(torso.Position, torso.CFrame * CFrame.new(0,0,-20).p)
  629. bg.cframe = c
  630. bg.Parent = torso
  631. bp.position = torso.Position
  632. bp.Parent = torso
  633. local norm = torso.CFrame
  634. dmg = normaldmg/1.3
  635. for i=0,60,20 do
  636. rw.C0 = battleright * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),0,0)
  637. lw.C0 = battleleft * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),0,0)
  638. wewe.C0 = battlewep * CFrame.Angles(0,0,0)
  639. wait()
  640. end
  641. local lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  642. wait(0.3)
  643. pwns:play()
  644. local poz = norm * CFrame.new(0,0,-18).p
  645. local pa = Instance.new("Part")
  646. prop(pa,mod,false,0.1,0.03,0.9,0.9,(norm.p - torso.Position).magnitude,"Black",true,"Custom")
  647. pa.CFrame = CFrame.new(norm.p, poz) * CFrame.new(0,0,-(norm.p - poz).magnitude/2)
  648. coroutine.resume(coroutine.create(function()
  649. coroutine.resume(coroutine.create(function()
  650. for i=1,20 do
  651. wait()
  652. pa.Size = Vector3.new(0.9,0.9,(norm.p - torso.Position).magnitude)
  653. pa.CFrame = CFrame.new(norm.p, torso.Position) * CFrame.new(0,0,-(norm.p - torso.Position).magnitude/2)
  654. end
  655. end))
  656. wait(0.25)
  657. for i=0.1,1,0.15 do
  658. pa.Transparency = i
  659. wait()
  660. end
  661. pa:remove()
  662. end))
  663. hum.PlatformStand = true
  664. hurt = true
  665. bp.position = poz
  666. for i=60,-80,-40 do
  667. rw.C0 = battleright * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),0,0)
  668. lw.C0 = battleleft * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i/2),0,0)
  669. wewe.C0 = battlewep * CFrame.Angles(0,0,0)
  670. eff2()
  671. wait()
  672. end
  673. wait(0.1)
  674. hurt = false
  675. hum.PlatformStand = false
  676. for i = -80,0,20 do
  677. rw.C0 = battleright * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),0,0)
  678. lw.C0 = battleleft * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i/2),0,0)
  679. wewe.C0 = battlewep * CFrame.Angles(0,0,0)
  680. wait()
  681. end
  682. rw.C0 = battleright
  683. lw.C0 = battleleft
  684. wewe.C0 = battlewep
  685. dmg = normaldmg
  686. wait(0.2)
  687. bp.Parent = nil
  688. bg.Parent = nil
  689. wait(0.15)
  690. attacking = false
  691. end
  692. end
  693. function spinattack()
  694. if attacking == false then
  695. attacking = true
  696. coroutine.resume(coroutine.create(function()
  697. bp.position = torso.Position
  698. bp.Parent = torso
  699. bg.Parent = torso
  700. for i=0,90,10 do
  701. rw.C0 = battleright * CFrame.new(i/140,0,0) * CFrame.Angles(math.rad(-i/4),0,math.rad(i))
  702. lw.C0 = battleleft * CFrame.new(0,i/90,0) * CFrame.Angles(0,0,math.rad(-i*1.5))
  703. wewe.C0 = battlewep * CFrame.Angles(math.rad(-i),0,math.rad(-i))
  704. wait()
  705. end
  706. end))
  707. local cf = torso.CFrame
  708. local spin = true
  709. charge:play()
  710. coroutine.resume(coroutine.create(function()
  711. while spin do
  712. local d = Instance.new("Part")
  713. prop(d,mod,false,1,0,1,1,1,"Medium blue",true,"Custom")
  714. local poa = cf
  715. d.CFrame = poa
  716. local r = Instance.new("SpecialMesh",d)
  717. r.MeshId = "http://www.roblox.com/asset/?id=3270017"
  718. r.Scale = Vector3.new(1,1,1)
  719. coroutine.resume(coroutine.create(function()
  720. for i=3,20,1 do
  721. wait()
  722. r.Scale = Vector3.new(i,i,i/3)
  723. d.CFrame = poa * CFrame.new(0,i/10,0) * CFrame.Angles(math.pi/2,0,0)
  724. d.Transparency = (i/14)-0.5
  725. end
  726. d:remove()
  727. end))
  728. wait(0.4)
  729. end
  730. end))
  731. hurt = true
  732. for i=0,360*5, 40 do
  733. local hj = cf * CFrame.Angles(0,math.rad(i),0) * CFrame.new(0,0,-30)
  734. bg.cframe = CFrame.new(cf.p,hj.p)
  735. wait()
  736. end
  737. hurt = false
  738. spin = false
  739. for i=90,0,-10 do
  740. rw.C0 = battleright * CFrame.new(i/140,0,0) * CFrame.Angles(math.rad(-i/4),0,math.rad(i))
  741. lw.C0 = battleleft * CFrame.new(0,i/90,0) * CFrame.Angles(0,0,math.rad(-i*1.5))
  742. wewe.C0 = battlewep * CFrame.Angles(math.rad(-i),0,math.rad(-i))
  743. wait()
  744. end
  745. bg.Parent = nil
  746. bp.Parent = nil
  747. wait()
  748. rw.C0 = battleright
  749. lw.C0 = battleleft
  750. wewe.C0 = battlewep
  751. attacking = false
  752. end
  753. end
  754. function side()
  755. if attacking == false then
  756. attacking = true
  757. for i=0,90,9 do
  758. rw.C0 = battleright * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),math.rad(-i),math.rad(i))
  759. lw.C0 = battleleft * CFrame.new(i/270,i/230,0) * CFrame.Angles(0,0,math.rad(i/2.1))
  760. wewe.C0 = battlewep * CFrame.Angles(math.rad(-i/3),0,0)
  761. wait()
  762. end
  763. local lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  764. hurt = true
  765. slash.Pitch = 1.2
  766. slash:play()
  767. for i=0,90,10 do
  768. rw.C0 = lo * CFrame.new(0,0,0) * CFrame.Angles(math.rad(-i/1.5),0,0)
  769. lw.C0 = lo2 * CFrame.new(0,i/230,0) * CFrame.Angles(0,0,math.rad(-i*1.2))
  770. wewe.C0 = lo3 * CFrame.Angles(math.rad(-i/1.8),0,0)
  771. eff()
  772. wait()
  773. end
  774. lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  775. hurt = false
  776. for i=0,90,10 do
  777. rw.C0 = lo * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i/1.5),math.rad(i/1),0)
  778. lw.C0 = lo2 * CFrame.new(math.rad(i/2),math.rad(-i/6.5),0) * CFrame.Angles(0,0,math.rad(i/1.3))
  779. wewe.C0 = lo3 * CFrame.Angles(math.rad(i/1.1),0,0)
  780. wait()
  781. end
  782. rw.C0 = battleright
  783. lw.C0 = battleleft
  784. wewe.C0 = battlewep
  785. attacking = false
  786. end
  787. end
  788. function pow()
  789. if attacking == false then
  790. attacking = true
  791. for i=0,90,15 do
  792. rw.C0 = battleright * CFrame.new(i/140,0,0) * CFrame.Angles(math.rad(-i/4),0,math.rad(i))
  793. lw.C0 = battleleft * CFrame.new(0,i/90,0) * CFrame.Angles(0,0,math.rad(-i*1.5))
  794. wewe.C0 = battlewep * CFrame.Angles(math.rad(-i),0,math.rad(-i))
  795. wait()
  796. end
  797. local lo, lo2, lo3 = rw.C0, lw.C0, wewe.C0
  798. local poz = CFrame.new(torso.Position)
  799. bp.position = poz.p
  800. bp.Parent = torso
  801. bg.cframe = CFrame.new(torso.Position, torso.CFrame * CFrame.new(0,0,-10).p)
  802. bg.Parent = torso
  803. coroutine.resume(coroutine.create(function()
  804. local ma = Instance.new("Part")
  805. prop(ma,mod,false,0,0,1,1,1,"White",true,"Custom")
  806. ma.CFrame = poz * CFrame.new(0,45,0)
  807. local mam = Instance.new("CylinderMesh",ma)
  808. mam.Scale = Vector3.new(3,1,3)
  809. for i=1,50,5 do
  810. mam.Scale = Vector3.new(i/9,i*1.3,i/9)
  811. ma.CFrame = poz * CFrame.new(0,-mam.Scale.Y/2+45,0)
  812. wait()
  813. end
  814. brek:play()
  815. local p = Instance.new("Part")
  816. prop(p,mod,false,0,0,1,1,1,"White",true,"Custom")
  817. p.CFrame = poz
  818. local a = Instance.new("SpecialMesh",p)
  819. a.MeshId = "http://www.roblox.com/asset/?id=20329976"
  820. a.Scale = Vector3.new(2,2,2)
  821. local p2 = p:clone()
  822. p2.Parent = mod
  823. local nubs = getnoobs(poz.p,7)
  824. for _,v in pairs(nubs) do
  825. v.Humanoid.PlatformStand = true
  826. v.Humanoid.Health = v.Humanoid.Health - math.random(splashdmg/2, splashdmg)
  827. v.Torso.Velocity = CFrame.new(poz.p,v.Torso.Position).lookVector * 25
  828. v.Torso.RotVelocity = Vector3.new(math.random(-20,20),math.random(-20,20),math.random(-20,20))
  829. coroutine.resume(coroutine.create(function() wait(0.6) v.Humanoid.PlatformStand = false end))
  830. end
  831. for i=2,12,0.8 do
  832. wait()
  833. p.CFrame = poz * CFrame.Angles(0,math.rad(i*10),0)
  834. a.Scale = Vector3.new(i,i/1.25,i)
  835. p.Transparency = (i/10)-0.2
  836. p2.Transparency = p.Transparency
  837. p2.Mesh.Scale = Vector3.new(i/1.6,i/2.2,i/1.6)
  838. p2.CFrame = poz * CFrame.Angles(0,math.rad(-i*10),0)
  839. ma.Transparency = (i/10)-0.2
  840. end
  841. p:remove()
  842. p2:remove()
  843. ma:remove()
  844. end))
  845. for i=0,60,20 do
  846. rw.C0 = lo * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),0,0)
  847. lw.C0 = lo2 * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),0,0)
  848. wait()
  849. end
  850. wait(0.8)
  851. bg.Parent = nil
  852. bp.Parent = nil
  853. for i=60,0,-20 do
  854. rw.C0 = lo * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),0,0)
  855. lw.C0 = lo2 * CFrame.new(0,0,0) * CFrame.Angles(math.rad(i),0,0)
  856. wait()
  857. end
  858. for i=90,0,-15 do
  859. rw.C0 = battleright * CFrame.new(i/140,0,0) * CFrame.Angles(math.rad(-i/4),0,math.rad(i))
  860. lw.C0 = battleleft * CFrame.new(0,i/90,0) * CFrame.Angles(0,0,math.rad(-i*1.5))
  861. wewe.C0 = battlewep * CFrame.Angles(math.rad(-i),0,math.rad(-i))
  862. wait()
  863. end
  864. rw.C0 = battleright
  865. lw.C0 = battleleft
  866. wewe.C0 = battlewep
  867. wait(0.4)
  868. attacking = false
  869. end
  870. end
  871. function keys(k)
  872. if hum.Health > 0 and bin.Parent ~= nil and selected then
  873. local key = k:lower()
  874. if key == "q" then
  875. stab()
  876. elseif key == "r" then
  877. spin()
  878. elseif key == "e" then
  879. stoof()
  880. elseif key == "f" then
  881. flip()
  882. elseif key == "t" then
  883. pwn()
  884. elseif key == "z" then
  885. spinattack()
  886. elseif key == "x" then
  887. pow()
  888. elseif key == "g" then
  889. side()
  890. end
  891. end
  892. end
  893. function select(mouse)
  894. if bin.Parent ~= nil then
  895. repeat wait() until selected == false and attacking == false
  896. selmot()
  897. mouse.Button1Down:connect(function()
  898. if hum.Health > 0 and bin.Parent ~= nil then
  899. attack()
  900. end
  901. end)
  902. mouse.KeyDown:connect(function(key) keys(key) end)
  903. end
  904. end
  905. function desel()
  906. repeat wait() until selected == true and attacking == false
  907. deselmot()
  908. end
  909. bin.Selected:connect(select)
  910. bin.Deselected:connect(desel)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement