Beta version :D

Some menus, simple dissolve transitions, ambience music and sound effects. Yep, I'm almost there (although there's still too much to do, like creating bunchs of levels for example XD I really should create some quickly =D)
 
Well, I guess it was time to release something already. Although code is _really_ ugly and I don't think many peoples would like to take a look there (there's almost no comments, and usually I'm a comment freak), but well, it's sort of playable right now (though you can't clear levels yet xD)

Anyways, controls and gameplay instructions are on README.txt file. Make sure if you have xdrlib as well, I'm using it to package the map files (I'm lazy to write a xml parser, you know), it can be downloaded from python's SVN if you don't have it, but it's bundled with Python so it shouldn't be a issue (I guess).

Other than this, I hope you can enjoy the game (there's not much of it yet, I know) :D

I tested it only on Windows XP yet, but it should run on other OS as well (hopefully), anyways if you have some bug please report (all the more if it's a Mac one, as I don't have one D:)

(log in to comment)

Comments

Hi

I thought i'd place a bug report for your demo here.

My system specs are
OS: Slackware 12.2 (linux kernel 2.6)
Single core 1.7 GHz, 512 Mb
pygame 1.9 (default easy_install I didn't roll my own.)
python 1.5.4

Traceback (most recent call last):
  File "/home/jervis/pyweek9/higanbana/higanbana-0.1.1-beta/run_game.py", line 6, in <module>
    higanbana.main()
  File "/home/jervis/pyweek9/higanbana/higanbana-0.1.1-beta/higanbana/higanbana.py", line 72, in main
    core.initializeFonts()
  File "/home/jervis/pyweek9/higanbana/higanbana-0.1.1-beta/higanbana/core.py", line 210, in initializeFonts
    fonts = fontmgr.cFontManager(((None, 24), (None, 36), ('arial', 24)))
  File "/home/jervis/pyweek9/higanbana/higanbana-0.1.1-beta/higanbana/fontmgr.py", line 33, in __init__
    assert fontFullFileName, 'Font: %s Size: %d is not available.' % pair
AssertionError: Font: arial Size: 24 is not available.

This occurs when I run game from source using pygame run_game.py

I then removed the reference to arial font, and replaced with None.

on running again i got.

bash$ python run_game.py
Traceback (most recent call last):
  File "/home/jervis/pyweek9/higanbana/higanbana-0.1.1-beta/run_game.py", line 6, in <module>
    higanbana.main()
  File "/home/jervis/pyweek9/higanbana/higanbana-0.1.1-beta/higanbana/higanbana.py", line 111, in main
    core.next_screen()
  File "/home/jervis/pyweek9/higanbana/higanbana-0.1.1-beta/higanbana/game.py", line 432, in main_menu
    core.play_music("main menu")
  File "/home/jervis/pyweek9/higanbana/higanbana-0.1.1-beta/higanbana/core.py", line 133, in play_music
    pygame.mixer.music.load(file)
pygame.error: Module format not recognized

using pdb I found that the file was a mp3 file (import os;os.path.exists(file) == True)
and pygame's support of mp3 on some systems is limited (according to the documentation.)

I've done some googling and found that there might be a way to run it if you dont have id3 tags in your file? Sorry no time to test that theory here on my end until tonight. An alternative is to ship .ogg files in place of the .mp3

Cheers.



Ubuntu Linux 9.04 i386
Pentium4 monocore @2ghz
python 2.6.2
pygame 1.9

guest@p4:/mnt/sda1/trabalhos/pygame/recolhas/pyweek/09/_rascunhos/higanbana-0.1.1-beta$ python run_game.py
/usr/lib/python2.6/dist-packages/pygame/sysfont.py:139: DeprecationWarning: os.popen3 is deprecated.  Use the subprocess module.
  flin, flout, flerr = os.popen3('fc-list : file family style')
Traceback (most recent call last):
  File "run_game.py", line 6, in <module>
    higanbana.main()
  File "/mnt/sda1/trabalhos/pygame/recolhas/pyweek/09/_rascunhos/higanbana-0.1.1-beta/higanbana/higanbana.py", line 111, in main
    core.next_screen()
  File "/mnt/sda1/trabalhos/pygame/recolhas/pyweek/09/_rascunhos/higanbana-0.1.1-beta/higanbana/game.py", line 249, in main_game
    load_level(level, mc)
  File "/mnt/sda1/trabalhos/pygame/recolhas/pyweek/09/_rascunhos/higanbana-0.1.1-beta/higanbana/game.py", line 156, in load_level
    core.level.load("map/level_" + str(levelN) + ".rmap")
  File "/mnt/sda1/trabalhos/pygame/recolhas/pyweek/09/_rascunhos/higanbana-0.1.1-beta/higanbana/map.py", line 337, in load
    self.genBitmask()
  File "/mnt/sda1/trabalhos/pygame/recolhas/pyweek/09/_rascunhos/higanbana-0.1.1-beta/higanbana/map.py", line 289, in genBitmask
    bmSurf.fill((0,0,0,255), rect=(pygame.Rect(x*tw+self.x,y*th+33+self.y,tw,th)))
TypeError: fill() takes no keyword arguments
guest@p4:/mnt/sda1/trabalhos/pygame/recolhas/pyweek/09/_rascunhos/higanbana-0.1.1-beta$
@jtrain:
Hm, I thought I've removed references for arial fonts xD (now they're removed)

About the music files, I was going to use OGG at start, but there's some strange bug in pygame.mixer.music that makes them freeze the game (at least on Windows), I've tried changing the encoding and stuff but don't seems to be a problem with the file.

I guess I'll have to use XM/IT/MID files for music .-. (and I had so many good mp3 files here)

@nitrofurano
Hm... I'm using Python 2.5, so I didn't got this error. But by reading PyGame's docs it seems that rect is a keyword argument (maybe something changed in Python 2.6 or in PyGame for Python 2.6), anyways just removing the keyword works :D

btw, are you brazilian or portuguese?
For what it's worth, I had no errors with the demo on windows 7, python2.6, pygame 1.9.  I do know I have seen mp3s not work in places though, so that comment in the docs is not unfounded.

Ogg files should not freeze, they work fine on every windows (and non-windows) system I have tested (and I have something that is fairly widely tested with no freezing reports). Also, if I convert the main menu to an ogg, it plays just fine. I wonder what is going on with your computer? Are you sure the .ogg file was a proper .ogg?
also at some point it was a problem with pygame 1.8.1 related to change-restart music.
There was a workaround for 1.8.1, was less notable in 1.7, fixed in 1.9 series, see:
http://thread.gmane.org/gmane.comp.python.pygame/15321/focus=15383
 
Note that there the bugdemo was playing .mod files.
 
And in the 1.7 vs, mp3 support was flaky, much better the ogg support.




@killdream
thanks, i'll see that!
about the question, besides i were born in Portugal, and lived half of my life in Brazil, i have both nationality, because i have family in both countries