Advertisement
AgentVK

KUNAI

Jan 2nd, 2018
278
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 39.45 KB | None | 0 0
  1. --[[ A script By makhail07
  2.  
  3.  
  4. Discord demitasse#2958
  5.  
  6. Description:
  7. ]]--
  8.  
  9. local IDs = {340106355,927529620,876981900,398987889}
  10.  
  11. function swait(num)
  12. if num==0 or num==nil then
  13. game:service'RunService'.Stepped:wait(0)
  14. else
  15. for i=0,num do
  16. game:service'RunService'.Stepped:wait(0)
  17. end
  18. end
  19. end
  20. function thread(f)
  21. coroutine.resume(coroutine.create(f))
  22. end
  23. function clerp(a, b, t)
  24. local qa = {
  25. QuaternionFromCFrame(a)
  26. }
  27. local qb = {
  28. QuaternionFromCFrame(b)
  29. }
  30. local ax, ay, az = a.x, a.y, a.z
  31. local bx, by, bz = b.x, b.y, b.z
  32. local _t = 1 - t
  33. return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
  34. end
  35. function QuaternionFromCFrame(cf)
  36. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  37. local trace = m00 + m11 + m22
  38. if trace > 0 then
  39. local s = math.sqrt(1 + trace)
  40. local recip = 0.5 / s
  41. return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
  42. else
  43. local i = 0
  44. if m00 < m11 then
  45. i = 1
  46. end
  47. if m22 > (i == 0 and m00 or m11) then
  48. i = 2
  49. end
  50. if i == 0 then
  51. local s = math.sqrt(m00 - m11 - m22 + 1)
  52. local recip = 0.5 / s
  53. return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
  54. elseif i == 1 then
  55. local s = math.sqrt(m11 - m22 - m00 + 1)
  56. local recip = 0.5 / s
  57. return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
  58. elseif i == 2 then
  59. local s = math.sqrt(m22 - m00 - m11 + 1)
  60. local recip = 0.5 / s
  61. return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
  62. end
  63. end
  64. end
  65. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  66. local xs, ys, zs = x + x, y + y, z + z
  67. local wx, wy, wz = w * xs, w * ys, w * zs
  68. local xx = x * xs
  69. local xy = x * ys
  70. local xz = x * zs
  71. local yy = y * ys
  72. local yz = y * zs
  73. local zz = z * zs
  74. 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))
  75. end
  76. function QuaternionSlerp(a, b, t)
  77. local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
  78. local startInterp, finishInterp
  79. if cosTheta >= 1.0E-4 then
  80. if 1 - cosTheta > 1.0E-4 then
  81. local theta = math.acos(cosTheta)
  82. local invSinTheta = 1 / math.sin(theta)
  83. startInterp = math.sin((1 - t) * theta) * invSinTheta
  84. finishInterp = math.sin(t * theta) * invSinTheta
  85. else
  86. startInterp = 1 - t
  87. finishInterp = t
  88. end
  89. elseif 1 + cosTheta > 1.0E-4 then
  90. local theta = math.acos(-cosTheta)
  91. local invSinTheta = 1 / math.sin(theta)
  92. startInterp = math.sin((t - 1) * theta) * invSinTheta
  93. finishInterp = math.sin(t * theta) * invSinTheta
  94. else
  95. startInterp = t - 1
  96. finishInterp = t
  97. end
  98. 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
  99. end
  100. function rayCast(Position, Direction, Range, Ignore)
  101. return game:service("Workspace"):FindPartOnRay(Ray.new(Position, Direction.unit * (Range or 999.999)), Ignore)
  102. end
  103. --Wait what okay
  104. wait()
  105. local plr = game:service'Players'.LocalPlayer
  106. local char = plr.Character
  107. local hum = char.Humanoid
  108. local ra = char["Right Arm"]
  109. local la= char["Left Arm"]
  110. local rl= char["Right Leg"]
  111. local ll = char["Left Leg"]
  112. local hed = char.Head
  113. local root = char.HumanoidRootPart
  114. local rootj = root.RootJoint
  115. local tors = char.Torso
  116. local mouse = plr:GetMouse()
  117. local RootCF = CFrame.fromEulerAnglesXYZ(-1.57, 0, 3.14)
  118. local RHCF = CFrame.fromEulerAnglesXYZ(0, 1.6, 0)
  119. local LHCF = CFrame.fromEulerAnglesXYZ(0, -1.6, 0)
  120. local maincolor = BrickColor.new("Magenta")
  121. cf = CFrame.new
  122. angles = CFrame.Angles
  123. attack = false
  124. euler=CFrame.fromEulerAnglesXYZ
  125. equipped = false
  126. necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  127. RSH, LSH = nil, nil
  128. RW = Instance.new("Weld")
  129. LW = Instance.new("Weld")
  130. RH = tors["Right Hip"]
  131. LH = tors["Left Hip"]
  132. RSH = tors["Right Shoulder"]
  133. LSH = tors["Left Shoulder"]
  134. RSH.Parent = nil
  135. LSH.Parent = nil
  136. RW.Name = "RW"
  137. RW.Part0 = tors
  138. RW.C0 = CFrame.new(1.5, 0.5, 0)
  139. RW.C1 = CFrame.new(0, 0.5, 0)
  140. RW.Part1 = ra
  141. RW.Parent = tors
  142. LW.Name = "LW"
  143. LW.Part0 = tors
  144. LW.C0 = CFrame.new(-1.5, 0.5, 0)
  145. LW.C1 = CFrame.new(0, 0.5, 0)
  146. LW.Part1 = la
  147. LW.Parent = tors
  148. print('User is '..plr.Name)
  149. Effects = {}
  150.  
  151. ArtificialHB = Instance.new("BindableEvent", script)
  152. ArtificialHB.Name = "Heartbeat"
  153.  
  154. script:WaitForChild("Heartbeat")
  155.  
  156. frame = 1 / 60
  157. tf = 0
  158. allowframeloss = false
  159. tossremainder = false
  160. lastframe = tick()
  161. script.Heartbeat:Fire()
  162.  
  163. game:GetService("RunService").Heartbeat:connect(function(s, p)
  164. tf = tf + s
  165. if tf >= frame then
  166. if allowframeloss then
  167. script.Heartbeat:Fire()
  168. lastframe = tick()
  169. else
  170. for i = 1, math.floor(tf / frame) do
  171. script.Heartbeat:Fire()
  172. end
  173. lastframe = tick()
  174. end
  175. if tossremainder then
  176. tf = 0
  177. else
  178. tf = tf - frame * math.floor(tf / frame)
  179. end
  180. end
  181. end)
  182. local RbxUtility = LoadLibrary("RbxUtility")
  183. local Create = RbxUtility.Create
  184.  
  185. function Damage(Part, hit, minim, maxim, knockback, Type, Property, Delay, HitSound, HitPitch)
  186. if hit.Parent == nil then
  187. return
  188. end
  189. local h = hit.Parent:FindFirstChildOfClass("Humanoid")
  190. for _, v in pairs(hit.Parent:children()) do
  191. if v:IsA("Humanoid") then
  192. h = v
  193. end
  194. end
  195. if h ~= nil and hit.Parent.Name ~= char.Name and hit.Parent:FindFirstChild("UpperTorso") ~= nil then
  196. warn'No R15 allowed'
  197. hit.Parent:FindFirstChild("Head"):BreakJoints()
  198. end
  199.  
  200. if h ~= nil and hit.Parent.Name ~= char.Name and hit.Parent:FindFirstChild("Torso") ~= nil then
  201. if hit.Parent:findFirstChild("DebounceHit") ~= nil then
  202. if hit.Parent.DebounceHit.Value == true then
  203. return
  204. end
  205. end
  206. if insta == true then
  207. hit.Parent:FindFirstChild("Head"):BreakJoints()
  208. end
  209. local c = Create("ObjectValue"){
  210. Name = "creator",
  211. Value = game:service("Players").LocalPlayer,
  212. Parent = h,
  213. }
  214. game:GetService("Debris"):AddItem(c, .5)
  215. if HitSound ~= nil and HitPitch ~= nil then
  216. CFuncs.Sound.Create(HitSound, hit, 1, HitPitch)
  217. end
  218. local Damage = math.random(minim, maxim)
  219. local blocked = false
  220. local block = hit.Parent:findFirstChild("Block")
  221. if block ~= nil then
  222. if block.className == "IntValue" then
  223. if block.Value > 0 then
  224. blocked = true
  225. block.Value = block.Value - 1
  226. print(block.Value)
  227. end
  228. end
  229. end
  230. if blocked == false then
  231. h.Health = h.Health - Damage
  232. ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, tors.BrickColor.Color)
  233. else
  234. h.Health = h.Health - (Damage / 2)
  235. ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, tors.BrickColor.Color)
  236. end
  237. if Type == "Knockdown" then
  238. local hum = hit.Parent.Humanoid
  239. hum.PlatformStand = true
  240. coroutine.resume(coroutine.create(function(HHumanoid)
  241. swait(1)
  242. HHumanoid.PlatformStand = false
  243. end), hum)
  244. local angle = (hit.Position - (Property.Position + Vector3.new(0, 0, 0))).unit
  245. local bodvol = Create("BodyVelocity"){
  246. velocity = angle * knockback,
  247. P = 5000,
  248. maxForce = Vector3.new(8e+003, 8e+003, 8e+003),
  249. Parent = hit,
  250. }
  251. local rl = Create("BodyAngularVelocity"){
  252. P = 3000,
  253. maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000,
  254. angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)),
  255. Parent = hit,
  256. }
  257. game:GetService("Debris"):AddItem(bodvol, .5)
  258. game:GetService("Debris"):AddItem(rl, .5)
  259. elseif Type == "Normal" then
  260. local vp = Create("BodyVelocity"){
  261. P = 500,
  262. maxForce = Vector3.new(math.huge, 0, math.huge),
  263. velocity = Property.CFrame.lookVector * knockback + Property.Velocity / 1.05,
  264. }
  265. if knockback > 0 then
  266. vp.Parent = hit.Parent.Torso
  267. end
  268. game:GetService("Debris"):AddItem(vp, .5)
  269. elseif Type == "Up" then
  270. local bodyVelocity = Create("BodyVelocity"){
  271. velocity = Vector3.new(0, 20, 0),
  272. P = 5000,
  273. maxForce = Vector3.new(8e+003, 8e+003, 8e+003),
  274. Parent = hit,
  275. }
  276. game:GetService("Debris"):AddItem(bodyVelocity, .5)
  277. elseif Type == "DarkUp" then
  278. coroutine.resume(coroutine.create(function()
  279. for i = 0, 1, 0.1 do
  280. swait()
  281. Effects.Block.Create(BrickColor.new("Black"), hit.Parent.Torso.CFrame, 5, 5, 5, 1, 1, 1, .08, 1)
  282. end
  283. end))
  284. local bodyVelocity = Create("BodyVelocity"){
  285. velocity = Vector3.new(0, 20, 0),
  286. P = 5000,
  287. maxForce = Vector3.new(8e+003, 8e+003, 8e+003),
  288. Parent = hit,
  289. }
  290. game:GetService("Debris"):AddItem(bodyVelocity, 1)
  291. elseif Type == "Snare" then
  292. local bp = Create("BodyPosition"){
  293. P = 2000,
  294. D = 100,
  295. maxForce = Vector3.new(math.huge, math.huge, math.huge),
  296. position = hit.Parent.Torso.Position,
  297. Parent = hit.Parent.Torso,
  298. }
  299. game:GetService("Debris"):AddItem(bp, 1)
  300. elseif Type == "Freeze" then
  301. local BodPos = Create("BodyPosition"){
  302. P = 50000,
  303. D = 1000,
  304. maxForce = Vector3.new(math.huge, math.huge, math.huge),
  305. position = hit.Parent.Torso.Position,
  306. Parent = hit.Parent.Torso,
  307. }
  308. local BodGy = Create("BodyGyro") {
  309. maxTorque = Vector3.new(4e+005, 4e+005, 4e+005) * math.huge ,
  310. P = 20e+003,
  311. Parent = hit.Parent.Torso,
  312. cframe = hit.Parent.Torso.CFrame,
  313. }
  314. hit.Parent.Torso.Anchored = true
  315. coroutine.resume(coroutine.create(function(Part)
  316. swait(1.5)
  317. Part.Anchored = false
  318. end), hit.Parent.Torso)
  319. game:GetService("Debris"):AddItem(BodPos, 3)
  320. game:GetService("Debris"):AddItem(BodGy, 3)
  321. end
  322. local debounce = Create("BoolValue"){
  323. Name = "DebounceHit",
  324. Parent = hit.Parent,
  325. Value = true,
  326. }
  327. game:GetService("Debris"):AddItem(debounce, Delay)
  328. c = Create("ObjectValue"){
  329. Name = "creator",
  330. Value = Player,
  331. Parent = h,
  332. }
  333. game:GetService("Debris"):AddItem(c, .5)
  334. end
  335. end
  336.  
  337. function ShowDamage(Pos, Text, Time, Color)
  338. local Rate = (1 / 30)
  339. local Pos = (Pos or Vector3.new(0, 0, 0))
  340. local Text = (Text or "")
  341. local Time = (Time or 2)
  342. local Color = (Color or Color3.new(1, 0, 1))
  343. local EffectPart = CFuncs.Part.Create(workspace, "SmoothPlastic", 0, 1, BrickColor.new(Color), "Effect", Vector3.new(0, 0, 0))
  344. EffectPart.Anchored = true
  345. local BillboardGui = Create("BillboardGui"){
  346. Size = UDim2.new(3, 0, 3, 0),
  347. Adornee = EffectPart,
  348. Parent = EffectPart,
  349. }
  350. local TextLabel = Create("TextLabel"){
  351. BackgroundTransparency = 1,
  352. Size = UDim2.new(1, 0, 1, 0),
  353. Text = Text,
  354. Font = "Highway",
  355. TextColor3 = Color,
  356. TextScaled = true,
  357. Parent = BillboardGui,
  358. }
  359. game.Debris:AddItem(EffectPart, (Time))
  360. EffectPart.Parent = game:GetService("Workspace")
  361. delay(0, function()
  362. local Frames = (Time / Rate)
  363. for Frame = 1, Frames do
  364. wait(Rate)
  365. local Percent = (Frame / Frames)
  366. EffectPart.CFrame = CFrame.new(Pos) + Vector3.new(0, Percent, 0)
  367. TextLabel.TextTransparency = Percent
  368. end
  369. if EffectPart and EffectPart.Parent then
  370. EffectPart:Destroy()
  371. end
  372. end)
  373. end
  374. function MagnitudeDamage(Part, Magnitude, MinimumDamage, MaximumDamage, KnockBack, Type, HitSound, HitPitch)
  375. for _, c in pairs(workspace:children()) do
  376. local hum = c:findFirstChild("Humanoid")
  377. if hum ~= nil then
  378. local head = c:findFirstChild("Torso") or c:findFirstChild("UpperTorso") or c:FindFirstChild('LowerTorso')
  379. if head ~= nil then
  380. local targ = head.Position - Part.Position
  381. local mag = targ.magnitude
  382. if mag <= Magnitude and c.Name ~= plr.Name then
  383. Damage(head, head, MinimumDamage, MaximumDamage, KnockBack, Type, root, .1, "rbxassetid://" .. HitSound, HitPitch)
  384. end
  385. end
  386. end
  387. end
  388. end
  389. CFuncs = {
  390. Part = {
  391. Create = function(Parent, Material, Reflectance, Transparency, BColor, Name, Size)
  392. local Part = Create("Part")({
  393. Parent = Parent,
  394. Reflectance = Reflectance,
  395. Transparency = Transparency,
  396. CanCollide = false,
  397. Locked = true,
  398. BrickColor = BrickColor.new(tostring(BColor)),
  399. Name = Name,
  400. Size = Size,
  401. Material = Material
  402. })
  403. RemoveOutlines(Part)
  404. return Part
  405. end
  406. },
  407. Mesh = {
  408. Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale)
  409. local Msh = Create(Mesh)({
  410. Parent = Part,
  411. Offset = OffSet,
  412. Scale = Scale
  413. })
  414. if Mesh == "SpecialMesh" then
  415. Msh.MeshType = MeshType
  416. Msh.MeshId = MeshId
  417. end
  418. return Msh
  419. end
  420. },
  421. Mesh = {
  422. Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale)
  423. local Msh = Create(Mesh)({
  424. Parent = Part,
  425. Offset = OffSet,
  426. Scale = Scale
  427. })
  428. if Mesh == "SpecialMesh" then
  429. Msh.MeshType = MeshType
  430. Msh.MeshId = MeshId
  431. end
  432. return Msh
  433. end
  434. },
  435. Weld = {
  436. Create = function(Parent, Part0, Part1, C0, C1)
  437. local Weld = Create("Weld")({
  438. Parent = Parent,
  439. Part0 = Part0,
  440. Part1 = Part1,
  441. C0 = C0,
  442. C1 = C1
  443. })
  444. return Weld
  445. end
  446. },
  447. Sound = {
  448. Create = function(id, par, vol, pit)
  449. coroutine.resume(coroutine.create(function()
  450. local S = Create("Sound")({
  451. Volume = vol,
  452. Pitch = pit or 1,
  453. SoundId = id,
  454. Parent = par or workspace
  455. })
  456. wait()
  457. S:play()
  458. game:GetService("Debris"):AddItem(S, 6)
  459. end))
  460. end
  461. },
  462. ParticleEmitter = {
  463. Create = function(Parent, Color1, Color2, LightEmission, Size, Texture, Transparency, ZOffset, Accel, Drag, LockedToPart, VelocityInheritance, EmissionDirection, Enabled, LifeTime, Rate, Rotation, RotSpeed, Speed, VelocitySpread)
  464. local fp = Create("ParticleEmitter")({
  465. Parent = Parent,
  466. Color = ColorSequence.new(Color1, Color2),
  467. LightEmission = LightEmission,
  468. Size = Size,
  469. Texture = Texture,
  470. Transparency = Transparency,
  471. ZOffset = ZOffset,
  472. Acceleration = Accel,
  473. Drag = Drag,
  474. LockedToPart = LockedToPart,
  475. VelocityInheritance = VelocityInheritance,
  476. EmissionDirection = EmissionDirection,
  477. Enabled = Enabled,
  478. Lifetime = LifeTime,
  479. Rate = Rate,
  480. Rotation = Rotation,
  481. RotSpeed = RotSpeed,
  482. Speed = Speed,
  483. VelocitySpread = VelocitySpread
  484. })
  485. return fp
  486. end
  487. }
  488. }
  489. function RemoveOutlines(part)
  490. part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10
  491. end
  492. function CreatePart(FormFactor, Parent, Material, Reflectance, Transparency, BColor, Name, Size)
  493. local Part = Create("Part")({
  494. formFactor = FormFactor,
  495. Parent = Parent,
  496. Reflectance = Reflectance,
  497. Transparency = Transparency,
  498. CanCollide = false,
  499. Locked = true,
  500. BrickColor = BrickColor.new(tostring(BColor)),
  501. Name = Name,
  502. Size = Size,
  503. Material = Material
  504. })
  505. RemoveOutlines(Part)
  506. return Part
  507. end
  508. function CreateMesh(Mesh, Part, MeshType, MeshId, OffSet, Scale)
  509. local Msh = Create(Mesh)({
  510. Parent = Part,
  511. Offset = OffSet,
  512. Scale = Scale
  513. })
  514. if Mesh == "SpecialMesh" then
  515. Msh.MeshType = MeshType
  516. Msh.MeshId = MeshId
  517. end
  518. return Msh
  519. end
  520. function CreateWeld(Parent, Part0, Part1, C0, C1)
  521. local Weld = Create("Weld")({
  522. Parent = Parent,
  523. Part0 = Part0,
  524. Part1 = Part1,
  525. C0 = C0,
  526. C1 = C1
  527. })
  528. return Weld
  529. end
  530. EffectModel = Instance.new("Model", char)
  531. Effects = {
  532. Block = {
  533. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type)
  534. local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  535. prt.Anchored = true
  536. prt.CFrame = cframe
  537. local msh = CFuncs.Mesh.Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  538. game:GetService("Debris"):AddItem(prt, 10)
  539. if Type == 1 or Type == nil then
  540. table.insert(Effects, {
  541. prt,
  542. "Block1",
  543. delay,
  544. x3,
  545. y3,
  546. z3,
  547. msh
  548. })
  549. elseif Type == 2 then
  550. table.insert(Effects, {
  551. prt,
  552. "Block2",
  553. delay,
  554. x3,
  555. y3,
  556. z3,
  557. msh
  558. })
  559. else
  560. table.insert(Effects, {
  561. prt,
  562. "Block3",
  563. delay,
  564. x3,
  565. y3,
  566. z3,
  567. msh
  568. })
  569. end
  570. end
  571. },
  572. Sphere = {
  573. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  574. local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  575. prt.Anchored = true
  576. prt.CFrame = cframe
  577. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  578. game:GetService("Debris"):AddItem(prt, 10)
  579. table.insert(Effects, {
  580. prt,
  581. "Cylinder",
  582. delay,
  583. x3,
  584. y3,
  585. z3,
  586. msh
  587. })
  588. end
  589. },
  590. Cylinder = {
  591. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  592. local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  593. prt.Anchored = true
  594. prt.CFrame = cframe
  595. local msh = CFuncs.Mesh.Create("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  596. game:GetService("Debris"):AddItem(prt, 10)
  597. table.insert(Effects, {
  598. prt,
  599. "Cylinder",
  600. delay,
  601. x3,
  602. y3,
  603. z3,
  604. msh
  605. })
  606. end
  607. },
  608. Wave = {
  609. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  610. local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  611. prt.Anchored = true
  612. prt.CFrame = cframe
  613. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://431164262", Vector3.new(0, 0, 0), Vector3.new(x1 / 60, y1 / 60, z1 / 60))
  614. game:GetService("Debris"):AddItem(prt, 10)
  615. table.insert(Effects, {
  616. prt,
  617. "Cylinder",
  618. delay,
  619. x3 / 60,
  620. y3 / 60,
  621. z3 / 60,
  622. msh
  623. })
  624. end
  625. },
  626. Ring = {
  627. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  628. local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  629. prt.Anchored = true
  630. prt.CFrame = cframe
  631. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://3270017", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  632. game:GetService("Debris"):AddItem(prt, 10)
  633. table.insert(Effects, {
  634. prt,
  635. "Cylinder",
  636. delay,
  637. x3,
  638. y3,
  639. z3,
  640. msh
  641. })
  642. end
  643. },
  644. Break = {
  645. Create = function(brickcolor, cframe, x1, y1, z1)
  646. local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5))
  647. prt.Anchored = true
  648. prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  649. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  650. local num = math.random(10, 50) / 1000
  651. game:GetService("Debris"):AddItem(prt, 10)
  652. table.insert(Effects, {
  653. prt,
  654. "Shatter",
  655. num,
  656. prt.CFrame,
  657. math.random() - math.random(),
  658. 0,
  659. math.random(50, 100) / 100
  660. })
  661. end
  662. }
  663. }
  664. function BlockEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type)
  665. local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  666. prt.Anchored = true
  667. prt.CFrame = cframe
  668. local msh = CreateMesh("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  669. game:GetService("Debris"):AddItem(prt, 10)
  670. if Type == 1 or Type == nil then
  671. table.insert(Effects, {
  672. prt,
  673. "Block1",
  674. delay,
  675. x3,
  676. y3,
  677. z3,
  678. msh
  679. })
  680. elseif Type == 2 then
  681. table.insert(Effects, {
  682. prt,
  683. "Block2",
  684. delay,
  685. x3,
  686. y3,
  687. z3,
  688. msh
  689. })
  690. elseif Type == 3 then
  691. table.insert(Effects, {
  692. prt,
  693. "Block3",
  694. delay,
  695. x3,
  696. y3,
  697. z3,
  698. msh
  699. })
  700. end
  701. end
  702. function SphereEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  703. local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  704. prt.Anchored = true
  705. prt.CFrame = cframe
  706. local msh = CreateMesh("SpecialMesh", prt, "Sphere", "nil", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  707. game:GetService("Debris"):AddItem(prt, 10)
  708. table.insert(Effects, {
  709. prt,
  710. "Cylinder",
  711. delay,
  712. x3,
  713. y3,
  714. z3,
  715. msh
  716. })
  717. end
  718. function RingEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  719. local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5))
  720. prt.Anchored = true
  721. prt.CFrame = cframe * CFrame.new(x1, y1, z1)
  722. local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "264766957", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  723. game:GetService("Debris"):AddItem(prt, 10)
  724. table.insert(Effects, {
  725. prt,
  726. "Cylinder",
  727. delay,
  728. x3,
  729. y3,
  730. z3,
  731. msh
  732. })
  733. end
  734. function CylinderEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  735. local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  736. prt.Anchored = true
  737. prt.CFrame = cframe
  738. local msh = CreateMesh("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  739. game:GetService("Debris"):AddItem(prt, 10)
  740. table.insert(Effects, {
  741. prt,
  742. "Cylinder",
  743. delay,
  744. x3,
  745. y3,
  746. z3,
  747. msh
  748. })
  749. end
  750. function WaveEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  751. local prt = CreatePart(3, workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  752. prt.Anchored = true
  753. prt.CFrame = cframe
  754. local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "264766957", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  755. game:GetService("Debris"):AddItem(prt, 10)
  756. table.insert(Effects, {
  757. prt,
  758. "Cylinder",
  759. delay,
  760. x3,
  761. y3,
  762. z3,
  763. msh
  764. })
  765. end
  766. function SpecialEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  767. local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  768. prt.Anchored = true
  769. prt.CFrame = cframe
  770. local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "24388358", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  771. game:GetService("Debris"):AddItem(prt, 10)
  772. table.insert(Effects, {
  773. prt,
  774. "Cylinder",
  775. delay,
  776. x3,
  777. y3,
  778. z3,
  779. msh
  780. })
  781. end
  782. function BreakEffect(brickcolor, cframe, x1, y1, z1)
  783. local prt = CreatePart(3, workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5))
  784. prt.Anchored = true
  785. prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  786. local msh = CreateMesh("SpecialMesh", prt, "Sphere", "nil", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  787. local num = math.random(10, 50) / 1000
  788. game:GetService("Debris"):AddItem(prt, 10)
  789. table.insert(Effects, {
  790. prt,
  791. "Shatter",
  792. num,
  793. prt.CFrame,
  794. math.random() - math.random(),
  795. 0,
  796. math.random(50, 100) / 100
  797. })
  798. end
  799. function part(formfactor,parent,reflectance,transparency,brickcolor,name,size)
  800. local fp=Instance.new("Part")
  801. fp.formFactor=formfactor
  802. fp.Parent=parent
  803. fp.Reflectance=reflectance
  804. fp.Transparency=transparency
  805. fp.CanCollide=false
  806. fp.Locked=true
  807. fp.BrickColor=brickcolor
  808. fp.Name=name
  809. fp.Size=size
  810. fp.Position=tors.Position
  811. RemoveOutlines(fp)
  812. fp.Material="SmoothPlastic"
  813. fp:BreakJoints()
  814. return fp
  815. end
  816.  
  817. function mesh(Mesh,part,meshtype,meshid,offset,scale)
  818. local mesh=Instance.new(Mesh)
  819. mesh.Parent=part
  820. if Mesh=="SpecialMesh" then
  821. mesh.MeshType=meshtype
  822. if meshid~="nil" then
  823. mesh.MeshId="http://www.roblox.com/asset/?id="..meshid
  824. end
  825. end
  826. mesh.Offset=offset
  827. mesh.Scale=scale
  828. return mesh
  829. end
  830. function MagicBlock(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  831. local prt=part(3,char,0,0,brickcolor,"Effect",Vector3.new(0.5,0.5,0.5))
  832. prt.Anchored=true
  833. prt.Material = "Neon"
  834. prt.CFrame=cframe
  835. prt.CFrame=prt.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))
  836. msh=mesh("BlockMesh",prt,"","",Vector3.new(0,0,0),Vector3.new(x1,y1,z1))
  837. game:GetService("Debris"):AddItem(prt,5)
  838. coroutine.resume(coroutine.create(function(Part,Mesh)
  839. for i=0,1,delay do
  840. swait()
  841. Part.CFrame=Part.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))
  842. Part.Transparency=i
  843. Mesh.Scale=Mesh.Scale+Vector3.new(x3,y3,z3)
  844. end
  845. Part.Parent=nil
  846. end),prt,msh)
  847. end
  848. function MagicShockTrailAlt2(origcolor2,cframe,x1,y1,z1,x3,y3,z3,delay,rottype)
  849. local prt=part(3,char,0,0,origcolor2,"Effect",Vector3.new(0.5,0.5,0.5))
  850. prt.Anchored=true
  851. prt.Material = "Neon"
  852. prt.CFrame=cframe
  853. msh=mesh("BlockMesh",prt,"","",Vector3.new(0,0,0),Vector3.new(x1,y1,z1))
  854. game:GetService("Debris"):AddItem(prt,5)
  855. coroutine.resume(coroutine.create(function(Part,Mesh)
  856. local rtype = rottype
  857. for i=0,1,delay do
  858. swait()
  859. if rtype == 1 then
  860. prt.CFrame = prt.CFrame*CFrame.Angles(0,0,0.1)
  861. elseif rtype == 2 then
  862. prt.CFrame = prt.CFrame*CFrame.Angles(0,0,-0.1)
  863. end
  864. prt.Transparency=i
  865. Mesh.Scale=Mesh.Scale+Vector3.new(x3,y3,z3)
  866. end
  867. Part.Parent=nil
  868. end),prt,msh)
  869. end
  870.  
  871. --[[
  872. Thanks for using Build-To-Lua by jarredbcv.
  873. ]]--
  874.  
  875.  
  876. New = function(Object, Parent, Name, Data)
  877. local Object = Instance.new(Object)
  878. for Index, Value in pairs(Data or {}) do
  879. Object[Index] = Value
  880. end
  881. Object.Parent = Parent
  882. Object.Name = Name
  883. return Object
  884. end
  885.  
  886. Kunai = New("Model",char,"Kunai",{})
  887. Handle = New("Part",Kunai,"Handle",{BrickColor = BrickColor.new("Really red"),FormFactor = Enum.FormFactor.Plate,Size = Vector3.new(1, 0.800000012, 1),CFrame = CFrame.new(77.4998779, 0.800036013, -64.5, 0, 0, -1, 0, 1, -0, 1, 0, -0),BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(1, 0, 0),})
  888. Mesh = New("CylinderMesh",Handle,"Mesh",{Scale = Vector3.new(0.5, 1, 0.300000012),})
  889. Part = New("Part",Kunai,"Part",{BrickColor = BrickColor.new("Dark stone grey"),FormFactor = Enum.FormFactor.Plate,Size = Vector3.new(1, 0.800000012, 1),CFrame = CFrame.new(77.4998779, 1.60002196, -64.5, -0, 0, 1, -0, 1, 0, -1, 0, 0),Color = Color3.new(0.388235, 0.372549, 0.384314),})
  890. Mesh = New("SpecialMesh",Part,"Mesh",{Scale = Vector3.new(0.379999995, 1.29999995, 0.379999995),VertexColor = Vector3.new(5, 5, 5),MeshId = "http://www.roblox.com/Asset/?id=9756362",TextureId = "http://www.roblox.com/asset/?id=41938593",MeshType = Enum.MeshType.FileMesh,})
  891. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0),C1 = CFrame.new(0, 0.799985945, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0),})
  892. Part = New("Part",Kunai,"Part",{BrickColor = BrickColor.new("Dark stone grey"),FormFactor = Enum.FormFactor.Plate,Size = Vector3.new(1, 0.400000006, 1),CFrame = CFrame.new(77.4998779, 0.200001001, -64.5, 0, 0, 1, 0, -1, 0, 1, 0, 0),BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.388235, 0.372549, 0.384314),})
  893. Mesh = New("SpecialMesh",Part,"Mesh",{Scale = Vector3.new(0.400000006, 0.400000006, 1.5),VertexColor = Vector3.new(5, 5, 5),MeshId = "http://www.roblox.com/asset/?id=3270017",TextureId = "http://www.roblox.com/asset/?id=41938593",MeshType = Enum.MeshType.FileMesh,})
  894. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle,C0 = CFrame.new(0, 0, 0, 0, 0, 1, 0, -1, 0, 1, 0, 0),C1 = CFrame.new(0, -0.600035012, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0),})
  895.  
  896. Kunai2 = New("Model",char,"Kunai2",{})
  897. Handle2 = New("Part",Kunai2,"Handle2",{BrickColor = BrickColor.new("Really red"),FormFactor = Enum.FormFactor.Plate,Size = Vector3.new(1, 0.800000012, 1),CFrame = CFrame.new(77.4998779, 0.800036013, -64.5, 0, 0, -1, 0, 1, -0, 1, 0, -0),BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(1, 0, 0),})
  898. Mesh = New("CylinderMesh",Handle2,"Mesh",{Scale = Vector3.new(0.5, 1, 0.300000012),})
  899. Part = New("Part",Kunai2,"Part",{BrickColor = BrickColor.new("Dark stone grey"),FormFactor = Enum.FormFactor.Plate,Size = Vector3.new(1, 0.800000012, 1),CFrame = CFrame.new(77.4998779, 1.60002196, -64.5, -0, 0, 1, -0, 1, 0, -1, 0, 0),Color = Color3.new(0.388235, 0.372549, 0.384314),})
  900. Mesh = New("SpecialMesh",Part,"Mesh",{Scale = Vector3.new(0.379999995, 1.29999995, 0.379999995),VertexColor = Vector3.new(5, 5, 5),MeshId = "http://www.roblox.com/Asset/?id=9756362",TextureId = "http://www.roblox.com/asset/?id=41938593",MeshType = Enum.MeshType.FileMesh,})
  901. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle2,C0 = CFrame.new(0, 0, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0),C1 = CFrame.new(0, 0.799985945, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0),})
  902. Part = New("Part",Kunai2,"Part",{BrickColor = BrickColor.new("Dark stone grey"),FormFactor = Enum.FormFactor.Plate,Size = Vector3.new(1, 0.400000006, 1),CFrame = CFrame.new(77.4998779, 0.200001001, -64.5, 0, 0, 1, 0, -1, 0, 1, 0, 0),BottomSurface = Enum.SurfaceType.Smooth,TopSurface = Enum.SurfaceType.Smooth,Color = Color3.new(0.388235, 0.372549, 0.384314),})
  903. Mesh = New("SpecialMesh",Part,"Mesh",{Scale = Vector3.new(0.400000006, 0.400000006, 1.5),VertexColor = Vector3.new(5, 5, 5),MeshId = "http://www.roblox.com/asset/?id=3270017",TextureId = "http://www.roblox.com/asset/?id=41938593",MeshType = Enum.MeshType.FileMesh,})
  904. mot = New("Motor",Part,"mot",{Part0 = Part,Part1 = Handle2,C0 = CFrame.new(0, 0, 0, 0, 0, 1, 0, -1, 0, 1, 0, 0),C1 = CFrame.new(0, -0.600035012, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0),})
  905.  
  906. local NewInstance = function(instance,parent,properties)
  907. local inst = Instance.new(instance,parent)
  908. if(properties)then
  909. for i,v in next, properties do
  910. pcall(function() inst[i] = v end)
  911. end
  912. end
  913. return inst;
  914. end
  915. local HW = NewInstance('Weld',char,{Part0=ra,Part1=Handle,C0 = CFrame.new(0,-1,0)*CFrame.Angles(math.rad(-65),0,math.rad(-90))})
  916. local HW2 = NewInstance('Weld',char,{Part0=la,Part1=Handle2,C0 = CFrame.new(0,-1,0)*CFrame.Angles(math.rad(-65),0,math.rad(90))})
  917.  
  918. Days = Instance.new("Sound",tors)
  919. Days.SoundId = "rbxassetid://398987889"
  920. Days.Volume = 1.5
  921. Days.Looped = true
  922. Days:Play()
  923.  
  924. function Jab()
  925. attack=true
  926. for i = 0,2,0.1 do
  927. swait()
  928. rootj.C0 = clerp(rootj.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(90)),.3)
  929. tors.Neck.C0 = clerp(tors.Neck.C0,necko *angles(math.rad(0),math.rad(0),math.rad(-65)),.3)
  930. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(90)), 0.3)
  931. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-20), math.rad(0), math.rad(-30)), 0.3)
  932. HW.C0=clerp(HW.C0,cf(0,-1,0)*angles(math.rad(-180),math.rad(0),math.rad(0)),0.15)
  933. end
  934. attack=false
  935. end
  936.  
  937. mouse.KeyDown:connect(function(key)
  938. if key == 'r' and attack == false then
  939. Jab()
  940. end
  941. end)
  942. ------------------------------------
  943. mouse.KeyDown:connect(function(key)
  944. if string.byte(key) == 48 then
  945. Swing = 2
  946. char.Humanoid.WalkSpeed = 50
  947. end
  948. end)
  949.  
  950. mouse.KeyUp:connect(function(key)
  951. if string.byte(key) == 48 then
  952. Swing = 1
  953. char.Humanoid.WalkSpeed = 16
  954. end
  955. end)
  956. ---------------------------------
  957.  
  958. local idle=0
  959. local sine = 0
  960. local change = 1
  961. local val = 0
  962. toim = 0
  963. hum.Animator.Parent = nil
  964. idleanim=.4
  965. while true do
  966. swait()
  967. sine = sine + change
  968. local torvel=(root.Velocity*Vector3.new(1,0,1)).magnitude
  969. local velderp=root.Velocity.y
  970. hitfloor,posfloor=rayCast(root.Position,(CFrame.new(root.Position,root.Position - Vector3.new(0,1,0))).lookVector,4,char)
  971. if equipped==true or equipped==false then
  972. if attack==false then
  973. idle=idle+1
  974. else
  975. idle=0
  976. end
  977. if root.Velocity.y > 1 and hitfloor==nil then
  978. Anim="Jump"
  979. if attack==false then
  980. rootj.C0 = clerp(rootj.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  981. tors.Neck.C0 = clerp(tors.Neck.C0,necko *angles(math.rad(-10),math.rad(0),math.rad(0)),.3)
  982. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(30), math.rad(0), math.rad(20)), 0.3)
  983. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-20), math.rad(0), math.rad(-30)), 0.3)
  984. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(-20)),.3)
  985. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-60),math.rad(0)),.3)
  986. end
  987. elseif root.Velocity.y < -1 and hitfloor==nil then
  988. Anim="Fall"
  989. if attack==false then
  990. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(-20)),.3)
  991. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-60),math.rad(0)),.3)
  992. rootj.C0 = clerp(rootj.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  993. tors.Neck.C0 = clerp(tors.Neck.C0,necko *angles(math.rad(40),math.rad(0),math.rad(0)),.3)
  994. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(30), math.rad(0), math.rad(20)), 0.3)
  995. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-20), math.rad(0), math.rad(-30)), 0.3)
  996. end
  997. elseif torvel<1 and hitfloor~=nil then
  998. Anim="Idle"
  999. change = 2
  1000. if attack==false then
  1001. rootj.C0=clerp(rootj.C0,RootCF*cf(0,0,-0.1+0.1*math.cos(sine/20))*angles(math.rad(0),math.rad(0),math.rad(-45)),0.15)
  1002. tors.Neck.C0=clerp(tors.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(45)),.3)
  1003. RH.C0=clerp(RH.C0,cf(1,-0.9-0.1*math.cos(sine/20),0)*angles(math.rad(-2.5),math.rad(90),math.rad(-0))*angles(math.rad(-7.5),math.rad(0),math.rad(0)),0.15)
  1004. LH.C0=clerp(LH.C0,cf(-1,-0.9-0.1*math.cos(sine/20),0)*angles(math.rad(-2.5),math.rad(-90),math.rad(-0))*angles(math.rad(-7.5),math.rad(0),math.rad(0)),0.15)
  1005. RW.C0 = clerp(RW.C0, CFrame.new(1, 0.5+0.04*math.sin(sine/25), -0.35) * angles(math.rad(90 - 1 * math.cos(sine / 25)), math.rad(0), math.rad(-50)), 0.1)
  1006. LW.C0 = clerp(LW.C0, CFrame.new(-1, 0.5+0.04*math.sin(sine/25), -0.35) * angles(math.rad(55 - 1 * math.cos(sine / 25)), math.rad(-7), math.rad(70)), 0.1)
  1007. HW.C0=clerp(HW.C0,cf(0,-1,0)*angles(math.rad(-65),math.rad(0),math.rad(-90)),0.15)
  1008. HW2.C0=clerp(HW2.C0,cf(0,-1,0)*angles(math.rad(-65),math.rad(0),math.rad(90)),0.15)
  1009. end
  1010. elseif torvel>2 and torvel<22 and hitfloor~=nil then
  1011. Anim="Walk"
  1012. change = 1
  1013. if attack==false then
  1014. rootj.C0=clerp(rootj.C0,RootCF*cf(0,0,-0.175+0.025*math.cos(sine/3.5)+ -math.sin(sine/3.5)/7)*angles(math.rad(5-2.5*math.cos(sine/3.5)),math.rad(0),math.rad(10*math.cos(sine/7))),0.15)
  1015. tors.Neck.C0 = clerp(tors.Neck.C0, necko * cf(0, 0, 0) * angles(math.rad(0), math.rad(0), math.rad(0)), 0.3)
  1016. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(40) * math.cos(sine / 7), math.rad(0), math.rad(5)), 0.3)
  1017. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-40) * math.cos(sine / 7), math.rad(0), math.rad(-5)), 0.3)
  1018. RH.C0=clerp(RH.C0,cf(1,-0.925-0.5*math.cos(sine/7)/2,0.5*math.cos(sine/7)/2)*angles(math.rad(-5-15*math.cos(sine/7))+ -math.sin(sine/7)/1.5,math.rad(90-10*math.cos(sine/7)),math.rad(0)),0.15)
  1019. LH.C0=clerp(LH.C0,cf(-1,-0.925+0.5*math.cos(sine/7)/2,-0.5*math.cos(sine/7)/2)*angles(math.rad(-5+15*math.cos(sine/7))+ math.sin(sine/7)/1.5,math.rad(-90-10*math.cos(sine/7)),math.rad(0)),0.15)
  1020. HW.C0=clerp(HW.C0,cf(0,-1,0)*angles(math.rad(-85),math.rad(0),math.rad(-180)),0.15)
  1021. HW2.C0=clerp(HW2.C0,cf(0,-1,0)*angles(math.rad(-85),math.rad(0),math.rad(180)),0.15)
  1022. end
  1023. elseif torvel>=22 and hitfloor~=nil then
  1024. Anim="Run"
  1025. change = 2
  1026. rootj.C0=clerp(rootj.C0,RootCF*cf(0,0,-0.175+0.025*math.cos(sine/3.5)+ -math.sin(sine/3.5)/7)*angles(math.rad(25),math.rad(0),math.rad(10*math.cos(sine/7))),0.15)
  1027. tors.Neck.C0 = clerp(tors.Neck.C0, necko * cf(0, 0, 0) * angles(math.rad(0), math.rad(0), math.rad(0)), 0.3)
  1028. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(55), math.rad(-55), math.rad(90)), 0.3)
  1029. LW.C0=clerp(LW.C0,cf(-0.85,0.5 + 0.1 * math.cos(sine / 60),-0.65)*angles(math.rad(40),math.rad(0),math.rad(90 + 2.5)),.3)
  1030. RH.C0=clerp(RH.C0,cf(1,-0.925-0.5*math.cos(sine/7)/2,0.5*math.cos(sine/7)/1)*angles(math.rad(-5-15*math.cos(sine/7))+ -math.sin(sine/7)/1,math.rad(90-10*math.cos(sine/7)),math.rad(0)),0.15)
  1031. LH.C0=clerp(LH.C0,cf(-1,-0.925+0.5*math.cos(sine/7)/2,-0.5*math.cos(sine/7)/1)*angles(math.rad(-5+15*math.cos(sine/7))+ math.sin(sine/7)/1,math.rad(-90-10*math.cos(sine/7)),math.rad(0)),0.15)
  1032. HW.C0=clerp(HW.C0,cf(0,-1,0)*angles(math.rad(-65),math.rad(0),math.rad(-90)),0.15)
  1033. HW2.C0=clerp(HW2.C0,cf(0,-1,0)*angles(math.rad(-65),math.rad(0),math.rad(90)),0.15)
  1034. end
  1035. end
  1036. if 0 < #Effects then
  1037. for e = 1, #Effects do
  1038. if Effects[e] ~= nil then
  1039. local Thing = Effects[e]
  1040. if Thing ~= nil then
  1041. local Part = Thing[1]
  1042. local Mode = Thing[2]
  1043. local Delay = Thing[3]
  1044. local IncX = Thing[4]
  1045. local IncY = Thing[5]
  1046. local IncZ = Thing[6]
  1047. if 1 >= Thing[1].Transparency then
  1048. if Thing[2] == "Block1" then
  1049. Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  1050. local Mesh = Thing[1].Mesh
  1051. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1052. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1053. elseif Thing[2] == "Block2" then
  1054. Thing[1].CFrame = Thing[1].CFrame + Vector3.new(0, 0, 0)
  1055. local Mesh = Thing[7]
  1056. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1057. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1058. elseif Thing[2] == "Block3" then
  1059. Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) + Vector3.new(0, 0.15, 0)
  1060. local Mesh = Thing[7]
  1061. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1062. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1063. elseif Thing[2] == "Cylinder" then
  1064. local Mesh = Thing[1].Mesh
  1065. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1066. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1067. elseif Thing[2] == "Blood" then
  1068. local Mesh = Thing[7]
  1069. Thing[1].CFrame = Thing[1].CFrame * Vector3.new(0, 0.5, 0)
  1070. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  1071. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1072. elseif Thing[2] == "Elec" then
  1073. local Mesh = Thing[1].Mesh
  1074. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[7], Thing[8], Thing[9])
  1075. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1076. elseif Thing[2] == "Disappear" then
  1077. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1078. elseif Thing[2] == "Shatter" then
  1079. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  1080. Thing[4] = Thing[4] * CFrame.new(0, Thing[7], 0)
  1081. Thing[1].CFrame = Thing[4] * CFrame.fromEulerAnglesXYZ(Thing[6], 0, 0)
  1082. Thing[6] = Thing[6] + Thing[5]
  1083. end
  1084. else
  1085. Part.Parent = nil
  1086. table.remove(Effects, e)
  1087. end
  1088. end
  1089. end
  1090. end
  1091. end
  1092. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement