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

Re: [pygame] side scroller



On Thu, 12 Sep 2002, Pete Shinners wrote:

> some warnings though. the way you are managing graphics
> now is very memory intensive. also treating the 'world' as
> a single graphic means you won't be able to use hardware
> acceleration if it is needed later. (most video cards
> don't suppose such wide images in hardware). currently the
> image only needs about 800k of ram. but if the game is
> running on a 32bit display (like mine) the image will
> expand to over 3MB when you convert. this is just
> something you'll need to keep in mind. if you fill the
> full 480 screen with pixels and double the width of the
> level, you'll quickly be at 12MB of ram for that
> background image.

Yep. I tripled the width of the world, and it's much worse
now. I'm thinking it might make sense to break it into
blocks the a little bit wider than the screen, and just show
two at a time.. 

It sounds like it might help to actually set the screen mode
to a full-screen mode with fewer colors than to just run it
in a window with whatever bit depth the user is set to..
Otherwise, even a plain black and white image would be slow,
right?

What other options do I have besides "the way you are
managing graphics now"?

 
> the sidescroller physics are tricky. i've tried a couple
> times and have never gotten them to work. once you add the
> platforms it is a sticky situation. for example, when the
> jumping character collides with a platform, has he hit the
> edges of the platform, or landed on top. or maybe he
> jumped into the bottom of it with his head? getting that
> mario-style control is a lot of polish work. :]

I think this can be solved by making two invisible sprites,
each one pixel tall and as wide as the hero.  One rides
around on his head, the other on his feet.  What do you
think?

BTW, I do want to make a mario-style game, but I'm also
thinking about a Maniac-Mansion-style adventure game, so if
the speed turns out to be an issue, this isn't a completely
lost cause... :)

Cheers,

- Michal   http://www.sabren.net/   sabren@manifestation.com 
------------------------------------------------------------
Switch to Cornerhost!             http://www.cornerhost.com/
       High Powered Hosting - With a Human Touch. :)
------------------------------------------------------------

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