Now systems.cpp is disconnected from levelmanager. That leaves the GUIs and then to completely remove it and clean up the api.

This commit is contained in:
Zed A. Shaw 2025-08-19 11:05:32 -04:00
parent 81e25f73bb
commit d5ff57e025
9 changed files with 106 additions and 89 deletions

View file

@ -128,7 +128,7 @@ namespace gui {
}
void LootUI::drop_item(DinkyECS::Entity item_id) {
System::drop_item($level, item_id);
System::drop_item(item_id);
update();
}
@ -137,14 +137,14 @@ namespace gui {
}
bool LootUI::occupied(guecs::Entity slot) {
return System::inventory_occupied($level, $target, $gui.name_for(slot));
return System::inventory_occupied($target, $gui.name_for(slot));
}
void LootUI::swap(guecs::Entity gui_a, guecs::Entity gui_b) {
if(gui_a != gui_b) {
auto& a_name = $gui.name_for(gui_a);
auto& b_name = $gui.name_for(gui_b);
System::inventory_swap($level, $target, a_name, b_name);
System::inventory_swap($target, a_name, b_name);
}
update();