dragopatiot

Frost Sword

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