Gear that wears out: adding durability to a browser RPG without punishing players
For most of its life, gear in our browser crime RPG, Underground Evolution, lasted forever. You bought a pistol, you equipped it, and it was the same pistol a thousand fights later. That is simple, but it has a cost: onc
For most of its life, gear in our browser crime RPG, Underground Evolution, lasted forever. You bought a pistol, you equipped it, and it was the same pistol a thousand fights later. That is simple, but it has a cost: once a player owns the best gear they can afford, money stops mattering, and the repair shops in the city have nothing to do.
So we added wear and tear. This post is about the rules we chose, and the small details that kept it from feeling like a tax.
Hit points you can read
Every weapon, piece of armour and car now has hit points, shown plainly: a pistol reads 180 / 200. Better gear has more hit points, so it lasts longer. That gives players a second reason to upgrade besides raw stats.
Numbers alone are hard to scan in a long inventory, so each item also gets a word that follows its condition: Mint, Good, Worn, Battered, Broken. Players glance at the word and read the number when they care.
One mistake we made early: items already had a "repairs left" counter, and players confused it with condition. We renamed it to a chip that reads Repairs left: Many / Few / None, so the two can never be mistaken for each other.
Wear that follows what you did
We wanted wear to feel earned, not random. The rules are short:
- Your weapon wears by the strikes it lands. A long fight costs more than a quick one.
- A beating wears your armour more than a clean win. Armour that took the hits shows it.
- Driving wears your car, a little more on long trips.
- Every fight costs a little, win or lose. Nobody gets a free ride.
The cap that keeps it fair
The rule that mattered most was a ceiling: one fight never takes more than 5% of a piece. Without it, one unlucky fight against a much stronger player could wreck a weapon someone saved up for. With it, wear is a slow drift that players can plan around.
In simplified form, the per-fight wear looks like this:
// Simplified: wear for one piece of gear after one fight.
function fightWear(int $maxHp, int $strikes, bool $lost): int
{
$wear = $strikes; // weapons: one point per landed strike
if ($lost) {
$wear = (int) ceil($wear * 1.5); // a beating costs armour more
}
$wear = max(1, $wear); // every fight costs a little
$cap = (int) floor($maxHp * 0.05);
return min($wear, max(1, $cap)); // never more than 5% of the piece
}
The real numbers are tuned per item type, but the shape is the same: a floor so fights always count, and a cap so no single fight hurts too much.
Tell players before it breaks
Durability systems feel unfair when gear breaks by surprise. So the game sends a notice when a piece is half worn, and again when it is nearly worn out, each with a link straight to the repair place. Players who would rather keep an eye on it themselves can switch those notices off in their preferences.
Repairs, item cards and item pages all show hit points too, so the number is never hidden behind a click.
Why it's worth it
Wear gives the repair shops in the city a job, and gives better gear a clear long-term value. A beaten-up coat after a rough week also tells a little story about how you play.
We also added a new medal, Battle-Worn. If a system costs players something, it helps to give them something to show for it.
Underground Evolution is a free 1920s crime RPG for adults (18+), set in Vesper City, playable in the browser and on the phone. Play free at https://underground-evolution.com, or wishlist the Steam edition: https://store.steampowered.com/app/5550110/
Originally published by Dev.to WebDev. Aggregated on AIWithGhost for educational purposes — full credit and traffic to the original publisher.