using Core.Annotations; using Core.Controllers; using Core.DI; using Core.Models.Eft.Common; using Core.Models.Eft.Hideout; using Core.Models.Eft.ItemEvent; using Core.Models.Enums; using Core.Models.Spt.Config; using Core.Servers; namespace Core.Callbacks; [Injectable] public class HideoutCallbacks : OnUpdate { protected HideoutController _hideoutController; protected ConfigServer _configServer; protected HideoutConfig _hideoutConfig; public HideoutCallbacks ( HideoutController hideoutController, ConfigServer configServer ) { _hideoutController = hideoutController; _configServer = configServer; _hideoutConfig = configServer.GetConfig(ConfigTypes.HIDEOUT); } /// /// Handle HideoutUpgrade event /// /// /// /// /// public ItemEventRouterResponse Upgrade(PmcData pmcData, HideoutUpgradeRequestData info, string sessionID, ItemEventRouterResponse output) { // _hideoutController.StartUpgrade(pmcData, info, sessionID, output); // TODO: HideoutController is not implemented rn return output; } /// /// Handle HideoutUpgradeComplete event /// /// /// /// /// public ItemEventRouterResponse UpgradeComplete(PmcData pmcData, HideoutUpgradeCompleteRequestData info, string sessionID, ItemEventRouterResponse output) { // _hideoutController.UpgradeComplete(pmcData, info, sessionID, output); // TODO: HideoutController is not implemented rn return output; } /// /// Handle HideoutPutItemsInAreaSlots /// /// /// /// /// public ItemEventRouterResponse PutItemsInAreaSlots(PmcData pmcData, HideoutPutItemInRequestData info, string sessionID) { // return _hideoutController.PutItemsInAreaSlots(pmcData, info, sessionID); // TODO: HideoutController is not implemented rn throw new NotImplementedException(); } /// /// Handle HideoutTakeItemsFromAreaSlots event /// /// /// /// /// public ItemEventRouterResponse TakeItemsFromAreaSlots(PmcData pmcData, HideoutTakeItemOutRequestData info, string sessionID) { // return _hideoutController.TakeItemsFromAreaSlots(pmcData, info, sessionID); // TODO: HideoutController is not implemented rn throw new NotImplementedException(); } /// /// Handle HideoutToggleArea event /// /// /// /// /// public ItemEventRouterResponse ToggleArea(PmcData pmcData, HideoutToggleAreaRequestData info, string sessionID) { // return _hideoutController.ToggleArea(pmcData, info, sessionID); // TODO: HideoutController is not implemented rn throw new NotImplementedException(); } /// /// Handle HideoutSingleProductionStart event /// /// /// /// /// public ItemEventRouterResponse SingleProductionStart(PmcData pmcData, HideoutSingleProductionStartRequestData info, string sessionID) { // return _hideoutController.SingleProductionStart(pmcData, info, sessionID); // TODO: HideoutController is not implemented rn throw new NotImplementedException(); } /// /// Handle HideoutScavCaseProductionStart event /// /// /// /// /// public ItemEventRouterResponse ScavCaseProductionStart(PmcData pmcData, HideoutScavCaseStartRequestData info, string sessionID) { // return _hideoutController.ScavCaseProductionStart(pmcData, info, sessionID); // TODO: HideoutController is not implemented rn throw new NotImplementedException(); } /// /// Handle HideoutContinuousProductionStart /// /// /// /// /// public ItemEventRouterResponse ContinuousProductionStart(PmcData pmcData, HideoutContinuousProductionStartRequestData info, string sessionID) { // return _hideoutController.ContinuousProductionStart(pmcData, info, sessionID); // TODO: HideoutController is not implemented rn throw new NotImplementedException(); } /// /// Handle HideoutTakeProduction event /// /// /// /// /// public ItemEventRouterResponse TakeProduction(PmcData pmcData, HideoutTakeProductionRequestData info, string sessionID) { // return _hideoutController.TakeProduction(pmcData, info, sessionID); // TODO: HideoutController is not implemented rn throw new NotImplementedException(); } /// /// Handle HideoutQuickTimeEvent /// /// /// /// /// /// public ItemEventRouterResponse HandleQTEEvent(PmcData pmcData, HandleQTEEventRequestData info, string sessionID, ItemEventRouterResponse output) { // _hideoutController.HandleQTEEventOutcome(sessionID, pmcData, info, output); // TODO: HideoutController is not implemented rn return output; } /// /// Handle client/game/profile/items/moving - RecordShootingRangePoints /// /// /// /// /// /// public ItemEventRouterResponse RecordShootingRangePoints(PmcData pmcData, RecordShootingRangePoints info, string sessionID, ItemEventRouterResponse output) { // _hideoutController.RecordShootingRangePoints(sessionID, pmcData, info); // TODO: HideoutController is not implemented rn return output; } /// /// Handle client/game/profile/items/moving - RecordShootingRangePoints /// /// /// /// /// public ItemEventRouterResponse ImproveArea(PmcData pmcData, HideoutImproveAreaRequestData info, string sessionID) { // return _hideoutController.ImproveArea(sessionID, pmcData, info); // TODO: HideoutController is not implemented rn throw new NotImplementedException(); } /// /// Handle client/game/profile/items/moving - HideoutCancelProductionCommand /// /// /// /// /// public ItemEventRouterResponse CancelProduction(PmcData pmcData, HideoutImproveAreaRequestData info, string sessionID) { // return _hideoutController.CancelProduction(sessionID, pmcData, info); // TODO: HideoutController is not implemented rn throw new NotImplementedException(); } /// /// Handle client/game/profile/items/moving - HideoutCircleOfCultistProductionStart /// /// /// /// /// public ItemEventRouterResponse CicleOfCultistProductionStart(PmcData pmcData, HideoutCircleOfCultistProductionStartRequestData info, string sessionID) { // return _hideoutController.CicleOfCultistProductionStart(sessionID, pmcData, info); // TODO: HideoutController is not implemented rn throw new NotImplementedException(); } /// /// Handle client/game/profile/items/moving - HideoutDeleteProductionCommand /// /// /// /// /// public ItemEventRouterResponse HideoutDeleteProductionCommand(PmcData pmcData, HideoutDeleteProductionRequestData info, string sessionID) { // return _hideoutController.HideoutDeleteProductionCommand(sessionID, pmcData, info); // TODO: HideoutController is not implemented rn throw new NotImplementedException(); } /// /// Handle client/game/profile/items/moving - HideoutCustomizationApply /// /// /// /// /// public ItemEventRouterResponse HideoutCustomizationApplyCommand(PmcData pmcData, HideoutCustomizationApplyRequestData info, string sessionID) { // return _hideoutController.HideoutCustomizationApply(sessionID, pmcData, info); // TODO: HideoutController is not implemented rn throw new NotImplementedException(); } public async Task OnUpdate(long timeSinceLastRun) { if (timeSinceLastRun > _hideoutConfig.RunIntervalSeconds) { // _hideoutController.Update(); return true; } return false; } public string GetRoute() { return "spt-hideout"; } }