switch target to ES5

This commit is contained in:
Rudis Muiznieks 2021-08-23 09:16:45 -05:00
parent 20f5b326e9
commit ed54d98b63
4 changed files with 12 additions and 5 deletions

View file

@ -35,6 +35,9 @@
- higher makes recruitment harder
- political influence
- affects credibility, needed to enact policies
- global birth/death rates
- religious fanaticism
- affects follower growth/loss
- consumable resource type
- one-off actions that cost money
- ad blitz to improve credibility
@ -44,3 +47,6 @@
- policies
- can affect a wide range of stuff
- costs political influence to enact and maintain
- inter-religion relationships
- hostility between religiions
- holy wars (affects birth/death rate)

View file

@ -3,7 +3,7 @@
<head>
<title>irreligio.us</title>
<meta charset='utf-8'>
<script src='js/irreligious.js'></script>
<script src='js/irreligious.min.js'></script>
</head>
<body>
<div id='irreligious-game'></div>

View file

@ -112,9 +112,10 @@ class GameState {
{ value: 1e18, symbol: 'E' }
];
const rx: RegExp = /\.0+$|(\.[0-9]*[1-9])0+$/;
const item: vlookup =
lookup.slice().reverse()
.find((i: vlookup): boolean => num >= i.value);
let item: vlookup;
for (item of lookup.slice().reverse()) {
if (num >= item.value) break;
}
return item
? (num / item.value).toFixed(this.numberFormatDigits)
.replace(rx, '$1') + item.symbol

View file

@ -6,7 +6,7 @@
"removeComments": true,
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"target": "ES6",
"target": "ES5",
"module": "none"
}
}