Gamer125 / fofix

Automatically exported from code.google.com/p/fofix
0 stars 0 forks source link

Tracks other than 'song' cannot be loaded #1274

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Describe the problem. What did you expect? What do you see?
The guitar, drum, and rhythm tracks don't play in-game.

List the steps to recreate the problem.
1.Open the game
2.Select any song, any difficulty
3.Hit all notes so that track should continue to play

What version are you using? Include the FoFiX version, the Python version,
your operating system, and whether it is Git, alpha, beta, RC, or final
release.  (If it's Git, please include the commit hash.)

Game version: 3.121 final
Python version: 2.6.7-3
OS: Linux Mint Debian Edition x64

Did you read the wiki on how to report bugs, conveniently called
ReportingBugs? If this is a bug report, please include the log file!

I believe that these are the lines from the log file that are relevant:

[   35.564308] (W) Unable to load guitar track: global name 'zeros' is not 
defined
[   35.564409] (W) Unable to load rhythm track: global name 'zeros' is not 
defined
[   35.564454] (W) Unable to load drum track: global name 'zeros' is not defined

My complete log file is attached.

I have gathered that "zeros" is a numpy function, and have tried re-installing 
numpy, but the problem persists. I have also tried installing pygame 1.91 from 
the Debian unstable repository, to no avail.

Original issue reported on code.google.com by iislsdum on 31 Dec 2011 at 9:34

Attachments:

GoogleCodeExporter commented 9 years ago
I have the same problem!I found somewhere that lines 231-233 need to be 
de-indented by two, but these causes a "(pygame parachute) Floating Point 
Exception" problem and the game exits just before the song begins.Any ideas??

Original comment by alexots...@gmail.com on 14 Mar 2012 at 7:07

GoogleCodeExporter commented 9 years ago
Okay, so the problem seems to be that Debian is no longer packaging Numeric, 
and when import Numeric fails in Audio.py, the game crashes.

This is actually patched in Debian (debian/patches/no_numeric_module in sid at 
least), with the patch below.  A better way to fix it though would be to put 
the "import Numeric" in a try/except block, and then fall back to using numpy 
if that doesn't work. e.g. (untested):

{{{
...
if tuple(int(i) for i in pygame.__version__[:5].split('.')) < (1, 9, 0):
  # Must use Numeric instead of numpy, since PyGame 1.7.1 is
  # not compatible with the latter, and 1.8.x isn't either (though it claims to be).
  try:
    import Numeric
    def zeros(size):
      return Numeric.zeros(size, typecode='s')   #myfingershurt: typecode s = short = int16
  except:
    import numpy
    def zeros(size):
      return numpy.zeros(size, dtype='h')
else:
...
}}}

Attached is the debian patch for reference (basically just commenting out some 
lines)

Now back to playing :D

Original comment by shigaw...@gmail.com on 30 Mar 2012 at 1:54

Attachments:

GoogleCodeExporter commented 9 years ago
Sorry my bad! it seems i didn't explain well what i did!

 I have tried this patch and also just tried what you suggested but it didn't work. So, as i stated in my previous comment, i read somewhere that a possible problem would be that the line "import nympy" etc.. is thought to be part of the sound class (the above class) and thus not working! So it was suggested to de-intend these lines (231-233) by two..Unfortunately this didn't work either!

So no solution yet :/

Original comment by alexots...@gmail.com on 1 Apr 2012 at 2:29

GoogleCodeExporter commented 9 years ago
Any fix?? I tried many things but have found nothing!

Original comment by alexots...@gmail.com on 12 Jun 2012 at 12:10

GoogleCodeExporter commented 9 years ago
Yeah I discovered this bug yesterday when I decided to play again with my old 
collection of songs. Horror, nothing playble in linux now !!!
So I spent my whole day on it, and found a solution : the problem is in 
pyvorbis, you need to patch it and reinstall it (it tries to force a function 
type in an array of callbacks which is suicidal, it's a miracle that this thing 
ever worked, but it gave me troubles).
Anyway I'll try to post the patch to debian or something later.
Meanwhile if you are interested, here it is.

Original comment by emmanuel...@gmail.com on 28 Jul 2012 at 4:23

Attachments:

GoogleCodeExporter commented 9 years ago
ok i'll give it a try as soon as possible (i'm on vacation now). In about 10 
days i'll post my results here.

Original comment by alexots...@gmail.com on 11 Aug 2012 at 10:45

GoogleCodeExporter commented 9 years ago
i applied the patch, no more "(pygame parachute) Floating Point Exception", but 
now it says "Unable to load guitar track: 'NoneType' object has no attribute 
'__getitem__'". So no guitar sound... I tried to figure out the cause of this. 
It semms that there is a  __getitem__  only in song.py and shader.py.. 
Obviously we are concerned about the Song.py.
I'll try to fix this. Thanks for the patch anyway!

Original comment by alexots...@gmail.com on 18 Aug 2012 at 4:06