[comp.sys.amiga.tech] Bob Inefficiencies

hansel@amy.UUCP (Steve Hansel) (07/17/88)

I preparation for writing a 'Killer Demo' I've been playing with bobs.
Recently, I performed the following experiment:

I created 15 good sized (128 x 59) bobs on the screen in such a way that
they didn't overlap.  I then moved only one bob by changing Bob.X and
Bob.Y, doing a SortGList, and then DrawGList.  To my surprise ALL bobs are
erased and redrawn.

Besides bothering my sense of efficiency, this will make my program very slow.
I would like to write a routine that examines the GList and tells the system
which bobs not to redraw.

I plan to only redraw bobs that have changed position or are overlapping with
bobs that are being redrawn.  This is where the problem is.  How do I
tell the DrawGList routine not to erase and redraw a bob?  I've tried
setting the BDRAWN flag but this doesn't seem to have any effect.  The only
thing I can think to do, is remove those bobs from the Glist, do the 
DrawGList and then put them back.

Can anyone think of an easier or better method?

	Thanks

	Steve Hansel

	rutgers!amy!hansel
	gryphon.cst.com!amy!hansel
	oberon.usc.edu!amy!hansel