From 71958c359977fba1bb1686f9c07b96d015ca6f5d Mon Sep 17 00:00:00 2001 From: nothere Date: Fri, 5 Sep 2003 20:54:15 +0000 Subject: [PATCH] =?utf8?q?=E5=AE=BF=E5=B1=8B=E3=81=AB24=E6=99=82=E9=96=93?= =?utf8?q?=E3=81=84=E3=81=A4=E3=81=A7=E3=82=82=E6=B3=8A=E3=81=BE=E3=82=8C?= =?utf8?q?=E3=82=8B=E3=82=88=E3=81=86=E3=81=AB=E5=A4=89=E6=9B=B4.=20?= =?utf8?q?=E6=9C=9D=E3=82=84=E6=98=BC=E3=81=AB=E6=B3=8A=E3=81=BE=E3=81=A3?= =?utf8?q?=E3=81=9F=E5=A0=B4=E5=90=88=E3=81=AF=E5=BD=93=E6=97=A5=E3=81=AE?= =?utf8?q?=2018:00=E3=81=AB=E8=B5=B7=E3=81=8D=E3=82=8B.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- src/bldg.c | 139 +++++++++++++++++++++++++++++-------------------------------- 1 file changed, 67 insertions(+), 72 deletions(-) diff --git a/src/bldg.c b/src/bldg.c index 3421aa01a..ae098fd0d 100644 --- a/src/bldg.c +++ b/src/bldg.c @@ -2800,120 +2800,115 @@ msg_print(" break; case BACT_REST: /* Rest for the night */ - if (!is_daytime()) /* Nighttime only */ + if ((p_ptr->poisoned) || (p_ptr->cut)) { - if ((p_ptr->poisoned) || (p_ptr->cut)) - { #ifdef JP -msg_print("¤¢¤Ê¤¿¤ËɬÍפʤΤÏÉô²°¤Ç¤Ï¤Ê¤¯¡¢¼£ÎżԤǤ¹¡£"); + msg_print("¤¢¤Ê¤¿¤ËɬÍפʤΤÏÉô²°¤Ç¤Ï¤Ê¤¯¡¢¼£ÎżԤǤ¹¡£"); #else - msg_print("You need a healer, not a room."); + msg_print("You need a healer, not a room."); #endif - msg_print(NULL); + msg_print(NULL); #ifdef JP -msg_print("¤¹¤ß¤Þ¤»¤ó¡¢¤Ç¤â¤¦¤Á¤Ç狼¤Ë»à¤Ê¤ì¤Á¤ãº¤¤ê¤Þ¤¹¤ó¤Ç¡£"); + msg_print("¤¹¤ß¤Þ¤»¤ó¡¢¤Ç¤â¤¦¤Á¤Ç狼¤Ë»à¤Ê¤ì¤Á¤ãº¤¤ê¤Þ¤¹¤ó¤Ç¡£"); #else - msg_print("Sorry, but don't want anyone dying in here."); + msg_print("Sorry, but don't want anyone dying in here."); #endif + } + else + { + int oldturn = turn; + int prev_day, prev_hour, prev_min; - } - else - { - int oldturn = turn; + extract_day_hour_min(&prev_day, &prev_hour, &prev_min); #ifdef JP - do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "½É²°¤ËÇñ¤Þ¤Ã¤¿¡£"); + do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "½É²°¤ËÇñ¤Þ¤Ã¤¿¡£"); #else - do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "stay over night at the inn"); + if ((prev_hour >= 6) && (prev_hour <= 17)) do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "stay over daytime at the inn."); + else do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "stay over night at the inn."); #endif - turn = (turn / (TURNS_PER_TICK*TOWN_DAWN/2) + 1) * (TURNS_PER_TICK*TOWN_DAWN/2); - if (((oldturn + TURNS_PER_TICK * TOWN_DAWN / 4) % (TURNS_PER_TICK * TOWN_DAWN)) > TURNS_PER_TICK * TOWN_DAWN/4) do_cmd_write_nikki(NIKKI_HIGAWARI, 0, NULL); - p_ptr->chp = p_ptr->mhp; + turn = (turn / (TURNS_PER_TICK*TOWN_DAWN/2) + 1) * (TURNS_PER_TICK*TOWN_DAWN/2); + if ((prev_hour >= 18) && (prev_hour <= 23)) do_cmd_write_nikki(NIKKI_HIGAWARI, 0, NULL); + p_ptr->chp = p_ptr->mhp; - dungeon_turn += MIN(turn - oldturn, TURNS_PER_TICK*250); + dungeon_turn += MIN(turn - oldturn, TURNS_PER_TICK*250); - if (ironman_nightmare) - { + if (ironman_nightmare) + { #ifdef JP -msg_print("̲¤ê¤Ë½¢¤¯¤È¶²¤í¤·¤¤¸÷·Ê¤¬¿´¤ò¤è¤®¤Ã¤¿¡£"); + msg_print("̲¤ê¤Ë½¢¤¯¤È¶²¤í¤·¤¤¸÷·Ê¤¬¿´¤ò¤è¤®¤Ã¤¿¡£"); #else - msg_print("Horrible visions flit through your mind as you sleep."); + msg_print("Horrible visions flit through your mind as you sleep."); #endif + /* Pick a nightmare */ + get_mon_num_prep(get_nightmare, NULL); - /* Pick a nightmare */ - get_mon_num_prep(get_nightmare, NULL); - - /* Have some nightmares */ - while(1) - { - have_nightmare(get_mon_num(MAX_DEPTH)); + /* Have some nightmares */ + while(1) + { + have_nightmare(get_mon_num(MAX_DEPTH)); - if (!one_in_(3)) break; - } + if (!one_in_(3)) break; + } - /* Remove the monster restriction */ - get_mon_num_prep(NULL, NULL); + /* Remove the monster restriction */ + get_mon_num_prep(NULL, NULL); #ifdef JP -msg_print("¤¢¤Ê¤¿¤ÏÀ䶫¤·¤ÆÌܤò³Ð¤Þ¤·¤¿¡£"); + msg_print("¤¢¤Ê¤¿¤ÏÀ䶫¤·¤ÆÌܤò³Ð¤Þ¤·¤¿¡£"); + do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "°­Ì´¤Ë¤¦¤Ê¤µ¤ì¤Æ¤è¤¯Ì²¤ì¤Ê¤«¤Ã¤¿¡£"); #else - msg_print("You awake screaming."); + msg_print("You awake screaming."); + do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "be troubled by a nightmare."); #endif + } + else + { + set_blind(0); + set_confused(0); + p_ptr->stun = 0; + p_ptr->chp = p_ptr->mhp; + p_ptr->csp = p_ptr->msp; + if (p_ptr->pclass == CLASS_MAGIC_EATER) + { + int i; + for (i = 0; i < 72; i++) + { + p_ptr->magic_num1[i] = p_ptr->magic_num2[i]*EATER_CHARGE; + } + for (; i < 108; i++) + { + p_ptr->magic_num1[i] = 0; + } + } + if ((prev_hour >= 6) && (prev_hour <= 17)) + { #ifdef JP - do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "°­Ì´¤Ë¤¦¤Ê¤µ¤ì¤Æ¤è¤¯Ì²¤ì¤Ê¤«¤Ã¤¿¡£"); + msg_print("¤¢¤Ê¤¿¤Ï¥ê¥Õ¥ì¥Ã¥·¥å¤·¤ÆÌܳФᡢͼÊý¤ò·Þ¤¨¤¿¡£"); + do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "ͼÊý¤ò·Þ¤¨¤¿¡£"); #else - do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "be troubled by a nightmare."); + msg_print("You awake refreshed for the evening."); + do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "awake refreshed."); #endif } else { - set_blind(0); - set_confused(0); - p_ptr->stun = 0; - p_ptr->chp = p_ptr->mhp; - p_ptr->csp = p_ptr->msp; - if (p_ptr->pclass == CLASS_MAGIC_EATER) - { - int i; - for (i = 0; i < 72; i++) - { - p_ptr->magic_num1[i] = p_ptr->magic_num2[i]*EATER_CHARGE; - } - for (; i < 108; i++) - { - p_ptr->magic_num1[i] = 0; - } - } - #ifdef JP -msg_print("¤¢¤Ê¤¿¤Ï¥ê¥Õ¥ì¥Ã¥·¥å¤·¤ÆÌܳФᡢ¿·¤¿¤ÊÆü¤ò·Þ¤¨¤¿¡£"); + msg_print("¤¢¤Ê¤¿¤Ï¥ê¥Õ¥ì¥Ã¥·¥å¤·¤ÆÌܳФᡢ¿·¤¿¤ÊÆü¤ò·Þ¤¨¤¿¡£"); + do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "¤¹¤¬¤¹¤¬¤·¤¤Ä«¤ò·Þ¤¨¤¿¡£"); #else msg_print("You awake refreshed for the new day."); -#endif - -#ifdef JP - do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "¤¹¤¬¤¹¤¬¤·¤¤Ä«¤ò¤à¤«¤¨¤¿¡£"); -#else do_cmd_write_nikki(NIKKI_BUNSHOU, 0, "awake refreshed."); #endif } - - p_ptr->leftbldg = TRUE; } - } - else - { -#ifdef JP -msg_print("Éô²°¤ÏÌë¤À¤±»ÈÍѲÄǽ¤Ç¤¹¡£"); -#else - msg_print("The rooms are available only at night."); -#endif - return (FALSE); + p_ptr->leftbldg = TRUE; } break; + case BACT_RUMORS: /* Listen for rumors */ { char Rumor[1024]; -- 2.11.0