From bafe41334c16b82dfe843277113cf731f2bab17b Mon Sep 17 00:00:00 2001
From: Markus Uhlin <markus@nifty-networks.net>
Date: Sun, 5 May 2024 17:31:37 +0200
Subject: Reformatted possible_knight_moves()

---
 FICS/movecheck.c | 49 ++++++++++++++++++++++++++++++-------------------
 1 file changed, 30 insertions(+), 19 deletions(-)

diff --git a/FICS/movecheck.c b/FICS/movecheck.c
index 1303b37..5ffd3c4 100644
--- a/FICS/movecheck.c
+++ b/FICS/movecheck.c
@@ -398,26 +398,37 @@ PRIVATE void possible_pawn_moves(game_state_t * gs,
   }
 }
 
-PRIVATE void possible_knight_moves(game_state_t * gs,
-				    int onf, int onr,
-				    int *posf, int *posr, int *numpos)
+PRIVATE void
+possible_knight_moves(game_state_t *gs,
+    int onf, int onr,
+    int *posf, int *posr,
+    int *numpos)
 {
-  static int knightJumps[8][2] = {{-1, 2}, {1, 2}, {2, -1}, {2, 1},
-  {-1, -2}, {1, -2}, {-2, 1}, {-2, -1}};
-  int f, r;
-  int j;
-
-  for (j = 0; j < 8; j++) {
-    f = knightJumps[j][0] + onf;
-    r = knightJumps[j][1] + onr;
-    if ((f < 0) || (f > 7))
-      continue;
-    if ((r < 0) || (r > 7))
-      continue;
-    if ((gs->board[f][r] == NOPIECE) ||
-	(iscolor(gs->board[f][r], CToggle(gs->onMove))))
-      add_pos(f, r, posf, posr, numpos);
-  }
+	int		f, r;
+	int		j;
+	static int	knightJumps[8][2] = {
+		{-1, 2},
+		{1, 2},
+		{2, -1},
+		{2, 1},
+		{-1, -2},
+		{1, -2},
+		{-2, 1},
+		{-2, -1}
+	};
+
+	for (j = 0; j < 8; j++) {
+		f = knightJumps[j][0] + onf;
+		r = knightJumps[j][1] + onr;
+
+		if ((f < 0) || (f > 7))
+			continue;
+		if ((r < 0) || (r > 7))
+			continue;
+		if ((gs->board[f][r] == NOPIECE) ||
+		    (iscolor(gs->board[f][r], CToggle(gs->onMove))))
+			add_pos(f, r, posf, posr, numpos);
+	}
 }
 
 PRIVATE void
-- 
cgit v1.2.3