summaryrefslogtreecommitdiff
path: root/assets/javascripts/rectangles/models/wall.js
diff options
context:
space:
mode:
authorJules Laplace <jules@okfoc.us>2014-04-25 16:08:48 -0400
committerJules Laplace <jules@okfoc.us>2014-04-25 16:08:48 -0400
commit1b06bfa4b67747229c3283a9466047b1daece035 (patch)
treecd889dd15463324be0c03aaa96bca6eeaf89052e /assets/javascripts/rectangles/models/wall.js
parent0772bb5e55d0d00c925620a27b59a7f52aaa4199 (diff)
improve names
Diffstat (limited to 'assets/javascripts/rectangles/models/wall.js')
-rw-r--r--assets/javascripts/rectangles/models/wall.js31
1 files changed, 31 insertions, 0 deletions
diff --git a/assets/javascripts/rectangles/models/wall.js b/assets/javascripts/rectangles/models/wall.js
new file mode 100644
index 0000000..e25d2dd
--- /dev/null
+++ b/assets/javascripts/rectangles/models/wall.js
@@ -0,0 +1,31 @@
+window.wall = (function(){
+
+ var wall = function(opt){
+ this.id = opt.id
+ this.room = opt.room
+ this.rect = opt.rect
+ this.mx = []
+ }
+
+ wall.prototype.toString = function(){
+ return this.rect.toString()
+ }
+
+ wall.prototype.reset = function(){
+ }
+
+ wall.prototype.bind = function(){
+ this.$walls.bind({
+ mouseover: function(){
+ },
+ mousemove: function(e){
+ },
+ mousedown: function(){
+ $(this).css("background-color", choice(window.palettes.colors))
+ }
+ })
+ }
+
+ return wall
+
+})()