Catch-all for some front-end viewer bugs (#503)

* (1) remove green camera helper when no cameras (2) remove remaining spline if no more cameras

* removed transform stuff if camera is deleted

* rm transform controls when deleted; only show render helper when 2 cameras present; disable play if max of slider reached

* fixed weird glitching; made render camera snap immediately to moved camera

* click off will remove transform

* lint
This commit is contained in:
evonneng authored and GitHub committed 2022-09-22 21:49:26 -07:00
1 parent 1c0ede17a9
commit 1d8e1eabc3
4 files changed
+128 -22

No files matched your search

+16
View File
@@ -65,6 +65,22 @@ export default class SceneNode {
return this.find(path.concat(['<object>'])).object;
}
find_no_create(path) {
if (path.length === 0) {
return this;
}
const name = path[0];
const child = this.children[name];
if (child === undefined) {
return null;
}
return child.find(path.slice(1));
}
find_object_no_create(path){
return this.find_no_create(path.concat(['<object>'])).object;
}
set_property(property, value) {
if (property === 'position') {
this.object.position.set(value[0], value[1], value[2]);