diff --git a/game.py b/game.py
index 23adb15..5822d6c 100644
--- a/game.py
+++ b/game.py
@@ -3560,7 +3560,7 @@ ACTION_GLYPHS.update({
for _index, (_area, _level, _prefix, _races) in enumerate(AREAS):
for _race, *_rest in _races:
ACTION_GLYPHS[f"fight_{_slug(_race)}"] = (RACE_GLYPHS[_race], TIER_TINTS[_index])
-UI_GLYPHS = ["two-coins", "sparkles", "hearts", "prayer", "checked-shield", "magic-shield",
+UI_GLYPHS = ["two-coins", "sparkles", "hearts", "prayer", "checked-shield", "magic-shield", "stopwatch",
*(kind["glyph"] for kind in DAMAGE_TYPES.values())]
diff --git a/static/app.js b/static/app.js
index 6f2e9f9..c6a484f 100644
--- a/static/app.js
+++ b/static/app.js
@@ -664,6 +664,39 @@ function gearStats(it) {
return stats.filter(Boolean).join(", ") + (it.weight ? ` (${C.weights[it.weight].name.toLowerCase()})` : "");
}
+const GEAR_SLOTS = ["weapon", "shield", "helmet", "body", "legs"];
+
+// A weapon's or armour piece's stats in a small grid. Weapons: damage type and power | 1H or 2H | swing
+// time; armour: armour | weight | ward. Below: what it needs to wear, and any bonus for you.
+function gearChips(it) {
+ const cell = (icon, text, tip, cls = "") => `${icon}${text === "" ? "" : `${text}`}`;
+ const hands = (two) => `${two ? "2H" : "1H"}`;
+ let row = ["", "", ""];
+ if (it.style) {
+ const st = C.styles[it.style], dt = C.damage_types[st.damage];
+ row = [cell(glyph(dt.glyph, dt.tint), it.power, `${dt.name} damage, +${it.power} power`),
+ cell(hands(it.two_handed), "", it.two_handed ? "Two-handed: no shield" : "One-handed: room for a shield"),
+ cell(glyph("stopwatch", "#9fb3c8"), `${st.interval}s`, `A swing every ${st.interval}s`)];
+ } else if (it.slot === "shield") {
+ row = [cell(glyph("checked-shield", "#d4dae2"), it.armour, `+${it.armour} armour, +${it.power} power`),
+ cell(hands(false), "", "Held in one hand"),
+ cell(glyph("checked-shield", "#e0b04a"), `${Math.round(C.block_chance * 100)}%`, "Blocks this share of hits")];
+ } else if (it.weight) {
+ row = [cell(glyph("checked-shield", "#d4dae2"), it.armour, `+${it.armour} armour: less damage from blows`),
+ cell("", C.weights[it.weight].name, `${C.weights[it.weight].name} armour`, "muted"),
+ cell(glyph("magic-shield", "#a77be8"), it.ward, `+${it.ward} ward: less damage from magic`)];
+ }
+ let req = "", bonus = "";
+ if (it.req) {
+ const [skill, level] = it.req;
+ req = cell(skillOf(skill).icon, level, `Needs ${skillOf(skill).name.toLowerCase()} ${level}`, S.me.levels[skill] < level ? "short" : "");
+ }
+ if (it.style && C.class_style[S.me.cls] === it.style) {
+ bonus = cell(C.classes[S.me.cls].icon, "+15%", "Your trade's weapon: +15% damage", "trade");
+ }
+ return `
${row.join("")}${req}${bonus || ""}
`;
+}
+
// What an item does once made: healing, defence, tool speed, and who can use it.
function itemStats(id) {
const it = item(id);
@@ -733,7 +766,9 @@ function actionCard(a) {
}
if (a.special === "bury") extra = `