mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-08-09 01:07:09 +02:00
more logging
This commit is contained in:
parent
eabeb98076
commit
1d9b3fadaf
1 changed files with 18 additions and 3 deletions
|
@ -24,11 +24,26 @@ var soundBoxes = [];
|
||||||
|
|
||||||
var testSound = SoundCache.getSound("https://s3-us-west-1.amazonaws.com/hifi-content/eric/Sounds/dove.wav");
|
var testSound = SoundCache.getSound("https://s3-us-west-1.amazonaws.com/hifi-content/eric/Sounds/dove.wav");
|
||||||
|
|
||||||
var numSounds = 45;
|
if(!testSound.downloaded) {
|
||||||
for (var i = 0; i < numSounds; i++) {
|
|
||||||
playSound();
|
print("EBL SOUND IS NOT READY YET")
|
||||||
|
testSound.ready.connect(function() {
|
||||||
|
playSounds();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
// otherwise play sounds right away
|
||||||
|
playSounds();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function playSounds() {
|
||||||
|
print("EBL PLAY SOUNDS!")
|
||||||
|
var numSounds = 45;
|
||||||
|
for (var i = 0; i < numSounds; i++) {
|
||||||
|
playSound();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
function playSound() {
|
function playSound() {
|
||||||
var position = Vec3.sum(basePosition, {x: randFloat(-.1, .1), y: randFloat(-1, 1), z: randFloat(-3, -.1)});
|
var position = Vec3.sum(basePosition, {x: randFloat(-.1, .1), y: randFloat(-1, 1), z: randFloat(-3, -.1)});
|
||||||
var injector = Audio.playSound(testSound, {
|
var injector = Audio.playSound(testSound, {
|
||||||
|
|
Loading…
Reference in a new issue