Bouncing squares

I believe you. I don't know anything about the algorithm it uses to determine if irregular shapes are touching at any point.

Try it now... sometime it's better...

The patch


That is better, but of course it's a kludge that you have to work around a limitation in Snap!. (And it still bounces off the edge way before actually hitting it; you'd think that'd be the easiest thing for Snap! to get right.)

ahhhh. i think i know why

i dont know the exact code used for the block but the reason is because an image in bitmap in order to look clean has gradients. these gradients are at the edge of the image also and are nearly invisible but still there

EDIT: there is no real way to fix this without going into the pixels of the image and calculating your own is touching block. tho you can simulate a fix by just continuing the movement for a couple steps after it senses it touching

I think that's what @loucheman did!

PS There's a rumor that you can tell Javascript not to use antialiasing when drawing lines. (I don't mean you, the Snap! user, can add JS code to do that; I mean Snap! could do it. But it's only a rumor, denied by Jens. I am only an egg.)

do i have permission to look into it

What? You don't need our permission to look into things. That's the whole idea of free software. What annoys Jens is people turning the forum into a discussion of JS instead of Snap!. And also people posting Github bug reports about things that aren't bugs.