Skip to content

[openworlds] Add attributed icon registry for actions, conditions, items, and factions #174

Description

@100yenadmin

Summary And Gameplay Impact

Add an attributed, local icon registry for OpenWorlds so actions, conditions, quests, inventory categories, factions, travel affordances, and display-only capability states are readable at a glance. This is the safest high-velocity UI lift: it improves table/combat/atlas scanability without changing engine mechanics or game-state authority.

Current ClawDnD State

OpenWorlds already renders the visible macOS app surface, and issue #133 tracks capability badges/display-only states. The UI still relies heavily on text labels, small glyphs, and prototype affordances. There is no local icon registry, no reusable gameplay icon taxonomy, and no attribution path for imported third-party SVGs.

External Source Value And Recommendation

Use game-icons/icons as a curated asset source, not a runtime dependency and not a bulk import. The repo license text says icons are Creative Commons BY 3.0 unless a contributor is explicitly CC0, and asks derivative works to mention the icon authors. Import only a small audited subset with exact author/source/license attribution.

Recommended initial subset:

  • lorc/sword-clash.svg for attack/combat.
  • lorc/open-book.svg for codex/lore.
  • lorc/tied-scroll.svg for quests.
  • lorc/compass.svg for atlas/travel.
  • lorc/campfire.svg for camp/rest.
  • lorc/locked-chest.svg for locked/unavailable/stash.
  • delapouite/dice-twenty-faces-twenty.svg for dice/roll.
  • delapouite/rolling-dices.svg for random/roll surfaces.
  • delapouite/health-potion.svg for consumables.
  • delapouite/coins.svg for economy/merchant.
  • delapouite/tavern-sign.svg for settlements/hubs.

Architecture Plan

  • Add a small OpenWorlds icon registry, e.g. viewer/openworlds/icon-registry.js or viewer/openworlds/icons.jsx.
  • Add SVGs under viewer/openworlds/assets/icons/game-icons/<author>/<slug>.svg.
  • Add viewer/openworlds/assets/icons/ATTRIBUTION.md with author, source path, source URL, and license for every imported icon.
  • Add or extend THIRD_PARTY_NOTICES.md so packaged app builds carry the attribution.
  • Wire icons through semantic ids such as combat.attack, dice.d20, atlas.travel, quest.scroll, camp.rest, inventory.potion, and economy.coins.
  • Pair icons with issue [openworlds] Add capability badges and display-only states for unbacked screens #133 capability labels so display-only screens still identify themselves honestly.
  • Do not fetch icons from the network at runtime.

Files And Modules Likely Touched

  • viewer/openworlds/icon-registry.js or viewer/openworlds/icons.jsx
  • viewer/openworlds/assets/icons/game-icons/**
  • viewer/openworlds/assets/icons/ATTRIBUTION.md
  • viewer/openworlds/screen-table.jsx
  • viewer/openworlds/screen-combat.jsx
  • viewer/openworlds/screen-map.jsx
  • viewer/openworlds/screen-inventory.jsx
  • viewer/openworlds/screen-relations.jsx
  • viewer/openworlds/styles.css
  • viewer/tests/test_openworlds_static.py
  • scripts/license_check.py
  • THIRD_PARTY_NOTICES.md

State-Authority Boundary

This issue is presentation-only. The registry must not introduce game-state writes, local browser state authority, or inferred action legality. Icons decorate read models and /move-backed player-intent actions only.

Acceptance Criteria

  • Imported icons are limited to an audited curated subset.
  • Every imported SVG has an attribution entry with author, source path, source URL, and license.
  • THIRD_PARTY_NOTICES.md covers the imported Game Icons subset.
  • OpenWorlds uses semantic icon ids instead of hardcoded scattered asset paths.
  • Missing icon ids degrade to a local fallback glyph, not a broken image.
  • At least table actions, combat actions, atlas/travel markers, quest markers, condition badges, and inventory/economy affordances use the registry where obvious.
  • No network CDN/icon calls are introduced.
  • Display-only/prototype controls remain labeled by capability state and are not made to look executable.

Focused Validation Commands

python3 -m unittest viewer.tests.test_openworlds_static -q
python3 scripts/license_check.py
git diff --check

Adversarial Risks

  • Missing CC-BY attribution in the packaged app.
  • Bulk-importing the icon set and making license review noisy.
  • Icons making unbacked prototype screens look wired.
  • Broken relative paths when OpenWorlds is served from bundled app resources.

Original-Agent Handoff

Start with:

  • viewer/openworlds/screen-table.jsx
  • viewer/openworlds/screen-combat.jsx
  • viewer/openworlds/screen-map.jsx
  • viewer/openworlds/styles.css
  • viewer/tests/test_openworlds_static.py
  • scripts/license_check.py

Refs #113, #115, #116, #117, #119, #121, #133.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestseverity:minorPolish gap — release-quality wouldn't ship with ittier-1Tier 1: Claude Code plugin

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions