Add soldiers upkeep
This commit is contained in:
parent
b8a3ab3efa
commit
6c0cdfd0ba
|
@ -1,6 +1,6 @@
|
||||||
"use strict";
|
"use strict";
|
||||||
//Licensed under the Apache License 2.0. See license file for information.
|
//Licensed under the Apache License 2.0. See license file for information.
|
||||||
// Ardon Income Calculator v3.3 stable.
|
// Ardon Income Calculator v3.4 stable.
|
||||||
// Written by Josh Mudge
|
// Written by Josh Mudge
|
||||||
// Ad Mejorem Dei Glorium
|
// Ad Mejorem Dei Glorium
|
||||||
|
|
||||||
|
@ -11,6 +11,7 @@ function calculate() {
|
||||||
//Get input
|
//Get input
|
||||||
|
|
||||||
var blocks = document.getElementById("blocks").value;
|
var blocks = document.getElementById("blocks").value;
|
||||||
|
var soldiers = document.getElementById("soldiers").value;
|
||||||
var one = document.getElementById("one").value;
|
var one = document.getElementById("one").value;
|
||||||
var gov = document.getElementById("gov").value;
|
var gov = document.getElementById("gov").value;
|
||||||
var design = document.getElementById("design").value;
|
var design = document.getElementById("design").value;
|
||||||
|
@ -35,6 +36,8 @@ function calculate() {
|
||||||
|
|
||||||
var gold = +blocks / 1000 * 100
|
var gold = +blocks / 1000 * 100
|
||||||
console.log(gold)
|
console.log(gold)
|
||||||
|
var gold = +gold - (soldiers * 50)
|
||||||
|
console.log(gold)
|
||||||
var infra = +infra / 1000 * 0.0025
|
var infra = +infra / 1000 * 0.0025
|
||||||
console.log(infra)
|
console.log(infra)
|
||||||
var one = +one / 1000 * 0.01
|
var one = +one / 1000 * 0.01
|
||||||
|
|
|
@ -10,7 +10,11 @@
|
||||||
<p>Enter the number of blocks eligable for rent excluding one "base of operations" you change. (1000 blocks = 1 emerald)</p>
|
<p>Enter the number of blocks eligable for rent excluding one "base of operations" you change. (1000 blocks = 1 emerald)</p>
|
||||||
<input type="number" id="blocks"></input>
|
<input type="number" id="blocks"></input>
|
||||||
<br><br><br><br>
|
<br><br><br><br>
|
||||||
Enter the number of blocks used for transportation, farmland, recreational purposes, soft infrastructure or utilities that is not buildings. (0.1% bonus)
|
Enter the number of soldiers you have. (upkeep cost of 50 gold/year)
|
||||||
|
<br><br>
|
||||||
|
<input type="number" id="soldiers"></input>
|
||||||
|
<br><br><br><br>
|
||||||
|
Enter the number of blocks used for transportation, farmland, recreational purposes, soft infrastructure or utilities that is not buildings. (0.25% bonus)
|
||||||
<br><br>
|
<br><br>
|
||||||
<input type="number" id="infra"></input>
|
<input type="number" id="infra"></input>
|
||||||
<br><br><br><br>
|
<br><br><br><br>
|
||||||
|
|
Loading…
Reference in New Issue