}
}
+static void set_gambling_monsters(player_type *creature_ptr)
+{
+ const int max_gambling_monsters = 4;
+ for (int i = 0; i < max_gambling_monsters; i++) {
+ rd_s16b(&battle_mon[i]);
+ if (z_older_than(10, 3, 4)) {
+ s16b tmp16s;
+ rd_s16b(&tmp16s);
+ mon_odds[i] = tmp16s;
+ } else
+ rd_u32b(&mon_odds[i]);
+ }
+}
+
/*!
* @brief その他の情報を読み込む / Read the "extra" information
* @param creature_ptr プレーヤーへの参照ポインタ
rd_skills(creature_ptr);
rd_race(creature_ptr);
set_imitation(creature_ptr);
- if (z_older_than(10, 0, 3))
- set_zangband_bounty_uniques(creature_ptr);
- else
- for (int i = 0; i < MAX_BOUNTY; i++)
- rd_s16b(¤t_world_ptr->bounty_r_idx[i]);
-
+ rd_bounty_uniques(creature_ptr);
if (z_older_than(10, 0, 3)) {
update_gambling_monsters(creature_ptr);
- } else {
- const int max_gambling_monsters = 4;
- for (int i = 0; i < max_gambling_monsters; i++) {
- rd_s16b(&battle_mon[i]);
- if (z_older_than(10, 3, 4)) {
- s16b tmp16s;
- rd_s16b(&tmp16s);
- mon_odds[i] = tmp16s;
- } else
- rd_u32b(&mon_odds[i]);
- }
- }
+ } else
+ set_gambling_monsters(creature_ptr);
rd_s16b(&creature_ptr->town_num);
rd_s16b(&creature_ptr->arena_number);
#include "savedata/load-v1-3-0.h"
#include "savedata/load-v1-7-0.h"
#include "savedata/load-zangband.h"
+#include "world/world.h"
void rd_base_info(player_type *creature_ptr)
{
}
set_race(creature_ptr);
-}
\ No newline at end of file
+}
+
+void rd_bounty_uniques(player_type *creature_ptr)
+{
+ if (z_older_than(10, 0, 3)) {
+ set_zangband_bounty_uniques(creature_ptr);
+ return;
+ }
+
+ for (int i = 0; i < MAX_BOUNTY; i++)
+ rd_s16b(¤t_world_ptr->bounty_r_idx[i]);
+}