diff options
| author | Jules Laplace <jules@okfoc.us> | 2015-04-20 13:17:15 -0400 |
|---|---|---|
| committer | Jules Laplace <jules@okfoc.us> | 2015-04-20 13:17:15 -0400 |
| commit | cee602fc6e1431fd505665a7b285c3fa85d32d3e (patch) | |
| tree | ca4cbff8bf8c71c64ed18ee38b893890e5cac286 | |
| parent | 24543d0839ad51b2afa7195b16d29bc52b3f1a1b (diff) | |
toggle billboard
| -rw-r--r-- | public/assets/javascripts/rectangles/engine/sculpture/types/_object.js | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/public/assets/javascripts/rectangles/engine/sculpture/types/_object.js b/public/assets/javascripts/rectangles/engine/sculpture/types/_object.js index 48fd96a..489a6a1 100644 --- a/public/assets/javascripts/rectangles/engine/sculpture/types/_object.js +++ b/public/assets/javascripts/rectangles/engine/sculpture/types/_object.js @@ -53,7 +53,13 @@ Sculpture.types.base = Fiber.extend(function(base){ }, setBillboard: function(val){ this.billboard = val - }, + if (this.billboard) { + this.mx.rotationY = cam.rotationY + } + else { + this.mx.rotationY = PI/2 + } + }, remove: function(){ if (this.removed) return |
