93 lines
3.7 KiB
C++
93 lines
3.7 KiB
C++
#ifndef BANK_HPP_INCLUDED
|
|
#define BANK_HPP_INCLUDED
|
|
|
|
#include "../../Core/Types/Convex.hpp"
|
|
#include <string>
|
|
#include <cstdint>
|
|
#include <vector>
|
|
|
|
/** @addtogroup Interfaces
|
|
* @{ */
|
|
/**
|
|
* @note All methods require the Bank to be currently Open to successfully return a proper result
|
|
*/
|
|
class Bank
|
|
{
|
|
public:
|
|
|
|
typedef enum WITHDRAW_MODE
|
|
{
|
|
ITEM,
|
|
NOTED
|
|
} WITHDRAW_MODE;
|
|
|
|
static bool IsOpen();
|
|
static bool Close();
|
|
static bool EnterPin();
|
|
|
|
static std::vector<std::int32_t> GetItemIDs();
|
|
static std::vector<std::string> GetItemNames();
|
|
static std::vector<std::int32_t> GetItemAmounts();
|
|
|
|
static std::int32_t GetItemAmount(std::int32_t ID);
|
|
static std::int32_t GetItemAmount(const std::string& Name);
|
|
|
|
static std::int32_t GetIndexOf(std::int32_t ID);
|
|
static std::int32_t GetIndexOf(const std::string& Name);
|
|
|
|
static Convex GetConvexByIndex(std::int32_t Index);
|
|
static Convex GetConvexOf(std::int32_t ID);
|
|
static Convex GetConvexOf(const std::string& Name);
|
|
|
|
static bool Contains(std::int32_t ID);
|
|
static bool Contains(const std::string& Name);
|
|
static bool Contains(const std::vector<std::int32_t>& IDs);
|
|
static bool Contains(const std::vector<std::string>& Names);
|
|
|
|
static bool ContainsAny(const std::vector<std::int32_t>& IDs);
|
|
static bool ContainsAny(const std::vector<std::string>& Names);
|
|
|
|
static bool ContainsOnly(std::int32_t ID);
|
|
static bool ContainsOnly(const std::string& Name);
|
|
static bool ContainsOnly(const std::vector<std::int32_t>& IDs);
|
|
static bool ContainsOnly(const std::vector<std::string>& Names);
|
|
|
|
static std::int32_t GetCurrentTab();
|
|
static std::int32_t GetTabOf(std::int32_t ID);
|
|
static std::int32_t GetTabOf(const std::string& Name);
|
|
static bool OpenTab(std::int32_t Tab);
|
|
|
|
static bool ScrollTo(std::int32_t ID, bool OpenRespectiveTab = false);
|
|
static bool ScrollTo(const std::string& Name, bool OpenRespectiveTab = false);
|
|
|
|
static bool InteractItemByIndex(std::int32_t ID, const std::string& Option);
|
|
static bool InteractItem(std::int32_t ID, const std::string& Option, bool OpenRespectiveTab = false);
|
|
static bool InteractItem(const std::string& Name, const std::string& Option, bool OpenRespectiveTab = false);
|
|
|
|
static bool WithdrawXOf(std::int32_t ID, std::int32_t Amount, bool OpenRespectiveTab = false);
|
|
static bool WithdrawXOf(const std::string& Name, std::int32_t Amount, bool OpenRespectiveTab = false);
|
|
static bool WithdrawAllOf(std::int32_t ID, bool OpenRespectiveTab = false);
|
|
static bool WithdrawAllOf(const std::string& Name, bool OpenRespectiveTab = false);
|
|
static bool WithdrawAllButOneOf(std::int32_t ID, bool OpenRespectiveTab = false);
|
|
static bool WithdrawAllButOneOf(const std::string& Name, bool OpenRespectiveTab = false);
|
|
|
|
static bool DepositAllOf(std::int32_t ID);
|
|
static bool DepositAllOf(const std::string& Name);
|
|
static bool DepositXOf(std::int32_t ID, std::int32_t Amount);
|
|
static bool DepositXOf(const std::string& Name, std::int32_t Amount);
|
|
static bool DepositAllExcept(const std::string& Name);
|
|
static bool DepositAllExcept(const std::vector<std::string>& Names);
|
|
static bool DepositAllExcept(std::int32_t ID);
|
|
static bool DepositAllExcept(const std::vector<std::int32_t>& IDs);
|
|
|
|
static bool DepositAll();
|
|
static bool DepositEquipment();
|
|
|
|
static WITHDRAW_MODE GetWithdrawMode();
|
|
static bool SetWithdrawMode(WITHDRAW_MODE Mode);
|
|
};
|
|
|
|
/** @} */
|
|
|
|
#endif // BANK_HPP_INCLUDED
|