mirror of
https://github.com/abakh/nbsdgames.git
synced 2025-02-02 15:07:27 -05:00
11 lines
284 B
Python
11 lines
284 B
Python
import os, sys
|
|
|
|
levels, ext = os.path.splitext(os.path.basename(sys.argv[1]))
|
|
for ext in ['.py', '.bin']:
|
|
levelfile = 'levels/%s%s' % (levels, ext)
|
|
if os.path.exists(levelfile):
|
|
break
|
|
sys.argv[1] = levelfile
|
|
|
|
exec(compile(open('bb.py', "rb").read(), 'bb.py', 'exec'))
|