R.E.P.O.
Install with App

Details

Latest version
0.7.3
Last Updated
First Uploaded
Downloads
5.6K
Likes
4
Size
107KB
Dependants
Edited · Nov 24, 2026
REPOPathfinder, a R.E.P.O. mod by Mentalize and Pez. An in-world dot trail to extraction or the truck. Client-side, no game code patched, BepInEx 5.

A BepInEx plugin for R.E.P.O. that draws a dot trail on the floor along the walkable path to the current extraction point, or back to the truck once every extraction is done. It reads the same game state the dots on the in-game map follow, and draws the route in the world so you can follow it without opening the map.

Hotkeys (configurable, all default to F-keys):

  • F4 — toggle the trail on / off.
  • F5 — switch the destination between Auto (current extraction, or the truck when all are complete) and Truck (always the truck, for going back to charge items mid-run). The choice is saved.
  • F6 — open the customization panel: RGBA color sliders, hex input, color presets, and live sliders for dot size / flow speed / spacing. Esc or F6 closes it. Changes are saved to the BepInEx config.

While you are dead, the trail starts from the player you are spectating.

The dot trail running across a wooden floor to the extraction point. The dot trail leading through a doorway and around a corner in a dark level.

What the DLL actually does

On plugin Awake(), it:

  • Reads its config. A standard BepInEx config file (BepInEx/config/isaia.repopathfinder.cfg) defines all hotkeys, dot visuals, animation tunables, and the path-recompute threshold. A [Internal] ConfigVersion key migrates stale defaults from prior versions in place — values that exactly match a previous default get overwritten with the current default; user-customized values are left alone. The file is written once at startup and once each time the F6 panel closes.
  • Binds the game fields it reads. If the three the trail cannot work without are missing (a game update renamed them), one error line names them, the trail stays off, and F4 shows "needs an update for this game version".
  • Creates a DontDestroyOnLoad GameObject. Adds two MonoBehaviours to it: PathfinderManager (path / animation / rendering) and PathfinderCustomizeUI (the F6 IMGUI overlay).

It installs no Harmony patches. If drawing the trail throws, the error is logged once; after 5 failed frames in a row the trail turns itself off until you press F4 again.

Path computation

The path is cached in world space, not recomputed every frame:

  1. Target. Truck mode: LevelGenerator.LevelPathTruck. Auto mode: RoundDirector.extractionPointCurrent, or the truck once RoundDirector.allExtractionPointsCompleted is set. The target point is moved onto the NavMesh (up to 4 m) before the search.

  2. Start. PlayerAvatar.LastNavmeshPosition; if that is more than 10 m from the player (stale), the player's own position moved onto the NavMesh. While dead: the spectated player's position, or no trail when nobody is being spectated.

  3. Recompute trigger. A new path is computed only when:

    • There is no cached path yet,
    • The target changed (different extraction, Auto↔Truck, or a new level), or
    • The player has drifted further than OffPathRecomputeThresholdMeters (default 3.0) from the cached polyline.

    Searches are at least 0.2 s apart, and 0.75 s apart after one that found nothing.

  4. Compute & cache. NavMesh.CalculatePath is called once. The corners and prefix arc-distances are stored; the displayed dots reference these stable world-space points for as long as the cache lives. When only a partial route exists, the trail shows it and a short notice says so. Each new target logs one line (Path to <name>: <status>, <n> corners, <m> m.).

  5. Each frame. The player is projected onto the cached polyline to produce a playerArc scalar; that's the trail's "back end". Walking forward changes only playerArc; the cached corners are untouched, so dot world positions stay stable regardless of how the player moves.

Animation & rendering

  • A pool of MaxDots (default 30) sphere primitives, colliders stripped, sharing one material with per-dot color set via MaterialPropertyBlock.
  • A single shared _animOffset ∈ [0, spacing) advances by FlowSpeed m/s. When it crosses spacing the circular pool pointer _frontPool decrements, which makes every sphere's slot index increment by 1 simultaneously. Spacing stays perfectly even regardless of how availableLength = totalLength - playerArc changes.
  • The single sphere whose slot wraps from MaxDots-1 to 0 per cycle has its smoothing flag cleared in the same step, so it snaps to its new position at the player end of the trail instead of being lerped across the room.
  • World position per dot: CachedPointAtDistance(playerArc + slot*spacing + animOffset), plus GroundOffset on Y. The result is exponentially smoothed toward the displayed position with rate PositionSmoothRate (default 25 1/s) for the rare cases where the path is re-cached.
  • Alpha fade per dot: min(SmoothStep(0..fadeZone, d), SmoothStep(0..fadeZone, endpoint-d)) where d = slot*spacing + animOffset, endpoint = min(availableLength, activeCount*spacing) and fadeZone = max(0.05, min(spacing, endpoint/2) * FadeZoneFraction). Hides the wrap and the path's own ends behind alpha-0 transitions.
  • The material's shader is the first of Sprites/Default, Unlit/Color, Hidden/Internal-Colored, Standard that the game build contains (a warning is logged if none is). _ZWrite 0 and SrcAlpha/OneMinusSrcAlpha blend are set if the chosen shader exposes those properties; render queue is 3500.

Customization UI

PathfinderCustomizeUI (default F6) is a draggable GUILayout.Window:

The F6 customize panel: color sliders, hex field, presets, and sliders for dot size, flow speed and spacing.
  • RGBA sliders (0–255 readout), #RRGGBBAA text field with Apply, preview swatch over a white underlay so transparency is obvious, eight color presets.
  • Sliders for DotScale, FlowSpeedMetersPerSec, SpacingMeters.
  • Reset Visuals writes each of the above ConfigEntries back to its DefaultValue. Close, F6 or Esc dismisses the panel.
  • Edits go straight to the BepInEx ConfigEntries, so the dots in the world update while you drag. The config file itself is written when the panel closes.
  • While the panel is open the game's controls are held still with the game's own switches (InputManager.DisableMovement, DisableAiming, DisableControlsExcept) and the cursor is freed with CursorManager.Unlock, the same calls the game's menus use. You cannot walk, look, grab or open the pause menu until it closes; push-to-talk keeps working. The hold lasts a quarter of a second past the last frame the panel was open, so the click or key that closed it does not reach the game.

Install

Install with a mod manager, or by hand: drop REPOPathfinder.dll into <profile>/BepInEx/plugins/REPOPathfinder/. Requires BepInEx-BepInExPack.

Compatibility

  • Checked against R.E.P.O. v0.5.3 (Unity 6) with BepInEx 5.4.23.
  • Client-side. The plugin is purely local: it reads PlayerController.instance.playerAvatarScript, RoundDirector.instance, LevelGenerator.Instance and SpectateCamera.instance to compute its own path and renders its own GameObjects. No RPCs, no Photon traffic. Each player can install independently; nothing about the plugin requires the host or other clients to have it.
  • No Harmony patches. The game's internal fields are read through typed accessors; nothing in the game or in Unity is patched. The F6 panel uses the game's public input and cursor switches, so it does not conflict with mods that patch input.
  • No NavMesh modifications. The plugin calls NavMesh.CalculatePath for itself; it does not bake or alter the game's NavMesh.

Changelog

0.7.3

  • Checked against the current game (R.E.P.O. v0.5.3, Unity 6).
  • The F6 panel now holds the game's controls with the game's own input switches: no walking, looking, grabbing or pause menu while it is open, and Esc closes it. The Unity input patches from 0.7.2 are gone; the plugin no longer patches anything.
  • While you are dead, the trail starts from the player you are spectating.
  • When no full route exists, the trail shows the closest one and says so. The target is moved onto the walkable area, so an extraction point slightly off the NavMesh still gets a trail.
  • The cached route is dropped when the level changes, and lowering MaxDots hides the extra dots straight away.
  • If a game update removes something the plugin reads, the log names it and F4 says the mod needs an update. Repeated errors turn the trail off instead of logging every frame.
  • The config file is written once at startup and when the panel closes. Six trail settings now have ranges.

Every version is in CHANGELOG.md.

Credits

REPOPathfinder is built by two developers:

The Thunderstore release is published under their shared handle, MentalizePez.

Thunderstore development is made possible with ads. Please consider making an exception to your adblock.