Advertisement
Sungmingamerpro13

ArrowScript

Aug 11th, 2022
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.71 KB | None | 0 0
  1. local player = game.Players.LocalPlayer
  2. local character = player.Character or player.CharacterAdded:Wait()
  3. local HumanoidRootPart = character:WaitForChild("HumanoidRootPart")
  4.  
  5. local Bean = script:WaitForChild("Beam"):Clone()
  6.  
  7. local function CreateBean(Bean, Attachment0, Part)
  8. local Attachment1 = Part:FindFirstChild("Attachment")
  9.  
  10. if Attachment1 then
  11. Bean.Attachment0 = Attachment0
  12. Bean.Attachment1 = Attachment1
  13. end
  14. end
  15.  
  16. game.ReplicatedStorage.ArrrowEvent.OnClientEvent:Connect(function(Part, Value)
  17. if Value == true then
  18. local Attachment0 = HumanoidRootPart:FindFirstChild("RootRigAttachment")
  19. CreateBean(Bean, Attachment0, Part)
  20. Bean.Parent = character
  21. else
  22. Bean:Remove()
  23. end
  24. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement