Projects BibleWeb Atmosphere Passage-aware scene switching
Needs Design

Passage-aware scene switching

Area: Atmosphere Milestone: v3

Context

Problem: If atmospheric backgrounds are implemented, they should match the content being read. Reading about Jesus by the Sea of Galilee should show the Galilee scene, not Jerusalem.

Solution: Automatically switch the background scene based on which Bible passage the user is reading, using a simple rule set.

Not included: Per-verse scene changes or historically accurate location mapping. This uses broad Bible-section rules.

Functional

Expected scene rules:

  • Galilee scene: Gospels (except passion chapters), general default
  • Jerusalem scene: Prophets, Revelation, Gospel passion chapters
  • Specific chapter ranges:
    • Matthew 26-28, Mark 14-15, Luke 22-24, John 18-21 → Jerusalem (passion narrative)
    • Everything else in Gospels → Galilee
    • Prophets + Revelation → Jerusalem
    • All other books → Galilee (default)

Edge cases:

  • Scene transitions should be smooth (crossfade, not abrupt switch)
  • Only applies when atmospheric backgrounds are enabled

UX & Design

Transition: Smooth crossfade between scenes when navigating to a chapter with a different scene.

Reference: BibleGame Game1.cs had this scene routing logic.

Technical

Implementation:

  • Map (bookId, chapter) to scene name using the rule set
  • On chapter navigation, check if scene changed → trigger crossfade
  • Simple lookup function: getSceneForPassage(bookId, chapter): 'galilee' | 'jerusalem'

Reference: BibleGame Game1.cs scene routing.

Files:

  • New utility: apps/web/src/lib/utils/atmosphere.ts (create)
  • Scene renderer component (depends on atmospheric backgrounds)

Status

Current: NEEDS_DESIGN Milestone: v3 Priority: Low — depends on atmospheric backgrounds being implemented first

Dependencies:

  • Requires: atmospheric backgrounds (NEEDS_DESIGN)