Added Era and Range to Sams and Ground Units V2

This commit is contained in:
WoodyXP 2023-06-22 16:10:48 +02:00
parent ca7c52ff67
commit 258f1136e2
3 changed files with 197 additions and 46 deletions

View File

@ -17,6 +17,7 @@ interface UnitBlueprint {
era?: string[];
label: string;
shortLabel: string;
range?: string;
loadouts: LoadoutBlueprint[];
filename: string;
}

File diff suppressed because it is too large Load Diff

View File

@ -35,6 +35,15 @@ export class UnitDatabase {
return null;
}
/* Gets a specific blueprint by range */
getByRange(range: string) {
for (let unit in this.blueprints) {
if (this.blueprints[unit].range === range)
return this.blueprints[unit];
}
return null;
}
/* Get all blueprints by role */
getByRole(role: string) {
var units = [];