[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] blitting from-to surface with per-pixel alpha doesn't work...



On Mon, 2005-11-28 at 10:20 -0500, Kris Schnee wrote:
> D. Gyimesi wrote:
> > The tank have turrets that are need to be rotated around its pivots
> > (when you move the mouse), and the whole tank should be rotatable around
> > its own pivot (when you press WASD). For example when you move the tank
> > and you want to turn to any directions.
> 
> Have you thought about using a limited number of pre-drawn frames 
> showing the tank parts facing different directions? You'd have to 
> calculate that a tank facing E with its turret 90 degrees to the right 
> should use the "turret facing S" frame, but that'd save you the 
> "expensive" rotation of images each frame.
> 
> Kris

The problem with pre-drawn frames is that almost every frame has a lot
of animation frames (shooting, damages, etc.), so this approach yield
more difficulities on drawing the animation phases.

-- 
DÃme

        Home: http://dgyimesi.uw.hu