Skip to content

feat: 로어 기반 PVP 스탯 시스템 구현#6

Merged
Junseo5 merged 16 commits intomainfrom
feature/lore-stat-system
Feb 1, 2026
Merged

feat: 로어 기반 PVP 스탯 시스템 구현#6
Junseo5 merged 16 commits intomainfrom
feature/lore-stat-system

Conversation

@Junseo5
Copy link
Copy Markdown
Member

@Junseo5 Junseo5 commented Feb 1, 2026

개요

아이템 로어에서 스탯을 파싱하여 PVP 전투에 적용하는 시스템을 구현합니다. 공격력, 방어력, 체력, 피흡수, 치명타, 회피율 등 7가지 스탯을 지원하며, GUI 에디터와 커스터마이징 가능한 설정 시스템을 포함합니다.

변경 유형

  • 버그 수정 (기존 기능을 깨뜨리지 않는 변경)
  • 새 기능 (기존 기능을 깨뜨리지 않는 변경)
  • Breaking Change (기존 기능에 영향을 주는 수정/추가)
  • 문서 업데이트
  • 리팩토링
  • 테스트 추가/수정
  • 빌드/CI 설정

관련 이슈

closes #1
closes #2
closes #3
closes #4
closes #5

변경 사항

  • StatType, ItemStats, PlayerStats, EquipmentSlot 도메인 모델 추가
  • DamageCalculator 서비스로 전투 데미지 계산 로직 구현
  • LoreTemplate, LoreManager로 config 기반 로어 파싱/생성 구현
  • ConfigManager, MessageManager로 설정 및 메시지 관리
  • PlayerStatsCache로 플레이어 스탯 캐싱
  • PlayerStatsService, CombatService, ItemLoreService 애플리케이션 서비스 추가
  • PlsCommand로 /pls 명령어 및 /로어 한국어 별칭 구현
  • EquipmentListener, CombatListener로 이벤트 처리
  • LoreEditGui로 GUI 스탯 에디터 구현
  • config.yml, messages.yml 설정 파일 추가
  • 도메인/인프라/통합 테스트 추가
  • JAR 파일명에 버전 포함되도록 build.gradle 수정
  • README.md 문서 작성

테스트 방법

  1. ./gradlew build로 빌드 및 테스트 실행
  2. 생성된 JAR 파일을 서버에 설치
  3. 아이템에 로어 추가 (예: §c⚔ 공격력 §f+100)
  4. /pls stats로 스탯 확인
  5. /pls edit로 GUI 에디터 테스트
  6. PVP 전투로 스탯 적용 확인

체크리스트

  • 코드가 프로젝트의 코딩 스타일을 따름
  • 변경 사항에 대한 테스트를 추가함
  • 기존 테스트가 모두 통과함
  • 문서를 업데이트함 (필요한 경우)

- Add StatType enum with 7 stat types (damage, defense, health, etc.)
- Add ItemStats immutable value object with builder pattern
- Add EquipmentSlot enum for armor and weapon slots
- Add PlayerStats for managing player's total stats
- Implement damage calculation with attack/defense stats
- Add critical hit calculation with chance and damage
- Add dodge chance calculation
- Add lifesteal healing calculation
- Add StatType enum tests
- Add ItemStats builder and immutability tests
- Add PlayerStats equipment management tests
- Add DamageCalculator calculation tests
- Add LoreTemplate for customizable lore format
- Add LoreManager for parsing and generating item lore
- Support config-based pattern matching for exact format
- Handle color codes (section and ampersand formats)
- Add ConfigManager for loading and caching config.yml
- Add MessageManager for localized messages
- Support weapon pattern matching with wildcards
- Load stat limits and calculation settings
- Add PlayerStatsCache with ConcurrentHashMap
- Add PluginMetrics for tracking parse/combat operations
- Add MetricsLogTask for periodic debug logging
- Test config-based pattern parsing
- Test lore generation with templates
- Test stat modification operations
- Test color code stripping
- Add PlayerStatsService for managing player stats
- Add CombatService for handling combat calculations
- Add ItemLoreService for item lore operations
- Integrate with domain services and infrastructure
- Add /pls command with subcommands
- Implement help, reload, stats, edit commands
- Add tab completion support
- Support Korean alias /로어
- Add EquipmentListener for detecting armor/weapon changes
- Add CombatListener for applying stats to combat
- Handle player join/quit events for stat updates
- Support PVP-only mode configuration
- Add LoreEditGui for visual stat editing
- Support click controls (left/right, shift modifiers)
- Add StatUpdateTask for periodic stat refresh
- Handle inventory close and save operations
- Add config.yml with stat settings and lore formats
- Add messages.yml for localized messages
- Support customizable lore format patterns
- Include weapon type patterns with wildcards
- Update main plugin class with dependency injection
- Wire all services, listeners, and commands
- Add Korean command alias /로어
- Support hot-reload with component recreation
- Test configuration reload functionality
- Verify service recreation after reload
- Test stats update after config changes
- Set version to 1.0.0
- Configure JAR filename as PVPLoreStat-{version}.jar
- Add test dependencies (JUnit, Mockito, MockBukkit)
- Add project overview and features
- Document all stats and calculation formulas
- Add installation and configuration guide
- Include command/permission reference
- Add GUI editor usage instructions
- Document API for developers
- Add FAQ section
@Junseo5 Junseo5 self-assigned this Feb 1, 2026
@Junseo5 Junseo5 merged commit 874e862 into main Feb 1, 2026
1 check passed
@Junseo5 Junseo5 deleted the feature/lore-stat-system branch February 1, 2026 13:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant