• R/O
  • HTTP
  • SSH
  • HTTPS

hengband: Commit

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


Commit MetaInfo

Revisionc92c3d8803b49b022627b4a724a9495d8d459fed (tree)
Time2018-12-04 20:43:11
AuthorDeskull <deskull@user...>
CommiterDeskull

Log Message

[Refactor] #37353 コメント整理 / Refactor comments.

Change Summary

Incremental Difference

--- a/src/artifact.c
+++ b/src/artifact.c
@@ -2265,8 +2265,6 @@ bool create_named_art(ARTIFACT_IDX a_idx, POSITION y, POSITION x)
22652265 IDX i;
22662266
22672267 artifact_type *a_ptr = &a_info[a_idx];
2268-
2269- /* Get local object */
22702268 q_ptr = &forge;
22712269
22722270 /* Ignore "empty" artifacts */
--- a/src/birth.c
+++ b/src/birth.c
@@ -2308,8 +2308,6 @@ void player_outfit(void)
23082308 object_type forge;
23092309 object_type *q_ptr;
23102310
2311-
2312- /* Get local object */
23132311 q_ptr = &forge;
23142312
23152313 /* Give the player some food */
@@ -2373,8 +2371,6 @@ void player_outfit(void)
23732371
23742372 add_outfit(q_ptr);
23752373 }
2376-
2377- /* Get local object */
23782374 q_ptr = &forge;
23792375
23802376 if ((p_ptr->prace == RACE_VAMPIRE) && (p_ptr->pclass != CLASS_NINJA))
@@ -2395,8 +2391,6 @@ void player_outfit(void)
23952391
23962392 add_outfit(q_ptr);
23972393 }
2398-
2399- /* Get local object */
24002394 q_ptr = &forge;
24012395
24022396 if ((p_ptr->pclass == CLASS_RANGER) || (p_ptr->pclass == CLASS_CAVALRY))
@@ -2525,8 +2519,6 @@ void player_outfit(void)
25252519 tv = TV_POTION;
25262520 sv = SV_POTION_RESTORE_MANA;
25272521 }
2528-
2529- /* Get local object */
25302522 q_ptr = &forge;
25312523
25322524 /* Hack -- Give the player an object */
--- a/src/chest.c
+++ b/src/chest.c
@@ -61,7 +61,6 @@ void chest_death(bool scatter, POSITION y, POSITION x, OBJECT_IDX o_idx)
6161 /* Drop some objects (non-chests) */
6262 for (; number > 0; --number)
6363 {
64- /* Get local object */
6564 q_ptr = &forge;
6665 object_wipe(q_ptr);
6766
--- a/src/cmd-eat.c
+++ b/src/cmd-eat.c
@@ -374,8 +374,6 @@ void do_cmd_eat_food_aux(INVENTORY_IDX item)
374374 {
375375 object_type forge;
376376 object_type *q_ptr;
377-
378- /* Get local object */
379377 q_ptr = &forge;
380378
381379 /* Obtain a local object */
--- a/src/cmd-item.c
+++ b/src/cmd-item.c
@@ -388,8 +388,6 @@ void do_cmd_wield(void)
388388 }
389389
390390 p_ptr->energy_use = 100;
391-
392- /* Get local object */
393391 q_ptr = &forge;
394392
395393 /* Obtain local object */
--- a/src/cmd-quaff.c
+++ b/src/cmd-quaff.c
@@ -51,8 +51,6 @@ void do_cmd_quaff_potion_aux(INVENTORY_IDX item)
5151 {
5252 o_ptr = &o_list[0 - item];
5353 }
54-
55- /* Get local object */
5654 q_ptr = &forge;
5755
5856 /* Obtain a local object */
--- a/src/cmd-usestaff.c
+++ b/src/cmd-usestaff.c
@@ -432,8 +432,6 @@ void do_cmd_use_staff_aux(INVENTORY_IDX item)
432432 {
433433 object_type forge;
434434 object_type *q_ptr;
435-
436- /* Get local object */
437435 q_ptr = &forge;
438436
439437 /* Obtain a local object */
--- a/src/cmd2.c
+++ b/src/cmd2.c
@@ -2824,8 +2824,6 @@ void do_cmd_fire_aux(INVENTORY_IDX item, object_type *j_ptr)
28242824 /* Start at the player */
28252825 y = p_ptr->y;
28262826 x = p_ptr->x;
2827-
2828- /* Get local object */
28292827 q_ptr = &forge;
28302828
28312829 /* Obtain a local object */
@@ -3437,8 +3435,6 @@ bool do_cmd_throw(int mult, bool boomerang, OBJECT_IDX shuriken)
34373435 }
34383436
34393437 }
3440-
3441- /* Get local object */
34423438 q_ptr = &forge;
34433439
34443440 /* Obtain a local object */
--- a/src/cmd4.c
+++ b/src/cmd4.c
@@ -5466,8 +5466,6 @@ static void do_cmd_knowledge_artifacts(void)
54665466 {
54675467 object_type forge;
54685468 object_type *q_ptr;
5469-
5470- /* Get local object */
54715469 q_ptr = &forge;
54725470
54735471 /* Create fake object */
@@ -6950,8 +6948,6 @@ static void desc_obj_fake(KIND_OBJECT_IDX k_idx)
69506948 {
69516949 object_type *o_ptr;
69526950 object_type object_type_body;
6953-
6954- /* Get local object */
69556951 o_ptr = &object_type_body;
69566952 object_wipe(o_ptr);
69576953
--- a/src/init1.c
+++ b/src/init1.c
@@ -4119,7 +4119,6 @@ static errr process_dungeon_file_aux(char *buf, int ymin, int xmin, int ymax, in
41194119 }
41204120 else if (object_index)
41214121 {
4122- /* Get local object */
41234122 object_type *o_ptr = &object_type_body;
41244123
41254124 /* Create the item */
--- a/src/load.c
+++ b/src/load.c
@@ -1399,8 +1399,6 @@ static errr rd_store(int town_number, int store_number)
13991399 {
14001400 object_type forge;
14011401 object_type *q_ptr;
1402-
1403- /* Get local object */
14041402 q_ptr = &forge;
14051403 object_wipe(q_ptr);
14061404
@@ -2397,8 +2395,6 @@ static errr rd_inventory(void)
23972395
23982396 /* Nope, we reached the end */
23992397 if (n == 0xFFFF) break;
2400-
2401- /* Get local object */
24022398 q_ptr = &forge;
24032399 object_wipe(q_ptr);
24042400
--- a/src/monster2.c
+++ b/src/monster2.c
@@ -4557,8 +4557,6 @@ void monster_drop_carried_objects(monster_type *m_ptr)
45574557
45584558 /* Acquire next object */
45594559 next_o_idx = o_ptr->next_o_idx;
4560-
4561- /* Get local object */
45624560 q_ptr = &forge;
45634561
45644562 /* Copy the object */
--- a/src/object2.c
+++ b/src/object2.c
@@ -4892,8 +4892,6 @@ void place_object(POSITION y, POSITION x, BIT_FLAGS mode)
48924892 /* Avoid stacking on other objects */
48934893 if (c_ptr->o_idx) return;
48944894
4895-
4896- /* Get local object */
48974895 q_ptr = &forge;
48984896 object_wipe(q_ptr);
48994897
@@ -5008,8 +5006,6 @@ void place_gold(POSITION y, POSITION x)
50085006 /* Avoid stacking on other objects */
50095007 if (c_ptr->o_idx) return;
50105008
5011-
5012- /* Get local object */
50135009 q_ptr = &forge;
50145010 object_wipe(q_ptr);
50155011
@@ -5419,7 +5415,6 @@ void acquirement(POSITION y1, POSITION x1, int num, bool great, bool special, bo
54195415 /* Acquirement */
54205416 while (num--)
54215417 {
5422- /* Get local object */
54235418 i_ptr = &object_type_body;
54245419 object_wipe(i_ptr);
54255420
@@ -5507,8 +5502,6 @@ void amusement(POSITION y1, POSITION x1, int num, bool known)
55075502 r -= amuse_info[i].prob;
55085503 if (r <= 0) break;
55095504 }
5510-
5511- /* Get local object */
55125505 i_ptr = &object_type_body;
55135506 object_wipe(i_ptr);
55145507 k_idx = lookup_kind(amuse_info[i].tval, amuse_info[i].sval);
@@ -6160,8 +6153,6 @@ INVENTORY_IDX inven_takeoff(INVENTORY_IDX item, ITEM_NUMBER amt)
61606153
61616154 /* Verify */
61626155 if (amt > o_ptr->number) amt = o_ptr->number;
6163-
6164- /* Get local object */
61656156 q_ptr = &forge;
61666157
61676158 /* Obtain a local object */
@@ -6254,8 +6245,6 @@ void inven_drop(INVENTORY_IDX item, ITEM_NUMBER amt)
62546245 o_ptr = &inventory[item];
62556246 }
62566247
6257-
6258- /* Get local object */
62596248 q_ptr = &forge;
62606249
62616250 /* Obtain local object */
@@ -6431,8 +6420,6 @@ void reorder_pack(void)
64316420
64326421 /* Take note */
64336422 flag = TRUE;
6434-
6435- /* Get local object */
64366423 q_ptr = &forge;
64376424
64386425 /* Save a copy of the moving item */
@@ -6483,8 +6470,6 @@ void display_koff(KIND_OBJECT_IDX k_idx)
64836470
64846471 /* No info */
64856472 if (!k_idx) return;
6486-
6487- /* Get local object */
64886473 q_ptr = &forge;
64896474
64906475 /* Prepare the object */
--- a/src/racial.c
+++ b/src/racial.c
@@ -101,8 +101,6 @@ static bool do_cmd_archer(void)
101101 else
102102 {
103103 s16b slot;
104-
105- /* Get local object */
106104 q_ptr = &forge;
107105
108106 /* Hack -- Give the player some small firestones */
@@ -151,8 +149,6 @@ static bool do_cmd_archer(void)
151149 {
152150 q_ptr = &o_list[0 - item];
153151 }
154-
155- /* Get local object */
156152 q_ptr = &forge;
157153
158154 /* Hack -- Give the player some small firestones */
@@ -209,8 +205,6 @@ static bool do_cmd_archer(void)
209205 {
210206 q_ptr = &o_list[0 - item];
211207 }
212-
213- /* Get local object */
214208 q_ptr = &forge;
215209
216210 /* Hack -- Give the player some small firestones */
@@ -1216,8 +1210,6 @@ static bool cmd_racial_power_aux(s32b command)
12161210 {
12171211 object_type *q_ptr;
12181212 object_type forge;
1219-
1220- /* Get local object */
12211213 q_ptr = &forge;
12221214
12231215 /* Create the food ration */
--- a/src/spells1.c
+++ b/src/spells1.c
@@ -5055,8 +5055,6 @@ static bool project_m(MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_P
50555055 {
50565056 object_type *q_ptr;
50575057 object_type forge;
5058-
5059- /* Get local object */
50605058 q_ptr = &forge;
50615059
50625060 /* Prepare to make a Blade of Chaos */
--- a/src/spells3.c
+++ b/src/spells3.c
@@ -4613,8 +4613,6 @@ bool eat_magic(int power)
46134613 {
46144614 object_type forge;
46154615 object_type *q_ptr;
4616-
4617- /* Get local object */
46184616 q_ptr = &forge;
46194617
46204618 /* Obtain a local object */
--- a/src/store.c
+++ b/src/store.c
@@ -1656,8 +1656,6 @@ bool combine_and_reorder_home(int store_num)
16561656
16571657 /* Take note */
16581658 flag = TRUE;
1659-
1660- /* Get local object */
16611659 j_ptr = &forge;
16621660
16631661 /* Save a copy of the moving item */
@@ -2094,8 +2092,6 @@ static void store_create(void)
20942092 level = rand_range(1, STORE_OBJ_LEVEL);
20952093 }
20962094
2097-
2098- /* Get local object */
20992095 q_ptr = &forge;
21002096
21012097 /* Create a new object of the chosen kind */
@@ -3483,8 +3479,6 @@ static void store_purchase(void)
34833479
34843480 /* Assume the player wants just one of them */
34853481 amt = 1;
3486-
3487- /* Get local object */
34883482 j_ptr = &forge;
34893483
34903484 /* Get a copy of the object */
@@ -3535,8 +3529,6 @@ msg_format("一つにつき $%ldです。", (long)(best));
35353529 /* Allow user abort */
35363530 if (amt <= 0) return;
35373531 }
3538-
3539- /* Get local object */
35403532 j_ptr = &forge;
35413533
35423534 /* Get desired object */
@@ -3952,8 +3944,6 @@ static void store_sell(void)
39523944 /* Allow user abort */
39533945 if (amt <= 0) return;
39543946 }
3955-
3956- /* Get local object */
39573947 q_ptr = &forge;
39583948
39593949 /* Get a copy of the object */
@@ -4055,8 +4045,6 @@ static void store_sell(void)
40554045
40564046 /* Identify it */
40574047 identify_item(o_ptr);
4058-
4059- /* Get local object */
40604048 q_ptr = &forge;
40614049
40624050 /* Get a copy of the object */
@@ -5118,8 +5106,6 @@ void do_cmd_store(void)
51185106 msg_print("Your pack overflows!");
51195107 #endif
51205108
5121-
5122- /* Get local object */
51235109 q_ptr = &forge;
51245110
51255111 /* Grab a copy of the item */
--- a/src/wizard1.c
+++ b/src/wizard1.c
@@ -238,8 +238,6 @@ static void kind_info(char *buf, char *dam, char *wgt, char *chance, DEPTH *lev,
238238 object_type forge;
239239 object_type *q_ptr;
240240 int i;
241-
242- /* Get local object */
243241 q_ptr = &forge;
244242
245243 /* Prepare a fake item */
@@ -1704,8 +1702,6 @@ static void spoil_artifact(cptr fname)
17041702
17051703 /* We only want objects in the current group */
17061704 if (a_ptr->tval != group_artifact[i].tval) continue;
1707-
1708- /* Get local object */
17091705 q_ptr = &forge;
17101706 object_wipe(q_ptr);
17111707
--- a/src/wizard2.c
+++ b/src/wizard2.c
@@ -893,8 +893,6 @@ static void wiz_reroll_item(object_type *o_ptr)
893893 /* Hack -- leave artifacts alone */
894894 if (object_is_artifact(o_ptr)) return;
895895
896-
897- /* Get local object */
898896 q_ptr = &forge;
899897
900898 /* Copy the object */
@@ -1106,8 +1104,6 @@ static void wiz_statistics(object_type *o_ptr)
11061104 prt(format(q, i, correct, matches, better, worse, other), 0, 0);
11071105 Term_fresh();
11081106 }
1109-
1110- /* Get local object */
11111107 q_ptr = &forge;
11121108 object_wipe(q_ptr);
11131109
@@ -1296,8 +1292,6 @@ static void do_cmd_wiz_play(void)
12961292 /* Save the screen */
12971293 screen_save();
12981294
1299-
1300- /* Get local object */
13011295 q_ptr = &forge;
13021296
13031297 /* Copy object */
@@ -1435,8 +1429,6 @@ static void wiz_create_item(void)
14351429 return;
14361430 }
14371431 }
1438-
1439- /* Get local object */
14401432 q_ptr = &forge;
14411433
14421434 /* Create the item */
@@ -1569,7 +1561,6 @@ static void do_cmd_wiz_learn(void)
15691561 /* Induce awareness */
15701562 if (k_ptr->level <= command_arg)
15711563 {
1572- /* Get local object */
15731564 q_ptr = &forge;
15741565
15751566 /* Prepare object */
--- a/src/xtra2.c
+++ b/src/xtra2.c
@@ -646,7 +646,6 @@ void check_quest_completion(monster_type *m_ptr)
646646
647647 for (i = 0; i < (dun_level / 15)+1; i++)
648648 {
649- /* Get local object */
650649 o_ptr = &forge;
651650 object_wipe(o_ptr);
652651
@@ -817,7 +816,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
817816
818817 if (arena_info[p_ptr->arena_number].tval)
819818 {
820- /* Get local object */
821819 q_ptr = &forge;
822820
823821 /* Prepare to make a prize */
@@ -880,8 +878,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
880878 if (!one_in_(5)) corpse = TRUE;
881879 }
882880 }
883-
884- /* Get local object */
885881 q_ptr = &forge;
886882
887883 /* Prepare to make an object */
@@ -933,7 +929,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
933929 /* Bloodletters of Khorne may drop a blade of chaos */
934930 if (drop_chosen_item && (randint1(100) < 15))
935931 {
936- /* Get local object */
937932 q_ptr = &forge;
938933
939934 /* Prepare to make a Blade of Chaos */
@@ -949,7 +944,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
949944 case MON_RAAL:
950945 if (drop_chosen_item && (dun_level > 9))
951946 {
952- /* Get local object */
953947 q_ptr = &forge;
954948 object_wipe(q_ptr);
955949
@@ -1053,8 +1047,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
10531047
10541048 case MON_SERPENT:
10551049 if (!drop_chosen_item) break;
1056-
1057- /* Get local object */
10581050 q_ptr = &forge;
10591051
10601052 /* Mega-Hack -- Prepare to make "Grond" */
@@ -1068,8 +1060,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
10681060
10691061 /* Drop it in the dungeon */
10701062 (void)drop_near(q_ptr, -1, y, x);
1071-
1072- /* Get local object */
10731063 q_ptr = &forge;
10741064
10751065 /* Mega-Hack -- Prepare to make "Chaos" */
@@ -1088,7 +1078,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
10881078 case MON_B_DEATH_SWORD:
10891079 if (drop_chosen_item)
10901080 {
1091- /* Get local object */
10921081 q_ptr = &forge;
10931082
10941083 /* Prepare to make a broken sword */
@@ -1104,7 +1093,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
11041093 if (drop_chosen_item && ((m_ptr->r_idx == MON_A_GOLD) ||
11051094 ((m_ptr->r_idx == MON_A_SILVER) && (r_ptr->r_akills % 5 == 0))))
11061095 {
1107- /* Get local object */
11081096 q_ptr = &forge;
11091097
11101098 /* Prepare to make a Can of Toys */
@@ -1132,7 +1120,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
11321120 case '(':
11331121 if (dun_level > 0)
11341122 {
1135- /* Get local object */
11361123 q_ptr = &forge;
11371124 object_wipe(q_ptr);
11381125
@@ -1150,7 +1137,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
11501137 case '/':
11511138 if (dun_level > 4)
11521139 {
1153- /* Get local object */
11541140 q_ptr = &forge;
11551141 object_wipe(q_ptr);
11561142
@@ -1168,7 +1154,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
11681154 case '[':
11691155 if (dun_level > 19)
11701156 {
1171- /* Get local object */
11721157 q_ptr = &forge;
11731158 object_wipe(q_ptr);
11741159
@@ -1186,7 +1171,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
11861171 case '\\':
11871172 if (dun_level > 4)
11881173 {
1189- /* Get local object */
11901174 q_ptr = &forge;
11911175 object_wipe(q_ptr);
11921176
@@ -1204,7 +1188,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
12041188 case '|':
12051189 if (m_ptr->r_idx != MON_STORMBRINGER)
12061190 {
1207- /* Get local object */
12081191 q_ptr = &forge;
12091192 object_wipe(q_ptr);
12101193
@@ -1282,7 +1265,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
12821265
12831266 if (k_idx)
12841267 {
1285- /* Get local object */
12861268 q_ptr = &forge;
12871269
12881270 /* Prepare to make a reward */
@@ -1324,7 +1306,6 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
13241306 /* Drop some objects */
13251307 for (j = 0; j < number; j++)
13261308 {
1327- /* Get local object */
13281309 q_ptr = &forge;
13291310 object_wipe(q_ptr);
13301311
@@ -4494,8 +4475,6 @@ void gain_level_reward(int chosen_reward)
44944475
44954476 msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[p_ptr->chaos_patron]);
44964477 msg_print(_("「汝の行いは貴き剣に値せり。」", "'Thy deed hath earned thee a worthy blade.'"));
4497-
4498- /* Get local object */
44994478 q_ptr = &forge;
45004479 dummy = TV_SWORD;
45014480 switch (randint1(p_ptr->lev))
Show on old repository browser