local animation = script:WaitForChild("Animation")
local prompt = script.Parent.ProximityPrompt
local Basic = script.Parent.Parent
local rockSound = game:GetService("SoundService").RockBreak
local TweenService = game:GetService("TweenService")
prompt.Triggered:Connect(function(player)
local Character = player.Character or player.CharacterAdded:Wait()
local Humanoid = Character:WaitForChild("Humanoid")
--local animationLoad = Humanoid:LoadAnimation(animation)
local Animator = Humanoid:FindFirstChildOfClass("Animator")
local anim = Animator:LoadAnimation(animation)
local pickaxe = game:GetService("ServerStorage").Pickaxe
local motor6D1 = game:GetService("ServerStorage").PickaxeR
local motor6D2 = game:GetService("ServerStorage")["Circle.001R"]
local motor6D3 = game:GetService("ServerStorage")["Circle.002R"]
local motor6D4 = game:GetService("ServerStorage").CubeR
local motor6D5 = game:GetService("ServerStorage")["Cube.001R"]
anim:Play()
pickaxe.Parent = player.Character["Right Arm"]
motor6D1.Parent = player.Character["Right Arm"]
motor6D2.Parent = player.Character["Right Arm"]
motor6D3.Parent = player.Character["Right Arm"]
motor6D4.Parent = player.Character["Right Arm"]
motor6D5.Parent = player.Character["Right Arm"]
motor6D1.Part0 = player.Character["Right Arm"]
motor6D1.Part1 = player.Character["Right Arm"].Pickaxe
motor6D2.Part0 = player.Character["Right Arm"]
motor6D2.Part1 = player.Character["Right Arm"].Pickaxe["Circle.001"]
motor6D3.Part0 = player.Character["Right Arm"]
motor6D3.Part1 = player.Character["Right Arm"].Pickaxe["Circle.002"]
motor6D4.Part0 = player.Character["Right Arm"]
motor6D4.Part1 = player.Character["Right Arm"].Pickaxe.Cube
motor6D5.Part0 = player.Character["Right Arm"]
motor6D5.Part1 = player.Character["Right Arm"].Pickaxe["Cube.001"]
Humanoid.WalkSpeed = 0
Humanoid.JumpHeight = 0
--Character.HumanoidRootPart.Position = script.Parent.Parent.TpToTreee.Position
prompt.Enabled = false
wait(200) -- break time
Basic.Parent = game:GetService("ReplicatedStorage")
prompt.Enabled = true
--script.Parent.Parent.Cylinder.Transparency = 0
anim:Stop()
pickaxe.Parent = game:GetService("ServerStorage")
motor6D1.Parent = game:GetService("ServerStorage")
motor6D2.Parent = game:GetService("ServerStorage")
motor6D3.Parent = game:GetService("ServerStorage")
motor6D4.Parent = game:GetService("ServerStorage")
motor6D5.Parent = game:GetService("ServerStorage")
rockSound:Play()
Humanoid.WalkSpeed = 13
Humanoid.JumpHeight = 7.2
player.Data.TreeCount.Value += player.Data.TreeCountGet.Value
local getText = player.PlayerGui.GetItems.treeGetText
local textGetClone = getText:Clone()
textGetClone.Parent = player.PlayerGui.GetItems
textGetClone.Visible = true
textGetClone.Name = "textGetClone"
local targetPosition = UDim2.new(0.882, 0, 0.532, 0)
local tweenInfo = TweenInfo.new(0.6)
local tween = TweenService:Create(textGetClone, tweenInfo, {Position = targetPosition})
tween:Play()
local getImage = player.PlayerGui.GetItems.treeGet
local getImageClone = getImage:Clone()
getImageClone.Parent = player.PlayerGui.GetItems
getImageClone.Visible = true
getImageClone.Name = "GetImageClone"
local targetPosition = UDim2.new(0.913, 0, 0.5, 0)
local tweenInfo = TweenInfo.new(0.6)
local tween = TweenService:Create(getImageClone, tweenInfo, {Position = targetPosition})
tween:Play()
wait(1.5)
getImageClone:Destroy()
textGetClone:Destroy()
wait(90) -- respawn time
Basic.Parent = workspace.Map["Luffy's Village"].Decorations
end)
So I have a motor6D I throw in the right hand of the player and connect it to the pickaxe, but for some reason, the part is in the player’s hand and only a stick in the player’s hand
What’s the problem, then, where exactly am I going wrong?