ints are ints
This commit is contained in:
parent
422989bebc
commit
addbe74222
2 changed files with 5 additions and 5 deletions
|
@ -16,7 +16,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="input_container">
|
<div class="input_container">
|
||||||
<label for="currentShipCount">Ship count:</label>
|
<label for="currentShipCount">Ship count:</label>
|
||||||
<input id="currentShipCount" type="number" value="20"></input>
|
<input id="currentShipCount" type="number" value=20></input>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<label>Hovered planet parameters</label>
|
<label>Hovered planet parameters</label>
|
||||||
|
|
|
@ -30,10 +30,10 @@
|
||||||
planets.push(
|
planets.push(
|
||||||
{
|
{
|
||||||
"name": parameters[i][j]["name"],
|
"name": parameters[i][j]["name"],
|
||||||
"ship_count": parameters[i][j]["shipCount"],
|
"ship_count": parseInt(parameters[i][j]["shipCount"]),
|
||||||
"owner": parameters[i][j]["colour"],
|
"owner": parameters[i][j]["colour"],
|
||||||
"x": j,
|
"x": parseInt(j),
|
||||||
"y": i
|
"y": parseInt(i)
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -56,7 +56,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
const handleConfirmButton = () => {
|
const handleConfirmButton = () => {
|
||||||
fields["mapOutput"].style.display = "block";
|
fields["mapOutput"].classList.remove("hidden");
|
||||||
fields["mapOutput"].value = JSON.stringify(constructMap(),null,2);
|
fields["mapOutput"].value = JSON.stringify(constructMap(),null,2);
|
||||||
console.log(constructMap());
|
console.log(constructMap());
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue