Level-Editor!
A small update: We have a level editor! I can switch it on/off on every level and it will just edit it in place for now. The goal is to save the edited level in its own category.
I got the methods from the JS-version, like adding/removing Drones and recounting the lines. So happy that I made the game-logic pretty functional and pure. Everything that is doing something will receive a board, with data, and return a new board.
function addDrone(board, fieldCoordinates) {
board = removeItem(board, fieldCoordinates);
board.drones.push(fieldCoordinates);
board = recalculateLineCounts(board);
return board;
}
