Development secrets in Alchemist Dungeon. Minimap
This post inspired by @noah-beckman question about how made the minimap in this game
So, let's start answering
First of all, the game zone is the matrix of tiles [N+2,N+2], where N - is dungeon size, so it makes easier to create level map. After the generation of dungeon I use loop [0..N+1,0..N+1] to create a level texture [N+2,N+2] pixels, which will be used later. Blue pixels shows walls and white - free space. Also I create a black fog of war texture with same size.
Next, the step-by-step explanation of map creation called every frame: 1. Copy level texture created earlier 2. Loop [0..N+1,0..N+1] to add info about exit and gas locations 3. Add the location of the player by transforming the coords with Mathf.Round function 4. Apply the changes for level texture copy 5. Loop [0..N+1,0..N+1] and calculate the distance between pixel and player coords. If it less than 5, set current pixel on fog or war texture to blank 6. Apply the changes for fog of war texture 7. Create blank texture [N+2,N+2] pixels 8. Loop [0..N+1,0..N+1] to fill created texture with combinig info of two previous textures. If fog of war pixel is black, add the black pixel, otherwise add the pixel from level with objects texture 9. Apply changes and transform to sprite 10. Show the sprite in UI
The image below represents how it works in game:

If you want to play the game: https://ldjam.com/events/ludum-dare/42/alchemist-dungeon
P.S: if the game got the 50 rating I'll post the explanation of dungeon generation algorithm