TheUnknownDiscord

Untitled

Oct 4th, 2021 (edited)
40
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Tool = Instance.new("Tool")
  2. Tool.Name = "Sword"
  3. Knife = Instance.new("Part")
  4. Knife.Name = "Handle"
  5. Knife.Parent = Tool
  6. Tool.Parent = owner.Character
  7. Knife.Size = Vector3.new(1, 1, 1)
  8. Knife.Massless = true
  9. Knife.CanCollide = true
  10. myhum = owner.Character.Humanoid
  11. local stab = Instance.new("Sound", owner.character.Head)
  12. stab.SoundId = "rbxassetid://199607491"
  13. stab.Volume = 0.5
  14. islunging = false
  15. Tool.Activated:connect(function()
  16. islunging = true
  17. stab.PlaybackSpeed = math.random(80, 125)/100
  18. stab:Stop()
  19. stab:Play()
  20. local Anim = Instance.new("StringValue")
  21. Anim.Name = "toolanim"
  22. Anim.Value = "Lunge"
  23. Anim.Parent = Tool
  24. wait(0.5)
  25. islunging = false
  26. end)
  27. roped = false
  28. function thinghere(plr,action,hit,target)
  29. if roped then
  30. alignposition:Destroy()
  31. roped = false
  32. else
  33. if islunging then
  34. roped = true
  35. local attachment0 = Instance.new("Attachment")
  36. attachment0.Parent = hit
  37. local attachment1 = Instance.new("Attachment")
  38. attachment1.Parent = Knife
  39. alignposition = Instance.new("AlignPosition")
  40. alignposition.Parent = Knife
  41. alignposition.Attachment0 = attachment0
  42. alignposition.Attachment1 = attachment1
  43. alignposition.RigidityEnabled = true
  44. attachment0.WorldCFrame = target
  45. end
  46. end
  47. end
  48. local E = Instance.new("RemoteEvent",NLS([[local E = script:FindFirstChildWhichIsA("RemoteEvent")
  49. on = false
  50. function onoff()
  51. if not on then
  52. on = true
  53. elseif on then
  54. on = false
  55. end
  56. end
  57. local Mouse = owner:GetMouse()
  58. function ButtonDown()
  59. if Mouse.Hit ~= nil then
  60. target = Mouse.Target
  61. onoff()
  62. E:FireServer("Down",Mouse.Target, Mouse.Hit)
  63. while on do
  64. task.wait()
  65. E:FireServer("Down", nil, Mouse.Hit)
  66. end
  67. end
  68. end
  69. Mouse.Button1Down:Connect(ButtonDown)
  70.  
  71. ]],owner.PlayerGui))
  72. E.OnServerEvent:Connect(thinghere)
RAW Paste Data