Moved the creature dig action logic to its own subfunction.

I also made the worker dig more reliably
when they see something to dig.