diff options
| author | Jules Laplace <jules@okfoc.us> | 2014-05-02 13:25:44 -0400 |
|---|---|---|
| committer | Jules Laplace <jules@okfoc.us> | 2014-05-02 13:25:44 -0400 |
| commit | 623916fe0961c6a2baeb3038224c22575050186d (patch) | |
| tree | 0937c16eedc744fd33ae4c42fd588e206a29d44a /assets/javascripts/rectangles/models/wall.js | |
| parent | b9f007562712688612269fad9c71df2d4981acaa (diff) | |
starting refactor
Diffstat (limited to 'assets/javascripts/rectangles/models/wall.js')
| -rw-r--r-- | assets/javascripts/rectangles/models/wall.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/assets/javascripts/rectangles/models/wall.js b/assets/javascripts/rectangles/models/wall.js index 8a74782..88eb75d 100644 --- a/assets/javascripts/rectangles/models/wall.js +++ b/assets/javascripts/rectangles/models/wall.js @@ -51,7 +51,7 @@ window.Wall = (function(){ Wall.prototype.bounds_for = function(img) { var coord = this.side & FRONT_BACK ? this.rect.x : this.rect.y return new Rect( new vec2( coord.a + img.width/2, coord.b - img.width/2 ), - new vec2( img.height/2, clipper.rooms[this.room].height - img.height/2 ) ) + new vec2( img.height/2, Rooms.list[this.room].height - img.height/2 ) ) } Wall.prototype.fits = function(img){ if (this.side & FRONT_BACK && this.rect.x.length() < img.width) { @@ -104,7 +104,7 @@ window.Wall = (function(){ Wall.prototype.siblings = function(){ var base = this var match = base.side | base.half_side - var walls = clipper.rooms[this.room].walls.filter(function(w){ + var walls = Rooms.list[this.room].walls.filter(function(w){ return (w.side | w.half_side) & match }) return walls; |
