From e885ee0039281c2957ece47e82be1b0a6624111a Mon Sep 17 00:00:00 2001 From: piaip Date: Sun, 6 Jan 2013 16:38:08 +0000 Subject: Change angel offline message git-svn-id: http://opensvn.csie.org/pttbbs/trunk@5761 63ad8ddf-47c3-0310-b6dd-a9e9d9715204 --- pttbbs/mbbsd/angel.c | 40 ++++++++++++---------------------------- pttbbs/sample/etc/angel_usage2 | 20 ++++++++++++++++++++ pttbbs/sample/etc/editable | 1 + 3 files changed, 33 insertions(+), 28 deletions(-) create mode 100644 pttbbs/sample/etc/angel_usage2 diff --git a/pttbbs/mbbsd/angel.c b/pttbbs/mbbsd/angel.c index 578de474..7968ca8f 100644 --- a/pttbbs/mbbsd/angel.c +++ b/pttbbs/mbbsd/angel.c @@ -661,6 +661,7 @@ static inline void AngelNotOnline(){ char buf[PATHLEN]; FILE *fp; + int y = 0; // use cached angel data (assume already called before.) // angel_reload_nick(); @@ -679,42 +680,25 @@ AngelNotOnline(){ NoAngelFound(NULL); return; } - clear(); + showtitle("¤p¤Ñ¨Ï¯d¨¥", BBSNAME); - move(4, 0); + move(2, 0); buf[0] = 0; - prints("±zªº%s¤p¤Ñ¨Ï²{¦b¤£¦b½u¤W", _myangel_nick); - - outs("\nÍ¢¯d¨¥µ¹§A¡G\n"); - outs(ANSI_COLOR(1;31;44) "¡ó¢s¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢t" ANSI_COLOR(37) "" - "¤p¤Ñ¨Ï¯d¨¥" ANSI_COLOR(31) "¢u¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢s¡ó" ANSI_RESET "\n"); - outs(ANSI_COLOR(1;31) "¢~¢t" ANSI_COLOR(32) " ¤p¤Ñ¨Ï " - " " ANSI_COLOR(31) "¢u¢¡" ANSI_RESET "\n"); + prints("±zªº%s¤p¤Ñ¨Ï²{¦b¤£¦b½u¤W¡AÍ¢¯d¨¥µ¹§A¡G\n", _myangel_nick); + show_file("etc/angel_usage2", vgety(), b_lines - vgety(), + SHOWFILE_ALLOW_ALL); fgets(buf, sizeof(buf), fp); // skip first line: entry for nick + y = 5; + while (fgets(buf, sizeof(buf), fp)) { chomp(buf); - prints(ANSI_COLOR(1;31) "¢x" ANSI_RESET "%-74.74s" ANSI_COLOR(1;31) "¢x" ANSI_RESET "\n", buf); + move_ansi(y++, 4); + outs(buf); } fclose(fp); - outs(ANSI_COLOR(1;31) "¢¢¢s¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w" - "¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢s¢£" ANSI_RESET "\n"); - outs(ANSI_COLOR(1;31;44) "¡ó¢r¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w" - "¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢w¢r¡ó" ANSI_RESET "\n"); - prints("%55s%s", "¯d¨¥¤é´Á: ", Cdatelite(&_myangel_touched)); - - - move(b_lines - 4, 0); -#ifdef BN_NEWBIE - outs("Á{®É§ä¤£¨ì¤p¤Ñ¨Ï¥i¨ì·s¤âª©(" BN_NEWBIE ")\n" -#endif -#ifdef BN_ANGELPRAY - "·Q¯d¨¥µ¹¤p¤Ñ¨Ï½Ð¨ì³\\Ä@ª©(" BN_ANGELPRAY ")\n" -#endif -#ifdef BN_ASKBOARD - "·Q§ä¬ÝªO¦b­þªº¸Ü¥i¨ì(" BN_ASKBOARD ")\n" -#endif - "½Ð¥ý¦b¦UªO¤W´M§äµª®×©Î«ö Ctrl-P µo°Ý"); + move_ansi(9, 43); + prints("¯d¨¥¤é´Á: %s\n", Cdatelite(&_myangel_touched)); // Query if user wants to go to newbie board switch(tolower(vmsg("·Q´«¦¨¥Ø«e¦b½u¤Wªº¤p¤Ñ¨Ï½Ð«ö h, " diff --git a/pttbbs/sample/etc/angel_usage2 b/pttbbs/sample/etc/angel_usage2 new file mode 100644 index 00000000..153bff5c --- /dev/null +++ b/pttbbs/sample/etc/angel_usage2 @@ -0,0 +1,20 @@ +       ¢u¢¦¢s¢{ + ùÝùê¢{       ¢r¢¦¢r¢¦¢¦¢{ +¢q¢t ¢¦¢t +¢¥¢s ¢uùß +ùà¢t ùé¢t + ùòùê¢s¢q¢r   ¢|¢¦¢r +  ùäùê¢t        + ¢© + ¢k¢g¢d + ¢l ¢f¢g¢d¢b + ¢o¢©  ¢f¢d¢g¢f¢f¢f¢e¢d¢b + ¢e  ¢h¢g¢g¢f¢e¢e¢© £_ ©ó¦¹µe­±¤U¡A«ö  h  ¥i§ó´«¦b½u¤W¤§¤p¤Ñ¨Ï + ¢d¢d¢g¢© ¢ª¢© £_ ·Q¯d¨¥µ¹¤p¤Ñ¨Ï½Ð¨ì ³\Ä@ªO (AngelPray) + ¢o¢o¢g¢h ¢¨¢d ¢© ¢k £_ ¦³¥ô¦ó°ÝÃD¥i¨ì ·s¤âªO (PttNewHand) + ¢ª¢g¢d¢b¢b ¢p¢n ¢l  ¢o £_ ·Q´M§ä¬ÝªO¥i¨ì °Ý§äªO (AskBoard) + ¢g¢d ¢« ¢l¢e¢m ¢l ¢l  ¡]¥i¥ý¦b¬ÝªO¤º«ö / ¿é¤JÃöÁä¦r´M§äµª®×¡A + ¡»¢i¢d ¢¨   ¢g   ¢m ¢m   ©Î«ö Ctrl-P µo°Ý¡C¡^ + ¢g¢e¢d¢« ¢b¢f¢« ¢n¢l ¢n +  ¢¨ ¢d¢f¢i ¢f¢« ¢o¢l + ¢f¢c¢f   ¢« diff --git a/pttbbs/sample/etc/editable b/pttbbs/sample/etc/editable index 1936c750..e4f6f1de 100644 --- a/pttbbs/sample/etc/editable +++ b/pttbbs/sample/etc/editable @@ -63,6 +63,7 @@ etc/board.help # ---------------------------------------- etc/angel_notify ¤p¤Ñ¨Ï»{ÃÒ³qª¾ etc/angel_usage ¤p¤Ñ¨Ï¥\¯à»¡©ú +etc/angel_usage2 ¤p¤Ñ¨ÏÂ÷½u°T®§(¦³¦Û­q) # ---------------------------------------- # ¥~Äy¨Ï¥ÎªÌ # ---------------------------------------- -- cgit v1.2.3