-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add multiple layers support for map memory #36381
Conversation
0522560
to
ee44d41
Compare
8ac34ff
to
9148bcf
Compare
@@ -174,7 +175,7 @@ struct level_cache { | |||
float seen_cache[MAPSIZE_X][MAPSIZE_Y]; | |||
float camera_cache[MAPSIZE_X][MAPSIZE_Y]; | |||
lit_level visibility_cache[MAPSIZE_X][MAPSIZE_Y]; | |||
std::bitset<MAPSIZE_X *MAPSIZE_Y> map_memory_seen_cache; | |||
std::map<map_memory_layer, std::bitset<MAPSIZE_X *MAPSIZE_Y>> map_memory_seen_cache; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See #36392
I don't think we need multiple caches here, fundamentally both render modes render one tile at a time, so I think we can get away with just the one bit per tile.
In an ideal world, what I'd really like to happen is the player memorizes the actual map entities instead of symbols/tiles, but THAT requires pretty much starting from scratch wiring the feature up. |
Please also test if debug map preview is working correctly with the new map memory code. |
Will reopen after 0.E. |
Summary
SUMMARY: Infrastructure "Add multiple layers support for map memory"
Purpose of change
Allow fixing outstanding bugs with map memory. Combine Curses and Tiles code.
Describe the solution
Refactored map memory to store multiple layers.
Testing
Additional context
TODO:
.mm
files;.mm
file;