wm: glendy

Download patch

ref: 8f208984e22543ac2335f45f003ccc31f2798b9d
parent: 22999a45321153513ec985c592164a5cebd6cb3e
author: mkf <mkf@cloud9p.org>
date: Sat Apr 20 13:39:00 EDT 2024

cli: ensure trapper can't put walls on glenda

--- a/cli.c
+++ b/cli.c
@@ -79,9 +79,11 @@
 		fprintf(stderr, "proc_put(): invalid input, x = %d, y = %d\n", x, y);
 		return;
 	}
-
-	if(doput(Pt(x, y)) == Wall)
+	r = doput(Pt(x, y));
+	if(r == Wall)
 		fprintf(stderr, "There is already a wall in x = %d, y = %d\n", x, y);
+	else if(r == Glenda)
+		fprintf(stderr, "You can't put a wall on glenda!\n");
 }
 
 /* m x y */