Mercurial > touhou
comparison eosd @ 338:65453340ae95
Print an error when all the needed files aren’t present.
author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> |
---|---|
date | Wed, 04 Jul 2012 18:08:57 +0200 |
parents | bc162f60f0a0 |
children | 7a05edbab88a |
comparison
equal
deleted
inserted
replaced
337:bc162f60f0a0 | 338:65453340ae95 |
---|---|
13 ## GNU General Public License for more details. | 13 ## GNU General Public License for more details. |
14 ## | 14 ## |
15 | 15 |
16 import argparse | 16 import argparse |
17 import os | 17 import os |
18 import sys | |
18 | 19 |
19 import pyximport | 20 import pyximport |
20 pyximport.install() | 21 pyximport.install() |
21 | 22 |
22 from pytouhou.resource.loader import Loader | 23 from pytouhou.resource.loader import Loader |
49 | 50 |
50 | 51 |
51 | 52 |
52 def main(path, data, stage_num, rank, character, replay, boss_rush, fps_limit, single_buffer): | 53 def main(path, data, stage_num, rank, character, replay, boss_rush, fps_limit, single_buffer): |
53 resource_loader = Loader(path) | 54 resource_loader = Loader(path) |
54 resource_loader.scan_archives(data) | 55 |
56 try: | |
57 resource_loader.scan_archives(data) | |
58 except IOError: | |
59 sys.stderr.write('Some data files were not found, did you forget the -p option?\n') | |
60 exit(1) | |
55 | 61 |
56 if stage_num is None: | 62 if stage_num is None: |
57 story = True | 63 story = True |
58 stage_num = 1 | 64 stage_num = 1 |
59 else: | 65 else: |