19 lines
486 B
TypeScript
19 lines
486 B
TypeScript
/// <reference path="./Research.ts" />
|
|
|
|
class BuildingPermit extends Research {
|
|
constructor () {
|
|
super('Building Permit',
|
|
'Unlocks several new buildings you can build outside of your compounds.');
|
|
this.cost.money = 250000;
|
|
}
|
|
|
|
public isUnlocked (state: GameState): boolean {
|
|
if (this._isUnlocked) return true;
|
|
const compounds = state.getResource('cmpnd');
|
|
if (compounds.value > 0) {
|
|
this._isUnlocked = true;
|
|
}
|
|
return this._isUnlocked;
|
|
}
|
|
}
|