diff --git a/calculate.js b/calculate.js
index 51428f1..07a6cb7 100644
--- a/calculate.js
+++ b/calculate.js
@@ -1,6 +1,6 @@
"use strict";
//Licensed under the Apache License 2.0. See license file for information.
-// Ardon Income Calculator v3.1.1 stable.
+// Ardon Income Calculator v3.2 stable.
// Written by Josh Mudge
// Ad Mejorem Dei Glorium
@@ -57,17 +57,23 @@ function calculate() {
console.log(metro)
var percent = +one + +design + +gov + +embassies + +capital + +infra + +chain + +town + +city + +metro
console.log(percent)
+ var bonus = +percent * 100
+ var bonus = bonus.toFixed(2);
+ console.log(bonus)
var total = +gold * +percent
console.log(total)
var total = +total + +gold
console.log(total)
var total = total.toFixed(0);
console.log(total)
- var date = Date();
- console.log(date)
+ var emeralds = +total / 100
+ console.log(emeralds)
+ //var date = Date();
+ //console.log(date)
//Show result
- alert("Your income is " + total + " Gold");
- document.getElementById("Income").innerHTML = "Your Income is " + total + " Gold per Minecraft Year (5 days)";
+ alert("Your Income is " + total + " Gold (or " + emeralds + " emeralds) per Minecraft Year (5 days)");
+ document.getElementById("Bonus").innerHTML = "Your Efficiency bonus is " + bonus + "%";
+ document.getElementById("Income").innerHTML = "Your Income is " + total + " Gold (or " + emeralds + " emeralds) per Minecraft Year (5 days)";
}
diff --git a/index.html b/index.html
index b846521..7afba94 100644
--- a/index.html
+++ b/index.html
@@ -52,6 +52,7 @@ Enter the number of metropolises in your empire. (See: https://ltlto.com/josh/mc
© Copyright 2017 Joshua Mudge