How hyperfy-xyz/hyperfy works
Main System Components
a) Client-Side Layer
• Following sub-components:
• UI Components (from src/client/components)
• Graphics Engine (Three.js integration)
• Physics Engine (PhysX client integration)
• VRM Avatar System
• Client Systems (Graphics, Controls, Network, etc.)
b) Core Layer (Middle)
• This in the center as it's shared between client and server
• Include:
• World Management
• Entity System
• Node System
• Asset Management
• Networking Protocol
c) Server-Side Layer
• At the bottom
• Include:
• Physics Server (PhysX)
• Network Handler
• Database Integration
• Server Systems
Component Relationships
• Double lines: Data synchronization
Specific Implementation Details
Key architectural elements:
• Entity-Component System (ECS)
• Relationship between Entities, Components, and Systems
• Node Hierarchy
• Demonstrate the relationship between different node types (Mesh, Group, RigidBody, etc.)
• Network Architecture
• WebSocket connections
• State synchronization flow
• Physics Integration
• PhysX integration points
• Collision system
System Interactions
Critical flows:
• Client-server communication
• Physics synchronization
• Asset loading pipeline
• User interaction handling
• World state management
Technical Stack Indicators
Technologies:
• Three.js
• PhysX
• WebSocket
• VRM
• Node.js
Remember to emphasize the real-time nature of the system and how different components work together to create the persistent virtual world experience.