refactor: migrate provinces generator to new module structure (#1295)

* refactor: migrate provinces generator to new module structure

* fix: after merge fixes of state

* refactor: fixed a bug so had to update tests
This commit is contained in:
Marc Emmanuel 2026-02-01 22:16:04 +01:00 committed by GitHub
parent 454178fa99
commit 0f19902a56
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 399 additions and 259 deletions

View file

@ -1,6 +1,7 @@
import type { Burg } from "../modules/burgs-generator";
import type { Culture } from "../modules/cultures-generator";
import type { PackedGraphFeature } from "../modules/features";
import type { Province } from "../modules/provinces-generator";
import type { River } from "../modules/river-generator";
import type { Route } from "../modules/routes-generator";
import type { State } from "../modules/states-generator";
@ -39,6 +40,7 @@ export interface PackedGraph {
religion: TypedArray; // cell religion id
state: number[]; // cell state id
area: TypedArray; // cell area
province: TypedArray; // cell province id
routes: Record<number, Record<number, number>>;
};
vertices: {
@ -56,4 +58,5 @@ export interface PackedGraph {
cultures: Culture[];
routes: Route[];
religions: any[];
provinces: Province[];
}