This repository has been archived on 2022-01-16. You can view files and clone it, but cannot push or open issues or pull requests.
irreligious/src/model/resource/Religion.ts

21 lines
520 B
TypeScript
Raw Normal View History

2021-08-18 10:09:19 -05:00
/// <reference path="../GameConfig.ts" />
/// <reference path="../IResource.ts" />
class Religion implements IResource {
public readonly description: string;
public readonly resourceType: ResourceType = ResourceType.Religion;
public value: number;
public max: number;
constructor (
config: GameConfig,
public readonly name: string,
populationShare: number
) {
this.description = name;
this.max = config.worldPopulation;
this.value = config.worldPopulation * populationShare;
}
}