feat: routes - add route on burg creation

This commit is contained in:
Azgaar 2024-08-11 15:47:15 +02:00
parent 16b441c5cf
commit 6907c9dcac
7 changed files with 191 additions and 95 deletions

View file

@ -279,7 +279,8 @@ function overviewBurgs(settings = {stateId: null, cultureId: null}) {
function addBurgOnClick() {
const point = d3.mouse(this);
const cell = findCell(point[0], point[1]);
const cell = findCell(...point);
if (pack.cells.h[cell] < 20)
return tip("You cannot place state into the water. Please click on a land cell", false, "error");
if (pack.cells.burg[cell])