Skip to content

feat: Migrate to @jbcom/strata API #18

@jbdevprimary

Description

@jbdevprimary

Overview

Migrate Otterfall from direct React Three Fiber usage to @jbcom/strata API for:

  • Reduced code complexity
  • Access to pre-built game systems
  • Consistent API with other arcade games
  • Mobile-first optimizations

Current Stack

  • @react-spring/three
  • @react-three/drei
  • @react-three/fiber
  • @react-three/postprocessing
  • @react-three/rapier
  • Custom terrain, water, vegetation

Strata Components to Use

Rendering

  • ProceduralSky - Replace custom sky
  • AdvancedWater - Replace custom water
  • Terrain - Replace custom terrain (if applicable)
  • GrassInstances, TreeInstances - Replace vegetation

Effects

  • VolumetricClouds - Add atmospheric depth
  • CinematicEffects - Film-quality post-processing
  • ParticleEmitter - GPU-accelerated particles

Game Systems

  • createGame API - Declarative game definition
  • GameStateStore - State management with undo/redo
  • ModeManager - Game mode switching

Creatures (if applicable)

  • createCreature - Otter character definition
  • createFurMaterial - Fur rendering

Installation

pnpm add @jbcom/strata

Example Migration

// Before
import { Sky, Water, Environment } from '@react-three/drei';

// After  
import { ProceduralSky, AdvancedWater, GrassInstances } from '@jbcom/strata';
import { createGame, StrataGame } from '@jbcom/strata/api';

Estimated Effort

20-30 hours

Related

Metadata

Metadata

Assignees

No one assigned

    Labels

    copilot-assignedAssigned to GitHub Copilot Coding Agent

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions