QcRepair Namespace
Repair in the crafting grid (decision E-236): two items of the same kind with durability, at least one of them worn, and nothing else make one item with both remaining durabilities plus a bonus of 5 % of the full durability. More...
| Header: | #include <common/gameplay/QcRepair.h> |
Variables
| const double | bonusShare |
Functions
| std::optional<QcItemStack> | result(const QcContentRegistry &content, const QList<QcItemStack> &grid) |
Detailed Description
Works on any grid size; tools and armour alike.
Variable Documentation
const double QcRepair::bonusShare
The bonus as a share of the full durability.
Function Documentation
std::optional<QcItemStack> QcRepair::result(const QcContentRegistry &content, const QList<QcItemStack> &grid)
Returns the repaired item for the cells grid, with the items of content, or nothing when they are no repair.