mirror of
https://github.com/overte-org/overte.git
synced 2025-04-15 08:26:36 +02:00
cleanup
This commit is contained in:
parent
bc29bcf0d2
commit
a00ce2599c
1 changed files with 7 additions and 2 deletions
|
@ -9,7 +9,9 @@
|
||||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||||
//
|
//
|
||||||
|
|
||||||
(function() {
|
(function() {
|
||||||
|
var ON_MODEL_URL="atp:/switches/fanswitch_on.fbx";
|
||||||
|
var OFF_MODEL_URL="atp:/switches/fanswitch_off.fbx";
|
||||||
|
|
||||||
var FAN_SOUND_ENTITY_NAME = "home_sfx_ceiling_fan"
|
var FAN_SOUND_ENTITY_NAME = "home_sfx_ceiling_fan"
|
||||||
var SEARCH_RADIUS = 100;
|
var SEARCH_RADIUS = 100;
|
||||||
|
@ -129,12 +131,15 @@
|
||||||
if (this._switch.state === 'off') {
|
if (this._switch.state === 'off') {
|
||||||
this.fanRotationOn();
|
this.fanRotationOn();
|
||||||
this.fanSoundOn();
|
this.fanSoundOn();
|
||||||
|
|
||||||
setEntityCustomData('home-switch', this.entityID, {
|
setEntityCustomData('home-switch', this.entityID, {
|
||||||
state: 'on'
|
state: 'on'
|
||||||
});
|
});
|
||||||
|
|
||||||
Entities.editEntity(this.entityID, {
|
Entities.editEntity(this.entityID, {
|
||||||
modelURL: ON_MODEL_URL
|
modelURL: ON_MODEL_URL
|
||||||
})
|
});
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
this.fanRotationOff();
|
this.fanRotationOff();
|
||||||
this.fanSoundOff();
|
this.fanSoundOff();
|
||||||
|
|
Loading…
Reference in a new issue