Advertisement
KrYn0MoRe

sf swords

Apr 19th, 2020
1,410
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 17.29 KB | None | 0 0
  1.  
  2. --Converted with ttyyuu12345's model to script plugin v4
  3. function sandbox(var,func)
  4.     local env = getfenv(func)
  5.     local newenv = setmetatable({},{
  6.         __index = function(self,k)
  7.             if k=="script" then
  8.                 return var
  9.             else
  10.                 return env[k]
  11.             end
  12.         end,
  13.     })
  14.     setfenv(func,newenv)
  15.     return func
  16. end
  17. cors = {}
  18. mas = Instance.new("Model",game:GetService("Lighting"))
  19. Script0 = Instance.new("Script")
  20. Script1 = Instance.new("Script")
  21. Script2 = Instance.new("Script")
  22. Script0.Name = "Blumina"
  23. Script0.Parent = mas
  24. table.insert(cors,sandbox(Script0,function()
  25. local Tool0 = Instance.new("Tool")
  26. local Part2 = Instance.new("Part")
  27. local SpecialMesh3 = Instance.new("SpecialMesh")
  28. local Sparkles4 = Instance.new("Sparkles")
  29. Tool0.Name = "Blumina"
  30. Tool0.Parent = owner['Backpack']
  31. Tool0.Grip = CFrame.new(0, 0, -1.5, 0, 0, 1, 1, 0, 0, 0, 1, 0)
  32. Tool0.GripForward = Vector3.new(-1, -0, -0)
  33. Tool0.GripPos = Vector3.new(0, 0, -1.5)
  34. Tool0.GripRight = Vector3.new(0, 1, 0)
  35. Tool0.GripUp = Vector3.new(0, 0, 1)
  36. Part2.Name = "Handle"
  37. Part2.Parent = Tool0
  38. Part2.CFrame = CFrame.new(-20.6640606, 0.400005996, 9.11587429, -1, 1.99379383e-06, 2.97924635e-06, -1.99379474e-06, -1, -3.01450541e-07, 2.97924589e-06, -3.01456453e-07, 1)
  39. Part2.Orientation = Vector3.new(0, 0, -180)
  40. Part2.Position = Vector3.new(-20.6640606, 0.400005996, 9.11587429)
  41. Part2.Rotation = Vector3.new(0, 0, -180)
  42. Part2.Color = Color3.new(0, 0.12549, 0.376471)
  43. Part2.Velocity = Vector3.new(-0.00497130677, -0.00215061568, 0.00259776041)
  44. Part2.Size = Vector3.new(1, 0.800000012, 4)
  45. Part2.BottomSurface = Enum.SurfaceType.Smooth
  46. Part2.BrickColor = BrickColor.new("Navy blue")
  47. Part2.Reflectance = 0.40000000596046
  48. Part2.RotVelocity = Vector3.new(-0.0043529924, 0.00333694159, 0.000599374238)
  49. Part2.TopSurface = Enum.SurfaceType.Smooth
  50. Part2.brickColor = BrickColor.new("Navy blue")
  51. SpecialMesh3.Parent = Part2
  52. SpecialMesh3.MeshId = "rbxasset://fonts/sword.mesh"
  53. SpecialMesh3.VertexColor = Vector3.new(1, 1, 0)
  54. SpecialMesh3.MeshType = Enum.MeshType.FileMesh
  55. Sparkles4.Parent = Part2
  56. Sparkles4.Color = Color3.new(1.02083, 1, 1)
  57. Sparkles4.SparkleColor = Color3.new(0.576471, 0.0980392, 1)
  58.  
  59. -------- OMG HAX
  60.  
  61. local r = game:service("RunService")
  62.  
  63.  
  64. local damage = 10
  65.  
  66.  
  67. local slash_damage = 20
  68. local lunge_damage = 40
  69.  
  70. local sword = Part2
  71. local Tool = Tool0
  72.  
  73.  
  74. local SlashSound = Instance.new("Sound")
  75. SlashSound.SoundId = "rbxasset://sounds\\swordslash.wav"
  76. SlashSound.Parent = sword
  77. SlashSound.Volume = .7
  78.  
  79. local LungeSound = Instance.new("Sound")
  80. LungeSound.SoundId = "rbxasset://sounds\\swordlunge.wav"
  81. LungeSound.Parent = sword
  82. LungeSound.Volume = .6
  83.  
  84. local UnsheathSound = Instance.new("Sound")
  85. UnsheathSound.SoundId = "rbxasset://sounds\\unsheath.wav"
  86. UnsheathSound.Parent = sword
  87. UnsheathSound.Volume = 1
  88.  
  89.  
  90.  
  91.  
  92.  
  93.  
  94. function blow(hit)
  95.     local humanoid = hit.Parent:findFirstChild("Humanoid")
  96.     local vCharacter = Tool.Parent
  97.     local vPlayer = game.Players:playerFromCharacter(vCharacter)
  98.     local hum = vCharacter:findFirstChild("Humanoid") -- non-nil if tool held by a character
  99.     if humanoid~=nil and humanoid ~= hum and hum ~= nil then
  100.         -- final check, make sure sword is in-hand
  101.  
  102.         local right_arm = vCharacter:FindFirstChild("Right Arm")
  103.         if (right_arm ~= nil) then
  104.             local joint = right_arm:FindFirstChild("RightGrip")
  105.             if (joint ~= nil and (joint.Part0 == sword or joint.Part1 == sword)) then
  106.                 tagHumanoid(humanoid, vPlayer)
  107.                 humanoid:TakeDamage(damage)
  108.                 wait(1)
  109.                 untagHumanoid(humanoid)
  110.             end
  111.         end
  112.  
  113.  
  114.     end
  115. end
  116.  
  117.  
  118.  
  119. function tagHumanoid(humanoid, player)
  120.     local creator_tag = Instance.new("ObjectValue")
  121.     creator_tag.Value = player
  122.     creator_tag.Name = "creator"
  123.     creator_tag.Parent = humanoid
  124. end
  125.  
  126. function untagHumanoid(humanoid)
  127.     if humanoid ~= nil then
  128.         local tag = humanoid:findFirstChild("creator")
  129.         if tag ~= nil then
  130.             tag.Parent = nil
  131.         end
  132.     end
  133. end
  134.  
  135.  
  136. function attack()
  137.     damage = slash_damage
  138.     SlashSound:play()
  139.     local anim = Instance.new("StringValue")
  140.     anim.Name = "toolanim"
  141.     anim.Value = "Slash"
  142.     anim.Parent = Tool
  143. end
  144.  
  145. function lunge()
  146.     damage = lunge_damage
  147.  
  148.     LungeSound:play()
  149.  
  150.     local anim = Instance.new("StringValue")
  151.     anim.Name = "toolanim"
  152.     anim.Value = "Lunge"
  153.     anim.Parent = Tool
  154.    
  155.     local torso = (Tool.Parent:FindFirstChild("Torso") or Tool.Parent:FindFirstChild("HumanoidRootPart"))
  156.    
  157.     local force = Instance.new("BodyVelocity")
  158.     force.velocity =  Vector3.new(0,80,0) --(Tool.Parent:FindFirstChild("Torso") or Tool.Parent:FindFirstChild("HumanoidRootPart")).CFrame.lookVector * 80
  159.     force.Parent = torso
  160.     wait(.25)
  161.     force.velocity =  (torso.CFrame.lookVector * 120)  + Vector3.new(0, 60,0)
  162.     swordOut()
  163.     game:GetService("Debris"):AddItem(force,.5)
  164.     wait(1)
  165.     swordUp()
  166.  
  167.     damage = slash_damage
  168. end
  169.  
  170. function swordUp()
  171.     Tool.GripForward = Vector3.new(-1,0,0)
  172.     Tool.GripRight = Vector3.new(0,1,0)
  173.     Tool.GripUp = Vector3.new(0,0,1)
  174. end
  175.  
  176. function swordOut()
  177.     Tool.GripForward = Vector3.new(0,0,1)
  178.     Tool.GripRight = Vector3.new(0,-1,0)
  179.     Tool.GripUp = Vector3.new(-1,0,0)
  180. end
  181.  
  182. function swordAcross()
  183.     -- parry
  184. end
  185.  
  186.  
  187. Tool.Enabled = true
  188. local last_attack = 0
  189. function onActivated()
  190.  
  191.     if not Tool.Enabled then
  192.         return
  193.     end
  194.  
  195.     Tool.Enabled = false
  196.  
  197.     local character = Tool.Parent;
  198.     local humanoid = character.Humanoid
  199.     if humanoid == nil then
  200.         print("Humanoid not found")
  201.         return
  202.     end
  203.  
  204.     t = r.Stepped:wait()
  205.  
  206.     if (t - last_attack < .2) then
  207.         pcall(function()
  208.             lunge()
  209.         end)
  210.     else
  211.         pcall(function()
  212.             attack()
  213.         end)
  214.     end
  215.  
  216.     last_attack = t
  217.  
  218.     --wait(.5)
  219.  
  220.     Tool.Enabled = true
  221. end
  222.  
  223.  
  224. function onEquipped()
  225.     UnsheathSound:play()
  226. end
  227.  
  228.  
  229. Tool.Activated:connect(onActivated)
  230. Tool.Equipped:connect(onEquipped)
  231.  
  232.  
  233. connection = sword.Touched:connect(blow)
  234. end))
  235. Script1.Name = "Darkheart"
  236. Script1.Parent = mas
  237. table.insert(cors,sandbox(Script1,function()
  238. local Tool0 = Instance.new("Tool")
  239. local Part2 = Instance.new("Part")
  240. local SpecialMesh3 = Instance.new("SpecialMesh")
  241. local Sparkles7 = Instance.new("Sparkles")
  242. local Sparkles8 = Instance.new("Sparkles")
  243. Tool0.Name = "Darkheart"
  244. Tool0.Parent = owner['Backpack']
  245. Tool0.TextureId = "http://www.roblox.com/asset/?id=16868189"
  246. Tool0.Grip = CFrame.new(0, 0, -1.5, 0, 0, 1, 1, 0, 0, 0, 1, 0)
  247. Tool0.GripForward = Vector3.new(-1, -0, -0)
  248. Tool0.GripPos = Vector3.new(0, 0, -1.5)
  249. Tool0.GripRight = Vector3.new(0, 1, 0)
  250. Tool0.GripUp = Vector3.new(0, 0, 1)
  251. Part2.Name = "Handle"
  252. Part2.Parent = Tool0
  253. Part2.CFrame = CFrame.new(-18.6640892, 0.400011003, 9.11577606, -1, -1.7095083e-06, -2.80470631e-05, 1.70952512e-06, -1, -6.01045372e-07, -2.80470631e-05, -6.01093348e-07, 1)
  254. Part2.Orientation = Vector3.new(0, 0, 180)
  255. Part2.Position = Vector3.new(-18.6640892, 0.400011003, 9.11577606)
  256. Part2.Rotation = Vector3.new(0, 0, 180)
  257. Part2.Color = Color3.new(0.388235, 0.372549, 0.384314)
  258. Part2.Velocity = Vector3.new(-0.00113814184, 0.00240389677, -0.00323618972)
  259. Part2.Size = Vector3.new(1, 0.800000012, 4)
  260. Part2.BottomSurface = Enum.SurfaceType.Smooth
  261. Part2.BrickColor = BrickColor.new("Dark stone grey")
  262. Part2.Reflectance = 0.69999998807907
  263. Part2.RotVelocity = Vector3.new(-0.00962590333, 0.00151013187, -0.0043386193)
  264. Part2.TopSurface = Enum.SurfaceType.Smooth
  265. Part2.brickColor = BrickColor.new("Dark stone grey")
  266. SpecialMesh3.Parent = Part2
  267. SpecialMesh3.MeshId = "rbxasset://fonts/sword.mesh"
  268. SpecialMesh3.Scale = Vector3.new(0.800000012, 0.800000012, 1)
  269. SpecialMesh3.VertexColor = Vector3.new(0, 0, 0)
  270. SpecialMesh3.TextureId = "rbxasset://textures/SwordTexture.png"
  271. SpecialMesh3.MeshType = Enum.MeshType.FileMesh
  272. Sparkles7.Name = "Sparkles1"
  273. Sparkles7.Parent = Part2
  274. Sparkles7.SparkleColor = Color3.fromRGB(66, 66, 66)
  275. Sparkles8.Name = "Sparkles1"
  276. Sparkles8.Parent = Part2
  277. Sparkles8.SparkleColor = Color3.fromRGB(0, 0, 0)
  278.  
  279. -------- OMG HAX
  280.  
  281. local r = game:service("RunService")
  282.  
  283.  
  284. local damage = 20
  285.  
  286.  
  287. local slash_damage = 18
  288. local lunge_damage = 36
  289.  
  290. local sword = Part2
  291. local Tool = Tool0
  292.  
  293.  
  294. local SlashSound = Instance.new("Sound")
  295. SlashSound.SoundId = "rbxasset://sounds\\swordslash.wav"
  296. SlashSound.Parent = sword
  297. SlashSound.Volume = .7
  298.  
  299. local LungeSound = Instance.new("Sound")
  300. LungeSound.SoundId = "rbxasset://sounds\\swordlunge.wav"
  301. LungeSound.Parent = sword
  302. LungeSound.Volume = .6
  303.  
  304. local UnsheathSound = Instance.new("Sound")
  305. UnsheathSound.SoundId = "rbxasset://sounds\\unsheath.wav"
  306. UnsheathSound.Parent = sword
  307. UnsheathSound.Volume = 1
  308.  
  309. function DarkKill(character, humanoid, attacker)
  310.  
  311.     if (character:FindFirstChild("ForceField") ~= nil) then return end
  312.  
  313.     local childs = character:GetChildren()
  314.  
  315.     local colors = {}
  316.  
  317.     tagHumanoid(humanoid, attacker)
  318.     humanoid.Health = 0
  319.  
  320.     for i=1,#childs do
  321.         if (childs[i].className == "Part") then
  322.             colors[i] = childs[i].BrickColor
  323.             childs[i].BrickColor = BrickColor.new(26)
  324.             childs[i].CanCollide = true
  325.             childs[i].Anchored = true
  326.         end
  327.     end
  328.  
  329.     wait(.25)
  330.    
  331.     for i=1,#childs do
  332.         if (childs[i].className == "Part") then
  333.             local b = Instance.new("BodyVelocity")
  334.             b.velocity = Vector3.new(math.random() - .5, 0, math.random() - .5).unit * 80
  335.             b.maxForce = Vector3.new(1e5,1e5,1e5)
  336.             b.Parent = childs[i]
  337.         end
  338.     end
  339.  
  340.     for i=1,#childs do
  341.         if (childs[i].className == "Part") then
  342.             childs[i].Anchored = false
  343.         end
  344.     end
  345.  
  346.    
  347.    
  348.  
  349.    
  350.  
  351.  
  352.  
  353. end
  354.  
  355.  
  356.  
  357.  
  358. function blow(hit)
  359.     local humanoid = hit.Parent:findFirstChild("Humanoid")
  360.     local vCharacter = Tool.Parent
  361.     local vPlayer = game.Players:playerFromCharacter(vCharacter)
  362.     local hum = vCharacter:findFirstChild("Humanoid") -- non-nil if tool held by a character
  363.     if humanoid~=nil and humanoid ~= hum and hum ~= nil then
  364.         -- final check, make sure sword is in-hand
  365.  
  366.         local right_arm = vCharacter:FindFirstChild("Right Arm")
  367.         if (right_arm ~= nil) then
  368.             local joint = right_arm:FindFirstChild("RightGrip")
  369.             if (joint ~= nil and (joint.Part0 == sword or joint.Part1 == sword)) then
  370.                 hum.Health = hum.Health + (damage * .4)
  371.                 if humanoid.Health > damage then
  372.                     tagHumanoid(humanoid, vPlayer)
  373.                     humanoid:TakeDamage(damage)
  374.                 else
  375.                     DarkKill(humanoid.Parent, humanoid, vPlayer)
  376.                 end
  377.             end
  378.         end
  379.  
  380.  
  381.     end
  382. end
  383.  
  384.  
  385.  
  386. function tagHumanoid(humanoid, player)
  387.     local creator_tag = Instance.new("ObjectValue")
  388.     creator_tag.Value = player
  389.     creator_tag.Name = "creator"
  390.     creator_tag.Parent = humanoid
  391.     game.Debris:AddItem(creator_tag, 1)
  392. end
  393.  
  394.  
  395.  
  396.  
  397. function attack()
  398.     damage = slash_damage
  399.     SlashSound:play()
  400.     local anim = Instance.new("StringValue")
  401.     anim.Name = "toolanim"
  402.     anim.Value = "Slash"
  403.     anim.Parent = Tool
  404. end
  405.  
  406. function lunge()
  407.     damage = lunge_damage
  408.  
  409.     LungeSound:play()
  410.  
  411.     local anim = Instance.new("StringValue")
  412.     anim.Name = "toolanim"
  413.     anim.Value = "Lunge"
  414.     anim.Parent = Tool
  415.    
  416.     local torso = (Tool.Parent:FindFirstChild("Torso") or Tool.Parent:FindFirstChild("HumanoidRootPart"))
  417.    
  418.     --[[
  419.     local force = Instance.new("BodyVelocity")
  420.     force.velocity = Vector3.new(0,10,0) --(Tool.Parent:FindFirstChild("Torso") or Tool.Parent:FindFirstChild("HumanoidRootPart")).CFrame.lookVector * 80
  421.     force.Parent = torso
  422.     --]]
  423.     wait(.25)
  424.     swordOut()
  425.     game:GetService("Debris"):AddItem(force,.25)
  426.     wait(1)
  427.     swordUp()
  428.  
  429.     damage = slash_damage
  430. end
  431.  
  432. function swordUp()
  433.     Tool.GripForward = Vector3.new(-1,0,0)
  434.     Tool.GripRight = Vector3.new(0,1,0)
  435.     Tool.GripUp = Vector3.new(0,0,1)
  436. end
  437.  
  438. function swordOut()
  439.     Tool.GripForward = Vector3.new(0,0,1)
  440.     Tool.GripRight = Vector3.new(0,-1,0)
  441.     Tool.GripUp = Vector3.new(-1,0,0)
  442. end
  443.  
  444. function swordAcross()
  445.     -- parry
  446. end
  447.  
  448.  
  449. Tool.Enabled = true
  450. local last_attack = 0
  451. function onActivated()
  452.  
  453.     if not Tool.Enabled then
  454.         return
  455.     end
  456.  
  457.     Tool.Enabled = false
  458.  
  459.     local character = Tool.Parent;
  460.     local humanoid = character.Humanoid
  461.     if humanoid == nil then
  462.         print("Humanoid not found")
  463.         return
  464.     end
  465.  
  466.     t = r.Stepped:wait()
  467.  
  468.     if (t - last_attack < .2) then
  469.         pcall(function()
  470.             lunge()
  471.         end)
  472.     else
  473.         pcall(function()
  474.             attack()
  475.         end)
  476.     end
  477.  
  478.     last_attack = t
  479.  
  480.     --wait(.5)
  481.  
  482.     Tool.Enabled = true
  483. end
  484.  
  485.  
  486. function onEquipped()
  487.     UnsheathSound:play()
  488. end
  489.  
  490.  
  491. Tool.Activated:connect(onActivated)
  492. Tool.Equipped:connect(onEquipped)
  493.  
  494.  
  495. connection = sword.Touched:connect(blow)
  496. end))
  497. Script2.Name = "Illumina"
  498. Script2.Parent = mas
  499. table.insert(cors,sandbox(Script2,function()
  500. local Tool0 = Instance.new("Tool")
  501. local Part2 = Instance.new("Part")
  502. local SpecialMesh3 = Instance.new("SpecialMesh")
  503. local Sparkles4 = Instance.new("Sparkles")
  504. Tool0.Name = "Illumina"
  505. Tool0.Parent = owner['Backpack']
  506. Tool0.TextureId = "http://www.roblox.com/asset/?id=16620737 "
  507. Tool0.Grip = CFrame.new(0, 0, -1.5, 0, 0, 1, 1, 0, 0, 0, 1, 0)
  508. Tool0.GripForward = Vector3.new(-1, -0, -0)
  509. Tool0.GripPos = Vector3.new(0, 0, -1.5)
  510. Tool0.GripRight = Vector3.new(0, 1, 0)
  511. Tool0.GripUp = Vector3.new(0, 0, 1)
  512. Part2.Name = "Handle"
  513. Part2.Parent = Tool0
  514. Part2.CFrame = CFrame.new(-19.6641598, 0.400011986, 9.11567211, 1, 2.05230458e-06, 9.50961635e-07, -2.05230504e-06, 1, 7.00738781e-07, -9.50960157e-07, -7.00740713e-07, 1)
  515. Part2.Position = Vector3.new(-19.6641598, 0.400011986, 9.11567211)
  516. Part2.Color = Color3.new(0, 0.12549, 0.376471)
  517. Part2.Velocity = Vector3.new(0.00569992978, 0.000912517484, -0.00128903938)
  518. Part2.Size = Vector3.new(1, 0.800000012, 4)
  519. Part2.BottomSurface = Enum.SurfaceType.Smooth
  520. Part2.BrickColor = BrickColor.new("Navy blue")
  521. Part2.Reflectance = 1
  522. Part2.RotVelocity = Vector3.new(-0.0109592956, -0.00260779588, -0.00672908593)
  523. Part2.TopSurface = Enum.SurfaceType.Smooth
  524. Part2.brickColor = BrickColor.new("Navy blue")
  525. SpecialMesh3.Parent = Part2
  526. SpecialMesh3.MeshId = "rbxasset://fonts/sword.mesh"
  527. SpecialMesh3.VertexColor = Vector3.new(1, 1, 0)
  528. SpecialMesh3.MeshType = Enum.MeshType.FileMesh
  529. Sparkles4.Parent = Part2
  530. Sparkles4.Color = Color3.new(1.01389, 1, 1)
  531. Sparkles4.SparkleColor = Color3.new(0.572549, 0.0980392, 1)
  532.  
  533. -------- OMG HAX
  534.  
  535. local r = game:service("RunService")
  536.  
  537.  
  538. local damage = 10
  539.  
  540.  
  541. local slash_damage = 20
  542. local lunge_damage = 40
  543.  
  544. local sword = Part2
  545. local Tool = Tool0
  546.  
  547.  
  548. local SlashSound = Instance.new("Sound")
  549. SlashSound.SoundId = "rbxasset://sounds\\swordslash.wav"
  550. SlashSound.Parent = sword
  551. SlashSound.Volume = .7
  552.  
  553. local LungeSound = Instance.new("Sound")
  554. LungeSound.SoundId = "rbxasset://sounds\\swordlunge.wav"
  555. LungeSound.Parent = sword
  556. LungeSound.Volume = .6
  557.  
  558. local UnsheathSound = Instance.new("Sound")
  559. UnsheathSound.SoundId = "rbxasset://sounds\\unsheath.wav"
  560. UnsheathSound.Parent = sword
  561. UnsheathSound.Volume = 1
  562.  
  563.  
  564.  
  565.  
  566.  
  567.  
  568. function blow(hit)
  569.     local humanoid = hit.Parent:findFirstChild("Humanoid")
  570.     local vCharacter = Tool.Parent
  571.     local vPlayer = game.Players:playerFromCharacter(vCharacter)
  572.     local hum = vCharacter:findFirstChild("Humanoid") -- non-nil if tool held by a character
  573.     if humanoid~=nil and humanoid ~= hum and hum ~= nil then
  574.         -- final check, make sure sword is in-hand
  575.  
  576.         local right_arm = vCharacter:FindFirstChild("Right Arm")
  577.         if (right_arm ~= nil) then
  578.             local joint = right_arm:FindFirstChild("RightGrip")
  579.             if (joint ~= nil and (joint.Part0 == sword or joint.Part1 == sword)) then
  580.                 tagHumanoid(humanoid, vPlayer)
  581.                 humanoid:TakeDamage(damage)
  582.  
  583.             end
  584.         end
  585.  
  586.  
  587.     end
  588. end
  589.  
  590.  
  591.  
  592. function tagHumanoid(humanoid, player)
  593.     local creator_tag = Instance.new("ObjectValue")
  594.     creator_tag.Value = player
  595.     creator_tag.Name = "creator"
  596.     creator_tag.Parent = humanoid
  597.     game.Debris:AddItem(creator_tag, 1)
  598. end
  599.  
  600.  
  601.  
  602. function attack()
  603.     damage = slash_damage
  604.     SlashSound:play()
  605.     local anim = Instance.new("StringValue")
  606.     anim.Name = "toolanim"
  607.     anim.Value = "Slash"
  608.     anim.Parent = Tool
  609. end
  610.  
  611. function lunge()
  612.     damage = lunge_damage
  613.  
  614.     LungeSound:play()
  615.  
  616.     local anim = Instance.new("StringValue")
  617.     anim.Name = "toolanim"
  618.     anim.Value = "Lunge"
  619.     anim.Parent = Tool
  620.    
  621.     local torso = (Tool.Parent:FindFirstChild("Torso") or Tool.Parent:FindFirstChild("HumanoidRootPart"))
  622.    
  623.     local force = Instance.new("BodyVelocity")
  624.     force.velocity = Vector3.new(0,80,0) --(Tool.Parent:FindFirstChild("Torso") or Tool.Parent:FindFirstChild("HumanoidRootPart")).CFrame.lookVector * 80
  625.     force.Parent = torso
  626.     wait(.25)
  627.     force.velocity = (torso.CFrame.lookVector * 120)  + Vector3.new(0, 60,0)
  628.     swordOut()
  629.     game:GetService("Debris"):AddItem(force,.5)
  630.     wait(1)
  631.     swordUp()
  632.  
  633.     damage = slash_damage
  634. end
  635.  
  636. function swordUp()
  637.     Tool.GripForward = Vector3.new(-1,0,0)
  638.     Tool.GripRight = Vector3.new(0,1,0)
  639.     Tool.GripUp = Vector3.new(0,0,1)
  640. end
  641.  
  642. function swordOut()
  643.     Tool.GripForward = Vector3.new(0,0,1)
  644.     Tool.GripRight = Vector3.new(0,-1,0)
  645.     Tool.GripUp = Vector3.new(-1,0,0)
  646. end
  647.  
  648. function swordAcross()
  649.     -- parry
  650. end
  651.  
  652.  
  653. Tool.Enabled = true
  654. local last_attack = 0
  655. function onActivated()
  656.  
  657.     if not Tool.Enabled then
  658.         return
  659.     end
  660.  
  661.     Tool.Enabled = false
  662.  
  663.     local character = Tool.Parent;
  664.     local humanoid = character.Humanoid
  665.     if humanoid == nil then
  666.         print("Humanoid not found")
  667.         return
  668.     end
  669.  
  670.     t = r.Stepped:wait()
  671.  
  672.     if (t - last_attack < .2) then
  673.         pcall(function()
  674.             lunge()
  675.         end)
  676.     else
  677.         pcall(function()
  678.             attack()
  679.         end)
  680.     end
  681.  
  682.     last_attack = t
  683.  
  684.     --wait(.5)
  685.  
  686.     Tool.Enabled = true
  687. end
  688.  
  689.  
  690. function onEquipped()
  691.     UnsheathSound:play()
  692. end
  693.  
  694.  
  695. Tool.Activated:connect(onActivated)
  696. Tool.Equipped:connect(onEquipped)
  697.  
  698.  
  699. connection = sword.Touched:connect(blow)
  700. end))
  701. for i,v in pairs(mas:GetChildren()) do
  702.     v.Parent = owner.Character
  703.     pcall(function() v:MakeJoints() end)
  704. end
  705. mas:Destroy()
  706. for i,v in pairs(cors) do
  707.     spawn(function()
  708.         pcall(v)
  709.     end)
  710. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement