| Total Complexity | 1 |
| Total Lines | 13 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | from typing import Tuple, List |
||
| 2 | |||
| 3 | import pygame |
||
| 4 | |||
| 5 | |||
| 6 | def load_sprites_from_dir( |
||
| 7 | directory: str, file_list: Tuple[str, ...] |
||
| 8 | ) -> List[pygame.Surface]: |
||
| 9 | """Return a dictionary of the map sprites from a given directory.""" |
||
| 10 | return [ |
||
| 11 | pygame.image.load(f'{directory}/{file_name}.png') |
||
| 12 | for file_name in file_list |
||
| 13 | ] |
||
| 14 |