generate static method
Implementation
static WorldMap generate({
required List<MatrixLayer> layers,
required TileModelBuilder builder,
}) {
List<Layer> tileLayers = [];
int index = 0;
for (var layer in layers) {
if (layer.axisInverted) {
tileLayers.add(
Layer(
id: index,
tiles: _buildInverted(layer.matrix, builder),
),
);
} else {
tileLayers.add(
Layer(
id: index,
tiles: _buildNormal(layer.matrix, builder),
),
);
}
index++;
}
return WorldMap(tileLayers);
}