How projeto-final-lei-ipt/planetarysystemv2 works
This repository contains browser-based planetary-system AR games, with webview as the current version and webview_v3 and webview_antigo as earlier implementations. In the current game, a player opens a scenario, the initializer loads its planet data and obtains the player’s location, and the scene-building code creates the AR system. Players can approach planets to answer quizzes, view planet information, and track progress. The excerpts show these runtime features and offline caching; several page and data relationships are documented only by filenames, so uncertain links are omitted.
Main entry points: webview/js Scenario initializers · webview_v3/js Scenario initializers · Old_main.js Worker game entry · Pages Game pages
Components 26
Current AR game
- Game pages
webview/Pages - Scenario initializers
webview/js - Planet data
webview/data - Scene builder
webview/js/script.js - AR components
webview/js/componentsV2.js - Utilities
webview/js/utils.js - Instructions and about
webview/Pages - Offline cache
webview/sw.js
V3 AR game
- Game pages
webview_v3/Pages - Scenario initializers
webview_v3/js - Planet data
webview_v3/data - Scene builder
webview_v3/js/script.js - AR components
webview_v3/js/componentsV2.js - Utilities
webview_v3/js/utils.js - Instructions and about
webview_v3/Pages - Offline cache
webview_v3/sw.js
Earlier implementations
- Worker game entry
webview_antigo/Old/Old_main.js - Planet worker
webview_antigo/Testes/planetWorker.js - Legacy AR components
webview_antigo/js/components.js - Legacy AR components v2
webview_antigo/js/componentsV2.js - Legacy scene builder
webview_antigo/js/script.js - Legacy quiz
webview_antigo/js/quiz.js
Browser platform
- Device location
- Browser cache
- A-Frame and AR.js
Other components
- Player
Connections 20
- Player → Game pages: opens
- Scenario initializers → Planet data: fetches
- Scenario initializers → Device location: requests location
- Scenario initializers → Scene builder: creates scene
- Scene builder → AR components: sets components
webview/js/script.js - Game pages → Instructions and about: links pages
- Offline cache → Browser cache: caches files
webview/sw.js - Game pages → Offline cache: cached by
webview/sw.js - Scenario initializers → Planet data: fetches
webview_v3/js/initializerX2.js - Scenario initializers → Device location: requests location
webview_v3/js/initializerX2.js - Scenario initializers → Scene builder: calls createPlanets
webview_v3/js/initializerX2.js - Scene builder → AR components: sets components
webview_v3/js/script.js - Game pages → Instructions and about: links pages
- Offline cache → Browser cache: caches files
webview_v3/sw.js - Game pages → Offline cache: cached by
webview_v3/sw.js - Worker game entry → Planet worker: dispatches worker
webview_antigo/Old/Old_main.js - Planet worker → Browser cache: fetches data
webview_antigo/Testes/planetWorker.js - Worker game entry → Legacy AR components: registers components
- Worker game entry → Legacy AR components v2: registers components
- Player → A-Frame and AR.js: uses AR