Risk of Rain 2
DigitalHeaven.Mods.RiskOfRain2 WIP is a BepInEx 5 mod that brings DigitalHeaven avatar replacement to Risk of Rain 2.
Requirements
Section titled “Requirements”| Mod loader | BepInEx 5 |
| Game version | Mono (default Steam build) |
| Rendering pipeline | Built-in |
| Humanoid rig | Full Unity Avatar rig (17 required bones) |
This mod depends on the DigitalHeaven.Unity library for model loading, rig setup, and material creation.
Core Features
Section titled “Core Features”| Feature | Status |
|---|---|
| Overlay | WIP |
| Avatar replacement | WIP |
Multiplayer Features
Section titled “Multiplayer Features”| Feature | Status |
|---|---|
| Avatar sync | WIP |
How It Works
Section titled “How It Works”The mod uses full replacement with multiplayer synchronization:
- When a player spawns, the mod hides the game’s character meshes
- A DH avatar is instantiated and parented under the active character
- Pose mirroring copies animations from the game’s Animator to the DH avatar using
HumanPoseHandler - The DH avatar is auto-scaled to match the game character’s proportions using
humanScale
Avatar barcodes are synchronized across all players using custom HLAPI network messages. When a remote player is using an avatar from a pallet you don’t have locally, the mod can request the pallet data from that player via the network.
In-Game Configuration
Section titled “In-Game Configuration”Config file: BepInEx/config/io.mltn.digitalheaven.ror2.cfg
| Setting | Section | Default | Description |
|---|---|---|---|
PlayerAvatar | [DigitalHeaven] | "" | Barcode for the player avatar |
Example Configuration
Section titled “Example Configuration”[DigitalHeaven]PlayerAvatar = io.example.my-avatar:avatar.dh-avatarDevelopment Setup
Section titled “Development Setup”The mod project lives at Mods/DigitalHeaven.Mods.RiskOfRain2/ and is included in the main DigitalHeaven.sln solution under the Mods folder.
Local Configuration
Section titled “Local Configuration”Copy DigitalHeaven.Mods.RiskOfRain2.csproj.user.example and remove the .example extension. This file configures your local game install path and is git-ignored:
<Project> <PropertyGroup> <RoR2Dir>D:\SteamLibrary\steamapps\common\Risk of Rain 2</RoR2Dir> </PropertyGroup></Project>By default, RoR2Dir is used to locate both BepInEx and the game’s managed assemblies. You can override them individually:
| Property | Default | Description |
|---|---|---|
RoR2Dir | (see .csproj) | Base game path. Controls everything if the other properties are not set. |
RoR2ManagedDir | $(RoR2Dir)\Risk of Rain 2_Data\Managed | Directory containing the game’s managed assemblies (Unity engine, RoR2, Assembly-CSharp, etc.). |
BepInExDir | $(RoR2Dir)\BepInEx | BepInEx root directory containing core\ and plugins\ folders. |
Building
Section titled “Building”The project references BepInEx DLLs from $(BepInExDir)\core\ and game assemblies from $(RoR2ManagedDir). After building, a post-build target automatically deploys the mod and its dependencies to $(BepInExDir)\plugins\DigitalHeaven\.
The project targets netstandard2.1 and references DigitalHeaven.Core, DigitalHeaven.Unity, DigitalHeaven.Overlay, and DigitalHeaven.Unity.Overlay as project dependencies.