Hi guys,
Thanks for all the ideas..... I apologize if I wasn't clear enough in my OP.
Since we found that collisions and rects are a stretch for beginning programmers, my colleague came up with the following code:
def imagesCollide(pic1,p1x,p1y,pic2,p2x,p2y):
  aRect = pic1.get_rect(center=[p1x,p1y])
  bRect = pic2.get_rect(center=[p2x,p2y])Â
 Â
  if aRect.colliderect(bRect):
    return True;
  else:
    return False;
So that allows us to replicate what we used last year in Blitz Basic, which was
ifImagesCollide(pic1,pic1x,pic1y, pic2, pic2x, pic2y)
One line of code! We (the other teacher and I understand rects but feel that the time spent explaining them was not commensurate with the value the students get at this level.
As for keyboard movement, in BlitzBasic it's
if keydown(right) then....
One line again! So no need to introduce the for event loop, etc.
We are making the switch to Python/Pygame because no one has ever heard of Blitz Basic, and we thought it was perhaps time to update, since most of the world is moving to Python for introducing text-based coding.
However, some of these things make us go hmmm....
Thanks in advance,
Bob Irving
Porter-Gaud School
Charleston, SC