mirror of
https://github.com/overte-org/overte.git
synced 2025-04-29 21:02:44 +02:00
rename files
This commit is contained in:
parent
5a9549a2d9
commit
28a5dba2d3
5 changed files with 29 additions and 17 deletions
20
examples/lights/lightLoader.js
Normal file
20
examples/lights/lightLoader.js
Normal file
|
@ -0,0 +1,20 @@
|
|||
//
|
||||
// lightLoader.js
|
||||
//
|
||||
// Created by James Pollack @imgntn on 12/15/2015
|
||||
// Copyright 2015 High Fidelity, Inc.
|
||||
//
|
||||
// Loads a test scene showing sliders that you can grab and move to change entity properties.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
|
||||
var grabScript = Script.resolvePath('../controllers/handControllerGrab.js');
|
||||
Script.load(grabScript);
|
||||
var lightModifier = Script.resolvePath('lightModifier.js');
|
||||
Script.load(lightModifier);
|
||||
Script.setTimeout(function() {
|
||||
var lightModifierTestScene = Script.resolvePath('lightModifierTestScene.js');
|
||||
Script.load(lightModifierTestScene);
|
||||
}, 750)
|
|
@ -1,7 +1,7 @@
|
|||
//
|
||||
// light_modifier.js
|
||||
// lightModifier.js
|
||||
//
|
||||
// Created byJames Pollack @imgntn on 12/15/2015
|
||||
// Created by James Pollack @imgntn on 12/15/2015
|
||||
// Copyright 2015 High Fidelity, Inc.
|
||||
//
|
||||
// Given a selected light, instantiate some entities that represent various values you can dynamically adjust by grabbing and moving.
|
||||
|
@ -201,13 +201,13 @@ entitySlider.prototype = {
|
|||
|
||||
//message is not for our light
|
||||
if (message.lightID !== this.lightID) {
|
||||
print('not our light')
|
||||
// print('not our light')
|
||||
return;
|
||||
}
|
||||
|
||||
//message is not our type
|
||||
if (message.sliderType !== this.sliderType) {
|
||||
print('not our slider type')
|
||||
// print('not our slider type')
|
||||
return
|
||||
}
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
//
|
||||
// light_modifier_test_scene.js
|
||||
// lightModifierTestScene.js
|
||||
//
|
||||
// Created byJames Pollack @imgntn on 12/15/2015
|
||||
// Created by James Pollack @imgntn on 12/15/2015
|
||||
// Copyright 2015 High Fidelity, Inc.
|
||||
//
|
||||
// Given a selected light, instantiate some entities that represent various values you can dynamically adjust.
|
||||
|
@ -116,7 +116,6 @@ function evalLightWorldTransform(modelPos, modelRot) {
|
|||
}
|
||||
|
||||
function cleanup() {
|
||||
print('CLEANUP TEST SCENE SCRIPT')
|
||||
Entities.deleteEntity(block);
|
||||
Entities.deleteEntity(ground);
|
||||
Entities.deleteEntity(light);
|
|
@ -1,8 +0,0 @@
|
|||
var grabScript = Script.resolvePath('../controllers/handControllerGrab.js');
|
||||
Script.load(grabScript);
|
||||
var lightModifier = Script.resolvePath('light_modifier.js');
|
||||
Script.load(lightModifier);
|
||||
Script.setTimeout(function() {
|
||||
var lightModifierTestScene = Script.resolvePath('light_modifier_test_scene.js');
|
||||
Script.load(lightModifierTestScene);
|
||||
}, 750)
|
|
@ -1,13 +1,14 @@
|
|||
//
|
||||
// slider.js
|
||||
//
|
||||
// Created byJames Pollack @imgntn on 12/15/2015
|
||||
// Created by James Pollack @imgntn on 12/15/2015
|
||||
// Copyright 2015 High Fidelity, Inc.
|
||||
//
|
||||
// Entity script that sends a scaled value to a light based on its distance from the start of its constraint axis.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
(function() {
|
||||
|
||||
var AXIS_SCALE = 1;
|
||||
|
@ -60,7 +61,7 @@
|
|||
this.sliderValue = this.scaleValueBasedOnDistanceFromStart(distance, EXPONENT_MAX);
|
||||
};
|
||||
|
||||
print('SLIDER VALUE:::' + this.sliderValue)
|
||||
//print('SLIDER VALUE:::' + this.sliderValue)
|
||||
this.sendValueToSlider();
|
||||
|
||||
},
|
||||
|
|
Loading…
Reference in a new issue