Kaynağa Gözat

Popups and building tooltips use words, not raw numbers

tags/v0.0.6
Fen Dweller 5 yıl önce
ebeveyn
işleme
ac1b68b075
Veri tabanında bu imza için bilinen anahtar bulunamadı GPG Anahtar Kimliği: E80B35A6F11C3656
1 değiştirilmiş dosya ile 3 ekleme ve 3 silme
  1. +3
    -3
      gorge.js

+ 3
- 3
gorge.js Dosyayı Görüntüle

@@ -593,7 +593,7 @@ function initializeData() {
function registerListeners() {
document.querySelector("#tasty-micro").addEventListener("click", (e) => {
const add = eatPrey();
const text = "+" + round(add, 1) + " food";
const text = "+" + render(round(add, 1), 3) + " food";
const gulp = "*glp*";
clickPopup(text, "food", [e.clientX, e.clientY]);
clickPopup(gulp, "gulp", [e.clientX, e.clientY]);
@@ -1051,11 +1051,11 @@ function prodSummary(id) {
let list = [];

list.push(
{ "text": "Each " + buildings[id].name + " produces " + contributions[id].food + " food/sec" }
{ "text": "Each " + buildings[id].name + " produces " + render(belongings[id].count == 0 ? 0 : contributions[id].food / belongings[id].count, 3) + " food/sec" }
);

list.push(
{ "text": "Your " + render(belongings[id].count) + " " + (belongings[id].count == 1 ? buildings[id].name + " is" : buildings[id].plural + " are") + " producing " + round(contributions[id].food, 1) + " food/sec" }
{ "text": "Your " + render(belongings[id].count) + " " + (belongings[id].count == 1 ? buildings[id].name + " is" : buildings[id].plural + " are") + " producing " + render(contributions[id].food, 3) + " food/sec" }
);

let percentage = round(100 * contributions[id].food / currentProductivity["food"], 2);


Yükleniyor…
İptal
Kaydet