Re: highscores list

2007-12-08 Thread Bruno Desthuilliers
Bruno Desthuilliers a écrit : (snip) > # hiscores.py > import sys > > def _read_scores(path): > f = open(path) > # we don't expect a huge file so it's simpler to > # read it all in memory > lines = f.readlines() > f.close() > > scores = [] > for line in filter(None, ma

Re: highscores list

2007-12-08 Thread Bruno Desthuilliers
Shawn Minisall a écrit : > I'm writing a game that uses two functions to check and see if a file > called highScoresList.txt exists in the main dir of the game program. > If it doesn, it creates one. That part is working fine. The problem is > arising when it goes to read in the high scores f

Re: highscores list

2007-12-08 Thread Samuel
On Sat, 08 Dec 2007 13:32:08 -0500, Shawn Minisall wrote: > I'm writing a game that uses two functions to check and see if a file > called highScoresList.txt exists in the main dir of the game program. If > it doesn, it creates one. That part is working fine. The problem is > arising when it goe

Re: highscores list

2007-12-08 Thread Chris
On Dec 8, 10:07 pm, Chris <[EMAIL PROTECTED]> wrote: > On Dec 8, 8:32 pm, Shawn Minisall <[EMAIL PROTECTED]> wrote: > > > > > I'm writing a game that uses two functions to check and see if a file > > called highScoresList.txt exists in the main dir of the game program. > > If it doesn, it creates o

Re: highscores list

2007-12-08 Thread Zepo Len
> I'm writing a game that uses two functions to check and see if a file > called highScoresList.txt exists in the main dir of the game program. > If it doesn, it creates one. That part is working fine. The problem is > arising when it goes to read in the high scores from the file when I

Re: highscores list

2007-12-08 Thread Chris
On Dec 8, 8:32 pm, Shawn Minisall <[EMAIL PROTECTED]> wrote: > I'm writing a game that uses two functions to check and see if a file > called highScoresList.txt exists in the main dir of the game program. > If it doesn, it creates one. That part is working fine. The problem is > arising when it g