Salem Map Tile Privacy Tool
![Post Post](./styles/salem/imageset/icon_post_target.gif)
I've mentioned it on Discord, but I've made a python tool which takes saved map tiles and removes player's bases. This is a step towards my goal of creating a public Salem map that also protects player privacy.
How it works:
The script imports each tile and looks for pavement. Currently it looks for stone, clay, brick, and dirt based on the pixel color. It then masks those pixels out and blurs the edges to make the edges a little more nature. Then the script looks to see what the most dominate color is on that pixel. It can then use that color to get what biome that tile is and uses a series the corresponding scrubber tile to cover up the player modified areas. It then saves the new tile in another folder.
Limitations
It's not perfect by any means. While it can detect black lines, often left by pavement only 1 tile wide, it messes up the environment too much to remove them, so I didn't include this. It also erases quarries, I might be able to remove this, but ultimately decided to leave this in and a couple other imaging artifacts so that you can't look at a tile and 100% know if it's been modified because of imprecision in the script or because it's hiding a base.
![Image](https://i.ibb.co/5TZJ3Yw/howitworks.png)
Examples:
Map of Area Around Providence
![Image](https://i.ibb.co/PFT49qw/Salem-Map-Resolution100.jpg)
How it works:
The script imports each tile and looks for pavement. Currently it looks for stone, clay, brick, and dirt based on the pixel color. It then masks those pixels out and blurs the edges to make the edges a little more nature. Then the script looks to see what the most dominate color is on that pixel. It can then use that color to get what biome that tile is and uses a series the corresponding scrubber tile to cover up the player modified areas. It then saves the new tile in another folder.
Limitations
It's not perfect by any means. While it can detect black lines, often left by pavement only 1 tile wide, it messes up the environment too much to remove them, so I didn't include this. It also erases quarries, I might be able to remove this, but ultimately decided to leave this in and a couple other imaging artifacts so that you can't look at a tile and 100% know if it's been modified because of imprecision in the script or because it's hiding a base.
![Image](https://i.ibb.co/5TZJ3Yw/howitworks.png)
Examples:
Map of Area Around Providence
![Image](https://i.ibb.co/PFT49qw/Salem-Map-Resolution100.jpg)