Basic loot UI mostly working. Each time you open there's a torch and you can place it visually on any slot on your character.

This commit is contained in:
Zed A. Shaw 2025-06-03 13:43:16 -04:00
parent 4b34de2109
commit 5c47a0151c
13 changed files with 123 additions and 46 deletions

View file

@ -15,6 +15,7 @@ json load_test_data(const string &fname) {
}
TEST_CASE("camera control", "[map]") {
components::init();
LevelManager levels;
GameLevel level = levels.current();
auto &map = *level.map;
@ -32,6 +33,7 @@ TEST_CASE("camera control", "[map]") {
}
TEST_CASE("map placement test", "[map:placement]") {
components::init();
for(int i = 0; i < 20; i++) {
LevelManager levels;
GameLevel level = levels.current();

View file

@ -256,6 +256,7 @@ TEST_CASE("prototype circle algorithm", "[matrix:circle]") {
}
TEST_CASE("viewport iterator", "[matrix:viewport]") {
components::init();
size_t width = Random::uniform<size_t>(20, 22);
size_t height = Random::uniform<size_t>(21, 25);
shared_ptr<Map> map = make_map();
@ -279,6 +280,7 @@ TEST_CASE("viewport iterator", "[matrix:viewport]") {
}
TEST_CASE("random rectangle", "[matrix:rando_rect]") {
components::init();
for(int i = 0; i < 5; i++) {
shared_ptr<Map> map = make_map();
map->invert_space();
@ -303,6 +305,7 @@ TEST_CASE("random rectangle", "[matrix:rando_rect]") {
}
TEST_CASE("standard rectangle", "[matrix:rectangle]") {
components::init();
for(int i = 0; i < 5; i++) {
shared_ptr<Map> map = make_map();
auto wall_copy = map->walls();

View file

@ -7,6 +7,7 @@
using namespace fmt;
TEST_CASE("test texture management", "[textures]") {
components::init();
textures::init();
auto spider = textures::get("hairy_spider");
REQUIRE(spider.sprite != nullptr);