so i have this script where if the player activates the proximity prompt, it finds a tool in the character then prints the name of the tool (basically find the tool that the player is equipping)
ProximityPrompt.Triggered:Connect(function(player)
local tool = player.Character:FindFirstChildOfClass("Tool")
print(tool.Name)
end)
however, it doesnt print anything despite me equipping a tool. it also prints out this error
Workspace.WoodenPlaqueDisplayFrame.ProxPromptPart.Script:8: attempt to index nil with 'Name'
im seriously confused, did i do something wrong?
** You are now Level 9! **