Relationship System

v1.1.0

Getting Started

Create your first merchant reputation system in 5 minutes.

Goal: Create a simple merchant reputation system in 5 minutes.

Step 1: Create Manager

  1. Create empty GameObject: "RelationshipManager"
  2. Add Component → Relationship Manager
  3. Add Component → Relationship Instruction Manager
The Instruction Manager auto-discovers scene-based instruction overrides.

Step 2: Create Relationship Definition

Assets → Create → Relationship System → Relationship Definition

Display Name: "Merchant Reputation"
Min Value: -100
Max Value: +100
Starting Value: 0
Levels:
  • Hostile: Threshold -50
  • Neutral: Threshold 0
  • Friendly: Threshold 50

Step 3: Add Character Relationships

Add CharacterRelationship component to Player and Merchant:

Player GameObject
└─ Character Relationship
   ├─ Character Name: "Player"
   └─ Auto Register: ✓

Merchant GameObject
└─ Character Relationship
   ├─ Character Name: "Town Merchant"
   └─ Auto Register: ✓

Step 4: Use GC2 Instructions

Create a Trigger to modify reputation when player completes a quest:

Trigger: On Quest Complete
Instructions:
  └─ Modify Relationship
     ├─ Entity A: Player
     ├─ Entity B: Merchant
     ├─ Change: +25
     └─ Definition: Merchant Reputation
Available instructions include: Modify Relationship, Set Relationship, Lock/Unlock, Add to Faction, and more. See GC2 Integration for full list.

Step 5: Test

  1. Press Play
  2. Open Window → Relationship System → Relationship Editor
  3. Trigger your quest completion
  4. Watch the relationship update in real-time!
🎉 Congratulations! You've created your first relationship system with bidirectional reputation tracking!

Next Steps

Now that you have the basics working, explore these topics:

Core Concepts

Learn about entities, definitions, levels, and factions

Auto-Hostility

Make NPCs attack based on reputation level

UI System

Display reputation to players with built-in views

Save/Load

Add persistence with the Remember component