## Re: [stella] he got game

 Subject: Re: [stella] he got game From: KirkIsrael@xxxxxxxxxxxxx Date: 2 Sep 2003 02:48:04 -0000
```>
> * When the player flaps (or moves left/right) you don't modify the position,
> you modify the speed
>
> * every frame, decelerate (slow down) the speed slightly (if you want
> friction)
>
> * every frame, add gravity to the speed for those objects affected by
> gravity
>
> * every frame, after all other calculations are done, the speed is added to
> the position to give the new position
>

Actually, this does describe pretty accurately how the up and down
speed of the paddles is now, which is what gives it its good floaty
motion. (And there's even something like the friction you describe,
in that when you hit the floor, you rebound with half the speed you
hit with.)

In fact, I find this is generally a wonderful way of making
simple games have complexity...
http://alienbill.com/abp/ , besides having JoustPong for Windows
(and Palm, and Java) there's an old 2-player only game I made
"InterGalactic SpaceMan BlastFest"...it was reasonably fun for
two players, but would have been really not much of anything without
the concept of inertia you describe.

(For that matter, "SFCave" utilizes the same thing...)

Anyway, in terms of allowing left and right movement, one concept
that came up early in rgvc was something like "JoustPolo"...
similar to what you describe, except I think it had the idea that
you can fly all the way across the court, not just on your side

AI possibly becomes more of a challenge for this kind of thing.
I don't know what beyond a simple "chase the ball" strategy I could
do...some complexity, like try not to chase the ball into your own
goal I suppose!

Hrm, maybe I do need to look into fractional speeds,  round down
to the nearest integer for what's actually added to the relevant
position each frame.  (Since after all, even "4/5 rounding" is
truncation but with a different window) Eww, pos/neg is going to
need some careful work

thx,
k

--
KirkIsrael@xxxxxxxxxxxxx    http://kisrael.com
"It's the cracked ones who let all the light into the world."
--writer from my Tufts writing class

----------------------------------------------------------------------------------------------
Archives (includes files) at http://www.biglist.com/lists/stella/archives/
Unsub & more at http://www.biglist.com/lists/stella/

```