Advertisement
Shadowsoda200

CUTALLTREES(lt2)

Jun 30th, 2019
138
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.63 KB | None | 0 0
  1. for i,v in pairs(game.Workspace:GetDescendants()) do
  2. if v.Name == "WoodSection" and v.Parent:FindFirstChild("CutEvent") then
  3. game.ReplicatedStorage.Interaction.ClientIsDragging:FireServer(v.Parent)
  4. game.ReplicatedStorage.Interaction.DestroyStructure:FireServer(v.Parent)
  5. end
  6. end
  7. game.Workspace.DescendantAdded:connect(function(Thing)
  8. wait(0.1)
  9. if Thing.Name == "WoodSection" and Thing.Parent:FindFirstChild("CutEvent") then
  10. game.ReplicatedStorage.Interaction.ClientIsDragging:FireServer(Thing.Parent)
  11. game.ReplicatedStorage.Interaction.DestroyStructure:FireServer(Thing.Parent)
  12. end
  13. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement