Allefant? Images?
There seem to be some resources missing from allefant_second.zip.
Traceback (most recent call last):
File "run_game.py", line 16, in
main.main()
File "/Local/Games/Python/PyWeek5/allefant5/lib/main.py", line 11, in main
run.main()
File "/Local/Games/Python/PyWeek5/allefant5/lib/run.py", line 200, in main
run.game = Game(run.w, run.h)
File "/Local/Games/Python/PyWeek5/allefant5/lib/game.py", line 21, in __init__
self.background1 = Picture("clock.jpg")
File "/Local/Games/Python/PyWeek5/allefant5/lib/picture.py", line 8, in Picture
pic = CachedPicture(path, area)
File "/Local/Games/Python/PyWeek5/allefant5/lib/picture.py", line 17, in __init__
image = pygame.image.load(data.loadblock(path))
File "/Local/Games/Python/PyWeek5/allefant5/lib/data.py", line 47, in loadblock
io = StringIO(dump.index[filename])
KeyError: 'clock.jpg'
There seem to be no images at all in the zip file.
(log in to comment)
Comments
Well, I tried the little-endian fix, but now I'm getting another problem:
Traceback (most recent call last):
File "run_game.py", line 16, in
main.main()
File "/Local/Games/Python/PyWeek5/allefant5/lib/main.py", line 11, in main
run.main()
File "/Local/Games/Python/PyWeek5/allefant5/lib/run.py", line 200, in main
run.game = Game(run.w, run.h)
File "/Local/Games/Python/PyWeek5/allefant5/lib/game.py", line 21, in __init__
self.background1 = Picture("clock.jpg")
File "/Local/Games/Python/PyWeek5/allefant5/lib/picture.py", line 8, in Picture
pic = CachedPicture(path, area)
File "/Local/Games/Python/PyWeek5/allefant5/lib/picture.py", line 17, in __init__
image = pygame.image.load(data.loadblock(path))
pygame.error: Unsupported image format
I checked, and my pygame definitely has support for jpg images.
Are there any other possible endianness bugs in there?
Okay, got it -- there was another endianness flag further down at line 38.
Thanks for your help.
ServalKatze on
2007/09/14 15:43:
I could run the game just fine (images were there, too) - maybe something's wrong with your download?