feat(combat): 맵 몬스터 카드 전투 — 클릭 타겟·멀티 적·전체 처치 승리 #26

Closed
gahusb wants to merge 0 commits from feature/map-monster-combat into main
Owner

개요

카드 공격 대상이 추상 슬라임에서 맵의 실제 몬스터로 바뀝니다. 몬스터를 클릭해 타겟을 지정하고, 공격 카드로 그 몬스터를 때리며, 맵의 모든 몬스터를 처치하면 전투 승리 → 기존 보상/노드/막 흐름으로
이어집니다.

주요 변경

  • 데이터: data/enemies.json에 맵 몬스터 타입(주황/파란버섯) + simEncounter. 신규 data/monster-slots.json(슬롯 화면좌표).
  • 밸런스 sim: tools/balance/sim-balance.mjs 멀티 몬스터로 재작성(타겟 선택·각자 의도·전체 처치 승리), 테스트 14/14.
  • 몬스터 마커: 신규 tools/monster/gen-combat-monster.mjs + CombatMonster.codeblock — 각 맵 몬스터에 EnemyId 부여 + BeginPlay 자기등록, 11맵 패치.
  • 컨트롤러: tools/deck/gen-slaydeck.mjs 전투를 멀티 몬스터로 — 등록 기반 BuildMonsters, 클릭 타겟(SetTarget), DealDamageToTarget/KillMonster, 멀티 EnemyTurn, 전체 처치 승리(CheckCombatEnd),
    머리 위 슬롯(HP바·의도) 렌더.
  • UI: ui/DefaultGroup.ui에 몬스터 슬롯 4개(HP바·의도·투명 타겟버튼).

검증

  • node --test tools/balance/sim-balance.test.mjs → 14/14
  • 생성기 결정적(2회 동일), JSON·중복 id 검사 통과
  • 메이커 플레이테스트: 등록(3마리)→타겟→카드 공격(HP 차감)→적 멀티 반격→전체 처치→승리·보상까지 무에러 확인

알려진 한계 / 후속

  • 사망 시 die 애니메이션은 미재생(상태전이가 서버 권한 필요 → SetVisible로 숨김 처리). 후속으로 서버측 이벤트 트리거 가능.
  • 슬롯 좌표는 data/monster-slots.json로 미세조정 가능.
  • map02~11 몬스터는 현재 전부 orange_mushroom 매핑(파란버섯 미배치) — 이름 매핑/배치로 확장 예정.

설계: docs/superpowers/specs/2026-06-10-map-monster-combat-design.md
계획: docs/superpowers/plans/2026-06-10-map-monster-combat.md

🤖 Generated with Claude Code

## 개요 카드 공격 대상이 추상 슬라임에서 **맵의 실제 몬스터**로 바뀝니다. 몬스터를 클릭해 타겟을 지정하고, 공격 카드로 그 몬스터를 때리며, **맵의 모든 몬스터를 처치하면 전투 승리** → 기존 보상/노드/막 흐름으로 이어집니다. ## 주요 변경 - **데이터**: `data/enemies.json`에 맵 몬스터 타입(주황/파란버섯) + `simEncounter`. 신규 `data/monster-slots.json`(슬롯 화면좌표). - **밸런스 sim**: `tools/balance/sim-balance.mjs` 멀티 몬스터로 재작성(타겟 선택·각자 의도·전체 처치 승리), 테스트 14/14. - **몬스터 마커**: 신규 `tools/monster/gen-combat-monster.mjs` + `CombatMonster.codeblock` — 각 맵 몬스터에 `EnemyId` 부여 + BeginPlay 자기등록, 11맵 패치. - **컨트롤러**: `tools/deck/gen-slaydeck.mjs` 전투를 멀티 몬스터로 — 등록 기반 `BuildMonsters`, 클릭 타겟(`SetTarget`), `DealDamageToTarget`/`KillMonster`, 멀티 `EnemyTurn`, 전체 처치 승리(`CheckCombatEnd`), 머리 위 슬롯(HP바·의도) 렌더. - **UI**: `ui/DefaultGroup.ui`에 몬스터 슬롯 4개(HP바·의도·투명 타겟버튼). ## 검증 - `node --test tools/balance/sim-balance.test.mjs` → 14/14 - 생성기 결정적(2회 동일), JSON·중복 id 검사 통과 - **메이커 플레이테스트**: 등록(3마리)→타겟→카드 공격(HP 차감)→적 멀티 반격→전체 처치→승리·보상까지 무에러 확인 ## 알려진 한계 / 후속 - 사망 시 die 애니메이션은 미재생(상태전이가 서버 권한 필요 → SetVisible로 숨김 처리). 후속으로 서버측 이벤트 트리거 가능. - 슬롯 좌표는 `data/monster-slots.json`로 미세조정 가능. - map02~11 몬스터는 현재 전부 orange_mushroom 매핑(파란버섯 미배치) — 이름 매핑/배치로 확장 예정. 설계: `docs/superpowers/specs/2026-06-10-map-monster-combat-design.md` 계획: `docs/superpowers/plans/2026-06-10-map-monster-combat.md` 🤖 Generated with [Claude Code](https://claude.com/claude-code)
gahusb added 15 commits 2026-06-10 08:29:17 +09:00
추상 단일 적 → 맵 실제 몬스터 멀티 전투(클릭 타겟·각자 HP/의도·전체 처치 시 승리).
컨트롤러 단일 소유 + script.CombatMonster(EnemyId) 매핑 + 월드 HP바 슬롯.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
데이터→sim(TDD)→CombatMonster 마커→컨트롤러 멀티 전투(상태/PlayCard/EnemyTurn/승리/렌더)→슬롯 UI→재생성·플레이테스트.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- ReviveMonsterEntity/KillMonster의 StateComponent:ChangeState 제거
  (client 실행공간에서 LEA-3022 InvalidExecSpace 발생) → SetVisible 기반 표시/숨김으로 대체
- monster-slots.json 좌표를 맵 우측 몬스터 무리 위로 조정
- 메이커 플레이테스트로 전체 전투 루프(등록·타겟·공격·적턴·처치·승리·보상) 무에러 확인

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
gahusb requested review from maple 2026-06-10 08:29:22 +09:00
gahusb added 1 commit 2026-06-10 08:34:44 +09:00
# Conflicts:
#	RootDesk/MyDesk/SlayDeckController.codeblock
maple closed this pull request 2026-06-10 20:06:28 +09:00

Pull request closed

Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: gahusb/maplecontest#26