Ejemplo n.º 1
0
 def generate_battle_map(self, state):
   old_player_coords = (state.player.x, state.player.y)
   rooms = MapCreation.make_battle_map(state)
   MapCreation.populate_rooms(state, rooms)
   self.complete_game_map[0] = self.game_map
   if state.dungeon_level >= 1:
     state.player.x, state.player.y = old_player_coords
Ejemplo n.º 2
0
 def generate_map(self, state, level):
   old_player_coords = (state.player.x, state.player.y)
   rooms = MapCreation.create_map_layout(state, level)
   state.player.x, state.player.y = rooms[0].center()
   MapCreation.place_objects_in_rooms(state, rooms, old_player_coords)