[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [pygame] Hi, I'm new...

> On 07 Jul 2001 11:39:30 +1000, Glen Wheeler wrote:
> >   Greetings pygame-ists,
> >
> >   I've been told to develop a game, and have been given very detailed
> > My first inclination was to do it with tkinter, as I had done all my
> > previous python games.
> >   However tkinter has so many horrible limitations w/r to games that I
> > forced to look into other options.  So, here I am with pygame.
> >   My question right now (before I start learning another wrapper :) is
> > it feasible to use pygame?'.  The game I'm developing (with the help of
> > team, I'm just head programmer/project head) will be an RPG based on a
> > called Warhammer Quest.  The first thing I'll need is a relatively big
> > resolution, say eg 1024x768.  Also, the main area where all the action
> > place would be lovely as a changeable camera angle in a 3d world - but I
> > think I'm dreaming there.  I'll probably end up with something ala
> > I&II.  If I did have the time, could I develop a 3d engine for pygame?
> > (even better) is there one already available?
> You could develop a 3D engine for pygame using PyOpenGL.  But it's
> probably not the level of abstraction you're looking for as a Python
> programming.  OpenGL is pretty low level, but it works.  A diablo-ish
> engine would work very well in pygame with bitmaps though.

  I think that's what I'm looking for.  A 3d engine in pyOpenGL is just too
complicated for me to implement with the time constraints I have.  Perhaps
next time :)

> >   I have plenty of other questions, but I'm almost 90% sure they can be
> > so I'll just ask this one - how well does pygame support threads?  One
> > problem with tkinter is the fact that you can't have threaded operations
> > which all update the GUI - tcl crashes, every time.  And the workaround
> > not pretty.
> As far as I know ppygame is pretty darn threadsafe

  Great to hear.

> >   Say eg that 4 warriors were standing in a dungeon room.  I would like
> > all to be doing something each - breathing, reading a scroll, playing
> > magic in the air, practising swings etc.  My solution would be to use a
> > seperate thread for each warrior - would this work in pygame, and if not
> > would you approach it?
> If I was doing it without threads, I would just use a game loop.. where
> every frame it calls a method of every player object to update itself..
> This is how most things work... usually you'll only have two or three
> threads in a game, not one per player.. there isn't really a reason for
> it, it's much easier to keep synchronization if you have only one thread
> updating the players, and it's not going to complicate the code very
> much at all.

  Indeed, I realised my example was faulty almost right after I had sent it
:)  I am thinking of keeping one thread on all the game events, and another
on any underground operations (like what Pete was talking about, with http
access and a progress bar).


> -bob
> ____________________________________
> pygame mailing list
> pygame-users@seul.org
> http://pygame.seul.org

pygame mailing list