I have a dig treasure macro with a hotkey. It does not attempt to dig multiple times. I click the hotkey and target the ground where I want to dig. If it is not found, I click the hotkey again. Here is what mine looks like.
First I just add the shovel to a new macro
Then I just set it to use a stored object and target the current map I am using.
