Risk of Anticheat.
BepInEx mod for Risk of Rain 2. ESP on every interactable, a first-class legitbot + ragebot pair with projectile-lead prediction, host-only auto-pickup, and a custom 8-tab IMGUI menu. Personal singleplayer / co-op replacement for the abandoned Aerolt mod.
SYSTEM.TOPOLOGY
LAYER 01 / LOADER
BepInEx 5.4.21
Mono runtime + plugin host
LAYER 02 / PATCHES
Harmony runtime hooks
MMHOOK.RoR2 typed hooks
LAYER 03 / TARGET
Risk of Rain 2
Unity 2021.3.33 · RoR2.dll
LAYER 04 / OUTPUT
ESP · Legit · Rage · Cheats
8 tabs · 57 files · 5 ESP providers
Harmony-patched on top of BepInEx. Clean provider architecture, null-safe ESP, verified-at-load patches — none of the Aerolt-style NRE spam.
ESP Overlay
Null-safe boxes and labels on every interactable, enemy, and pickup. Replaces Aerolt's 2,692-NRE-per-session chest reveal with a clean provider pipeline.
- Five providers: Chest, Teleporter, Enemy, Pickup, Interactable
- Host-only chest-content reveal (server-authoritative data path)
- Enemy boxes: 2D / cornered / 3D with health bar, distance, shadowed name
- Per-rarity pickup filter (white / green / red / lunar / boss / equipment)
- Dynamic culling with on-screen cap — stays fast at 50+ entities
- Per-category color config for enemy / elite / boss / rarity groups
Legitbot
Camera-steer aim assist with FOV cone, per-axis smoothing, reaction delay, micro-jitter, and overshoot. Hold-to-aim gated by a configurable FOV ring.
- Target selection: BestAngle / Distance / Weighted / LowestHP
- Hitbox picker: Main / Nearest / CritSpot / LargestVolume / Weakpoint
- Per-axis smoothing (X/Y decoupled) with reaction delay and overshoot
- Sticky lock, micro-jitter, and humanization pass
- Optional visible camera movement via CollectLookInputInternal postfix
- Driver coin priority + auto-rescue auto-shoot
Ragebot
Snap-on-fire redirection via Harmony prefix on GenericSkill.ExecuteIfReady. Weighted target selection, sub-hitbox picker, and projectile-lead prediction.
- Prefix on RoR2.GenericSkill.ExecuteIfReady — fires at the resolved target
- Projectile-lead prediction with live-learned ProjectileSpeedTable
- Weighted scoring across angle / distance / HP / visibility
- Sub-hitbox picker for consistent headshot-equivalent spots
- Auto-shoot mode for hands-free clearing
- Target lock indicator with on-screen status
Prediction Engine
Per-body velocity tracking via PrevPosTracker so projectile lead accurate on enemies, Driver coins, and remote players — all of which read zero Rigidbody.velocity on clients.
- CharacterBody.onBodyStartGlobal registers every body with the tracker
- Driver coin bodies tracked separately — they bypass InstanceTracker
- ProjectileSpeedTable with tier-1 live-learning on FireProjectile
- Tier-2 reflection fallback when the live cache misses
- Instance-id keyed predictor with scene-swap invalidation
Auto-Pickup & Cheats
Host-only auto-pickup with per-rarity allowlist and radius. Plus bhop, god mode, infinite sprint, and an item spawner — the standard loadout, implemented cleanly.
- Auto-pickup with Safe / Everything / Custom presets
- Radius-gated pickup scan, server-authoritative execution
- Bhop: FixedUpdate prefix skipping grounded-ness gate
- God mode: TakeDamage patch with explicit opt-in
- Infinite sprint: FixedUpdate postfix
- Item spawner with search + rarity filter
Custom IMGUI Menu
860×560 menu with 8 tabs. Skeet/Neverlose-hybrid aesthetic — near-black surfaces, cyan accent, hollow-square checkboxes, keybind capture, color swatches.
- Eight tabs: Rage, Legit, Players, World, Indicators, Misc, Spawner, Configs
- Independent Legit + Rage cards — peer-concurrent, not a radio
- Keybind capture widget with press-any-key + Escape to cancel
- Color swatch widget for ESP / indicator / hit-marker colors
- RiskOfOptions integration for pause-menu settings screen
- Config profiles with save / load / last-used autoload
Indicators
Custom crosshair, configurable FOV ring (dotted or smooth), hit markers with sound, skill-cooldown HUD, target-lock indicator, and a cheat-convention watermark.
- Crosshair styles: Dot / Cross / Plus / T — tunable size / thickness / gap
- FOV ring with separate colors for legit vs rage states
- Hit-marker renderer with color, duration, and sound toggle
- Skill-cooldown HUD for the local player's loadout
- Watermark with corner placement + opacity
Panic Key & Safety
Single-key master kill flips every gameplay toggle off — even while the menu is open. UI overlays survive so you keep control.
- Edge-triggered on Cfg.PanicKey — default End
- Disables rage, legit, auto-shoot, ESP, auto-pickup, hit markers, bhop, fly, god mode, infinite sprint
- Menu, hotkeys modal, crosshair, skill-cooldown HUD survive
- Harmony VerifyPatches logs whether each hook actually applied
Legit and rage, running side-by-side
The Legit and Rage cards are peer-concurrent — not a radio. Legit steers the camera through a CollectLookInputInternal postfix; rage prefixes GenericSkill.ExecuteIfReady to redirect the shot at resolved target time. Both share the same target selector, hitbox picker, and prediction stack.
Target Selection
- TargetSelector scores every CharacterBody each frame
- Modes: BestAngle / Distance / Weighted / LowestHP
- EnemyTeamFilter — EnemiesOnly, EnemiesAndNeutral, All
- Optional visibility linecast and FOV cone check
- Driver-coin priority + rescue auto-shoot branch
Hitbox Picker
- Modes: Main / Nearest / CritSpot / LargestVolume / Weakpoint
- SkinnedMeshRenderer → Collider bounds cascade
- Sub-hitbox targeting for consistent weak-spot hits
- Per-body caching — rebuilt on body-start
Prediction
- PrevPosTracker derives velocities every FixedUpdate
- ProjectileSpeedTable — tier-1 live-learned, tier-2 reflection
- Lead-solved target point passed to rage + legit alike
- Instance-id keyed, invalidated on scene change + respawn
Humanization
- Per-axis smoothing (X/Y decoupled)
- Reaction delay + micro-jitter + overshoot
- Sticky lock with release-on-out-of-FOV
- Visible camera movement toggle for legit mode
How it's built
Core mod logic across 57 source files, ~14k lines
Mono mod loader for Risk of Rain 2's Unity 2021.3.33 runtime
Runtime method patching on RoR2 + UnityEngine types
Custom 860×560 menu, ESP renderer, overlays, indicators
Pause-menu settings screen integration (hard dep)
Typed hooks generated from RoR2 assemblies
Build & Deploy
MSBuild auto-bumps version.build each compile, generates a VersionInfo.g.cs const, and repackages a Thunderstore-ready zip. The DLL deploys straight into the active r2modman profile plus any legacy folders — re-import the zip to refresh the in-launcher version string.
Load-time Patch Verification
VerifyPatches() enumerates every Harmony-patched method on boot and logs whether Ragebot, LegitAimHook, BhopHook, InfSprintHook, and GodModeHook actually bound — silent patch failures are impossible to miss.
Default hotkeys
Every bind is remappable from the Configs tab or via the RiskOfOptions pause-menu panel. Persisted into the BepInEx config file per r2modman profile.
Installation
Install BepInEx
Use r2modmanPlus — create a Risk of Rain 2 profile and it installs bbepis-BepInExPack 5.4.2121 for you. Easier than the manual route; launcher-managed profiles are the recommended path.
Add RiskOfOptions
Risk of Anticheat has a hard dependency on Rune580-Risk_Of_Options 2.8.5 for the pause-menu settings screen. Install it from Thunderstore / r2modman before the mod zip.
Install the mod
Drop the latest release zip onto r2modmanPlus (or extract luinbytes-RiskOfAnticheat/ into your profile's BepInEx/plugins/ folder). Zip ships with the manifest + icon for launcher recognition.
Launch & configure
Boot the game via r2modman. Press Insert in-game to open the menu, hold F4 for the hotkey overlay. Rebinds persist per-profile; End is the panic key if anything misbehaves.
Get the mod
Personal singleplayer / co-op tool. Open source. Thunderstore-packaged zips for easy r2modman install, or grab the DLL directly.