Merge branch 'master' of https://github.com/Azgaar/Fantasy-Map-Generator into burg-groups

This commit is contained in:
Azgaar 2025-03-15 14:49:43 +01:00
commit 95b7ed9ea4
33 changed files with 572 additions and 378 deletions

View file

@ -4,6 +4,11 @@
// clip polygon by graph bbox
function clipPoly(points, secure = 0) {
if (points.length < 2) return points;
if (points.some(point => point === undefined)) {
ERROR && console.error("Undefined point in clipPoly", points);
return points;
}
return polygonclip(points, [0, 0, graphWidth, graphHeight], secure);
}