From 4737d337fa7119c1b64d3fd3b996e126b669d3a7 Mon Sep 17 00:00:00 2001 From: Shard Date: Thu, 26 Mar 2026 23:08:45 +0000 Subject: [PATCH] Fix triangular board compile error (nested Math.Max) --- Server/src/SOR.Game/Grid/BoardShapeGenerator.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Server/src/SOR.Game/Grid/BoardShapeGenerator.cs b/Server/src/SOR.Game/Grid/BoardShapeGenerator.cs index e23631c..e519ac1 100644 --- a/Server/src/SOR.Game/Grid/BoardShapeGenerator.cs +++ b/Server/src/SOR.Game/Grid/BoardShapeGenerator.cs @@ -148,7 +148,7 @@ public static class BoardShapeGenerator // base = w - 1 // side = (w - 1)/2 + (h - 1) // Enforce equality by picking h = (w + 1)/2, i.e. side = base. - int side = Math.Max(12, rules.BoardWidth - 1, 2 * (rules.BoardHeight - 1)); + int side = Math.Max(12, Math.Max(rules.BoardWidth - 1, 2 * (rules.BoardHeight - 1))); if (side % 2 != 0) side++; // keep width odd so apex is centered exactly int w = side + 1; // odd