Refactor world bootstrap and allow empty startup worlds
This commit is contained in:
@@ -5,7 +5,6 @@ namespace SpaceGame.Api.Universe.Scenario;
|
||||
|
||||
internal static class LoaderSupport
|
||||
{
|
||||
internal const string DefaultFactionId = "sol-dominion";
|
||||
internal const float MinimumFactionCredits = 0f;
|
||||
internal const float MinimumRefineryOre = 0f;
|
||||
internal const float MinimumRefineryStock = 0f;
|
||||
@@ -97,7 +96,7 @@ internal static class LoaderSupport
|
||||
{
|
||||
if (!moduleDefinitions.TryGetValue(moduleId, out var definition))
|
||||
{
|
||||
return;
|
||||
throw new InvalidOperationException($"Module '{moduleId}' is not defined in static data.");
|
||||
}
|
||||
|
||||
station.Modules.Add(StationModuleRuntime.Create($"{station.Id}-module-{station.Modules.Count + 1}", definition));
|
||||
|
||||
Reference in New Issue
Block a user