You are viewing a potentially older version of this package. View all versions.
modx-GrabRecharge-2.0.0 icon

GrabRecharge

A BepInEx plugin that allows players to recharge grabbed items manually using customizable mod power.

Date uploaded a day ago
Version 2.0.0
Download link modx-GrabRecharge-2.0.0.zip
Downloads 1311
Dependency string modx-GrabRecharge-2.0.0

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

Player Grab Recharge

A BepInEx plugin for Unity-based games that allows players to recharge grabbed battery items manually using customizable mod power. Built with Harmony patching and Photon networking support.


Features

  • Manual Battery Recharge: Recharge grabbed batteries using a configurable key.
  • Toggle/Hold Mode: Use toggle or hold input to control recharging.
  • Mod Power System: Recharging consumes mod power and regenerates over time.
  • Visual UI: Optional in-game UI shows current mod power level and cooldowns.
  • Multiplayer Support: Proper PhotonView ownership handling in multiplayer environments.
  • Debug Logging: Toggleable detailed logs for troubleshooting.

Requirements

  • BepInEx 5.x
  • HarmonyLib
  • Photon Unity Networking (PUN2) enabled project
  • TMPro (TextMeshPro) used for in-game UI

Installation

  1. Install BepInEx in your game directory.
  2. Place the compiled PlayerGrabRecharge.dll into the BepInEx/plugins folder.
  3. Launch the game once to generate the configuration file.
  4. Customize settings in BepInEx/config/modx.playergrabrecharge.cfg.

Configuration Options

Setting Description Default
Recharge Key Key to activate recharge Z
Toggle Mode Recharge mode: true = toggle, false = hold false
Recharge Rate Battery charge per second (1-30) 10
Enable Debug Logging Enables verbose logs in console false
Show Charge Bar Show mod power UI on screen true

How It Works

  • When you grab a battery item, a mod power gauge is displayed (if enabled).

  • Hold or toggle the recharge key (Z by default) to charge the battery:

    • Recharge drains mod power.
    • Mod power regenerates over time when idle.
    • If mod power depletes, a cooldown starts before it begins to regen.

Debugging

Enable "Enable Debug Logging" in the config to log:

  • Ownership requests
  • Recharge start/stop triggers
  • Battery life and mod power changes
  • Cooldown and regeneration steps

Compatibility & Multiplayer

  • Fully compatible with Photon Multiplayer.
  • Master client (Host) can only rechrage items.
  • Automatically syncs recharge behavior across clients.

Credits

Developed by modx Powered by BepInEx, Harmony, and Photon PUN2