Removed UTF-8 new line characters, QT script errors on those lines in Windows.

This commit is contained in:
Thijs Wenker 2014-04-23 14:40:06 +02:00
parent ee929f2551
commit ebc6f4e78e
6 changed files with 11 additions and 12 deletions

View file

@ -50,7 +50,7 @@ function maybePlaySound(deltaTime) {
const CLAP_DISTANCE = 0.2;
if (!clapping[palm] && (distanceBetween < CLAP_DISTANCE) && (speed > CLAP_SPEED)) {
var options = new AudioInjectionOptions();
var options = new AudioInjectionOptions();
options.position = palm1Position;
options.volume = speed / 2.0;
if (options.volume > 1.0) options.volume = 1.0;

View file

@ -61,7 +61,7 @@ function checkSticks(deltaTime) {
// Waiting for change in velocity direction or slowing to trigger drum sound
if ((palmVelocity.y > 0.0) || (speed < STOP_SPEED)) {
state[palm] = 0;
var options = new AudioInjectionOptions();
var options = new AudioInjectionOptions();
options.position = Controller.getSpatialControlPosition(palm * 2 + 1);
if (strokeSpeed[palm] > 1.0) { strokeSpeed[palm] = 1.0; }
options.volume = strokeSpeed[palm];

View file

@ -9,12 +9,12 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
// First, load the clap sound from a URL
var clap = new Sound("https://s3-us-west-1.amazonaws.com/highfidelity-public/sounds/Animals/bushtit_1.raw");
var clap = new Sound("https://s3-us-west-1.amazonaws.com/highfidelity-public/sounds/Animals/bushtit_1.raw");
function maybePlaySound(deltaTime) {
if (Math.random() < 0.01) {
// Set the location and other info for the sound to play
var options = new AudioInjectionOptions();
var options = new AudioInjectionOptions();
var palmPosition = Controller.getSpatialControlPosition(0);
options.position = palmPosition;
options.volume = 0.5;

View file

@ -217,7 +217,7 @@ function update(deltaTime) {
if (invaderStepOfCycle % stepsPerSound == 0) {
// play the move sound
var options = new AudioInjectionOptions();
var options = new AudioInjectionOptions();
if (soundInMyHead) {
options.position = { x: MyAvatar.position.x + 0.0,
y: MyAvatar.position.y + 0.1,
@ -329,7 +329,7 @@ function fireMissile() {
lifetime: 5
});
var options = new AudioInjectionOptions();
var options = new AudioInjectionOptions();
if (soundInMyHead) {
options.position = { x: MyAvatar.position.x + 0.0,
y: MyAvatar.position.y + 0.1,
@ -379,7 +379,7 @@ function deleteIfInvader(possibleInvaderParticle) {
Particles.deleteParticle(myMissile);
// play the hit sound
var options = new AudioInjectionOptions();
var options = new AudioInjectionOptions();
if (soundInMyHead) {
options.position = { x: MyAvatar.position.x + 0.0,
y: MyAvatar.position.y + 0.1,
@ -417,4 +417,3 @@ initializeInvaders();
// shut down the game after 1 minute
var gameTimer = Script.setTimeout(endGame, itemLifetimes * 1000);

View file

@ -111,7 +111,7 @@ function checkControllerSide(whichSide) {
velocity : { x: 0, y: 0, z: 0}, inHand: true };
Particles.editParticle(closestParticle, properties);
var options = new AudioInjectionOptions();
var options = new AudioInjectionOptions();
options.position = ballPosition;
options.volume = 1.0;
Audio.playSound(catchSound, options);
@ -152,7 +152,7 @@ function checkControllerSide(whichSide) {
}
// Play a new ball sound
var options = new AudioInjectionOptions();
var options = new AudioInjectionOptions();
options.position = ballPosition;
options.volume = 1.0;
Audio.playSound(catchSound, options);
@ -201,7 +201,7 @@ function checkControllerSide(whichSide) {
rightHandParticle = false;
}
var options = new AudioInjectionOptions();
var options = new AudioInjectionOptions();
options.position = ballPosition;
options.volume = 1.0;
Audio.playSound(throwSound, options);

View file

@ -64,7 +64,7 @@ collisionBubble[1] = Overlays.addOverlay("sphere",
visible: false
});
var audioOptions = new AudioInjectionOptions();
var audioOptions = new AudioInjectionOptions();
audioOptions.position = { x: MyAvatar.position.x, y: MyAvatar.position.y + 1, z: MyAvatar.position.z };
audioOptions.volume = 1;