Implement Crafting, Social, Magic discipline stubs with expandable root-and-branch structure #234

Open
opened 2026-03-16 01:40:18 +00:00 by freemo · 0 comments
Owner

Metadata

Key Value
Parent Epic #225 — Non-Combat Discipline Trees
Legendary #198 — Character Progression & Skills
Branch feature/m4-non-combat-discipline-stubs
Commit Message feat(skills): implement Crafting, Social, Magic discipline stubs
Points 5
Priority Medium
MoSCoW Could Have

Background and Context

While the Combat and Survival disciplines have full multi-tier trees, the remaining three disciplines — Crafting, Social, and Magic — need expandable stub structures for the v1.3.0 release. Each gets its root node (already defined) plus a set of tier-1 branch stubs that establish the intended direction of each discipline without implementing the full depth.

These stubs serve multiple purposes: they show players the breadth of the skill system, they provide a framework for future expansion, and they validate that the SkillTree data model handles multiple discipline trees simultaneously without issues.

Expected Behavior

  1. Crafting Discipline Stubs (tier 1, require Crafting level 1):

    • Smithing: Forging weapons, armor, and metal tools from raw ore and ingots.
    • Tailoring: Crafting cloth and leather equipment, enchantable garments, and bags.
    • Woodworking: Carving bows, staves, shields, and wooden structures.
  2. Social Discipline Stubs (tier 1, require Social level 1):

    • Persuasion: Influencing NPCs through charm, logic, and emotional appeal.
    • Barter: Negotiating better prices, trade deals, and resource exchanges.
    • Leadership: Inspiring allies, managing groups, and coordinating efforts.
  3. Magic Discipline Stubs (tier 1, require Magic level 1):

    • Elemental: Channeling fire, ice, lightning, and earth magic.
    • Restoration: Healing, purification, and protective ward magic.
    • Enchantment: Imbuing items with magical properties and enhancements.
  4. YAML Structure: Each stub follows the same schema as combat/survival branches, with clear descriptions indicating these are expandable starting points.

  5. Tree Structure:

    Crafting (tier 0) → Smithing, Tailoring, Woodworking (tier 1)
    Social (tier 0) → Persuasion, Barter, Leadership (tier 1)
    Magic (tier 0) → Elemental, Restoration, Enchantment (tier 1)
    
  6. Extensibility: Each stub node's YAML includes a # TODO: Add tier-2+ branches in future epics comment to signal intended expansion.

Acceptance Criteria

  • 3 Crafting branch stubs (Smithing, Tailoring, Woodworking) defined in conf/skill_trees.yaml.
  • 3 Social branch stubs (Persuasion, Barter, Leadership) defined in conf/skill_trees.yaml.
  • 3 Magic branch stubs (Elemental, Restoration, Enchantment) defined in conf/skill_trees.yaml.
  • All stubs are tier 1 and require their root discipline at level 1.
  • list_by_discipline returns correct counts: Crafting 4, Social 4, Magic 4.
  • children_of("crafting") returns Smithing, Tailoring, Woodworking.
  • children_of("social") returns Persuasion, Barter, Leadership.
  • children_of("magic") returns Elemental, Restoration, Enchantment.
  • validate! passes with all 5 discipline trees loaded simultaneously.
  • Total node count across all disciplines: Combat 10 + Survival 10 + Crafting 4 + Social 4 + Magic 4 = 32.

Subtasks

  • Add Smithing, Tailoring, Woodworking definitions to conf/skill_trees.yaml under crafting.
  • Add Persuasion, Barter, Leadership definitions to conf/skill_trees.yaml under social.
  • Add Elemental, Restoration, Enchantment definitions to conf/skill_trees.yaml under magic.
  • Add TODO comments for future tier-2+ expansion in each stub section.
  • Verify list_by_discipline returns correct counts for all 3 disciplines.
  • Verify children_of returns correct stubs for each discipline root.
  • Verify validate! passes with all 32 nodes across 5 disciplines.
  • Verify check_unlockable correctly gates stubs behind discipline root level 1.
  • Docs: Update YARD comments on affected classes and methods. Update relevant Docusaurus documentation pages if applicable.
  • Tests (Cucumber): Add tests/unit/non_combat_stubs.feature covering stub loading from YAML, prerequisite gating for discipline roots, children_of for crafting/social/magic, full tree validation with 32 nodes, discipline listing counts.
  • Tests (Cucumber Integration): Add integration feature in tests/integration/ for Crafting, Social, Magic discipline stubs with full tree validation.
  • Tests (Profiling): Run bundle exec rake unit_profile and verify no performance regressions.
  • Quality: Verify coverage >=97% via bundle exec rake unit. If coverage is <97% then review the current unit test coverage report at build/tests/unit/coverage/ and use it to write new Cucumber based unit tests to improve code coverage. Specifically, write Cucumber/Gherkin style unit tests that are descriptively named and specifically improve coverage on whichever file has the most uncovered lines by writing tests that will target the uncovered lines in the report. Once that is done rerun bundle exec rake unit to verify all tests pass and coverage is above >=97%. Only mark this as complete once coverage is >=97%, if not repeat this task as many times as is needed until coverage reaches >=97%.
  • Quality: Run bundle exec rake (default task: unit tests with coverage) and bundle exec rake integration, fix any errors if needed ensuring both pass across entire code base, do not ignore any failure even if it seems unrelated to this commit, fix it.

Definition of Done

This issue is complete when:

  • All subtasks above are completed and checked off.
  • A Git commit is created where the first line of the commit message matches the Commit Message in Metadata exactly, followed by a blank line, then additional lines providing relevant details about the implementation.
  • The commit is pushed to the remote on the branch matching the Branch in Metadata exactly.
  • The commit is submitted as a pull request to master, reviewed, and merged before this issue is marked done.
## Metadata | Key | Value | |-----|-------| | **Parent Epic** | #225 — Non-Combat Discipline Trees | | **Legendary** | #198 — Character Progression & Skills | | **Branch** | `feature/m4-non-combat-discipline-stubs` | | **Commit Message** | `feat(skills): implement Crafting, Social, Magic discipline stubs` | | **Points** | 5 | | **Priority** | Medium | | **MoSCoW** | Could Have | ## Background and Context While the Combat and Survival disciplines have full multi-tier trees, the remaining three disciplines — Crafting, Social, and Magic — need expandable stub structures for the v1.3.0 release. Each gets its root node (already defined) plus a set of tier-1 branch stubs that establish the intended direction of each discipline without implementing the full depth. These stubs serve multiple purposes: they show players the breadth of the skill system, they provide a framework for future expansion, and they validate that the `SkillTree` data model handles multiple discipline trees simultaneously without issues. ## Expected Behavior 1. **Crafting Discipline Stubs** (tier 1, require Crafting level 1): - **Smithing**: Forging weapons, armor, and metal tools from raw ore and ingots. - **Tailoring**: Crafting cloth and leather equipment, enchantable garments, and bags. - **Woodworking**: Carving bows, staves, shields, and wooden structures. 2. **Social Discipline Stubs** (tier 1, require Social level 1): - **Persuasion**: Influencing NPCs through charm, logic, and emotional appeal. - **Barter**: Negotiating better prices, trade deals, and resource exchanges. - **Leadership**: Inspiring allies, managing groups, and coordinating efforts. 3. **Magic Discipline Stubs** (tier 1, require Magic level 1): - **Elemental**: Channeling fire, ice, lightning, and earth magic. - **Restoration**: Healing, purification, and protective ward magic. - **Enchantment**: Imbuing items with magical properties and enhancements. 4. **YAML Structure:** Each stub follows the same schema as combat/survival branches, with clear descriptions indicating these are expandable starting points. 5. **Tree Structure:** ``` Crafting (tier 0) → Smithing, Tailoring, Woodworking (tier 1) Social (tier 0) → Persuasion, Barter, Leadership (tier 1) Magic (tier 0) → Elemental, Restoration, Enchantment (tier 1) ``` 6. **Extensibility:** Each stub node's YAML includes a `# TODO: Add tier-2+ branches in future epics` comment to signal intended expansion. ## Acceptance Criteria - [ ] 3 Crafting branch stubs (Smithing, Tailoring, Woodworking) defined in `conf/skill_trees.yaml`. - [ ] 3 Social branch stubs (Persuasion, Barter, Leadership) defined in `conf/skill_trees.yaml`. - [ ] 3 Magic branch stubs (Elemental, Restoration, Enchantment) defined in `conf/skill_trees.yaml`. - [ ] All stubs are tier 1 and require their root discipline at level 1. - [ ] `list_by_discipline` returns correct counts: Crafting 4, Social 4, Magic 4. - [ ] `children_of("crafting")` returns Smithing, Tailoring, Woodworking. - [ ] `children_of("social")` returns Persuasion, Barter, Leadership. - [ ] `children_of("magic")` returns Elemental, Restoration, Enchantment. - [ ] `validate!` passes with all 5 discipline trees loaded simultaneously. - [ ] Total node count across all disciplines: Combat 10 + Survival 10 + Crafting 4 + Social 4 + Magic 4 = 32. ## Subtasks - [ ] Add Smithing, Tailoring, Woodworking definitions to `conf/skill_trees.yaml` under crafting. - [ ] Add Persuasion, Barter, Leadership definitions to `conf/skill_trees.yaml` under social. - [ ] Add Elemental, Restoration, Enchantment definitions to `conf/skill_trees.yaml` under magic. - [ ] Add TODO comments for future tier-2+ expansion in each stub section. - [ ] Verify `list_by_discipline` returns correct counts for all 3 disciplines. - [ ] Verify `children_of` returns correct stubs for each discipline root. - [ ] Verify `validate!` passes with all 32 nodes across 5 disciplines. - [ ] Verify `check_unlockable` correctly gates stubs behind discipline root level 1. - [ ] Docs: Update YARD comments on affected classes and methods. Update relevant Docusaurus documentation pages if applicable. - [ ] Tests (Cucumber): Add `tests/unit/non_combat_stubs.feature` covering stub loading from YAML, prerequisite gating for discipline roots, children_of for crafting/social/magic, full tree validation with 32 nodes, discipline listing counts. - [ ] Tests (Cucumber Integration): Add integration feature in `tests/integration/` for Crafting, Social, Magic discipline stubs with full tree validation. - [ ] Tests (Profiling): Run `bundle exec rake unit_profile` and verify no performance regressions. - [ ] Quality: Verify coverage >=97% via `bundle exec rake unit`. If coverage is <97% then review the current unit test coverage report at `build/tests/unit/coverage/` and use it to write new Cucumber based unit tests to improve code coverage. Specifically, write Cucumber/Gherkin style unit tests that are descriptively named and specifically improve coverage on whichever file has the most uncovered lines by writing tests that will target the uncovered lines in the report. Once that is done rerun `bundle exec rake unit` to verify all tests pass and coverage is above >=97%. Only mark this as complete once coverage is >=97%, if not repeat this task as many times as is needed until coverage reaches >=97%. - [ ] Quality: Run `bundle exec rake` (default task: unit tests with coverage) and `bundle exec rake integration`, fix any errors if needed ensuring both pass across **entire** code base, do not ignore any failure even if it seems unrelated to this commit, fix it. ## Definition of Done This issue is complete when: - All subtasks above are completed and checked off. - A Git commit is created where the **first line** of the commit message matches the Commit Message in Metadata exactly, followed by a blank line, then additional lines providing relevant details about the implementation. - The commit is pushed to the remote on the branch matching the **Branch** in Metadata exactly. - The commit is submitted as a **pull request** to `master`, reviewed, and **merged** before this issue is marked done.
freemo added this to the v1.3.0 milestone 2026-03-16 01:40:18 +00:00
freemo self-assigned this 2026-03-16 01:40:18 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference: aethyr/Aethyr#234
No description provided.