OSDN Git Service

[Fix] #39494 英語版の型警告を修正. / Fix compiler warnings on English environment.
authordeskull <deskull@users.sourceforge.jp>
Sat, 26 Oct 2019 10:59:01 +0000 (19:59 +0900)
committerdeskull <deskull@users.sourceforge.jp>
Sat, 26 Oct 2019 10:59:01 +0000 (19:59 +0900)
src/cmd/cmd-item.c
src/wizard1.c

index 8c21bc3..bde57d4 100644 (file)
@@ -65,12 +65,11 @@ void do_cmd_inven(player_type *creature_ptr)
 #ifdef JP
        sprintf(out_val, "持ち物: 合計 %3d.%1d kg (限界の%ld%%) コマンド: ",
                (int)lbtokg1(creature_ptr->total_weight) , (int)lbtokg2(creature_ptr->total_weight) ,
-               (long int)((creature_ptr->total_weight * 100) / weight_limit(creature_ptr)));
 #else
        sprintf(out_val, "Inventory: carrying %d.%d pounds (%ld%% of capacity). Command: ",
                (int)(creature_ptr->total_weight / 10), (int)(creature_ptr->total_weight % 10),
-               (creature_ptr->total_weight * 100) / weight_limit(creature_ptr));
 #endif
+               (long int)(creature_ptr->total_weight * 100) / weight_limit(creature_ptr));
 
        prt(out_val, 0, 0);
        command_new = inkey();
index ba5f48a..25c1489 100644 (file)
@@ -1319,7 +1319,7 @@ static void analyze_misc(object_type *o_ptr, char *misc_desc)
 #ifdef JP
                lbtokg1(a_ptr->weight), lbtokg2(a_ptr->weight), (long int)a_ptr->cost);
 #else
-               a_ptr->weight / 10, a_ptr->weight % 10, a_ptr->cost);
+               a_ptr->weight / 10, a_ptr->weight % 10, (long int)a_ptr->cost);
 #endif
 }