楽しい当たり判定

http://d.hatena.ne.jp/ono36/20070718/p1
楽しい。何度も読んじゃう。
XYだと
if( ( rectA.x < RectB.x + RectB.w ) &&
    ( rectB.x < RectA.x + RectA.w ) &&
    ( rectA.y < RectB.y + RectB.h ) &&
    ( rectB.y < RectA.y + RectA.h ) ) {
	/*当たっている場合にこの部分が実行されます*/
}
ですって。楽しい。