mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-16 08:12:24 +00:00
Read what the camera follows through one module
src/data/followed.js answers what the camera follows: the camera port's target, or the entity a layer still tracks itself, seen through the same fields. Ownership checks, render holds, guards, voice actions, the CCTV pacing and the navigation release paths read it instead of Cesium's trackedEntity, so they keep working when layers follow through the port. The release paths stop following, cancel the flight and release the camera through the port. The rotate refusal names the followed target by its name or label title.
This commit is contained in:
1 parent
6c215f93a9
commit
7eec2f828c
29 files changed
+404
-97
No files matched your search
@@ -33,6 +33,13 @@ const INJECTED = {
|
||||
'./layers/recent-imagery': 'src/layers/recentImagery/rendering.js',
|
||||
};
|
||||
|
||||
/**
|
||||
* Modules whose use of the bridge holds up without the factory: with no
|
||||
* port they read Cesium's `trackedEntity` instead, which is all an unbound
|
||||
* viewer can follow by.
|
||||
*/
|
||||
const FALLS_BACK = new Set(['src/data/followed.js']);
|
||||
|
||||
const pkg = JSON.parse(readFileSync(path.join(root, 'package.json'), 'utf8'));
|
||||
|
||||
/** The browser module an export resolves to, or null for Node-only ones. */
|
||||
@@ -112,6 +119,7 @@ function reachable(entry, { eager = false } = {}) {
|
||||
for (const { specifier, lazy } of specifiersOf(file)) {
|
||||
if (eager && lazy) continue;
|
||||
const next = resolve(file, specifier);
|
||||
if (next === BRIDGE && FALLS_BACK.has(file)) continue;
|
||||
if (next && !seen.has(next)) {
|
||||
seen.add(next);
|
||||
queue.push(next);
|
||||
|
||||
Reference in new issue
Block a user