How daolyap/tonights-the-night works
Tonight’s The Night is a configurable GTA V riot mod. The player opens the in-game menu, selects a mode and settings, then the Director runs the simulation: factions and spawn profiles define the crowds, while gameplay systems handle escalation, pursuit, infection, ambience and other effects. Configuration and profiles make the experience customizable and persistent. The Director excerpt confirms orchestration of several systems; README-described capabilities are included, but links to unsampled implementations are omitted where their wiring cannot be verified.
Main entry points: Director.cs Riot Director · Faction.cs Faction Model · RiotMenu.cs In-Game Menu · Profiles.cs Saved Profiles
Components 24
Runtime Control
- Riot Director
src/TonightsTheNight/Core/Director.cs - Entity Registry
src/TonightsTheNight/Core/EntityRegistry.cs
Modes and Factions
- Stock Modes
src/TonightsTheNight/Factions/StockModes.cs - Faction Model
src/TonightsTheNight/Factions/Faction.cs - Mode Library
src/TonightsTheNight/Factions/ModeLibrary.cs - Faction Relations
src/TonightsTheNight/Factions/RelationshipMatrix.cs - Spawn Profiles
src/TonightsTheNight/Factions/SpawnProfile.cs - Weapon Presets
src/TonightsTheNight/Factions/WeaponPresets.cs
Gameplay Simulation
- Crowd Spawner
src/TonightsTheNight/Core/Spawner.cs - Escalation
src/TonightsTheNight/Core/Escalation.cs - Infection Spread
src/TonightsTheNight/Core/Contagion.cs - Vehicle Pursuit
src/TonightsTheNight/Core/Pursuit.cs - Hunter Encounter
src/TonightsTheNight/Core/Hunter.cs - World Ambience
src/TonightsTheNight/Core/Ambience.cs - Riot Zones
src/TonightsTheNight/Core/RiotZone.cs - HUD and Timer
src/TonightsTheNight/Core/Hud.cs - Looting
src/TonightsTheNight/Core/Looting.cs
Settings and UI
- In-Game Menu
src/TonightsTheNight/Menu/RiotMenu.cs - Config Store
src/TonightsTheNight/Config/ConfigStore.cs - Default Settings
src/TonightsTheNight/Config/DefaultConfig.cs - Saved Profiles
src/TonightsTheNight/Config/Profiles.cs - JSON Utilities
src/TonightsTheNight/Util/Json.cs
Other components
- Player
- GTA V Runtime
Connections 21
- Player → In-Game Menu: opens F6 menu
- In-Game Menu → Config Store: edits settings
- In-Game Menu → Saved Profiles: saves or loads
- Saved Profiles → Config Store: imports and exports
- Saved Profiles → JSON Utilities: parses and writes
- Default Settings → JSON Utilities: builds values
- Mode Library → Stock Modes: loads mode data
- Stock Modes → Faction Model: defines factions
- Faction Model → Spawn Profiles: sets spawn rules
- Faction Model → Weapon Presets: defines loadouts
- Riot Director → Entity Registry: tracks entities
- Riot Director → Vehicle Pursuit: ends pursuits
- Riot Director → Looting: ends looting
- Riot Director → Crowd Spawner: runs riot simulation
- Riot Director → Faction Relations: sets faction relations
- Riot Director → GTA V Runtime: controls game entities
- Crowd Spawner → GTA V Runtime: creates peds and vehicles
- Hunter Encounter → GTA V Runtime: runs encounter
- Vehicle Pursuit → GTA V Runtime: tasks chase vehicles
- World Ambience → GTA V Runtime: changes world effects
- Player → GTA V Runtime: plays simulation