content/hifi-content/rebecca/studio/goToDanceFloor.js
2022-02-14 02:04:11 +01:00

36 lines
1.1 KiB
JavaScript

(function() {
var _this;
var injector;
var GoToDance = function() {
_this = this;
};
GoToDance.prototype = {
/* PLAY A SOUND: Plays the specified sound at the position of the user's Avatar using the volume and playback
mode requested. */
playSound: function(sound, volume, position, localOnly, loop){
if (sound.downloaded) {
if (injector) {
injector.stop();
injector = null;
}
injector = Audio.playSound(sound, {
position: position,
volume: volume,
localOnly: localOnly,
loop: loop
});
}
},
/* ON MOUSE PRESS: Store the initial point to start line. */
mousePressOnEntity: function(event) {
MyAvatar.position = {"x":-94.84981536865234,"y":909.1155395507812,"z":28.403423309326172};
MyAvatar.orientation = {"x":0,"y":0.9834045171737671,"z":0,"w":0.18142621219158173};
}
};
return new GoToDance();
});