22class LegacyTradeableComponent {
26 ::ll::TypedStorage<1, 1, bool> mAddRecipeOnUpdate;
27 ::ll::TypedStorage<1, 1, bool> mResetLockedOnFirstTrade;
28 ::ll::TypedStorage<1, 1, bool> mWillingToBreed;
29 ::ll::TypedStorage<4, 4, int> mRiches;
30 ::ll::TypedStorage<4, 4, int> mTradeTier;
31 ::ll::TypedStorage<4, 4, int> mUpdateMerchantTimer;
32 ::ll::TypedStorage<8, 8, ::ActorUniqueID> mLastPlayerTradeID;
33 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::MerchantRecipeList>> mOffers;
34 ::ll::TypedStorage<8, 32, ::std::string> mDisplayName;
35 ::ll::TypedStorage<8, 24, ::std::vector<int>> mTradeRecipeFirstTime;
40 LegacyTradeableComponent& operator=(LegacyTradeableComponent
const&);
41 LegacyTradeableComponent(LegacyTradeableComponent
const&);
46 MCFOLD
void DecrementMerchantTimer();
48 MCFOLD
void IncrementTradeTier();
50 MCAPI LegacyTradeableComponent();
52 MCAPI ::TradeTable* _getTradeTable(
::Actor& owner);
54 MCAPI
bool _refreshTrades(
::Actor& owner);
56 MCAPI
void _updateMaxTradeTier(
::Actor& owner,
int tradeTier);
60 MCAPI ::UpdateTradePacket createDataPacket(
::Actor& owner, ::ContainerID containerID);
62 MCFOLD
bool getAddRecipeOnUpdate()
const;
64 MCFOLD ::std::string
const& getDisplayName()
const;
68 MCFOLD ::ActorUniqueID
const getLastPlayerTradeID()
const;
70 MCAPI ::MerchantRecipeList* getOffers(
::Actor& owner);
72 MCFOLD
bool getResetLockedOnFirstTrade()
const;
74 MCFOLD
int getRiches()
const;
76 MCFOLD
int getTradeTier()
const;
78 MCFOLD
int getUpdateMerchantTimer()
const;
81 MCAPI
void handleHaggleAudioCue(
::Actor& owner,
bool canPlayValidHaggleSound);
83 MCAPI
void initFromDefinition(
::Actor& actor);
86 MCAPI ::std::string
const& loadDisplayName(
::Actor& owner);
90 MCAPI
void notifyTrade(
::Actor& owner,
int recipeIndex,
int numTrades);
92 MCAPI ::LegacyTradeableComponent& operator=(::LegacyTradeableComponent&&);
96 MCAPI
void reloadComponent(
::Actor& actor);
98 MCAPI
void restockAllRecipes(
::Actor& owner);
100 MCFOLD
void setAddRecipeOnUpdate(
bool addRecipeOnUpdate);
108 MCFOLD
void setResetLockedOnFirstTrade(
bool resetLockedOnFirstTrade);
110 MCFOLD
void setRiches(
int riches);
112 MCFOLD
void setTradeTier(
int tier);
114 MCAPI
bool shouldConvertTrades(
::Actor& owner)
const;
116 MCAPI
bool shouldPersistTrades(
::Actor& owner)
const;
118 MCAPI
void updateTradeTier(
::Actor& owner);
120 MCAPI ~LegacyTradeableComponent();
126 MCAPI
static bool isUseNewTradeScreen(
::Actor const& owner);