Final Submission - Aranara
Ok, I submitted my final version.I ended up with 12 levels. I was able to incorporate all of the gameplay elements that I developed all week and overall I am very happy with the game. I think there is plenty of polishing that can be done and lots of the ideas in the levels can be expanded upon. I will do that later after a bit of recuperation!
I never did get to the bottom of the music bug on OSX (I'm pretty sure it is pyglet or avbin) and on my linux box sometimes parts of the batch do not render properly. It looks like this might be a Catalyst driver issue.
Now I am looking forward to trying out the games from everyone else!
(log in to comment)
Comments
http://media.pyweek.org/dl/17/Aranara/aranara-0.2.3.tar.gz
Git repository of the game: https://code.google.com/p/aranara/
Download of the final game: Git repository of the game: https://code.google.com/p/aranara/
line 1387, in load return riff.WaveSource(filename, file) File
"/home/nuno/Jogos/pyweek/env/lib/python2.7/site-packages/pyglet/media/riff.py",
line 201, in __init__ 'AVbin is required to decode compressed media')
pyglet.media.riff.WAVEFormatException: AVbin is required to decode compressed media
I have installed AVbin from
http://avbin.github.io/AVbin/Home/Home.html
and got the message at the end of the
process: AVbin 10 successfully installed.
but still no luck.
https://github.com/AVbin/AVbin/downloads
I had a lot of problems with AVBin 10 and some wave files (specially short ones).
In my experience is better to install AVBin 11 alpha in Linux: I had a lot of problems with AVBin 10 and some wave files (specially short ones).
I just checked my Linux box and the AVBin I downloaded for testing was v7 I think! (https://code.google.com/p/avbin/). This appears to be way out of date compared to what reidrac is pointing to but it did work on Linux Mint 13 (64-bit).
Let me know if you are still not able to get it to work.
Paul
It seems that whatever is looking for AVbin can't find it in my system...
Add the following to the end of aranara/sound.py
class DummyPlayer:
def __init__(self, *args, **kw):
pass
def dummy(self, *args, **kw):
pass
play = pause = stop = queue = dummy
playing = False
pyglet.resource.media = DummyPlayer
pyglet.media.Player = DummyPlayer
Traceback (most recent call last):
File "C:\Users\Marek\Downloads\pyweek\aranara-0.2.3.tar\dist\aranara-0.2.3\run_game.py", line 23, in <module>
aranara.__main__.main(options)
File "C:\Users\Marek\Downloads\pyweek\aranara-0.2.3.tar\dist\aranara-0.2.3\aranara\__main__.py", line 25, in main
pyglet.resource.reindex()
File "C:\Python26\lib\site-packages\pyglet\resource.py", line 328, in reindex
'Backslashes not permitted in relative path'
AssertionError: Backslashes not permitted in relative path
Two approaches here (I don't have a windows machine to check):
1. Change line 22 in aranara/__main__.py from
pyglet.resource.path = [
'data', os.path.join('data', 'levelicons'), os.path.join('data', 'music'),
os.path.join('data', 'scified2002')]
to:
to:
pyglet.resource.path = [
'data', 'data/levelicons', 'data/music',
'data/scified2002']
I think this should work as Python on windows treats forward and back slashes the same.
2. Change line 22 to
I think this should work as Python on windows treats forward and back slashes the same.
2. Change line 22 to
pyglet.resource.path = ['data']
AND
Go into the "data" folder and copy the contents of the sub-folders "levelicons", "music" and "scified2002" into the "data" folder.
This is the sledgehammer approach but should work also.
Let me know if it works.
AND
Go into the "data" folder and copy the contents of the sub-folders "levelicons", "music" and "scified2002" into the "data" folder.
This is the sledgehammer approach but should work also.
Let me know if it works.
"""Paths are always case-sensitive and forward slashes are always used as path
separators, even in cases when the filesystem or platform does not do this.
This avoids a common programmer error when porting applications between
platforms."""
So, in order to prevent a common programmer error where a programmer forgets to put platform independent code in there, pyglet creates a game bug when the programmer remembers to do the right thing ;)
I guess it is a trap to catch out a programmer who thinks he knows better than to read the documentation - consider me trapped!
So, in order to prevent a common programmer error where a programmer forgets to put platform independent code in there, pyglet creates a game bug when the programmer remembers to do the right thing ;)
I guess it is a trap to catch out a programmer who thinks he knows better than to read the documentation - consider me trapped!
Hmm... Thanks for solving the first error, that was just awkward from Pyglet team :) But now I'm getting another error... :( Almost looks like it's my destiny not to run this game...
Traceback (most recent call last):
Traceback (most recent call last):
File "run_game.py", line 23, in <module>
aranara.__main__.main(options)
File "C:\Users\Marek\Downloads\pyweek\aranara-0.2.3.tar\dist\aranara-0.2.3\aranara\__main__.py", line 32, in main
start = startscreen.StartScreen('start-screen', options)
File "C:\Users\Marek\Downloads\pyweek\aranara-0.2.3.tar\dist\aranara-0.2.3\aranara\engine\world.py", line 35, in __init__
self.batches = collections.OrderedDict()
AttributeError: 'module' object has no attribute 'OrderedDict'
Two possible solutions (there's always two!)
1. Upgrade python (or create a virtualenv)
2. I think the game doesn't actually need the OrderedDict and an ordinary dict will work so change line 35 in aranara/engine/world.py from,
self.batches = collections.OrderedDict()
to
to
self.batches = {}
I did a quick test and it seems OK. It might cause the wrong draw order and things might disappear from view although from my test I didn't spot anything.
Another option is to monkey-patch OrderedDict into your version of Python. But I wouldn't necessarily recommend that ;) https://pypi.python.org/pypi/ordereddict
I did a quick test and it seems OK. It might cause the wrong draw order and things might disappear from view although from my test I didn't spot anything.
Another option is to monkey-patch OrderedDict into your version of Python. But I wouldn't necessarily recommend that ;) https://pypi.python.org/pypi/ordereddict
paulpaterson on 2013/09/08 04:16:
Here is the video of the completed game (even faithfully showing the music bug!).http://youtu.be/gOxoX0vPu0k
The actual framerate is higher than this (usually 60fps on my Mac mini) but capturing the video slows it down quite a bit.