I'm stumped, can someone help me write a code?

Hi, I am sorry, for asking people to make a script for me. I feel guilty!

But I have 3 trees. They are labeled tree_1, tree_2, and tree_3. I would like to have a script where if you click near the tree, you get one wood every 1 second. And you get up to 5 wood every tree. When you get all the trunks, it would disappear. Then it would come back in 10 minutes (600 seconds).

I would also like to use this script for when you click on something, you get it in your inventory, with any name I assign it to. For example: If I find this thing called stone, and click on it, I would get one stone every second and it would disappear when I get 5 stones, and it would come back in 10 minutes (600 seconds).

So in a nutshell: It’s basically like chopping down wood in minecraft.

THANKS!!!

P.S. For the image, lets just say I want to collect stone from the rocks, and collect wood from trees, using the same script, and for me to get rock using a tree script, I would just change the words in the coding.

And… what have you tried? Post some snippet of your code so we can help with a specific issue, because people won’t do your job for you.

Nope, I’ve been trying to code this all day and I cannot get it right. Goodbye, thought the community helps people instead of slapping me in the face and lick my computer until its brown.

The community helps people that help themselves.

The community is not a code charity