• R/O
  • HTTP
  • SSH
  • HTTPS

hengband: Commit

変愚蛮怒のメインリポジトリです


Commit MetaInfo

Revision2ad178fdd4a52441ba2d92ca4e164280ace19290 (tree)
Time2019-02-07 10:28:23
AuthorDeskull <deskull@user...>
CommiterDeskull

Log Message

[Refactor] #37353 メッセージ整理。 / Refactor messages.

Change Summary

Incremental Difference

--- a/src/store.c
+++ b/src/store.c
@@ -3692,21 +3692,11 @@ static void display_inventory(void)
36923692 if (st_ptr->stock_num > store_bottom)
36933693 {
36943694 /* Show "more" reminder (after the last item) */
3695-#ifdef JP
3696- prt("-続く-", k + 6, 3);
3697-#else
3698- prt("-more-", k + 6, 3);
3699-#endif
3700-
3695+ prt(_("-続く-", "-more-"), k + 6, 3);
37013696
37023697 /* Indicate the "current page" */
37033698 /* Trailing spaces are to display (Page xx) and (Page x) */
3704-#ifdef JP
3705- put_str(format("(%dページ) ", store_top/store_bottom + 1), 5, 20);
3706-#else
3707- put_str(format("(Page %d) ", store_top/store_bottom + 1), 5, 20);
3708-#endif
3709-
3699+ put_str(format(_("(%dページ) ", "(Page %d) "), store_top/store_bottom + 1), 5, 20);
37103700 }
37113701
37123702 if (cur_store_num == STORE_HOME || cur_store_num == STORE_MUSEUM)
@@ -3733,13 +3723,7 @@ static void store_prt_gold(void)
37333723 {
37343724 char out_val[64];
37353725
3736-#ifdef JP
3737- prt("手持ちのお金: ", 19 + xtra_stock, 53);
3738-#else
3739- prt("Gold Remaining: ", 19 + xtra_stock, 53);
3740-#endif
3741-
3742-
3726+ prt(_("手持ちのお金: ", "Gold Remaining: "), 19 + xtra_stock, 53);
37433727 sprintf(out_val, "%9ld", (long)p_ptr->au);
37443728 prt(out_val, 19 + xtra_stock, 68);
37453729 }
@@ -3995,48 +3979,29 @@ static s32b last_inc = 0L;
39953979 static int get_haggle(concptr pmt, s32b *poffer, PRICE price, int final)
39963980 {
39973981 s32b i;
3998-
39993982 concptr p;
4000-
40013983 char buf[128];
40023984 char out_val[160];
40033985
4004-
40053986 /* Clear old increment if necessary */
40063987 if (!allow_inc) last_inc = 0L;
40073988
4008-
40093989 /* Final offer */
40103990 if (final)
40113991 {
4012-#ifdef JP
4013- sprintf(buf, "%s [承諾] ", pmt);
4014-#else
4015- sprintf(buf, "%s [accept] ", pmt);
4016-#endif
4017-
3992+ sprintf(buf, _("%s [承諾] ", "%s [accept] "), pmt);
40183993 }
40193994
40203995 /* Old (negative) increment, and not final */
40213996 else if (last_inc < 0)
40223997 {
4023-#ifdef JP
4024- sprintf(buf, "%s [-$%ld] ", pmt, (long)(ABS(last_inc)));
4025-#else
4026- sprintf(buf, "%s [-%ld] ", pmt, (long)(ABS(last_inc)));
4027-#endif
4028-
3998+ sprintf(buf, _("%s [-$%ld] ", "%s [-%ld] "), pmt, (long)(ABS(last_inc)));
40293999 }
40304000
40314001 /* Old (positive) increment, and not final */
40324002 else if (last_inc > 0)
40334003 {
4034-#ifdef JP
4035- sprintf(buf, "%s [+$%ld] ", pmt, (long)(ABS(last_inc)));
4036-#else
4037- sprintf(buf, "%s [+%ld] ", pmt, (long)(ABS(last_inc)));
4038-#endif
4039-
4004+ sprintf(buf, _("%s [+$%ld] ", "%s [+%ld] "), pmt, (long)(ABS(last_inc)));
40404005 }
40414006
40424007 /* Normal haggle */
@@ -4045,11 +4010,9 @@ static int get_haggle(concptr pmt, s32b *poffer, PRICE price, int final)
40454010 sprintf(buf, "%s ", pmt);
40464011 }
40474012
4048-
40494013 /* Paranoia */
40504014 msg_print(NULL);
40514015
4052-
40534016 /* Ask until done */
40544017 while (TRUE)
40554018 {
@@ -4125,12 +4088,7 @@ static int get_haggle(concptr pmt, s32b *poffer, PRICE price, int final)
41254088 }
41264089
41274090 /* Warning */
4128-#ifdef JP
4129- msg_print("値がおかしいです。");
4130-#else
4131- msg_print("Invalid response.");
4132-#endif
4133-
4091+ msg_print(_("値がおかしいです。", "Invalid response."));
41344092 msg_print(NULL);
41354093 }
41364094
Show on old repository browser