using SPTarkov.DI.Annotations; using SPTarkov.Server.Core.Controllers; using SPTarkov.Server.Core.Models.Eft.Common; using SPTarkov.Server.Core.Utils; namespace SPTarkov.Server.Core.Callbacks; [Injectable] public class WeatherCallbacks( HttpResponseUtil _httpResponseUtil, WeatherController _weatherController ) { /// /// Handle client/weather /// /// /// /// Session/player id /// public ValueTask GetWeather(string url, EmptyRequestData _, string sessionID) { return new ValueTask(_httpResponseUtil.GetBody(_weatherController.Generate())); } /// /// Handle client/localGame/weather /// /// /// /// Session/player id /// public ValueTask GetLocalWeather(string url, EmptyRequestData _, string sessionID) { return new ValueTask( _httpResponseUtil.GetBody(_weatherController.GenerateLocal(sessionID)) ); } }