Python game programming?
Pete Shinners
pete at shinners.org
Mon Jan 7 01:42:03 EST 2002
Jordan wrote:
> I'm interested in doing game development with Python, but I'm beginning to
> wonder about the feasability. Someone recently posted a real-world example
> of Python being 700x slower than C, which would obviously be bad for games.
> I realize that real-time 3d is probably out of the question, but what about
> a 2d isometric engine like Baldur's Gate or Diablo? Would it be possible
> to make something like that using PyGame? If not, which lang should I use
> (I have some experience with C/C++, but I'd have to "refresh" my memory)?
> Would Delphi be a better choice than C/C++ for this sort of thing? Thanks
> in advance for your time and help.
also remember games like quake3 and unreal run as intepreted bytecode.
although, the language is a bit more efficient/simpler than python.
compiling the quake3 bytecode to native dll's on windows yeilds a 5-10%
improvement (if i remember correctly).
i've written games like solarwolf and getting over 40fps with python is
not a problem, in fact a large percentage of the runtime is still spent
inside C graphics code.
using pygame i'd say your program will run about 15% slower than a
similar program written in C using SDL. pygame and sdl are good for a
lot of games, but don't expect high framerates for fullscreen scrolling.
this is a slightly 'weak' area for current version of SDL on software
display devices. expect about 20-30 fps for that type of game, but it
jumps up to around 100 if you use directx hardware or linux dga.
More information about the Python-list
mailing list