diff --git a/static/js/prototype/ArrowCamera.js b/static/js/prototype/ArrowCamera.js index 2085cde..5ffb592 100644 --- a/static/js/prototype/ArrowCamera.js +++ b/static/js/prototype/ArrowCamera.js @@ -41,6 +41,13 @@ var ArrowCamera = function(arg1, arg2, arg3, arg4, position, target) { ArrowCamera.prototype = Object.create(THREE.PerspectiveCamera.prototype); ArrowCamera.prototype.constructor = ArrowCamera; +ArrowCamera.prototype.check = function() { + this.object3D.traverse(function(obj) { + if (obj instanceof THREE.Mesh) + obj.material.color.setHex(0x663366); + }); +} + ArrowCamera.prototype.initExtremity = function() { var geometry = new THREE.Geometry(); diff --git a/static/js/prototype/OldFixedCamera.js b/static/js/prototype/OldFixedCamera.js index 0636443..07daf80 100644 --- a/static/js/prototype/OldFixedCamera.js +++ b/static/js/prototype/OldFixedCamera.js @@ -91,6 +91,8 @@ var OldFixedCamera = function(arg1, arg2, arg3, arg4, position, target) { OldFixedCamera.prototype = Object.create(THREE.PerspectiveCamera.prototype); OldFixedCamera.prototype.constructor = OldFixedCamera; +OldFixedCamera.prototype.check = function() {} + // Update function OldFixedCamera.prototype.update = function(position) { // Compute distance between center of camera and position diff --git a/static/js/prototype/raycasterTools.js b/static/js/prototype/raycasterTools.js index 6c40f11..4ad2814 100644 --- a/static/js/prototype/raycasterTools.js +++ b/static/js/prototype/raycasterTools.js @@ -79,6 +79,7 @@ CameraSelecter.prototype.click = function(event) { event.arrow_id = cameras.cameras.indexOf(newCamera); event.send(); + newCamera.check(); this.cameras.mainCamera().moveHermite(newCamera); buttonManager.updateElements(); } else if (newCamera instanceof Coin) {