Refactored inventory some so that the UI is not so knowing of the internals.
This commit is contained in:
parent
e0e7a1027c
commit
0878a9e978
8 changed files with 90 additions and 92 deletions
|
@ -1,6 +1,7 @@
|
|||
#pragma once
|
||||
#include "components.hpp"
|
||||
#include <nlohmann/json.hpp>
|
||||
#include "levelmanager.hpp"
|
||||
|
||||
namespace components {
|
||||
using namespace nlohmann;
|
||||
|
@ -26,5 +27,7 @@ namespace components {
|
|||
int item_index(std::string id);
|
||||
|
||||
void erase_item(size_t at);
|
||||
|
||||
std::pair<bool, std::string> use(GameLevel &level, size_t at);
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue