Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Tool = Instance.new("Tool")
- Tool.Name = "Sword"
- Knife = Instance.new("Part")
- Knife.Name = "Handle"
- Knife.Parent = Tool
- Tool.Parent = owner.Character
- Knife.Size = Vector3.new(1, 1, 1)
- Knife.Massless = true
- Knife.CanCollide = true
- myhum = owner.Character.Humanoid
- local stab = Instance.new("Sound", owner.character.Head)
- stab.SoundId = "rbxassetid://199607491"
- stab.Volume = 0.5
- islunging = false
- Tool.Activated:connect(function()
- islunging = true
- stab.PlaybackSpeed = math.random(80, 125)/100
- stab:Stop()
- stab:Play()
- local Anim = Instance.new("StringValue")
- Anim.Name = "toolanim"
- Anim.Value = "Lunge"
- Anim.Parent = Tool
- wait(0.5)
- islunging = false
- end)
- roped = false
- function thinghere(plr,action,hit,target)
- if roped then
- alignposition:Destroy()
- roped = false
- else
- if islunging then
- roped = true
- local attachment0 = Instance.new("Attachment")
- attachment0.Parent = hit
- local attachment1 = Instance.new("Attachment")
- attachment1.Parent = Knife
- alignposition = Instance.new("AlignPosition")
- alignposition.Parent = Knife
- alignposition.Attachment0 = attachment0
- alignposition.Attachment1 = attachment1
- alignposition.RigidityEnabled = true
- attachment0.WorldCFrame = target
- end
- end
- end
- local E = Instance.new("RemoteEvent",NLS([[local E = script:FindFirstChildWhichIsA("RemoteEvent")
- on = false
- function onoff()
- if not on then
- on = true
- elseif on then
- on = false
- end
- end
- local Mouse = owner:GetMouse()
- function ButtonDown()
- if Mouse.Hit ~= nil then
- target = Mouse.Target
- onoff()
- E:FireServer("Down",Mouse.Target, Mouse.Hit)
- while on do
- task.wait()
- E:FireServer("Down", nil, Mouse.Hit)
- end
- end
- end
- Mouse.Button1Down:Connect(ButtonDown)
- ]],owner.PlayerGui))
- E.OnServerEvent:Connect(thinghere)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement