From 4304399561b613ec2fab11be3bb1a6f4e11c4477 Mon Sep 17 00:00:00 2001 From: Cody Boone Ferguson <53008573+xexyl@users.noreply.github.com> Date: Mon, 6 Nov 2023 05:52:54 -0800 Subject: [PATCH] Slight improvement to 1991/buzzard alt code Now allows for 'q' to exit the maze. This is to be a bit more intuitive at least for those who use the alt version, which is not the recommended version to try first nor should it be. This change is not in the original nor should it be. --- 1991/buzzard/buzzard.alt.c | 2 +- thanks-for-fixes.md | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/1991/buzzard/buzzard.alt.c b/1991/buzzard/buzzard.alt.c index ae4af0a1a..f7a274844 100644 --- a/1991/buzzard/buzzard.alt.c +++ b/1991/buzzard/buzzard.alt.c @@ -27,5 +27,5 @@ p=P(d+1);q=P(d);if (abs(y) ),++i)D(g+2*i+(s==-1),"--");}else if (abs(y) ==p)D(g-s*(2*p+1),"|");else D(g- (abs(y) *s*2),(s==1)^(y>0)?"\\":"/");}d-=s;}puts( -"");h=0;}}f+=(b=='l')-(b=='h');f&=3;if(b=='k'){if(!m(1,0))continue; +"");h=0;}}f+=(b=='l')-(b=='h');f&=3;if(b=='q')return 0;if(b=='k'){if(!m(1,0))continue; A+=X(f);B+=X(f-1);}}W((b=getchar())!=-1&&m(0,0)==1);return 0;} diff --git a/thanks-for-fixes.md b/thanks-for-fixes.md index fab948f02..ec40f530c 100644 --- a/thanks-for-fixes.md +++ b/thanks-for-fixes.md @@ -1125,7 +1125,8 @@ hard-coded but instead be `__FILE__`. Finally Cody added the [alternate version](1991/buzzard/README.md#alternate-code) which will possibly feel more at home with those familiar with vi(m) (it certainly does feel more at home with -him): `k` for forward, `h` for left and `l` for right. +him): `k` for forward, `h` for left and `l` for right. This version also has a +more useful way to exit, just entering `q` followed by enter. ## [1991/dds](1991/dds/dds.c) ([README.md](1991/dds/README.md]))