diff options
| author | Jules Laplace <jules@okfoc.us> | 2014-04-25 12:12:21 -0400 |
|---|---|---|
| committer | Jules Laplace <jules@okfoc.us> | 2014-04-25 12:12:21 -0400 |
| commit | 0772bb5e55d0d00c925620a27b59a7f52aaa4199 (patch) | |
| tree | 780b8b7685976014df8b5741b56ba96eecd67a82 /assets/javascripts/rectangles | |
| parent | 6a39854726c511f3df0b4aff619ecac1943c993c (diff) | |
ceiling
Diffstat (limited to 'assets/javascripts/rectangles')
| -rw-r--r-- | assets/javascripts/rectangles/_env.js | 13 | ||||
| -rw-r--r-- | assets/javascripts/rectangles/engine/mover.js | 3 |
2 files changed, 4 insertions, 12 deletions
diff --git a/assets/javascripts/rectangles/_env.js b/assets/javascripts/rectangles/_env.js index 9bdad6a..1252778 100644 --- a/assets/javascripts/rectangles/_env.js +++ b/assets/javascripts/rectangles/_env.js @@ -4,7 +4,7 @@ environment.init = function(){ if (window.scene) { scene.camera.move({ "x": 1000, - "y": 1500, + "y": 0, "z": 250, "rotationX": 0, // PI/2, "rotationY": PI/2, // PI @@ -30,23 +30,16 @@ environment.init = function(){ rect: new rect(450,150, 650,350), height: 300, })) + app.movements.gravity(true) - if (window.location.href.match(/stone/)) { - app.on("clip", function(){ - $(".face").css({ - "background-image": "url(http://i.asdf.us/im/4a/_1398144847_frankhats.gif)" - }) - }) - $("#map").hide() - } + $("#map").hide() builder.init() clipper.init() mover.init() window.scene && scene.update() environment.update() - } environment.update = function(t){ if (window.scene && scene.camera) { diff --git a/assets/javascripts/rectangles/engine/mover.js b/assets/javascripts/rectangles/engine/mover.js index 71656ef..757dbfa 100644 --- a/assets/javascripts/rectangles/engine/mover.js +++ b/assets/javascripts/rectangles/engine/mover.js @@ -16,10 +16,9 @@ var mover = new function(){ var radius = scene.camera.radius cam.y = pos.y - + // if we were in a room already.. if (base.room) { - // check if we're still in the room if (base.room.rect.containsDisc(pos.x, pos.z, radius)) { cam.x = pos.x |
