One-hit repair (Rust)
Can anyone make a plugin that allows players to fully repair any entity with one-hit of the hammer tool?
Not  area-of-effect, just the entity that the player hit.
@Ultra that plugin is for down/upgrading building blocks.

I'm requesting a plugin that will repair any entity or building block with just one-hit of the hammer tool, instead of having to hit the entity multiple times until it's fully repaired.
I know there are some plugins that already do that, but those plugins repair the whole base (area-of-effect), I just want to make it so players have to hit each entity/building block only once to fully repair it to full hp.
RepairTool is for area-of-effect repairing, EnhancedHammer is for upgrading building blocks.
As I said, you need a combination of these two. I can make it for you but you must test by yourself. Then we make it public

Merged post

private object OnHammerHit(BasePlayer player, HitInfo info)
        {
            var hitEntity = info.HitEntity as BaseCombatEntity;
            if (hitEntity == null)
                return null;

            if (hitEntity.health != hitEntity.MaxHealth())
            {
                PrintToChat($"Setting {hitEntity.health} to {hitEntity.MaxHealth()}");
                hitEntity.health = hitEntity.MaxHealth();
            }

            return false;
        }
I have the plugin done and will post it later.

Ultra, that plugin won't take the full repair cost in to affect.
Ryz0r
I have the plugin done and will post it later.

Ultra, that plugin won't take the full repair cost in to affect.

More detail please. I tested that and it was working fine. I supposed it shoud work with 0 repair cost

Exactly what I was mentioning. It works if you don't want to have to pay for the repair

Merged post

Add me on Discord I have a temp working version till I upload to uMod Ryz0r#0101