docs: update README.md with relationship system documentation
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -52,6 +52,7 @@ In follow mode, the camera tracks an NPC and a panel slides in from the right sh
|
||||
- Current activity (Wandering, Eating, Resting, Socializing, Idle)
|
||||
- Live-updating needs bars (Hunger, Energy) with color-coded fill levels
|
||||
- NPC stats in a two-column grid (STR, DEX, CON, INT, PER / SOC, COU, CUR, EMP, TMP)
|
||||
- **Relations tab** showing relationships grouped by tier with slider visualization
|
||||
|
||||
The panel uses an EarthBound/SNES RPG-inspired aesthetic with doubled borders, pixel font, and smooth slide transitions.
|
||||
|
||||
@@ -276,9 +277,41 @@ Stats influence gameplay systems:
|
||||
- **Perception** extends or shrinks the social awareness radius
|
||||
- **Sociability** reduces social interaction cooldowns
|
||||
- **Empathy** biases social interactions toward positive outcomes
|
||||
- **Courage** influences willingness to interact with disliked NPCs
|
||||
- **Curiosity** extends awareness radius for NPCs not yet encountered
|
||||
|
||||
Stats also have **transient modifiers** (e.g., low hunger debuffs Intelligence) and **baseline drift** (tiny permanent shifts from experience over time).
|
||||
|
||||
## Relationships
|
||||
|
||||
NPCs form relationships through social interactions. Each relationship is tracked independently per NPC (asymmetric — A's view of B can differ from B's view of A).
|
||||
|
||||
**How it works:**
|
||||
- Relationships are lazy-initialized on first encounter (NPCs don't "know" each other until they interact)
|
||||
- Each interaction updates relationship values (-100 to 100) based on outcome, with **diminishing returns** on repeated interactions
|
||||
- Deltas are **blended asymmetrically**: 30% shared outcome + 70% individual perception
|
||||
- Stats influence relationships: **Empathy** boosts positive gains, **Temperament** amplifies negative losses, **Sociability** adds a general bonus and determines friend capacity
|
||||
|
||||
**Classification tiers** (derived from value):
|
||||
|
||||
| Range | Tier |
|
||||
|-------|------|
|
||||
| 80 to 100 | Partner |
|
||||
| 50 to 79 | Close Friend |
|
||||
| 20 to 49 | Friend |
|
||||
| 5 to 19 | Acquaintance |
|
||||
| -4 to 4 | Stranger |
|
||||
| -19 to -5 | Wary |
|
||||
| -49 to -20 | Rival |
|
||||
| -79 to -50 | Enemy |
|
||||
| -100 to -80 | Nemesis |
|
||||
|
||||
**Caps:** Partner cap defaults to 1 (2 for high sociability + empathy NPCs). Friend cap scales with sociability.
|
||||
|
||||
**Despawn behavior:** Strong relationships (|value| >= 20) persist as **memories** when an NPC is removed. Weaker relationships fade toward zero and are cleaned up.
|
||||
|
||||
All relationship tuning values are config-driven in `server/src/config/relationshipConfig.ts`, designed for future admin UI integration.
|
||||
|
||||
## Game Constants
|
||||
|
||||
All tunable game constants live in `shared/src/constants.ts`:
|
||||
|
||||
Reference in New Issue
Block a user