ok nicm

On Thu, Mar 31, 2011 at 10:30:48AM +0200, David Coppa wrote:
> Hi, 
> 
> Nice improvement for the best Tetris implementation ever made.
> From NetBSD.
> 
> OK? 
> 
> Index: screen.c
> ===================================================================
> RCS file: /cvs/src/games/tetris/screen.c,v
> retrieving revision 1.13
> diff -u -p -r1.13 screen.c
> --- screen.c  20 Apr 2006 03:25:36 -0000      1.13
> +++ screen.c  31 Mar 2011 08:16:26 -0000
> @@ -80,7 +80,9 @@ static char
>       *LLstr,                 /* last line, first column */
>       *pcstr,                 /* pad character */
>       *TEstr,                 /* end cursor motion mode */
> -     *TIstr;                 /* begin cursor motion mode */
> +     *TIstr,                 /* begin cursor motion mode */
> +     *VIstr,                 /* make cursor invisible */
> +     *VEstr;                 /* make cursor appear normal */
>  char
>       *SEstr,                 /* end standout mode */
>       *SOstr;                 /* begin standout mode */
> @@ -107,6 +109,8 @@ struct tcsinfo {          /* termcap string info
>       {"so", &SOstr},
>       {"te", &TEstr},
>       {"ti", &TIstr},
> +     {"vi", &VIstr},
> +     {"ve", &VEstr},
>       {"up", &UP},            /* cursor up */
>       { {0}, NULL}
>  };
> @@ -291,6 +295,8 @@ scr_set(void)
>        */
>       if (TIstr)
>               putstr(TIstr);  /* termcap(5) says this is not padded */
> +     if (VIstr)
> +             putstr(VIstr);  /* termcap(5) says this is not padded */
>       if (tstp != SIG_IGN)
>               (void) signal(SIGTSTP, scr_stop);
>       if (ttou != SIG_IGN)
> @@ -321,6 +327,8 @@ scr_end(void)
>       /* exit screen mode */
>       if (TEstr)
>               putstr(TEstr);  /* termcap(5) says this is not padded */
> +     if (VEstr)
> +             putstr(VEstr);  /* termcap(5) says this is not padded */
>       (void) fflush(stdout);
>       (void) tcsetattr(0, TCSADRAIN, &oldtt);
>       isset = 0;

Reply via email to