diff options
| author | Jules Laplace <jules@okfoc.us> | 2015-08-21 16:05:55 -0400 |
|---|---|---|
| committer | Jules Laplace <jules@okfoc.us> | 2015-08-21 16:05:55 -0400 |
| commit | 3e87dcb3de9ad29f7c021792cbafc32d4c758d3f (patch) | |
| tree | 6f73303f7b4c0a47dd8f9d55009795c2181e47af /public/assets/javascripts/ui/blueprint/BlueprintEditor.js | |
| parent | 0c1864a114a2efe1a3bb8b2b4951e8655712757a (diff) | |
assigning sides
Diffstat (limited to 'public/assets/javascripts/ui/blueprint/BlueprintEditor.js')
| -rw-r--r-- | public/assets/javascripts/ui/blueprint/BlueprintEditor.js | 24 |
1 files changed, 8 insertions, 16 deletions
diff --git a/public/assets/javascripts/ui/blueprint/BlueprintEditor.js b/public/assets/javascripts/ui/blueprint/BlueprintEditor.js index 0b27d0c..c7aa219 100644 --- a/public/assets/javascripts/ui/blueprint/BlueprintEditor.js +++ b/public/assets/javascripts/ui/blueprint/BlueprintEditor.js @@ -108,30 +108,22 @@ var BlueprintEditor = View.extend(AnimatedView.prototype).extend({ } shapes.forEach(function(shape){ -// shape.draw(map.draw.ctx) + shape.draw(map.draw.ctx) }) map.draw.ctx.strokeStyle = "#f00"; map.draw.x_at(0,0) map.draw.mouse(map.ui.mouse.cursor) map.draw.camera(scene.camera) - - this.rooms.open_segments.forEach(function(seg,i){ - map.draw.ctx.fillStyle = "rgba(0,0,255,0.2)" - map.draw.ctx.fillRect( seg.x.a, seg.y.a, seg.width()+10, seg.height() ) - }) - - this.rooms.closed_segments.forEach(function(seg,i){ - map.draw.ctx.fillStyle = "rgba(0,255,0,0.2)" - map.draw.ctx.fillRect( seg.x.a, seg.y.a, seg.width()+10, seg.height() ) - }) - var colors = ["rgba(0,0,0,0.1)"] +// var colors = ["rgba(0,0,0,0.1)"] - this.rooms.rooms.forEach(function(room,i){ - map.draw.ctx.fillStyle = colors[i % colors.length] - map.draw.ctx.fillRect( room.x.a, room.y.a, room.width(), room.height() ) - }) + map.draw.regions(this.rooms.rooms, colors, "#000") + +// this.rooms.rooms.forEach(function(room,i){ +// map.draw.ctx.fillStyle = colors[i % colors.length] +// map.draw.ctx.fillRect( room.x.a, room.y.a, room.width(), room.height() ) +// }) map.draw.ctx.restore() }, |
