Skip to content

Commit

Permalink
fixed erase bug, hit bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Ben D'Angelo committed Sep 22, 2012
1 parent 1e54d93 commit 50de549
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/core/query.js
Expand Up @@ -443,7 +443,7 @@
*/
p.erase = function(ref){
for(var i=this.length; i--;){
for(var i=0; i<this.length; i++){
if(this[i] == ref) this.splice(i, 1);
}
return this;
Expand Down
8 changes: 4 additions & 4 deletions src/math/hit.js
Expand Up @@ -31,10 +31,10 @@ re.c('hit')

return !
(
x - rx > this.posX + this.sizeX + regX ||
x + w + rx < this.posX - regX ||
y - ry > this.posY + this.sizeY + regY ||
y + h + ry < this.posY - regY
x + rx > this.posX + this.sizeX - regX ||
x + w - rx < this.posX + regX ||
y + ry > this.posY + this.sizeY - regY ||
y + h - ry < this.posY + regY
);
}

Expand Down

0 comments on commit 50de549

Please sign in to comment.