--- deliantra/server/random_maps/random_map.C 2006/09/16 22:24:13 1.5 +++ deliantra/server/random_maps/random_map.C 2006/12/12 21:39:56 1.7 @@ -70,18 +70,19 @@ if (RP->difficulty == 0) { RP->difficulty = RP->dungeon_level; /* use this instead of a map difficulty */ + if (RP->difficulty_increase > 0.001) - { - RP->difficulty = (int) ((float) RP->dungeon_level * RP->difficulty_increase); - if (RP->difficulty < 1) - RP->difficulty = 1; - } + RP->difficulty = (int) ((float) RP->dungeon_level * RP->difficulty_increase); + + if (RP->difficulty < 1) + RP->difficulty = 1; } else RP->difficulty_given = 1; if (RP->Xsize < MIN_RANDOM_MAP_SIZE) RP->Xsize = MIN_RANDOM_MAP_SIZE + RANDOM () % 25 + 5; + if (RP->Ysize < MIN_RANDOM_MAP_SIZE) RP->Ysize = MIN_RANDOM_MAP_SIZE + RANDOM () % 25 + 5; @@ -164,7 +165,6 @@ return theMap; } - /* function selects the layout function and gives it whatever arguments it needs. */ char ** @@ -992,12 +992,12 @@ { object *walk, *tmp; - copy_object (src_ob, dest_ob); + src_ob->copy_to (dest_ob); for (walk = src_ob->inv; walk != NULL; walk = walk->below) { - tmp = get_object (); - copy_object (walk, tmp); + tmp = object::create (); + walk->copy_to (tmp); insert_ob_in_ob (tmp, dest_ob); } }