Selaa lähdekoodia

Prevent a world height of 0 from being set

tags/v0.0.1
Fen Dweller 5 vuotta sitten
vanhempi
commit
3ddff0de27
2 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. +1
    -1
      macrovision.html
  2. +1
    -1
      macrovision.js

+ 1
- 1
macrovision.html Näytä tiedosto

@@ -25,7 +25,7 @@
<div id="main-area">
<div id="options">
<div class="option-row">
<input type="number" id="options-height-value" value="10">
<input type="number" id="options-height-value" min="1" value="10">
<select id="options-height-unit">
<option>meters</option>
<option>kilometers</option>


+ 1
- 1
macrovision.js Näytä tiedosto

@@ -264,7 +264,7 @@ document.addEventListener("mousemove", (e) => {
});

function updateWorldHeight() {
const value = document.querySelector("#options-height-value").value;
const value = Math.max(1, document.querySelector("#options-height-value").value);
const unit = document.querySelector("#options-height-unit").value;
const oldHeight = config.height;



Loading…
Peruuta
Tallenna