This commit is contained in:
wsh
2025-03-28 09:06:47 +09:00
parent a6998f0193
commit 0c5f601816
17 changed files with 481 additions and 145 deletions

View File

@@ -0,0 +1,31 @@
using System;
namespace XED.VirtualFactory
{
public class ResourceNeedsScanner : NeedsScanner
{
private readonly PortMap portMap;
public ResourceNeedsScanner(PortMap portMap)
{
this.portMap = portMap;
}
public override void Scanning()
{
GeneratePortCheck();
ScanningComplete();
}
private void GeneratePortCheck()
{
if(portMap.TryGetEmptyGeneratePorts(out var ports))
{
for (int i = 0; i < ports.Count; i++)
{
needs.Add(FactoryNeeds.GenerateLoad);
}
}
}
}
}