From 59389290a923eac9410c4b1cab6c2940f77c9b09 Mon Sep 17 00:00:00 2001 From: Claude Date: Wed, 5 Nov 2025 06:50:07 +0000 Subject: [PATCH 1/2] Fix Balcor class options: Replace 'machine' with 'tech' Issue: Balcor had the 'machine' class which is intended for robots/AI characters, but Balcor is an organic Nerind'ar engineer. Changes: - Replaced 'machine' class with 'tech' class in Balcor's classBoards - Removed redundant 'impervious' skill specification (already provided by support class) - Balcor now has access to engineering-appropriate skills: engineering, regulate, hackAndGrab, assist, camouflage, hardToHit, and distraction This makes thematic sense for Balcor's character description as a "Skilled Nerind'ar engineer with modified prosthetic arm." --- docs/data/corespace-data.json | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/docs/data/corespace-data.json b/docs/data/corespace-data.json index 27e3fe7..1c9da63 100644 --- a/docs/data/corespace-data.json +++ b/docs/data/corespace-data.json @@ -294,13 +294,7 @@ ] }, { - "id": "machine", - "availableSkills": [ - { - "skillId": "impervious", - "maxLevel": 3 - } - ] + "id": "tech" } ], "notes": "Balcor starts with Brutal Assault at level 2 and builds additional resilience and close combat tricks through Support or Marine class boards." From ca3f8a7bf8d63fc468097fbb40e68798be9602b4 Mon Sep 17 00:00:00 2001 From: Claude Date: Wed, 5 Nov 2025 06:53:27 +0000 Subject: [PATCH 2/2] Fix class dropdown: Show all classes for non-machine characters Issue: Characters like Balcor and Wade could only see 3-4 class options in the dropdown, when they should be able to choose from all available classes. Root Cause: The resolveAvailableClasses() function was limiting characters to only the classes listed in their classBoards array, regardless of whether they were machine-restricted characters or not. Changes: - Added machine-only character detection (checks if all classBoards are machine/machineTech) - Machine characters (Hopper, XL) still get only their restricted classes - Non-machine characters now see ALL global classes (all 14 classes) - Character-specific skill customizations from classBoards are merged into global classes - Characters without classBoards continue to get all classes (unchanged) Result: - Balcor now sees all 14 classes instead of just 3 - Wade now sees all 14 classes instead of just 4 - Balcor's custom Marine/Support/Tech skill lists are preserved - Wade's custom skill lists for his classes are preserved - Machine characters (Hopper, XL) remain restricted to machine classes only --- docs/js/character-page.js | 45 +++++++++++++++++++++++++++++++-------- 1 file changed, 36 insertions(+), 9 deletions(-) diff --git a/docs/js/character-page.js b/docs/js/character-page.js index 11f50ed..c21dec3 100644 --- a/docs/js/character-page.js +++ b/docs/js/character-page.js @@ -113,15 +113,42 @@ return fallbackClasses; } - return boards.map((board) => { - const global = state.globalClasses.get(board.id) || {}; - return { - ...global, - ...board, - availableSkills: board.availableSkills || global.availableSkills || [], - description: board.description || global.description || '', - flavorText: board.flavorText || global.flavorText || '', - }; + // Check if this is a machine-only character (only has machine/machineTech classes) + const isMachineOnly = boards.every(board => + board.id === 'machine' || board.id === 'machineTech' + ); + + // Machine characters only get their restricted class options + if (isMachineOnly) { + return boards.map((board) => { + const global = state.globalClasses.get(board.id) || {}; + return { + ...global, + ...board, + availableSkills: board.availableSkills || global.availableSkills || [], + description: board.description || global.description || '', + flavorText: board.flavorText || global.flavorText || '', + }; + }); + } + + // Non-machine characters get all classes, with character-specific customizations merged in + const customBoards = new Map(boards.map(board => [board.id, board])); + + return fallbackClasses.map((globalClass) => { + const customBoard = customBoards.get(globalClass.id); + if (customBoard) { + // Merge character-specific customizations with global class + return { + ...globalClass, + ...customBoard, + availableSkills: customBoard.availableSkills || globalClass.availableSkills || [], + description: customBoard.description || globalClass.description || '', + flavorText: customBoard.flavorText || globalClass.flavorText || '', + }; + } + // Use global class definition as-is + return globalClass; }); }