derive threat cost dynamically

This commit is contained in:
2026-06-13 21:50:00 +02:00
parent 3716c2b734
commit 10c5ad678f
28 changed files with 498 additions and 79 deletions

View File

@@ -0,0 +1,22 @@
#pragma once
#include <map>
#include <string>
#include <vector>
#include "ShipLayout.h"
struct GameConfig;
struct ThreatCostTable
{
std::map<std::string, double> itemThreat;
double scrapThreat = 0.0;
};
ThreatCostTable computeThreatCostTable(const GameConfig& config);
double calculateShipThreatCost(const ThreatCostTable& table,
const GameConfig& config,
const std::string& shipId,
const std::vector<PlacedModule>& modules);