This cleans up how I'm rendering the map but there's no way I can render a large map like this. It'd be way too big.

This commit is contained in:
Zed A. Shaw 2025-07-12 00:35:57 -04:00
parent 3b06105813
commit d9219a8c64
3 changed files with 74 additions and 42 deletions

View file

@ -22,6 +22,8 @@ namespace textures {
std::vector<int> ambient_light;
std::unordered_map<std::string, SpriteTexture> sprite_textures;
std::unordered_map<std::string, size_t> name_to_id;
std::unordered_map<wchar_t, sf::Sprite> map_sprites;
sf::Texture map_sprite_sheet{"./assets/map_tiles.png"};
};
void init();
@ -40,5 +42,7 @@ namespace textures {
const uint32_t* get_ceiling(size_t num);
sf::Sprite& get_map_sprite(wchar_t display);
size_t get_id(const std::string& name);
}