Psst... Lumi the AI assistant says hi! You're awesome for using accessibility tools.Skip to content
luinbytes.dev
← Back to projects
Game ModOpen Source

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.

Source files57
Lines of C#~14k
Menu tabs8
ESP providers5
01 / Features

Harmony-patched on top of BepInEx. Clean provider architecture, null-safe ESP, verified-at-load patches — none of the Aerolt-style NRE spam.

01

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
02

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
03

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
04

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
05

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
06

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
07

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
08

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
02 / Aim Pipeline

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
03 / Technical Details

How it's built

C#

Core mod logic across 57 source files, ~14k lines

BepInEx 5.4.21

Mono mod loader for Risk of Rain 2's Unity 2021.3.33 runtime

HarmonyX / Harmony 2

Runtime method patching on RoR2 + UnityEngine types

Unity IMGUI

Custom 860×560 menu, ESP renderer, overlays, indicators

RiskOfOptions 2.8.5

Pause-menu settings screen integration (hard dep)

MMHOOK.RoR2

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.

04 / Controls

Default hotkeys

UI
InsertOpen / close main menu
F4Hold — hotkeys reference overlay
EndPanic — disable every feature
Aim
Mouse1 (RMB)Legit hold key (default)
Rebinding
Click bindPress any key to capture
EscapeCancel capture

Every bind is remappable from the Configs tab or via the RiskOfOptions pause-menu panel. Persisted into the BepInEx config file per r2modman profile.

05 / Setup

Installation

01

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.

02

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.

03

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.

04

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.