diff --git a/scripts/defaultScripts.js b/scripts/defaultScripts.js index 4902f66a51..2270118861 100644 --- a/scripts/defaultScripts.js +++ b/scripts/defaultScripts.js @@ -25,7 +25,6 @@ var DEFAULT_SCRIPTS_COMBINED = [ "system/tablet-goto.js", "system/marketplaces/marketplaces.js", "system/edit.js", - "system/spectatorCamera.js", "system/notifications.js", "system/dialTone.js", "system/firstPersonHMD.js", diff --git a/unpublishedScripts/marketplace/spectator-camera/spectator-camera.fbx b/unpublishedScripts/marketplace/spectator-camera/spectator-camera.fbx new file mode 100644 index 0000000000..6bc8d23679 Binary files /dev/null and b/unpublishedScripts/marketplace/spectator-camera/spectator-camera.fbx differ diff --git a/scripts/system/spectatorCamera.js b/unpublishedScripts/marketplace/spectator-camera/spectatorCamera.js similarity index 98% rename from scripts/system/spectatorCamera.js rename to unpublishedScripts/marketplace/spectator-camera/spectatorCamera.js index bc975f59dd..b40fe7f8ba 100644 --- a/scripts/system/spectatorCamera.js +++ b/unpublishedScripts/marketplace/spectator-camera/spectatorCamera.js @@ -75,11 +75,11 @@ "collidesWith": "static,dynamic,kinematic,", "collisionMask": 7, "dynamic": cameraIsDynamic, - "modelURL": "http://hifi-content.s3.amazonaws.com/alan/dev/spectator-camera.fbx?7", + "modelURL": Script.resolvePath("spectator-camera.fbx"), "registrationPoint": { - "x": 0.53, + "x": 0.56, "y": 0.545, - "z": 0.16 + "z": 0.23 }, "rotation": cameraRotation, "position": cameraPosition, @@ -344,9 +344,9 @@ function registerButtonMappings() { var VRDevices = Controller.getDeviceNames().toString(); if (VRDevices) { - if (VRDevices.includes("Vive")) { + if (VRDevices.indexOf("Vive") !== -1) { controllerType = "Vive"; - } else if (VRDevices.includes("OculusTouch")) { + } else if (VRDevices.indexOf("OculusTouch") !== -1) { controllerType = "OculusTouch"; } else { sendToQml({ method: 'updateControllerMappingCheckbox', setting: switchViewFromController, controller: controllerType }); @@ -383,7 +383,7 @@ // Relevant Variables: // -SPECTATOR_CAMERA_QML_SOURCE: The path to the SpectatorCamera QML // -onSpectatorCameraScreen: true/false depending on whether we're looking at the spectator camera app. - var SPECTATOR_CAMERA_QML_SOURCE = "../SpectatorCamera.qml"; + var SPECTATOR_CAMERA_QML_SOURCE = Script.resourcesPath() + "qml/hifi/SpectatorCamera.qml"; var onSpectatorCameraScreen = false; function onTabletButtonClicked() { if (!tablet) {