diff --git a/Include/Game/Globals.hpp b/Include/Game/Globals.hpp index 2541a60..8240c85 100644 --- a/Include/Game/Globals.hpp +++ b/Include/Game/Globals.hpp @@ -71,15 +71,15 @@ namespace Globals const WidgetDef BANK_TABS_CONTAINER = { BANK_PARENT, 11 }; // Has all Tab children const WidgetDef BANK_ITEM_CONTAINER_WIDGET = { BANK_PARENT, 13 }; // Used for scrolling, contains all items, middle of the bank interface - const WidgetDef BANK_REARRANGE_MODE_SWAP = { BANK_PARENT, 18 }; - const WidgetDef BANK_REARRANGE_MODE_INSERT = { BANK_PARENT, 20 }; - const WidgetDef BANK_WITHDRAW_MODE_ITEM = { BANK_PARENT, 23 }; - const WidgetDef BANK_WITHDRAW_MODE_NOTED = { BANK_PARENT, 25 }; - const std::int32_t BANK_WITHDRAW_QUANTITY_CHILDREN[5] = { 29, 31, 33, 35, 37 }; // 1, 5, 10, x, all, uses BANK_PARENT - const WidgetDef BANK_SET_PLACEHOLDERS = { BANK_PARENT, 38 }; - const WidgetDef BANK_SEARCH = { BANK_PARENT, 40 }; - const WidgetDef BANK_DEPOSIT_ALL = { BANK_PARENT, 42 }; - const WidgetDef BANK_DEPOSIT_EQUIPMENT = { BANK_PARENT, 44 }; + const WidgetDef BANK_REARRANGE_MODE_SWAP = { BANK_PARENT, 20 }; // Text widget + const WidgetDef BANK_REARRANGE_MODE_INSERT = { BANK_PARENT, 22 }; + const WidgetDef BANK_WITHDRAW_MODE_ITEM = { BANK_PARENT, 25 }; + const WidgetDef BANK_WITHDRAW_MODE_NOTED = { BANK_PARENT, 27 }; + const std::int32_t BANK_WITHDRAW_QUANTITY_CHILDREN[5] = { 30, 32, 34, 36, 38 }; // 1, 5, 10, x, all, uses BANK_PARENT + const WidgetDef BANK_SET_PLACEHOLDERS = { BANK_PARENT, 41 }; + const WidgetDef BANK_SEARCH = { BANK_PARENT, 43 }; + const WidgetDef BANK_DEPOSIT_ALL = { BANK_PARENT, 45 }; + const WidgetDef BANK_DEPOSIT_EQUIPMENT = { BANK_PARENT, 47 }; const WidgetDef BANK_INVENTORY = { 15, 3 }; // When the bank is open, the Inventory has it's own widgets for items @@ -125,7 +125,7 @@ namespace Globals const WidgetDef EXCHANGE_AMOUNT = { EXCHANGE_PARENT, 25, 51 }; const WidgetDef EXCHANGE_PRICE = { EXCHANGE_PARENT, 25, 54 }; - const WidgetDef EXCHANGE_GUIDE = { EXCHANGE_PARENT, 25, 53 }; + const WidgetDef EXCHANGE_GUIDE = { EXCHANGE_PARENT, 25, 27 }; // 27? const WidgetDef EXCHANGE_CONFIRM = { EXCHANGE_PARENT, 25, 58 }; const WidgetDef EXCHANGE_ABORT = { EXCHANGE_PARENT, 23, 0 }; @@ -167,6 +167,17 @@ namespace Globals //************ Trade.cpp ************// const WidgetDef TRADE_SCREEN = { 335, 3 }; + const WidgetDef TRADE_SCREEN_ACCEPTED = { 335, 30 }; + const WidgetDef TRADE_SCREEN_CLOSE = { 335, 3, 13 }; + const WidgetDef TRADE_SCREEN_ACCEPT = { 335, 12 }; + const WidgetDef TRADE_SCREEN_DECLINE = { 335, 26 }; + + const WidgetDef TRADE_SCREEN_CONFIRM = { 334, 3 }; + const WidgetDef TRADE_SCREEN_CONFIRM_ACCEPTED = { 334, 4 }; + const WidgetDef TRADE_SCREEN_CONFIRM_CLOSE = { 334, 32 }; + const WidgetDef TRADE_SCREEN_CONFIRM_ACCEPT = { 334, 25 }; + const WidgetDef TRADE_SCREEN_CONFIRM_DECLINE = { 334, 26 }; + const std::int32_t TRADE_ITEM_CONTAINER_MY_OFFER = 90; const std::int32_t TRADE_ITEM_CONTAINER_THEIR_OFFER = 32858; diff --git a/Include/Game/Interfaces/Trade.hpp b/Include/Game/Interfaces/Trade.hpp index dec0d07..a1902dd 100644 --- a/Include/Game/Interfaces/Trade.hpp +++ b/Include/Game/Interfaces/Trade.hpp @@ -7,7 +7,17 @@ namespace Trade { - bool IsOpen(); + bool IsOpen(bool CheckConfirm = true); + + bool ConfirmOpen(); + + bool Close(bool AllowEsc = true); + + bool AcceptedOffer(); + + bool AcceptOffer(); + bool DeclineOffer(); + std::vector GetMyOfferItemIDs(); std::vector GetMyOfferItemNames(); diff --git a/Library/libAlpacaLibrary.a b/Library/libAlpacaLibrary.a index c0a0556..86a8d41 100644 Binary files a/Library/libAlpacaLibrary.a and b/Library/libAlpacaLibrary.a differ