You are viewing a potentially older version of this package. View all versions.
MrGlim-MapClickCodes-1.0.1 icon

MapClickCodes

Click code markers on the main ship radar to activate terminal codes (doors, turrets, mines, traps).

Date uploaded a day ago
Version 1.0.1
Download link MrGlim-MapClickCodes-1.0.1.zip
Downloads 6
Dependency string MrGlim-MapClickCodes-1.0.1

This mod requires the following mods to function

BepInEx-BepInExPack-5.4.2100 icon
BepInEx-BepInExPack

BepInEx pack for Mono Unity games. Preconfigured and ready to use.

Preferred version: 5.4.2100

README

MapClickCodes

Click a terminal code marker (door / turret / mine / trap / etc.) on the main ship radar screen to activate that object's code — same effect as typing the code into the terminal.

Features

  • Main radar only — uses StartOfRound.mapScreen mesh (not CrewMonitors clones, not other cameras).
  • Precise hits — raycast → mesh UV → mapCamera viewport, then tests against each TerminalAccessibleObject.mapRadarObject RectTransform (code box size + configurable padding). Empty map areas do nothing.
  • Vanilla-friendly — missing a marker still allows normal monitor / radar target switching.
  • Host-gated — click-to-code is active only when the lobby host has this mod enabled (same fairness pattern as other MrGlim advantage QoL mods). Clients retry hello sync until the host acknowledges.
  • Host-authoritative activate — non-host players hit-test locally, then the host runs CallFunctionFromTerminal (local SFX on the clicker is fine).
  • SFX — plays the terminal code-broadcast animation/sound when available.

How to use

  1. Stand in the ship and look at the large main map / radar monitor.
  2. Aim at a green/red code box on the radar feed.
  3. Press Interact (E) — that object's terminal code runs (CallFunctionFromTerminal).

Config (BepInEx/config/com.benhough.lethal.MapClickCodes.cfg)

Key Default Notes
Enabled true Master toggle
VerboseLogging false UV / match traces
HitRadius 0.022 Extra UV padding around marker rects
FlipUvV true Flip V when mapping mesh UV → viewport (toggle if vertically inverted)
InteractRange 4.5 Max ray distance to the screen mesh

Networking

Non-host clients with the mod send a named Netcode activate request to the host after a successful marker hit. The host validates the TerminalAccessibleObject (NetworkObjectId, with object-code fallback) and calls CallFunctionFromTerminal(). Door/turret/mine behaviour continues to use the object's own UnityEvents / ServerRpcs, so activation syncs like typing a code.

Both host and clients should install this mod from Thunderstore so everyone can click markers. Host must enable it for the lobby. Clients without the mod still see synced activations when someone else clicks, but cannot click themselves.

This is a convenience over walking to the terminal — treat it as an advantage feature for your lobby rules.

Dependencies

  • BepInExPack only (no OpenBodyCams).

Credits

Ben Hough (MrGlim) — Thunderstore team MrGlim.