… | |
… | |
333 | } |
333 | } |
334 | |
334 | |
335 | /* put a chest into the map, near x and y, with the treasure style |
335 | /* put a chest into the map, near x and y, with the treasure style |
336 | determined (may be null, or may be a treasure list from lib/treasures, |
336 | determined (may be null, or may be a treasure list from lib/treasures, |
337 | if the global variable "treasurestyle" is set to that treasure list's name */ |
337 | if the global variable "treasurestyle" is set to that treasure list's name */ |
338 | object * |
338 | static object * |
339 | place_chest (int treasureoptions, int x, int y, maptile *map, maptile *style_map, int n_treasures, random_map_params *RP) |
339 | place_chest (int treasureoptions, int x, int y, maptile *map, maptile *style_map, int n_treasures, random_map_params *RP) |
340 | { |
340 | { |
341 | object *the_chest = archetype::get (shstr_chest); /* was "chest_2" */ |
341 | object *the_chest = archetype::get (shstr_chest); /* was "chest_2" */ |
342 | |
342 | |
343 | /* first, find a place to put the chest. */ |
343 | /* first, find a place to put the chest. */ |
… | |
… | |
499 | return theMonsterToFind; |
499 | return theMonsterToFind; |
500 | } |
500 | } |
501 | |
501 | |
502 | /* sets up some data structures: the _recursive form does the |
502 | /* sets up some data structures: the _recursive form does the |
503 | real work. */ |
503 | real work. */ |
504 | object * |
504 | static object * |
505 | find_monster_in_room (maptile *map, int x, int y, random_map_params *RP) |
505 | find_monster_in_room (maptile *map, int x, int y, random_map_params *RP) |
506 | { |
506 | { |
507 | Layout layout2 (RP); |
507 | Layout layout2 (RP); |
508 | |
508 | |
509 | layout2->clear (); |
509 | layout2->clear (); |
… | |
… | |
674 | *cx = -1; |
674 | *cx = -1; |
675 | *cy = -1; |
675 | *cy = -1; |
676 | } |
676 | } |
677 | } |
677 | } |
678 | |
678 | |
679 | void |
679 | static void |
680 | remove_monsters (int x, int y, maptile *map) |
680 | remove_monsters (int x, int y, maptile *map) |
681 | { |
681 | { |
682 | for (object *tmp = GET_MAP_OB (map, x, y); tmp; ) |
682 | for (object *tmp = GET_MAP_OB (map, x, y); tmp; ) |
683 | { |
683 | { |
684 | object *next = tmp->above; |
684 | object *next = tmp->above; |