using SptCommon.Annotations; using Core.Helpers; using Core.Models.Eft.Common; using Core.Models.Eft.Common.Tables; using Core.Models.Eft.ItemEvent; using Core.Models.Eft.Ragfair; using Core.Models.Eft.Trade; using Core.Models.Spt.Config; using Core.Models.Utils; using Core.Routers; using Core.Servers; using Core.Services; using Core.Utils; namespace Core.Controllers; [Injectable] public class TradeController( ISptLogger _logger, DatabaseService _databaseService, EventOutputHolder _eventOutputHolder, TradeHelper _tradeHelper, TimeUtil _timeUtil, HashUtil _hashUtil, ItemHelper _itemHelper, ProfileHelper _profileHelper, RagfairOfferHelper _ragfairOfferHelper, TraderHelper _traderHelper, HttpResponseUtil _httpResponseUtil, LocalisationService _localisationService, RagfairPriceService _ragfairPriceService, ConfigServer _configServer ) { protected RagfairConfig _ragfairConfig = _configServer.GetConfig(); protected TraderConfig _traderConfig = _configServer.GetConfig(); /// /// Handle TradingConfirm event /// /// /// /// /// public ItemEventRouterResponse ConfirmTrading( PmcData pmcData, ProcessBaseTradeRequestData request, string sessionId) { throw new NotImplementedException(); } /// /// Handle RagFairBuyOffer event /// /// /// /// /// public ItemEventRouterResponse ConfirmRagfairTrading( PmcData pmcData, ProcessRagfairTradeRequestData request, string sessionId) { throw new NotImplementedException(); } /// /// Buy an item off the flea sold by a trader /// /// Session id /// Player profile /// Offer being purchased /// request data from client /// Output to send back to client private void BuyTraderItemFromRagfair( string sessionId, PmcData pmcData, RagfairOffer fleaOffer, OfferRequest offerRequest, ItemEventRouterResponse output) { throw new NotImplementedException(); } /// /// Buy an item off the flea sold by a PMC /// /// Session id /// Player profile /// Offer being purchased /// request data from client /// Output to send back to client private void BuyPmcItemFromRagfair( string sessionId, PmcData pmcData, RagfairOffer fleaOffer, OfferRequest offerRequest, ItemEventRouterResponse output) { throw new NotImplementedException(); } /// /// Is the provided offerid and ownerid from a player made offer /// /// id of the offer /// Owner id /// true if offer was made by a player private bool IsPlayerOffer( string offerId, string offerOwnerId) { throw new NotImplementedException(); } /// /// Does Player have necessary trader loyalty to purchase flea offer /// /// Flea offer being bought /// Player profile /// True if player can buy offer private bool PlayerLacksTraderLoyaltyLevelToBuyOffer( RagfairOffer fleaOffer, PmcData pmcData) { throw new NotImplementedException(); } /// /// Handle SellAllFromSavage event /// /// /// /// /// public ItemEventRouterResponse SellScavItemsToFence( PmcData pmcData, SellScavItemsToFenceRequestData request, string sessionId) { throw new NotImplementedException(); } /// /// Send the specified rouble total to player as mail /// /// Session id /// amount of roubles to send /// Trader to sell items to private void MailMoneyToPlayer( string sessionId, int roublesToSend, string trader) { throw new NotImplementedException(); } /// /// Looks up an items children and gets total handbook price for them /// /// parent item that has children we want to sum price of /// All items (parent + children) /// Prices of items from handbook /// Trader being sold to, to perform buy category check against /// Rouble price private int GetPriceOfItemAndChildren( string parentItemId, List items, Dictionary handbookPrices, TraderBase traderDetails) { throw new NotImplementedException(); } }