Update survival.js
This commit is contained in:
parent
0440d37a21
commit
4b66340699
|
|
@ -313,6 +313,7 @@ window.addEventListener("load",function(){
|
||||||
var pricesDiv = document.getElementById("category-prices");
|
var pricesDiv = document.getElementById("category-prices");
|
||||||
pricesDiv.style.display = "none";
|
pricesDiv.style.display = "none";
|
||||||
for (var element in elementWorth) {
|
for (var element in elementWorth) {
|
||||||
|
if (elementWorth[element] <= 0) { continue }
|
||||||
var name = (elements[element].name||element).replace(/_/g, " ").replace("."," ").replace(/\w\S*/g, function(txt){return txt.charAt(0).toUpperCase() + txt.substr(1).toLowerCase();}).replace(" ",".");
|
var name = (elements[element].name||element).replace(/_/g, " ").replace("."," ").replace(/\w\S*/g, function(txt){return txt.charAt(0).toUpperCase() + txt.substr(1).toLowerCase();}).replace(" ",".");
|
||||||
// create text with the name of the element and its worth, separated by •
|
// create text with the name of the element and its worth, separated by •
|
||||||
var text = name+"="+elementWorth[element] + " • ";
|
var text = name+"="+elementWorth[element] + " • ";
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue