Lyle-Tafoya / Omega

My C++ fork of the 1987 roguelike "Omega"
GNU General Public License v3.0
29 stars 3 forks source link

Implement FOV #30

Open Lyle-Tafoya opened 9 months ago

Lyle-Tafoya commented 9 months ago

Right now the game reveals everything within 1 tile of the player without a torch, and everything within 2 tiles of the player with a torch. Some dungeon rooms will illuminate all at once when they are entered. Once a tile is revealed, it always shows what items are on that tile, even if they change when the player cannot see that tile anymore (ie. if a mob picks up an item). Mobs are currently drawn at any distance from the player as long as they are in line of sight (ie. no wall between them). This rudimentary system may have been good enough back in 1987, but it's about time we implemented a proper FOV wth recursive shadowcasting or something to that effect. Tiles which are not visible should be grayed out like in DCSS, and should only display whatever was visible last time the tile was within the player's FOV.

Lyle-Tafoya commented 9 months ago

In Rampart City and villages and other above-ground locations, the day/night cycle should have an impact on FOV distance.