made coastlines a local call
code for layers refactored