[racket] Doing collision detection in universe.ss

From: Shriram Krishnamurthi (sk at cs.brown.edu)
Date: Wed Nov 28 16:08:28 EST 2012

Yaron, this summer my students, Kathi Fisler, and I built a block-based,
functional language with types (expressed as colors) and testing. It runs
in the browser, uses the WeScheme runtime and can express most Bootstrap

It needs more polish before we can release it to the world. We would be
happy to give previews to anyone who wants to see them.

Sent from phone. Please pardon terseness and mistakes.
On Nov 28, 2012 7:38 AM, "Yaron Minsky" <yminsky at gmail.com> wrote:

> To be clear, I'm firmly interested in tinkering, which is why I'm
> using universe.ss and image.ss.
> I do think that a good design goal for Racket's kid-oriented libraries
> would be to be feature compatible with Scratch.  It would be great if
> there were good ways of doing everything that Scratch can do, from
> playing sounds to detecting collisions, to (more aggressively) on-line
> hosting of the final result.  I'd love it if Racket were strictly
> better than Scratch for someone who really can figure out how to
> program, but it's just not true now.
> y
> On Wed, Nov 28, 2012 at 7:11 AM, Hendrik Boom <hendrik at topoi.pooq.com>
> wrote:
> > On Tue, Nov 27, 2012 at 08:56:13PM -0500, Yaron Minsky wrote:
> >> I've been weaning my son off of Scratch in favor of Racket, and trying
> >> to get him to write interactive games using universe.ss and image.ss.
> >> I'm wondering if anyone has suggestions for how to do things like
> >> collision detection.  image.ss has these nice first-class images, but
> >> I don't see a good way of querying two images to see if they overlap.
> >>
> >> Has anyone else had luck in doing this?  universe has a nice
> >> programming model, but I've found it challenging to find simple ways
> >> of doing the kinds of things that Scratch makes easy.
> >
> > There are two arts to collision detection: figuring out whether two
> > images collide (which gets trickier when they're in motion) and
> > organising all your objects so you don't have to test very many
> > combinations of them.
> >
> > Both of these can get quite complicated, and are susceptible to
> > nontrivial, complicated, and often necessary efficiency improvements
> > depending on special properties of the game.
> >
> > A one-size-fits-all solution may be good enough for tinkering with, but
> > serious use may well need serious hacking.
> >
> > -- hendrik
> > ____________________
> >   Racket Users list:
> >   http://lists.racket-lang.org/users
> ____________________
>   Racket Users list:
>   http://lists.racket-lang.org/users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20121128/d80eedf7/attachment.html>

Posted on the users mailing list.