Advertisement
izaquecosta

my knife

May 26th, 2018
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 62.12 KB | None | 0 0
  1.  
  2. ----edited by izaquecosta, Original creator:idk
  3.  
  4. wait(0.016666666666667)
  5. Anim = nil
  6. cf = CFrame.new
  7. function c3(cz, cx, cc)
  8. return Color3.new(cz / 255, cx / 255, cc / 255)
  9. end
  10. angles = CFrame.Angles
  11. Player = game.Players.LocalPlayer
  12. Character = Player.Character
  13. Humanoid = Character.Humanoid
  14. mouse = Player:GetMouse()
  15. local LeftArm = Character["Left Arm"]
  16. RightArm = Character["Right Arm"]
  17. LeftLeg = Character["Left Leg"]
  18. RightLeg = Character["Right Leg"]
  19. Head = Character.Head
  20. Torso = Character.Torso
  21. RootPart = Character.HumanoidRootPart
  22. RootJoint = RootPart.RootJoint
  23. Humanoid.Animator:Destroy()
  24. Character:WaitForChild("Animate"):Destroy()
  25. NeckCF = cf(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0)
  26. RootCF = angles(-1.57, 0, 3.14)
  27. LHC0 = cf(-1, -1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  28. LHC1 = cf(-0.5, 1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  29. RHC0 = cf(1, -1, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  30. RHC1 = cf(0.5, 1, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  31. RW = Instance.new("Weld")
  32. LW = Instance.new("Weld")
  33. RH = Torso["Right Hip"]
  34. LH = Torso["Left Hip"]
  35. Neck = Torso.Neck
  36. RSH = Torso["Right Shoulder"]
  37. LSH = Torso["Left Shoulder"]
  38. RSH.Parent = nil
  39. LSH.Parent = nil
  40. RW.Name = "Right Shoulder"
  41. RW.Part0 = Torso
  42. RW.C0 = cf(1.5, 0.5, 0)
  43. RW.C1 = cf(0, 0.5, 0)
  44. RW.Part1 = RightArm
  45. RW.Parent = Torso
  46. LW.Name = "Left Shoulder"
  47. LW.Part0 = Torso
  48. LW.C0 = cf(-1.5, 0.5, 0)
  49. LW.C1 = cf(0, 0.5, 0)
  50. LW.Part1 = LeftArm
  51. LW.Parent = Torso
  52. Effects = Instance.new("Folder", Character)
  53. Effects.Name = "Effects"
  54. Humanoid.WalkSpeed = 16
  55. partEffects, AttackHas, AttackNeeded, AttackCan = {}, {}, {}, {}
  56. AttackHas[1], AttackHas[2], AttackHas[3], AttackHas[4] = 1, 1, 1, 1
  57. AttackNeeded[1], AttackNeeded[2], AttackNeeded[3], AttackNeeded[4] = 1, 1, 1, 1
  58. AttackCan[1], AttackCan[2], AttackCan[3], AttackCan[4] = true, true, true, true
  59. sine = 0
  60. attackcounter = 1
  61. energyslashcounter = 1
  62. torvel = nil
  63. attacking = false
  64. hitfloor, posfloor = nil, nil
  65. tool = nil
  66. if script.Parent.ClassName == "HopperBin" then
  67. tool = script.Parent
  68. tool.Parent = Player.Backpack
  69. else
  70. tool = Instance.new("HopperBin", Player.Backpack)
  71. tool.Name = "Toy Knife"
  72. end
  73. hitbox = Instance.new("Part")
  74. hitbox.BrickColor = BrickColor.Black()
  75. hitbox.Transparency = 1
  76. hitbox.CanCollide = false
  77. hitbox.Anchored = false
  78. hitbox.Size = Vector3.new(3, 3, 4)
  79. meshes = {
  80. 3270017,
  81. 20329976,
  82. 448386996,
  83. 1095708,
  84. 1033714,
  85. 9756362
  86. }
  87. sounds = {
  88. {
  89. 320557413,
  90. 320557453,
  91. 320557487,
  92. 320557518,
  93. 320557537,
  94. 320557563,
  95. 233856146,
  96. 233856140
  97. },
  98. {
  99. 234365549,
  100. 234365573,
  101. 231917961,
  102. 231917950,
  103. 231917856,
  104. 231917863,
  105. 231917871
  106. },
  107. {
  108. 262562442,
  109. 231917806,
  110. 231917784
  111. },
  112. {
  113. 262562442,
  114. 233856048,
  115. 306247739
  116. }
  117. }
  118. ArtificialHB = Instance.new("BindableEvent", script)
  119. ArtificialHB.Name = "Heartbeat"
  120. script:WaitForChild("Heartbeat")
  121. frame = 0.025
  122. tf = 0
  123. allowframeloss = true
  124. tossremainder = false
  125. lastframe = tick()
  126. script.Heartbeat:Fire()
  127. game:GetService("RunService").Heartbeat:connect(function(s, p)
  128. tf = tf + s
  129. if tf >= frame then
  130. if allowframeloss then
  131. script.Heartbeat:Fire()
  132. lastframe = tick()
  133. else
  134. for i = 1, math.floor(tf / frame) do
  135. script.Heartbeat:Fire()
  136. end
  137. lastframe = tick()
  138. end
  139. if tossremainder then
  140. tf = 0
  141. else
  142. tf = tf - frame * math.floor(tf / frame)
  143. end
  144. end
  145. end)
  146. function swait(num)
  147. if num == 0 or num == nil then
  148. ArtificialHB.Event:wait()
  149. else
  150. for i = 0, num do
  151. ArtificialHB.Event:wait()
  152. end
  153. end
  154. end
  155. function thread(f)
  156. coroutine.resume(coroutine.create(f))
  157. end
  158. function clerp(a, b, t)
  159. local qa = {
  160. QuaternionFromCFrame(a)
  161. }
  162. local qb = {
  163. QuaternionFromCFrame(b)
  164. }
  165. local ax, ay, az = a.x, a.y, a.z
  166. local bx, by, bz = b.x, b.y, b.z
  167. local _t = 1 - t
  168. return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
  169. end
  170. function QuaternionFromCFrame(cf)
  171. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  172. local trace = m00 + m11 + m22
  173. if trace > 0 then
  174. local s = math.sqrt(1 + trace)
  175. local recip = 0.5 / s
  176. return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
  177. else
  178. local i = 0
  179. if m00 < m11 then
  180. i = 1
  181. end
  182. if m22 > (i == 0 and m00 or m11) then
  183. i = 2
  184. end
  185. if i == 0 then
  186. local s = math.sqrt(m00 - m11 - m22 + 1)
  187. local recip = 0.5 / s
  188. return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
  189. elseif i == 1 then
  190. local s = math.sqrt(m11 - m22 - m00 + 1)
  191. local recip = 0.5 / s
  192. return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
  193. elseif i == 2 then
  194. local s = math.sqrt(m22 - m00 - m11 + 1)
  195. local recip = 0.5 / s
  196. return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
  197. end
  198. end
  199. end
  200. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  201. local xs, ys, zs = x + x, y + y, z + z
  202. local wx, wy, wz = w * xs, w * ys, w * zs
  203. local xx = x * xs
  204. local xy = x * ys
  205. local xz = x * zs
  206. local yy = y * ys
  207. local yz = y * zs
  208. local zz = z * zs
  209. return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy))
  210. end
  211. function QuaternionSlerp(a, b, t)
  212. local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
  213. local startInterp, finishInterp
  214. if cosTheta >= 1.0E-4 then
  215. if 1 - cosTheta > 1.0E-4 then
  216. local theta = math.acos(cosTheta)
  217. local invSinTheta = 1 / math.sin(theta)
  218. startInterp = math.sin((1 - t) * theta) * invSinTheta
  219. finishInterp = math.sin(t * theta) * invSinTheta
  220. else
  221. startInterp = 1 - t
  222. finishInterp = t
  223. end
  224. elseif 1 + cosTheta > 1.0E-4 then
  225. local theta = math.acos(-cosTheta)
  226. local invSinTheta = 1 / math.sin(theta)
  227. startInterp = math.sin((t - 1) * theta) * invSinTheta
  228. finishInterp = math.sin(t * theta) * invSinTheta
  229. else
  230. startInterp = t - 1
  231. finishInterp = t
  232. end
  233. return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp
  234. end
  235. function rayCast(Pos, Dir, Max, Ignore)
  236. return game:service("Workspace"):FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore)
  237. end
  238. function newPart(par, brick, transp, anch, canc, size, name, mat, ref)
  239. local p = Instance.new("Part")
  240. p.BrickColor = brick
  241. p.Transparency = transp
  242. p.Material = mat and mat or "SmoothPlastic"
  243. p.Reflectance = ref and ref or 0
  244. p.Anchored = anch
  245. p.CanCollide = canc
  246. p.Size = size
  247. p.TopSurface, p.BottomSurface, p.LeftSurface, p.RightSurface, p.FrontSurface, p.BackSurface = 10, 10, 10, 10, 10, 10
  248. p.Name = name
  249. p.CFrame = RootPart.CFrame
  250. p.Parent = par
  251. return p
  252. end
  253. function mesh(Mesh, part, meshtype, meshid, offset, scale)
  254. local mesh = Instance.new(Mesh)
  255. mesh.Parent = part
  256. if Mesh == "SpecialMesh" then
  257. mesh.MeshType = meshtype
  258. if meshid then
  259. mesh.MeshId = "http://www.roblox.com/asset/?id=" .. meshid
  260. end
  261. end
  262. if offset then
  263. mesh.Offset = offset
  264. end
  265. mesh.Scale = scale
  266. return mesh
  267. end
  268. function weld(parent, part0, part1, c0, c1)
  269. local weld = Instance.new("Weld")
  270. weld.Parent = parent
  271. weld.Part0 = part0
  272. weld.Part1 = part1
  273. weld.C0 = c0
  274. if c1 then
  275. weld.C1 = c1
  276. end
  277. return weld
  278. end
  279. function randomangles(r)
  280. local random = math.rad((math.random() - 0.5) * 180)
  281. local randomangles = CFrame.Angles(random, random, random)
  282. if r and r == 0 then
  283. return angles(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  284. elseif r and r == 1 then
  285. return math.rad((math.random() - 0.5) * 180)
  286. elseif r and r == 2 then
  287. return math.random(-50, 50)
  288. else
  289. return randomangles
  290. end
  291. end
  292. function round(num)
  293. local a, b = math.modf(num)
  294. if num % 1 ~= 0 then
  295. return math.floor(num) + math.floor(b * 10 + 0.5) / 10
  296. else
  297. return math.floor(num)
  298. end
  299. end
  300. function sound(id, par, vol, dur, pit)
  301. coroutine.resume(coroutine.create(function()
  302. local sou = Instance.new("Sound", par or workspace)
  303. sou.Volume = vol
  304. sou.Pitch = pit or 1
  305. sou.SoundId = "http://www.roblox.com/asset/?id=" .. id
  306. swait()
  307. sou:play()
  308. wait(dur)
  309. sou:Destroy()
  310. end))
  311. end
  312. function findCloseHumanoid(centre, distance)
  313. local tab = {}
  314. for _, child in pairs(game.Workspace:GetChildren()) do
  315. if child:findFirstChild("Humanoid") and child:findFirstChild("Humanoid") ~= Humanoid and child:findFirstChild("Torso") then
  316. local vtors = child.Torso
  317. local mag = math.abs((vtors.Position - centre).magnitude)
  318. if distance >= mag then
  319. table.insert(tab, child.Humanoid)
  320. end
  321. end
  322. end
  323. return tab
  324. end
  325. function basicDamage(vhum, damage, colour)
  326. if not vhum or not vhum.Parent:findFirstChild("Humanoid") or vhum.Health <= 0 then
  327. return
  328. end
  329. vhum.Health = vhum.Health - damage
  330. local damagepart = Instance.new("Part", Effects)
  331. damagepart.Transparency = 1
  332. damagepart.Anchored = true
  333. damagepart.CanCollide = false
  334. damagepart.Size = Vector3.new(1, 1, 1)
  335. damagepart.Name = "DamagePart"
  336. damagepart.CFrame = vhum.Parent.Head.CFrame * CFrame.new(0, 1, 0)
  337. local g = Instance.new("BillboardGui", damagepart)
  338. g.Enabled = true
  339. g.Adornee = damagepart
  340. g.Size = UDim2.new(5, 0, 5, 0)
  341. g.ExtentsOffset = Vector3.new(0, 0, 0)
  342. g.StudsOffset = Vector3.new(0, 0, 0)
  343. local t = Instance.new("TextLabel", g)
  344. t.BackgroundTransparency = 1
  345. t.Font = "ArialBold"
  346. t.TextSize = 24
  347. t.Text = "-" .. round(damage)
  348. if round(damage) % 1 == 0 then
  349. t.Text = "-" .. round(damage) .. ".0"
  350. end
  351. t.Size = UDim2.new(1, 0, 1, 0)
  352. t.TextStrokeTransparency = 0
  353. t.TextTransparency = 0
  354. t.TextScaled = true
  355. t.TextWrapped = true
  356. t.TextXAlignment = "Center"
  357. t.TextYAlignment = "Center"
  358. t.TextColor3 = colour
  359. coroutine.resume(coroutine.create(function()
  360. for i = 1, 50 do
  361. game:GetService("RunService").Heartbeat:wait()
  362. local sinewave = math.sin(i / 500) * 4
  363. damagepart.CFrame = damagepart.CFrame * CFrame.new(Vector3.new(0, 0.3 - sinewave, 0))
  364. t.TextTransparency = t.TextTransparency + 0.02
  365. t.TextStrokeTransparency = t.TextTransparency + 0.02
  366. end
  367. damagepart:Destroy()
  368. end), t)
  369. end
  370. function magic(type, thing)
  371. local magicBlock = function(par, brick, cframe, x1, y1, z1, x3, y3, z3, delay, t)
  372. local prt = newPart(par, brick, 0, true, false, Vector3.new(), "Part", "SmoothPlastic", cframe)
  373. prt.CFrame = cframe
  374. local msh = mesh("BlockMesh", prt, nil, nil, Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  375. game:GetService("Debris"):AddItem(prt, 8)
  376. if t == 1 or t == nil then
  377. table.insert(partEffects, {
  378. prt,
  379. "Block1",
  380. delay,
  381. x3,
  382. y3,
  383. z3,
  384. msh
  385. })
  386. elseif t == 2 then
  387. table.insert(partEffects, {
  388. prt,
  389. "Block2",
  390. delay,
  391. x3,
  392. y3,
  393. z3,
  394. msh
  395. })
  396. end
  397. end
  398. local magicCylinder = function(par, brick, cframe, x1, y1, z1, x3, y3, z3, delay)
  399. local prt = newPart(par, brick, 0, true, false, Vector3.new(), "Part", "SmoothPlastic", cframe)
  400. local msh = mesh("CylinderMesh", prt, nil, nil, Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  401. game:GetService("Debris"):AddItem(prt, 8)
  402. table.insert(partEffects, {
  403. prt,
  404. "Cylinder",
  405. delay,
  406. x3,
  407. y3,
  408. z3,
  409. msh
  410. })
  411. end
  412. local magicSphere = function(par, brick, cframe, x1, y1, z1, x3, y3, z3, delay)
  413. local prt = newPart(par, brick, 0, true, false, Vector3.new(), "Part", "SmoothPlastic", cframe)
  414. local msh = mesh("SpecialMesh", prt, "Sphere", nil, Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  415. game:GetService("Debris"):AddItem(prt, 8)
  416. table.insert(partEffects, {
  417. prt,
  418. "Cylinder",
  419. delay,
  420. x3,
  421. y3,
  422. z3,
  423. msh
  424. })
  425. end
  426. local magicRing = function(par, brick, cframe, x1, y1, z1, x3, y3, z3, delay)
  427. local prt = newPart(par, brick, 0, true, false, Vector3.new(), "Part", "SmoothPlastic", cframe)
  428. prt.Anchored = true
  429. prt.CFrame = cframe
  430. local msh = mesh("SpecialMesh", prt, "FileMesh", 3270017, Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  431. game:GetService("Debris"):AddItem(prt, 2)
  432. coroutine.resume(coroutine.create(function(Part, Mesh, num)
  433. for i = 0, 1, delay do
  434. swait()
  435. Part.Transparency = i
  436. Mesh.Scale = Mesh.Scale + Vector3.new(x3, y3, z3)
  437. end
  438. Part:Destroy()
  439. end), prt, msh, (math.random(0, 1) + math.random()) / 5)
  440. end
  441. local magicSlash = function(par, brick, cframe, x1, y1, z1, x3, y3, z3, delay)
  442. local prt = newPart(par, brick, 0, true, false, Vector3.new(), "Part", cframe)
  443. prt.Anchored = true
  444. prt.CFrame = cframe
  445. local msh = mesh("SpecialMesh", prt, "FileMesh", 20329976, Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  446. game:GetService("Debris"):AddItem(prt, 2)
  447. coroutine.resume(coroutine.create(function(Part, Mesh, num)
  448. for i = 0, 1, delay do
  449. swait()
  450. Part.Transparency = i
  451. Mesh.Scale = Mesh.Scale + Vector3.new(x3, y3, z3)
  452. end
  453. Part:Destroy()
  454. end), prt, msh, (math.random(0, 1) + math.random()) / 5)
  455. end
  456. local par = thing[1]
  457. local brick = thing[2]
  458. local cframe = thing[3]
  459. local x1 = thing[4]
  460. local y1 = thing[5]
  461. local z1 = thing[6]
  462. local x3 = thing[7]
  463. local y3 = thing[8]
  464. local z3 = thing[9]
  465. local delay = thing[10]
  466. local t = thing[11]
  467. if type == "Block" or type == 1 then
  468. magicBlock(thing[1], thing[2], thing[3], thing[4], thing[5], thing[6], thing[7], thing[8], thing[9], thing[10], thing[11])
  469. elseif type == "Cylinder" or type == 2 then
  470. magicCylinder(thing[1], thing[2], thing[3], thing[4], thing[5], thing[6], thing[7], thing[8], thing[9], thing[10], thing[11])
  471. elseif type == "Sphere" or type == 3 then
  472. magicSphere(thing[1], thing[2], thing[3], thing[4], thing[5], thing[6], thing[7], thing[8], thing[9], thing[10], thing[11])
  473. elseif type == "Ring" or type == 4 then
  474. magicRing(thing[1], thing[2], thing[3], thing[4], thing[5], thing[6], thing[7], thing[8], thing[9], thing[10], thing[11])
  475. elseif type == "Slash" or type == 5 then
  476. magicSlash(thing[1], thing[2], thing[3], thing[4], thing[5], thing[6], thing[7], thing[8], thing[9], thing[10], thing[11])
  477. end
  478. end
  479. function newFrame(par, bg, transp, size, pos, name)
  480. local f = Instance.new("Frame", nil)
  481. f.BackgroundColor3 = bg
  482. f.BackgroundTransparency = transp
  483. f.BorderSizePixel = 0
  484. f.Position = pos
  485. f.Size = size
  486. f.Name = name
  487. f.Parent = par
  488. return f
  489. end
  490. function newLabel(par, size, pos, text, textsize, text3, textstroke3, scaled, name)
  491. local l = Instance.new("TextLabel", nil)
  492. l.BackgroundTransparency = 1
  493. l.Size = size
  494. l.Position = pos
  495. l.Text = text
  496. l.TextSize = textsize
  497. l.TextColor3 = text3
  498. l.TextStrokeColor3 = textstroke3
  499. if scaled then
  500. l.TextScaled = scaled
  501. else
  502. l.TextScaled = true
  503. end
  504. l.TextStrokeTransparency = 0
  505. l.Name = name
  506. l.Parent = par
  507. return l
  508. end
  509. a1t = "Darkness"
  510. a2t = "DarknessPower"
  511. a3t = "HateDarkness"
  512. a4t = "DeterminationOfDarkness"
  513. backc3 = c3(107, 107, 107)
  514. reloc3 = c3(62, 62, 62)
  515. g = Instance.new("ScreenGui")
  516. f1 = newFrame(g, backc3, 0.5, UDim2.new(0.18, 0, 0.08, 0), UDim2.new(0.8, 0, 0.85, 0), "")
  517. f2 = newFrame(g, backc3, 0.5, UDim2.new(0.18, 0, 0.08, 0), UDim2.new(0.8, 0, 0.76, 0), "")
  518. f3 = newFrame(g, backc3, 0.5, UDim2.new(0.18, 0, 0.08, 0), UDim2.new(0.8, 0, 0.67, 0), "")
  519. f4 = newFrame(g, backc3, 0.5, UDim2.new(0.18, 0, 0.08, 0), UDim2.new(0.8, 0, 0.58, 0), "")
  520. newFrame(f1, reloc3, 0, UDim2.new(1.002, 0, 1.002, 0), UDim2.new(0, 0, 0, 0), "Reload")
  521. newFrame(f2, reloc3, 0, UDim2.new(1.002, 0, 1.002, 0), UDim2.new(0, 0, 0, 0), "Reload")
  522. newFrame(f3, reloc3, 0, UDim2.new(1.002, 0, 1.002, 0), UDim2.new(0, 0, 0, 0), "Reload")
  523. newFrame(f4, reloc3, 0, UDim2.new(1.002, 0, 1.002, 0), UDim2.new(0, 0, 0, 0), "Reload")
  524. newLabel(f1, UDim2.new(1, 0, 0.4, 0), UDim2.new(0, 0, 0, 0), "(Z)", 18, c3(243, 242, 242), c3(0, 0, 0), true, "Key")
  525. newLabel(f2, UDim2.new(1, 0, 0.4, 0), UDim2.new(0, 0, 0, 0), "(X)", 18, c3(243, 242, 242), c3(0, 0, 0), true, "Key")
  526. newLabel(f3, UDim2.new(1, 0, 0.4, 0), UDim2.new(0, 0, 0, 0), "(C)", 18, c3(243, 242, 242), c3(0, 0, 0), true, "Key")
  527. newLabel(f4, UDim2.new(1, 0, 0.4, 0), UDim2.new(0, 0, 0, 0), "(V)", 18, c3(243, 242, 242), c3(0, 0, 0), true, "Key")
  528. newLabel(f1, UDim2.new(1, 0, 0.6, 0), UDim2.new(0, 0, 0.4, 0), a1t, 18, c3(243, 242, 242), c3(0, 0, 0), true, "Label")
  529. newLabel(f2, UDim2.new(1, 0, 0.6, 0), UDim2.new(0, 0, 0.4, 0), a2t, 18, c3(243, 242, 242), c3(0, 0, 0), true, "Label")
  530. newLabel(f3, UDim2.new(1, 0, 0.6, 0), UDim2.new(0, 0, 0.4, 0), a3t, 18, c3(243, 242, 242), c3(0, 0, 0), true, "Label")
  531. newLabel(f4, UDim2.new(1, 0, 0.6, 0), UDim2.new(0, 0, 0.4, 0), a4t, 18, c3(243, 242, 242), c3(0, 0, 0), true, "Label")
  532. g.Parent = Player.PlayerGui
  533. Reload = {}
  534. Reload[1] = f1.Reload
  535. Reload[2] = f2.Reload
  536. Reload[3] = f3.Reload
  537. Reload[4] = f4.Reload
  538. weapon = Instance.new("Model", Character)
  539. weapon.Name = "Toy Knife"
  540. p0 = newPart(weapon, BrickColor.new("Really black"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "Part")
  541. mesh("BlockMesh", p0, nil, nil, Vector3.new(0, 0, 0), Vector3.new(0.774999976, 2.39999986, 6.57500076))
  542. p1 = newPart(weapon, BrickColor.new("Really black"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "Part")
  543. mesh("SpecialMesh", p1, Enum.MeshType.Wedge, nil, Vector3.new(0, 0, 0), Vector3.new(0.774999976, 0.425000012, 1.70000005))
  544. p1 = newPart(weapon, BrickColor.new("Really black"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "p1")
  545. mesh("SpecialMesh", p1, Enum.MeshType.Wedge, nil, Vector3.new(0, 0, 0), Vector3.new(0.774999976, 0.425000012, 1.70000005))
  546. p2 = newPart(weapon, BrickColor.new("Really black"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "Part")
  547. mesh("BlockMesh", p2, nil, nil, Vector3.new(0, 0, 0), Vector3.new(0.774999976, 0.999999881, 3.02500105))
  548. p2 = newPart(weapon, BrickColor.new("Really black"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "p2")
  549. mesh("BlockMesh", p2, nil, nil, Vector3.new(0, 0, 0), Vector3.new(0.774999976, 0.999999881, 3.02500105))
  550. p3 = newPart(weapon, BrickColor.new("Really black"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "Part")
  551. mesh("BlockMesh", p3, nil, nil, Vector3.new(0, 0, 0), Vector3.new(0.774999976, 0.974999905, 1.70000064))
  552. p3 = newPart(weapon, BrickColor.new("Really black"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "p3")
  553. mesh("BlockMesh", p3, nil, nil, Vector3.new(0, 0, 0), Vector3.new(0.774999976, 0.974999905, 1.70000064))
  554. p4 = newPart(weapon, BrickColor.new("Really black"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "Part")
  555. mesh("SpecialMesh", p4, Enum.MeshType.Wedge, nil, Vector3.new(0, 0, 0), Vector3.new(0.774999976, 0.975000024, 1.32500005))
  556. p4 = newPart(weapon, BrickColor.new("Really black"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "p4")
  557. mesh("SpecialMesh", p4, Enum.MeshType.Wedge, nil, Vector3.new(0, 0, 0), Vector3.new(0.774999976, 0.975000024, 1.32500005))
  558. p5 = newPart(weapon, BrickColor.new("Really black"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "Part")
  559. mesh("SpecialMesh", p5, Enum.MeshType.Wedge, nil, Vector3.new(0, 0, 0), Vector3.new(0.774999976, 0.975000024, 0.350000083))
  560. p5 = newPart(weapon, BrickColor.new("Really black"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "p5")
  561. mesh("SpecialMesh", p5, Enum.MeshType.Wedge, nil, Vector3.new(0, 0, 0), Vector3.new(0.774999976, 0.975000024, 0.350000083))
  562. p6 = newPart(weapon, BrickColor.new("Crimson"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "Handle")
  563. mesh("SpecialMesh", p6, Enum.MeshType.Cylinder, nil, Vector3.new(0, 0, 0), Vector3.new(5, 0.75, 0.800000012))
  564. p6 = newPart(weapon, BrickColor.new("Crimson"), 0, false, false, Vector3.new(0.220000014, 0.220000014, 0.220000014), "p6")
  565. mesh("SpecialMesh", p6, Enum.MeshType.Cylinder, nil, Vector3.new(0, 0, 0), Vector3.new(5, 0.75, 0.800000012))
  566. weld(p0, p0, p1, CFrame.new(-0.400014997, -2.90028477, 2.71900272, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(0.400014997, 2.68303514, 3.62925434, -1, 0, 0, 0, -1, 0, 0, 0, 1))
  567. weld(p1, p1, p2, CFrame.new(0.400014997, 2.68303514, 3.62925434, -1, 0, 0, 0, -1, 0, 0, 0, 1), CFrame.new(-0.400014997, -3.05428457, 3.77500391, 1, 0, 0, 0, 1, 0, 0, 0, 1))
  568. weld(p2, p2, p3, CFrame.new(-0.400014997, -3.05428457, 3.77500391, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(-0.400014997, -2.83703494, 3.62925434, 1, 0, 0, 0, 1, 0, 0, 0, 1))
  569. weld(p3, p3, p4, CFrame.new(-0.400014997, -2.83703494, 3.62925434, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(0.400014997, 2.83703494, 3.96200418, -1, 0, 0, 0, -1, 0, 0, 0, 1))
  570. weld(p4, p4, p5, CFrame.new(0.400014997, 2.83703494, 3.96200418, -1, 0, 0, 0, -1, 0, 0, 0, 1), CFrame.new(0.400014997, 3.05703473, 4.14625359, -1, 0, 0, 0, -1, 0, 0, 0, 1))
  571. weld(p5, p5, p6, CFrame.new(0.400014997, 3.05703473, 4.14625359, -1, 0, 0, 0, -1, 0, 0, 0, 1), CFrame.new(1.48875475, 2.98278475, -0.400014997, 0, 4.37113883E-8, 1, 0, -1, 4.37113883E-8, 1, 0, 0))
  572. handleweld = Instance.new("Weld", RightArm)
  573. handleweld.Part1 = RightArm
  574. handleweld.Part0 = p6
  575. handlec0 = CFrame.new(0, -0.95, 0) * angles(0, math.pi / 2, math.pi)
  576. handleweld.C0 = handlec0
  577. function attackone()
  578. attacking = true
  579. for i = 0, 1, 0.1 do
  580. swait()
  581. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(0), 0, math.rad(60)), 0.4)
  582. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.Angles(0, 0, math.rad(-60)), 0.4)
  583. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.9, 0) * CFrame.Angles(math.rad(180), 0, math.rad(10)), 0.4)
  584. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0), 0, math.rad(-50)), 0.4)
  585. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  586. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  587. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(-12), math.rad(90), 0), 0.4)
  588. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(12), -math.rad(90), 0), 0.4)
  589. end
  590. local smp = newPart(Effects, BrickColor.new("Lily white"), 0, true, false, Vector3.new(), "Slash")
  591. mesh("SpecialMesh", smp, "FileMesh", meshes[3], Vector3.new(0, 0, 0), Vector3.new(0.002, 0.06, 0.06))
  592. smp.CFrame = RootPart.CFrame * CFrame.new(0, 0, -3.5) * CFrame.Angles(math.rad(90), math.rad(120), math.rad(0))
  593. delay(0.1, function()
  594. table.insert(partEffects, {
  595. smp,
  596. "Disappear",
  597. 0.05
  598. })
  599. end)
  600. sound(sounds[1][1], Character.Head, 1, 4, 1.5)
  601. local hitb = hitbox.Touched:connect(function(hit)
  602. if hit.Parent ~= Character and hit.Parent:findFirstChild("Humanoid") then
  603. if hit.Parent:findFirstChild("Hit" .. Player.Name) then
  604. return
  605. end
  606. local str = Instance.new("StringValue", hit.Parent)
  607. str.Name = "Hit" .. Player.Name
  608. game.Debris:AddItem(str, 0.3)
  609. basicDamage(hit.Parent.Humanoid, math.random(9, 13), Color3.fromRGB(243, 242, 242))
  610. end
  611. end)
  612. for i = 0, 1, 0.1 do
  613. swait()
  614. RootJoint.C0 = clerp(RootJoint.C0, RootCF * cf(0, 0, 0) * angles(math.rad(10), math.rad(0), math.rad(80)), 0.4)
  615. Neck.C0 = clerp(Neck.C0, NeckCF * angles(math.rad(0), math.rad(0), math.rad(-70)), 0.4)
  616. RW.C0 = clerp(RW.C0, CFrame.new(1.4, 0.5, 0) * angles(math.rad(45), math.rad(-65), math.rad(5)), 0.4)
  617. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0), 0, math.rad(-50)), 0.4)
  618. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  619. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  620. RH.C0 = clerp(RH.C0, cf(1, -1, 0) * angles(math.rad(0), math.rad(90), math.rad(0)), 0.4)
  621. LH.C0 = clerp(LH.C0, cf(-1, -1, 0) * angles(math.rad(0), math.rad(-90), math.rad(0)), 0.4)
  622. hitbox.Parent = weapon
  623. hitbox.Size = Vector3.new(2, 5, 8)
  624. if smp then
  625. hitbox.CFrame = smp.CFrame
  626. else
  627. hitbox.Parent = nil
  628. end
  629. end
  630. hitb:disconnect()
  631. hitbox.Parent = nil
  632. attacking = false
  633. end
  634. function attacktwo()
  635. attacking = true
  636. for i = 0, 1, 0.1 do
  637. swait()
  638. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(0), 0, math.rad(-80)), 0.4)
  639. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.Angles(math.rad(15), 0, math.rad(80)), 0.4)
  640. RW.C0 = clerp(RW.C0, CFrame.new(1.3, 0.5, -0.4) * CFrame.Angles(math.rad(90), math.rad(90), math.rad(0)) * CFrame.Angles(math.rad(25), 0, 0), 0.4)
  641. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0), 0, math.rad(-50)), 0.4)
  642. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  643. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  644. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(-12), math.rad(90), 0), 0.4)
  645. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(12), -math.rad(90), 0), 0.4)
  646. end
  647. local smp = newPart(Effects, BrickColor.new("Lily white"), 0, true, false, Vector3.new(), "Slash")
  648. mesh("SpecialMesh", smp, "FileMesh", meshes[3], Vector3.new(0, 0, 0), Vector3.new(0.002, 0.06, 0.06))
  649. smp.CFrame = RootPart.CFrame * CFrame.new(0, 0, -3.5) * CFrame.Angles(math.rad(90), math.rad(80), math.rad(0))
  650. delay(0.1, function()
  651. table.insert(partEffects, {
  652. smp,
  653. "Disappear",
  654. 0.05
  655. })
  656. end)
  657. sound(sounds[1][2], Character.Head, 1, 4, 1.5)
  658. local hitb = hitbox.Touched:connect(function(hit)
  659. if hit.Parent ~= Character and hit.Parent:findFirstChild("Humanoid") then
  660. if hit.Parent:findFirstChild("Hit" .. Player.Name) then
  661. return
  662. end
  663. local str = Instance.new("StringValue", hit.Parent)
  664. str.Name = "Hit" .. Player.Name
  665. game.Debris:AddItem(str, 0.3)
  666. basicDamage(hit.Parent.Humanoid, math.random(9, 13), Color3.fromRGB(243, 242, 242))
  667. end
  668. end)
  669. for i = 0, 1, 0.1 do
  670. swait()
  671. Neck.C0 = clerp(Neck.C0, NeckCF * angles(math.rad(0), math.rad(0), math.rad(0)), 0.4)
  672. RootJoint.C0 = clerp(RootJoint.C0, RootCF * cf(0, 0, 0) * angles(math.rad(5), math.rad(0), math.rad(0)), 0.4)
  673. RW.C0 = clerp(RW.C0, CFrame.new(1.4, 0.5, 0) * angles(math.rad(0), math.rad(-40), math.rad(60)), 0.4)
  674. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(45), 0, math.rad(-25)), 0.4)
  675. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  676. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  677. RH.C0 = clerp(RH.C0, cf(1, -1, 0) * angles(math.rad(0), math.rad(90), math.rad(0)), 0.4)
  678. LH.C0 = clerp(LH.C0, cf(-1, -1, 0) * angles(math.rad(0), math.rad(-90), math.rad(0)), 0.4)
  679. hitbox.Parent = weapon
  680. hitbox.Size = Vector3.new(2, 5, 8)
  681. if smp then
  682. hitbox.CFrame = smp.CFrame
  683. else
  684. hitbox.Parent = nil
  685. end
  686. end
  687. hitb:disconnect()
  688. hitbox.Parent = nil
  689. attacking = false
  690. end
  691. function attackthree()
  692. attacking = true
  693. for i = 0, 1, 0.1 do
  694. swait()
  695. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(0), 0, math.rad(-80)), 0.4)
  696. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.Angles(math.rad(20), 0, math.rad(80)), 0.4)
  697. RW.C0 = clerp(RW.C0, CFrame.new(1.3, 0.5, -0.4) * CFrame.Angles(math.rad(90), math.rad(90), math.rad(-45)) * CFrame.Angles(math.rad(-25), 0, 0), 0.4)
  698. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0), 0, math.rad(-50)), 0.4)
  699. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  700. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  701. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(-12), math.rad(90), 0), 0.4)
  702. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(12), -math.rad(90), 0), 0.4)
  703. end
  704. local smp = newPart(Effects, BrickColor.new("Lily white"), 0, true, false, Vector3.new(), "Slash")
  705. mesh("SpecialMesh", smp, "FileMesh", meshes[3], Vector3.new(0, 0, 0), Vector3.new(0.002, 0.06, 0.06))
  706. smp.CFrame = RootPart.CFrame * CFrame.new(0, 0, -3.5) * CFrame.Angles(math.rad(90), math.rad(-70), math.rad(0))
  707. delay(0.1, function()
  708. table.insert(partEffects, {
  709. smp,
  710. "Disappear",
  711. 0.05
  712. })
  713. end)
  714. sound(sounds[1][3], Character.Head, 1, 4, 1.5)
  715. local hitb = hitbox.Touched:connect(function(hit)
  716. if hit.Parent ~= Character and hit.Parent:findFirstChild("Humanoid") then
  717. if hit.Parent:findFirstChild("Hit" .. Player.Name) then
  718. return
  719. end
  720. local str = Instance.new("StringValue", hit.Parent)
  721. str.Name = "Hit" .. Player.Name
  722. game.Debris:AddItem(str, 0.3)
  723. basicDamage(hit.Parent.Humanoid, math.random(9, 13), Color3.fromRGB(243, 242, 242))
  724. end
  725. end)
  726. for i = 0, 1, 0.1 do
  727. swait()
  728. Neck.C0 = clerp(Neck.C0, NeckCF * angles(math.rad(0), math.rad(0), math.rad(0)), 0.4)
  729. RootJoint.C0 = clerp(RootJoint.C0, RootCF * cf(0, 0, 0) * angles(math.rad(5), math.rad(0), math.rad(0)), 0.4)
  730. RW.C0 = clerp(RW.C0, CFrame.new(1.4, 0.8, 0.4) * angles(math.rad(0), math.rad(-40), math.rad(120)), 0.4)
  731. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(45), 0, math.rad(-25)), 0.4)
  732. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  733. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  734. RH.C0 = clerp(RH.C0, cf(1, -1, 0) * angles(math.rad(0), math.rad(90), math.rad(0)), 0.4)
  735. LH.C0 = clerp(LH.C0, cf(-1, -1, 0) * angles(math.rad(0), math.rad(-90), math.rad(0)), 0.4)
  736. hitbox.Parent = weapon
  737. hitbox.Size = Vector3.new(2, 5, 8)
  738. if smp then
  739. hitbox.CFrame = smp.CFrame
  740. else
  741. hitbox.Parent = nil
  742. end
  743. end
  744. hitb:disconnect()
  745. hitbox.Parent = nil
  746. attacking = false
  747. end
  748. function rapidslash()
  749. attacking = true
  750. AttackHas[1] = 0
  751. AttackCan[1] = false
  752. for i = 1, 3 do
  753. swait()
  754. for i = 0, 1, 0.2 do
  755. swait()
  756. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(0), 0, math.rad(60)), 0.6)
  757. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.Angles(0, 0, math.rad(-60)), 0.6)
  758. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.9, 0) * CFrame.Angles(math.rad(180), 0, math.rad(10)), 0.6)
  759. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0), 0, math.rad(-50)), 0.6)
  760. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 1)
  761. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 1)
  762. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(-12), math.rad(90), 0), 0.6)
  763. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(12), -math.rad(90), 0), 0.6)
  764. end
  765. sound(sounds[1][1], Character.Head, 1, 7, 1.5)
  766. do
  767. local smp = newPart(Effects, BrickColor.new("Lily white"), 0, true, false, Vector3.new(), "Slash")
  768. mesh("SpecialMesh", smp, "FileMesh", meshes[3], Vector3.new(0, 0, 0), Vector3.new(0.002, 0.06, 0.06))
  769. smp.CFrame = RootPart.CFrame * CFrame.new(0, 0, -3.5) * CFrame.Angles(math.rad(90), math.rad(math.random(-360, 360)), math.rad(0))
  770. delay(0.1, function()
  771. table.insert(partEffects, {
  772. smp,
  773. "Disappear",
  774. 0.05
  775. })
  776. end)
  777. for i, v in pairs(findCloseHumanoid(smp.Position, 5)) do
  778. basicDamage(v, 6, c3(243, 242, 242))
  779. end
  780. for i = 0, 1, 0.2 do
  781. swait()
  782. RootJoint.C0 = clerp(RootJoint.C0, RootCF * cf(0, 0, 0) * angles(math.rad(10), math.rad(0), math.rad(80)), 0.6)
  783. Neck.C0 = clerp(Neck.C0, NeckCF * angles(math.rad(0), math.rad(0), math.rad(-70)), 0.6)
  784. RW.C0 = clerp(RW.C0, CFrame.new(1.4, 0.5, 0) * angles(math.rad(45), math.rad(-65), math.rad(5)), 0.6)
  785. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0), 0, math.rad(-50)), 0.6)
  786. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 1)
  787. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 1)
  788. RH.C0 = clerp(RH.C0, cf(1, -1, 0) * angles(math.rad(0), math.rad(90), math.rad(0)), 0.6)
  789. LH.C0 = clerp(LH.C0, cf(-1, -1, 0) * angles(math.rad(0), math.rad(-90), math.rad(0)), 0.6)
  790. end
  791. sound(sounds[1][1], Character.Head, 1, 7, 1.5)
  792. local smp = newPart(Effects, BrickColor.new("Lily white"), 0, true, false, Vector3.new(), "Slash")
  793. mesh("SpecialMesh", smp, "FileMesh", meshes[3], Vector3.new(0, 0, 0), Vector3.new(0.002, 0.06, 0.06))
  794. smp.CFrame = RootPart.CFrame * CFrame.new(0, 0, -3.5) * CFrame.Angles(math.rad(90), math.rad(math.random(-360, 360)), math.rad(0))
  795. delay(0.1, function()
  796. table.insert(partEffects, {
  797. smp,
  798. "Disappear",
  799. 0.05
  800. })
  801. end)
  802. for i, v in pairs(findCloseHumanoid(smp.Position, 5)) do
  803. basicDamage(v, 6, c3(243, 242, 242))
  804. end
  805. for i = 0, 1, 0.2 do
  806. swait()
  807. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(0), 0, math.rad(-80)), 0.6)
  808. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.Angles(math.rad(20), 0, math.rad(80)), 0.6)
  809. RW.C0 = clerp(RW.C0, CFrame.new(1.3, 0.5, -0.4) * CFrame.Angles(math.rad(90), math.rad(90), math.rad(-45)) * CFrame.Angles(math.rad(-25), 0, 0), 1)
  810. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0), 0, math.rad(-50)), 0.6)
  811. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 1)
  812. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 1)
  813. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(-12), math.rad(90), 0), 0.6)
  814. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(12), -math.rad(90), 0), 0.6)
  815. end
  816. sound(sounds[1][1], Character.Head, 1, 7, 1.5)
  817. local smp = newPart(Effects, BrickColor.new("Lily white"), 0, true, false, Vector3.new(), "Slash")
  818. mesh("SpecialMesh", smp, "FileMesh", meshes[3], Vector3.new(0, 0, 0), Vector3.new(0.002, 0.06, 0.06))
  819. smp.CFrame = RootPart.CFrame * CFrame.new(0, 0, -3.5) * CFrame.Angles(math.rad(90), math.rad(math.random(-360, 360)), math.rad(0))
  820. delay(0.1, function()
  821. table.insert(partEffects, {
  822. smp,
  823. "Disappear",
  824. 0.05
  825. })
  826. end)
  827. for i, v in pairs(findCloseHumanoid(smp.Position, 5)) do
  828. basicDamage(v, 6, c3(243, 242, 242))
  829. end
  830. for i = 0, 1, 0.2 do
  831. swait()
  832. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(0), 0, math.rad(-80)), 0.6)
  833. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.Angles(math.rad(15), 0, math.rad(80)), 0.6)
  834. RW.C0 = clerp(RW.C0, CFrame.new(1.3, 0.5, -0.4) * CFrame.Angles(math.rad(90), math.rad(90), math.rad(0)) * CFrame.Angles(math.rad(25), 0, 0), 0.6)
  835. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0), 0, math.rad(-50)), 0.6)
  836. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.6)
  837. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.6)
  838. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(-12), math.rad(90), 0), 0.6)
  839. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(12), -math.rad(90), 0), 0.6)
  840. end
  841. sound(sounds[1][1], Character.Head, 1, 7, 1.5)
  842. local smp = newPart(Effects, BrickColor.new("Lily white"), 0, true, false, Vector3.new(), "Slash")
  843. mesh("SpecialMesh", smp, "FileMesh", meshes[3], Vector3.new(0, 0, 0), Vector3.new(0.002, 0.06, 0.06))
  844. smp.CFrame = RootPart.CFrame * CFrame.new(0, 0, -3.5) * CFrame.Angles(math.rad(90), math.rad(math.random(-360, 360)), math.rad(0))
  845. delay(0.1, function()
  846. table.insert(partEffects, {
  847. smp,
  848. "Disappear",
  849. 0.05
  850. })
  851. end)
  852. for i, v in pairs(findCloseHumanoid(smp.Position, 5)) do
  853. basicDamage(v, 6, c3(243, 242, 242))
  854. end
  855. for i = 0, 1, 0.2 do
  856. swait()
  857. Neck.C0 = clerp(Neck.C0, NeckCF * angles(math.rad(0), math.rad(0), math.rad(0)), 0.6)
  858. RootJoint.C0 = clerp(RootJoint.C0, RootCF * cf(0, 0, 0) * angles(math.rad(5), math.rad(0), math.rad(0)), 0.6)
  859. RW.C0 = clerp(RW.C0, CFrame.new(1.4, 0.5, 0) * angles(math.rad(0), math.rad(-40), math.rad(60)), 0.6)
  860. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(45), 0, math.rad(-25)), 0.6)
  861. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 1)
  862. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 1)
  863. RH.C0 = clerp(RH.C0, cf(1, -1, 0) * angles(math.rad(0), math.rad(90), math.rad(0)), 0.6)
  864. LH.C0 = clerp(LH.C0, cf(-1, -1, 0) * angles(math.rad(0), math.rad(-90), math.rad(0)), 0.6)
  865. end
  866. sound(sounds[1][1], Character.Head, 1, 7, 1.5)
  867. local smp = newPart(Effects, BrickColor.new("Lily white"), 0, true, false, Vector3.new(), "Slash")
  868. mesh("SpecialMesh", smp, "FileMesh", meshes[3], Vector3.new(0, 0, 0), Vector3.new(0.002, 0.06, 0.06))
  869. smp.CFrame = RootPart.CFrame * CFrame.new(0, 0, -3.5) * CFrame.Angles(math.rad(90), math.rad(math.random(-360, 360)), math.rad(0))
  870. delay(0.1, function()
  871. table.insert(partEffects, {
  872. smp,
  873. "Disappear",
  874. 0.05
  875. })
  876. end)
  877. for i, v in pairs(findCloseHumanoid(smp.Position, 5)) do
  878. basicDamage(v, 6, c3(243, 242, 242))
  879. end
  880. end
  881. end
  882. AttackCan[1] = true
  883. attacking = false
  884. end
  885. function powerslash()
  886. attacking = true
  887. AttackCan[2] = false
  888. AttackHas[2] = AttackHas[2] - 0.2
  889. local orbs = {}
  890. if energyslashcounter == 1 then
  891. energyslashcounter = 2
  892. sound(367453005, Character.Head, 1, 4, 1)
  893. do
  894. local now = RootPart.CFrame * CFrame.new(0, 0, -10)
  895. local bo = {
  896. BrickColor.new("Bright orange"),
  897. BrickColor.new("Toothpaste")
  898. }
  899. local bon = bo[math.random(1, 2)]
  900. for i = 1, 5 do
  901. local orb = newPart(Effects, bon, 0, true, false, Vector3.new(), "Orange", "SmoothPlastic", RootPart.CFrame * CFrame.new(0, 0, -15))
  902. local omesh = mesh("SpecialMesh", orb, "Sphere", nil, Vector3.new(0, 0, 0), Vector3.new(5, 5, 5))
  903. orb.CFrame = now * CFrame.new((math.random() - 0.5) * 20, 0, (math.random() - 0.5) * 20)
  904. table.insert(orbs, orb)
  905. end
  906. for i = 0, 1, 0.05 do
  907. swait()
  908. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(0), 0, math.rad(-80)), 0.15)
  909. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.Angles(math.rad(5), 0, math.rad(80)), 0.15)
  910. RW.C0 = clerp(RW.C0, CFrame.new(1.3, 0.5, -0.4) * CFrame.Angles(math.rad(90), math.rad(90), math.rad(0)) * CFrame.Angles(math.rad(25), 0, 0), 0.2)
  911. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0), 0, math.rad(-50)), 0.4)
  912. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.15)
  913. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.15)
  914. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(-12), math.rad(90), 0), 0.15)
  915. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(12), -math.rad(90), 0), 0.15)
  916. end
  917. for i = 1, #orbs do
  918. do
  919. local orb = orbs[i]
  920. table.insert(partEffects, {
  921. orb,
  922. "Block2",
  923. 0.05,
  924. 10,
  925. 10,
  926. 10,
  927. orb.Mesh
  928. })
  929. thread(function()
  930. for i = 1, 3 do
  931. swait(5)
  932. for i, v in pairs(findCloseHumanoid(orb.Position, 10)) do
  933. if bon == BrickColor.new("Bright orange") then
  934. if (v.Parent.Torso.Velocity * Vector3.new(1, 1, 1)).magnitude < 2 then
  935. basicDamage(v, 6, BrickColor.new("Bright orange").Color)
  936. end
  937. elseif bon == BrickColor.new("Toothpaste") and (v.Parent.Torso.Velocity * Vector3.new(1, 1, 1)).magnitude > 2 then
  938. basicDamage(v, 6, BrickColor.new("Toothpaste").Color)
  939. end
  940. end
  941. end
  942. end)
  943. end
  944. end
  945. sound(sounds[1][2], Character.Head, 1, 4, 0.8)
  946. for i = 0, 1, 0.1 do
  947. swait()
  948. Neck.C0 = clerp(Neck.C0, NeckCF * angles(math.rad(0), math.rad(0), math.rad(0)), 0.4)
  949. RootJoint.C0 = clerp(RootJoint.C0, RootCF * cf(0, 0, 0) * angles(math.rad(15), math.rad(0), math.rad(-5)), 0.4)
  950. RW.C0 = clerp(RW.C0, CFrame.new(1.4, 0.5, 0) * angles(math.rad(0), math.rad(-40), math.rad(60)), 0.4)
  951. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(45), 0, math.rad(-25)), 0.4)
  952. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  953. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  954. RH.C0 = clerp(RH.C0, cf(1, -1, 0) * angles(math.rad(0), math.rad(90), math.rad(0)), 0.4)
  955. LH.C0 = clerp(LH.C0, cf(-1, -1, 0) * angles(math.rad(0), math.rad(-90), math.rad(0)), 0.4)
  956. end
  957. end
  958. elseif energyslashcounter == 2 then
  959. energyslashcounter = 3
  960. sound(306247749, Character.Head, 1, 4, 1)
  961. local gparts = {}
  962. for i = 1, 9 do
  963. local gpart = newPart(Effects, BrickColor.new("Really red"), 0, true, false, Vector3.new(), "Violet", "SmoothPlastic")
  964. local gmesh = mesh("CylinderMesh", gpart, nil, nil, Vector3.new(0, 0, 0), Vector3.new(50, 10, 50))
  965. gpart.CFrame = RootPart.CFrame * CFrame.new(math.random(-20, 20), -3, -15 + math.random(-20, 20))
  966. table.insert(gparts, gpart)
  967. end
  968. for i = 0, 1, 0.05 do
  969. swait()
  970. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(0), 0, math.rad(80)), 0.15)
  971. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.Angles(math.rad(5), 0, math.rad(-80)), 0.15)
  972. RW.C0 = clerp(RW.C0, CFrame.new(1.3, 0.5, 0.4) * CFrame.Angles(math.rad(-45), math.rad(0), math.rad(15)) * CFrame.Angles(math.rad(0), 0, 0), 0.2)
  973. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0), 0, math.rad(-50)), 0.4)
  974. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.15)
  975. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.15)
  976. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(-12), math.rad(90), 0), 0.15)
  977. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(12), -math.rad(90), 0), 0.15)
  978. end
  979. for i = 1, #gparts do
  980. local gpart = gparts[i]
  981. table.insert(partEffects, {
  982. gpart,
  983. "Block2",
  984. 0.05,
  985. -1,
  986. 50,
  987. -1,
  988. gpart.Mesh
  989. })
  990. for i, v in pairs(findCloseHumanoid(gpart.Position, 10)) do
  991. basicDamage(v, 15, BrickColor.new("Dark blue").Color)
  992. local bv = Instance.new("BodyVelocity", v.Parent.Torso)
  993. game.Debris:AddItem(bv, 1)
  994. bv.Velocity = Vector3.new(0, 40, 0)
  995. bv.MaxForce = Vector3.new(math.huge, math.huge, math.huge)
  996. end
  997. end
  998. sound(sounds[1][3], Character.Head, 1, 4, 0.8)
  999. for i = 0, 1, 0.1 do
  1000. swait()
  1001. Neck.C0 = clerp(Neck.C0, NeckCF * angles(math.rad(0), math.rad(0), math.rad(-80)), 0.4)
  1002. RootJoint.C0 = clerp(RootJoint.C0, RootCF * cf(0, 0, 0) * angles(math.rad(15), math.rad(0), math.rad(80)), 0.4)
  1003. RW.C0 = clerp(RW.C0, CFrame.new(1.4, 0.5, -0.4) * angles(math.rad(125), math.rad(-40), math.rad(60)), 0.4)
  1004. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(45), 0, math.rad(-25)), 0.4)
  1005. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  1006. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  1007. RH.C0 = clerp(RH.C0, cf(1, -1, 0) * angles(math.rad(0), math.rad(90), math.rad(0)), 0.4)
  1008. LH.C0 = clerp(LH.C0, cf(-1, -1, 0) * angles(math.rad(0), math.rad(-90), math.rad(0)), 0.4)
  1009. end
  1010. elseif energyslashcounter == 3 then
  1011. energyslashcounter = 1
  1012. for i = 0, 1, 0.05 do
  1013. swait()
  1014. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(0), 0, math.rad(80)), 0.15)
  1015. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.Angles(math.rad(5), 0, math.rad(-80)), 0.15)
  1016. RW.C0 = clerp(RW.C0, CFrame.new(1.3, 0.5, -0.4) * CFrame.Angles(math.rad(90), math.rad(90), math.rad(0)) * CFrame.Angles(math.rad(25), 0, 0), 0.2)
  1017. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0), 0, math.rad(-50)), 0.4)
  1018. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.15)
  1019. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.15)
  1020. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(-12), math.rad(90), 0), 0.15)
  1021. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(12), -math.rad(90), 0), 0.15)
  1022. end
  1023. sound(sounds[2][5], Character.Head, 1, 4, 0.8)
  1024. thread(function()
  1025. for i = 1, 6 do
  1026. swait()
  1027. sound(438149153, Character.Head, 1, 4, 0.8)
  1028. do
  1029. local prt = newPart(Effects, BrickColor.new("Bright yellow"), 0, false, false, Vector3.new(), "Yellow", "SmoothPlastic", RootPart.CFrame)
  1030. local mesh = mesh("SpecialMesh", prt, "Sphere", nil, Vector3.new(0, 0, 0), Vector3.new(5, 5, 2.5))
  1031. prt.CFrame = RootPart.CFrame * CFrame.new(math.random(-3, 3), math.random(-1, 1), math.random(-3, 3))
  1032. local bv = Instance.new("BodyVelocity", prt)
  1033. bv.Velocity = RootPart.CFrame.lookVector * 150
  1034. bv.MaxForce = Vector3.new(math.huge, math.huge, math.huge)
  1035. game.Debris:AddItem(bv, 6)
  1036. local orlook = RootPart.CFrame.lookVector
  1037. thread(function()
  1038. while prt do
  1039. swait()
  1040. local hitpart, pospart = rayCast(prt.Position, orlook, 4, Character)
  1041. if hitpart and pospart then
  1042. prt:Destroy()
  1043. do
  1044. local ref = newPart(Effects, BrickColor.Black(), 1, true, false, Vector3.new(), "")
  1045. ref.CFrame = CFrame.new(pospart)
  1046. sound(142070127, ref, 1, 4, 1)
  1047. delay(4, function()
  1048. ref:Destroy()
  1049. end)
  1050. magic("Block", {
  1051. Effects,
  1052. BrickColor.new("Bright yellow"),
  1053. CFrame.new(pospart),
  1054. 0.2,
  1055. 0.2,
  1056. 0.2,
  1057. 0.9,
  1058. 0.9,
  1059. 0.9,
  1060. 0.05,
  1061. 1
  1062. })
  1063. magic("Block", {
  1064. Effects,
  1065. BrickColor.new("Bright yellow"),
  1066. CFrame.new(pospart),
  1067. 0.2,
  1068. 0.2,
  1069. 0.2,
  1070. 0.9,
  1071. 0.9,
  1072. 0.9,
  1073. 0.05,
  1074. 1
  1075. })
  1076. if hitpart.Parent:findFirstChild("Humanoid") then
  1077. basicDamage(hitpart.Parent.Humanoid, 12, BrickColor.new("Bright yellow").Color)
  1078. end
  1079. break
  1080. end
  1081. end
  1082. end
  1083. end)
  1084. end
  1085. end
  1086. end)
  1087. end
  1088. attacking = false
  1089. AttackCan[2] = true
  1090. end
  1091. function leftright()
  1092. attacking = true
  1093. AttackCan[3] = false
  1094. for i = 0, 1, 0.1 do
  1095. swait()
  1096. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(0), 0, math.rad(-80)), 0.4)
  1097. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.Angles(math.rad(15), 0, math.rad(80)), 0.4)
  1098. RW.C0 = clerp(RW.C0, CFrame.new(1.3, 0.5, -0.4) * CFrame.Angles(math.rad(90), math.rad(90), math.rad(0)) * CFrame.Angles(math.rad(25), 0, 0), 0.4)
  1099. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0), 0, math.rad(-50)), 0.4)
  1100. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  1101. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  1102. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(-12), math.rad(90), 0), 0.4)
  1103. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(12), -math.rad(90), 0), 0.4)
  1104. end
  1105. thread(function()
  1106. local laser = newPart(nil, BrickColor.new("Bright red"), 0.5, true, false, Vector3.new(), "Laser", "SmoothPlastic")
  1107. local lmsh = mesh("BlockMesh", nil, nil, nil, Vector3.new(0, 0, 0), Vector3.new(5, 5, 5))
  1108. local lasers = {}
  1109. local keypoints1, keypoints2, keypoints3, keypoints4, keypoints5, keypoints6 = {}, {}, {}, {}, {}, {}
  1110. local radius = 10
  1111. local num = 12
  1112. for i = 1, num do
  1113. table.insert(keypoints1, {
  1114. RootPart.CFrame.p,
  1115. RootPart.CFrame.lookVector + Vector3.new(math.cos(math.rad(360 / num) * i), 0, math.sin(math.rad(360 / num) * i))
  1116. })
  1117. table.insert(keypoints2, {
  1118. RootPart.CFrame.p,
  1119. RootPart.CFrame.lookVector + Vector3.new(math.cos(math.rad(360 / num + 45 * i) * i), 0, math.sin(math.rad(360 / num + 45 * i) * i))
  1120. })
  1121. table.insert(keypoints3, {
  1122. RootPart.CFrame.p,
  1123. RootPart.CFrame.lookVector + Vector3.new(math.cos(math.rad(360 / num + 90 * i) * i), 0, math.sin(math.rad(360 / num + 90 * i) * i))
  1124. })
  1125. table.insert(keypoints4, {
  1126. RootPart.CFrame.p,
  1127. RootPart.CFrame.lookVector + Vector3.new(math.cos(math.rad(360 / num + 135 * i) * i), 0, math.sin(math.rad(360 / num + 135 * i) * i))
  1128. })
  1129. end
  1130. local keypointstotal = {
  1131. keypoints1,
  1132. keypoints2,
  1133. keypoints3,
  1134. keypoints4
  1135. }
  1136. for ii = 1, #keypointstotal do
  1137. swait(5)
  1138. do
  1139. local currpoint = keypointstotal[ii]
  1140. for i = 1, #currpoint do
  1141. do
  1142. local start = currpoint[i][1]
  1143. local look = currpoint[i][2]
  1144. local laserc = laser:Clone()
  1145. local lmshc = lmsh:Clone()
  1146. local hit, pos = rayCast(start, look, 100000, Character)
  1147. laserc.CFrame = CFrame.new((start + pos) / 2, pos) * angles(math.rad(90), 0, 0)
  1148. local mag = (laserc.Position - pos).magnitude * 2
  1149. lmshc.Scale = Vector3.new(2, mag * 5, 2)
  1150. laserc.Parent = Effects
  1151. lmshc.Parent = laserc
  1152. thread(function()
  1153. table.insert(partEffects, {
  1154. laserc,
  1155. "Block2",
  1156. 0.025,
  1157. -0.1,
  1158. 0,
  1159. -0.1,
  1160. lmshc
  1161. })
  1162. local start = currpoint[i][1]
  1163. local look = currpoint[i][2]
  1164. look = CFrame.new(start, start + look).lookVector
  1165. local hit, pos = rayCast(start, look, 100000, Character)
  1166. repeat
  1167. swait()
  1168. until laserc.Parent == nil
  1169. local lpart = newPart(Effects, BrickColor.new("Black"), 0.5, true, false, Vector3.new(), "Cut", "SmoothPlastic")
  1170. sound(406913243, Head, 0.6, 4, 1)
  1171. local lpartm = mesh("BlockMesh", lpart, nil, nil, Vector3.new(0, 0, 0), Vector3.new(5, mag * 5, 5))
  1172. lpart.CFrame = laserc.CFrame * CFrame.new(0, 0, 0)
  1173. table.insert(partEffects, {
  1174. lpart,
  1175. "Block2",
  1176. 0.05,
  1177. 1,
  1178. 0,
  1179. 1,
  1180. lpartm
  1181. })
  1182. local lpart = newPart(Effects, BrickColor.new("Lily white"), 0.5, true, false, Vector3.new(), "Cut", "SmoothPlastic")
  1183. local lpartm = mesh("BlockMesh", lpart, nil, nil, Vector3.new(0, 0, 0), Vector3.new(8, mag * 5, 8))
  1184. lpart.CFrame = laserc.CFrame * CFrame.new(0, 0, 0)
  1185. table.insert(partEffects, {
  1186. lpart,
  1187. "Block2",
  1188. 0.05,
  1189. 1,
  1190. 0,
  1191. 1,
  1192. lpartm
  1193. })
  1194. local hit, pos = rayCast(start, look, 100000, Character)
  1195. if hit ~= nil then
  1196. if hit.Parent.ClassName == "Accessory" or hit.Parent.ClassName == "Hat" then
  1197. if hit.Parent.Parent:findFirstChild("Humanoid") then
  1198. basicDamage(hit.Parent.Parent.Humanoid, 20, BrickColor.new("Bright red").Color)
  1199. end
  1200. elseif hit.Parent:findFirstChild("Humanoid") then
  1201. basicDamage(hit.Parent.Humanoid, 20, BrickColor.new("Bright red").Color)
  1202. end
  1203. end
  1204. end)
  1205. end
  1206. end
  1207. end
  1208. end
  1209. end)
  1210. for i = 0, 1, 0.1 do
  1211. swait()
  1212. Neck.C0 = clerp(Neck.C0, NeckCF * angles(math.rad(0), math.rad(0), math.rad(0)), 0.4)
  1213. RootJoint.C0 = clerp(RootJoint.C0, RootCF * cf(0, 0, 0) * angles(math.rad(5), math.rad(0), math.rad(0)), 0.4)
  1214. RW.C0 = clerp(RW.C0, CFrame.new(1.4, 0.5, 0) * angles(math.rad(0), math.rad(-40), math.rad(60)), 0.4)
  1215. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(45), 0, math.rad(-25)), 0.4)
  1216. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  1217. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.4)
  1218. RH.C0 = clerp(RH.C0, cf(1, -1, 0) * angles(math.rad(0), math.rad(90), math.rad(0)), 0.4)
  1219. LH.C0 = clerp(LH.C0, cf(-1, -1, 0) * angles(math.rad(0), math.rad(-90), math.rad(0)), 0.4)
  1220. end
  1221. AttackCan[3] = true
  1222. attacking = false
  1223. end
  1224. function mouse1d()
  1225. if tool.Active == false then
  1226. return
  1227. end
  1228. if attacking == false and attackcounter == 1 then
  1229. attackcounter = 2
  1230. attackone()
  1231. elseif attacking == false and attackcounter == 2 then
  1232. attackcounter = 3
  1233. attacktwo()
  1234. elseif attacking == false and attackcounter == 3 then
  1235. attackcounter = 1
  1236. attackthree()
  1237. end
  1238. end
  1239. function key(k)
  1240. if tool.Active == false then
  1241. return
  1242. end
  1243. k = k:lower()
  1244. if attacking == false and k == "z" and AttackHas[1] >= AttackNeeded[1] then
  1245. rapidslash()
  1246. elseif attacking == false and k == "x" and AttackHas[2] >= 0.2 then
  1247. powerslash()
  1248. elseif attacking == false and k == "c" and AttackHas[3] >= AttackNeeded[3] then
  1249. leftright()
  1250. elseif attacking ~= false or k ~= "v" or AttackHas[4] >= AttackNeeded[4] then
  1251. end
  1252. end
  1253. asdasd = mouse.Button1Down:connect(mouse1d)
  1254. asdasdf = mouse.KeyDown:connect(key)
  1255. Humanoid.Died:connect(function()
  1256. asdasd:disconnect()
  1257. asdasdf:disconnect()
  1258. end)
  1259. thread(function()
  1260. while true do
  1261. swait()
  1262. torvel = (RootPart.Velocity * Vector3.new(1, 0, 1)).magnitude
  1263. hitfloor, posfloor = rayCast(RootPart.Position, CFrame.new(RootPart.Position, RootPart.Position - Vector3.new(0, 1, 0)).lookVector, 4, Character)
  1264. sine = sine + 1
  1265. if AttackHas[1] < AttackNeeded[1] and AttackCan[1] == true then
  1266. AttackHas[1] = AttackHas[1] + 0.005
  1267. end
  1268. if AttackHas[2] < AttackNeeded[2] and AttackCan[2] == true then
  1269. AttackHas[2] = AttackHas[2] + 0.005
  1270. end
  1271. if AttackHas[3] < AttackNeeded[3] and AttackCan[3] == true then
  1272. AttackHas[3] = AttackHas[3] + 0.005
  1273. end
  1274. if AttackHas[4] < AttackNeeded[4] and AttackCan[4] == true then
  1275. AttackHas[4] = AttackHas[4] + 0.005
  1276. end
  1277. Reload[1]:TweenSize(UDim2.new(AttackHas[1] / AttackNeeded[1], 0, 1, 0), nil, 1, 0.4)
  1278. Reload[2]:TweenSize(UDim2.new(AttackHas[2] / AttackNeeded[2], 0, 1, 0), nil, 1, 0.4)
  1279. Reload[3]:TweenSize(UDim2.new(AttackHas[3] / AttackNeeded[3], 0, 1, 0), nil, 1, 0.4)
  1280. Reload[4]:TweenSize(UDim2.new(AttackHas[4] / AttackNeeded[4], 0, 1, 0), nil, 1, 0.4)
  1281. if 1 < RootPart.Velocity.y and hitfloor == nil then
  1282. if attacking == false then
  1283. Anim = "Jump"
  1284. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(-15), 0, math.rad(0)), 0.1)
  1285. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(-math.rad(17), 0, math.rad(12)), 0.2)
  1286. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.2)
  1287. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * CFrame.Angles(-math.rad(17), 0, -math.rad(12)), 0.2)
  1288. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.2)
  1289. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.Angles(0, 0, 0), 0.2)
  1290. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(-12), math.rad(90), 0), 0.2)
  1291. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(12), -math.rad(90), 0), 0.2)
  1292. end
  1293. elseif RootPart.Velocity.y < -1 and hitfloor == nil then
  1294. if attacking == false then
  1295. Anim = "Fall"
  1296. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(23), 0, 0), 0.2)
  1297. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.Angles(0, 0, 0), 0.2)
  1298. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * CFrame.Angles(-math.rad(17), 0, math.rad(12)), 0.2)
  1299. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.2)
  1300. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(-math.rad(17), 0, -math.rad(12)), 0.2)
  1301. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0), 0.2)
  1302. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(24), math.rad(90), 0), 0.2)
  1303. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(-12), -math.rad(90), 0), 0.2)
  1304. end
  1305. elseif torvel < 1 and hitfloor ~= nil then
  1306. if attacking == false then
  1307. Anim = "Idle"
  1308. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(-5), 0, math.rad(15)), 0.1)
  1309. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.new(0, 0, 0.2 * math.cos(sine / 25)) * CFrame.Angles(math.rad(10), 0, math.rad(-15)), 0.1)
  1310. RW.C0 = clerp(RW.C0, CFrame.new(1.4, 0.5 - 0.1 * math.cos(sine / 15), 0) * CFrame.Angles(math.rad(5), math.rad(-15), math.rad(10) + 0.1 * math.cos(sine / 25)), 0.2)
  1311. LW.C0 = clerp(LW.C0, CFrame.new(-1.4, 0.5 - 0.1 * math.cos(sine / 15), 0) * CFrame.Angles(math.rad(-5), math.rad(15), math.rad(-10) - 0.1 * math.cos(sine / 25)), 0.2)
  1312. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0), 0.2)
  1313. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0), 0.2)
  1314. RH.C0 = clerp(RH.C0, CFrame.new(1, -1.1 - 0.2 * math.cos(sine / 25), 0) * CFrame.Angles(math.rad(10), math.rad(105), math.rad(-5)) * CFrame.Angles(math.rad(-4), 0, math.rad(-5)), 0.2)
  1315. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1 - 0.2 * math.cos(sine / 25), 0) * CFrame.Angles(math.rad(10), -math.rad(75), math.rad(-2)) * CFrame.Angles(math.rad(-13), 0, 0), 0.2)
  1316. end
  1317. elseif torvel > 2 and hitfloor ~= nil and attacking == false then
  1318. Anim = "Walk"
  1319. Neck.C0 = clerp(Neck.C0, NeckCF * CFrame.Angles(math.rad(-5), 0, math.rad(0)), 0.1)
  1320. RootJoint.C0 = clerp(RootJoint.C0, RootCF * CFrame.new(0, 0, 0.2 * math.cos(sine / 25)) * CFrame.Angles(math.rad(10), 0, math.rad(0)), 0.1)
  1321. RW.C0 = clerp(RW.C0, CFrame.new(1.45, 0.5 - 0.1 * math.cos(sine / 15), 0) * CFrame.Angles(math.rad(5), math.rad(-15), math.rad(10) + 0.1 * math.cos(sine / 25)), 0.2)
  1322. LW.C0 = clerp(LW.C0, CFrame.new(-1.45, 0.5 - 0.1 * math.cos(sine / 15), 0) * CFrame.Angles(math.rad(-5), math.rad(15), math.rad(-10) - 0.1 * math.cos(sine / 25)), 0.2)
  1323. RW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0), 0.2)
  1324. LW.C1 = clerp(LW.C1, CFrame.new(0, 0.5, 0), 0.2)
  1325. RH.C0 = clerp(RH.C0, CFrame.new(1, -1, 0) * CFrame.Angles(math.cos(sine * 1.2 / 8), math.rad(90), 0), 0.3)
  1326. LH.C0 = clerp(LH.C0, CFrame.new(-1, -1, 0) * CFrame.Angles(-math.cos(sine * 1.2 / 8), -math.rad(90), 0), 0.3)
  1327. end
  1328. if 0 < #partEffects then
  1329. for e = 1, #partEffects do
  1330. if partEffects[e] ~= nil then
  1331. local Thing = partEffects[e]
  1332. if Thing ~= nil then
  1333. local Part = Thing[1]
  1334. local Mode = Thing[2]
  1335. local Delay = Thing[3]
  1336. local IncX = Thing[4]
  1337. local IncY = Thing[5]
  1338. local IncZ = Thing[6]
  1339. if 1 >= Thing[1].Transparency then
  1340. if Thing[2] == "Block1" then
  1341. Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  1342. local Mesh = Thing[1].Mesh
  1343. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1344. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1345. elseif Thing[2] == "Block2" then
  1346. Thing[1].CFrame = Thing[1].CFrame
  1347. local Mesh = Thing[7]
  1348. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1349. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1350. elseif Thing[2] == "Cylinder" then
  1351. local Mesh = Thing[1].Mesh
  1352. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1353. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1354. elseif Thing[2] == "Blood" then
  1355. local Mesh = Thing[7]
  1356. Thing[1].CFrame = Thing[1].CFrame * Vector3.new(0, 0.5, 0)
  1357. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1358. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1359. elseif Thing[2] == "Elec" then
  1360. local Mesh = Thing[1].Mesh
  1361. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[7], Thing[8], Thing[9])
  1362. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1363. elseif Thing[2] == "Disappear" then
  1364. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1365. elseif Thing[2] == "Shatter" then
  1366. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1367. Thing[4] = Thing[4] * CFrame.new(0, Thing[7], 0)
  1368. Thing[1].CFrame = Thing[4] * CFrame.fromEulerAnglesXYZ(Thing[6], 0, 0)
  1369. Thing[6] = Thing[6] + Thing[5]
  1370. end
  1371. else
  1372. Part:Destroy()
  1373. table.remove(partEffects, e)
  1374. end
  1375. end
  1376. end
  1377. end
  1378. end
  1379. end
  1380. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement