Hey,
just some suggestions to make the script better. Rather than right clicking all doors it should left click it, no human is going to right click on every door in the tunnels.
also rather than clicking the tile before opening the chest it should left click the chest and then open it just to simulate a more realistic play style.