Files
SPT-Server-Build/Libraries/Core/Loaders/PostDBModLoader.cs
T
Chomp ac7b2daeba Renamed interface to IOnLoad
Added OnLoad mod
Expanded `OnLoadOrder` options
2025-02-08 12:18:57 +00:00

30 lines
702 B
C#

using Core.DI;
using Core.Models.External;
using Core.Models.Utils;
using SptCommon.Annotations;
namespace Core.Loaders;
[Injectable(InjectableTypeOverride = typeof(IOnLoad), TypePriority = OnLoadOrder.PostDBModLoader)]
public class PostDBModLoader(
ISptLogger<PostDBModLoader> _logger,
IEnumerable<IPostDBLoadMod> _postDbLoadMods
) : IOnLoad
{
public async Task OnLoad()
{
_logger.Info("Loading PostDBLoadMod...");
foreach (var postDbLoadMod in _postDbLoadMods)
{
postDbLoadMod.PostDBLoad();
}
_logger.Info("Finished loading PostDBLoadMod...");
}
public string GetRoute()
{
return "spt-post-db-mods";
}
}