瀏覽代碼

Show how many of one entity another needs to eat per day

master
Fen Dweller 4 年之前
父節點
當前提交
c3f9500f77
共有 1 個檔案被更改,包括 10 行新增1 行删除
  1. +10
    -1
      macrovision.js

+ 10
- 1
macrovision.js 查看文件

@@ -645,6 +645,15 @@ function updateInfo() {
}
}
if (selectedEntity.currentView.energyIntake && prevSelectedEntity.currentView.energyValue) {
const consumeCount = math.divide(selectedEntity.currentView.energyIntake, prevSelectedEntity.currentView.energyValue);
console.log(consumeCount);
if (consumeCount > 0.1) {
text += selectedEntity.name + " needs to eat " + math.format(consumeCount, { precision: 1 }) + " of " + prevSelectedEntity.name + " per day" + "\n"
}
}
}
}
@@ -1330,7 +1339,7 @@ function makeEntity(info, views, sizes, forms = {}) {
}

if (config.autoCaloricValue && view.attributes.weight !== undefined && view.attributes.energyWorth === undefined) {
view.attributes.energyNeed = {
view.attributes.energyValue = {
name: "Caloric Value",
power: 3,
type: "energy",


Loading…
取消
儲存