floor_ptr->object_level = 1;
}
- alloc_object(player_ptr, ALLOC_SET_ROOM, ALLOC_TYP_OBJECT, randnor(DUN_AMT_ROOM, 3));
- alloc_object(player_ptr, ALLOC_SET_BOTH, ALLOC_TYP_OBJECT, randnor(DUN_AMT_ITEM, 3));
- alloc_object(player_ptr, ALLOC_SET_BOTH, ALLOC_TYP_GOLD, randnor(DUN_AMT_GOLD, 3));
+ constexpr auto alloc_room = 9;
+ alloc_object(player_ptr, ALLOC_SET_ROOM, ALLOC_TYP_OBJECT, randnor(alloc_room, 3));
+ constexpr auto alloc_item = 3;
+ alloc_object(player_ptr, ALLOC_SET_BOTH, ALLOC_TYP_OBJECT, randnor(alloc_item, 3));
+ constexpr auto alloc_gold = 3;
+ alloc_object(player_ptr, ALLOC_SET_BOTH, ALLOC_TYP_GOLD, randnor(alloc_gold, 3));
floor_ptr->object_level = floor_ptr->base_level;
if (alloc_guardian(player_ptr, true)) {
return true;
#define DUN_STR_WAT 3 /* Max number of rivers */
#define DUN_WAT_CHG 50 /* 1 in 50 chance of junction in river */
-/*
- * Dungeon treausre allocation values
- */
-#define DUN_AMT_ROOM 9 /* Amount of objects for rooms */
-#define DUN_AMT_ITEM 3 /* Amount of objects for rooms/corridors */
-#define DUN_AMT_GOLD 3 /* Amount of treasure for rooms/corridors */
-#define DUN_AMT_INVIS 3 /* Amount of invisible walls for rooms/corridors */
-
/* Chance of using syllables to form the name instead of the "template" files */
#define SINDARIN_NAME 10 /*!< ランダムアーティファクトにシンダリン銘をつける確率 */
#define TABLE_NAME 20 /*!< ランダムアーティファクトに漢字銘をつける確率(正確には TABLE_NAME - SINDARIN_NAME %)となる */