feat(phase5): 종족/클래스 시스템 균형 및 UI 통합
- 21개 종족 균형 재설계 (스탯 합계 = 0) - 18개 클래스 균형 재설계 (스탯 합계 = +3) - Traits에 raceId, classId 필드 추가 - 저장/불러오기에 종족/클래스 ID 추가 - 캐릭터 생성 UI에서 RaceData/ClassData 사용 - 선택 시 스탯 보정 및 패시브 정보 표시
This commit is contained in:
@@ -296,15 +296,28 @@ class Traits {
|
||||
required this.level,
|
||||
required this.motto,
|
||||
required this.guild,
|
||||
this.raceId = '',
|
||||
this.classId = '',
|
||||
});
|
||||
|
||||
final String name;
|
||||
|
||||
/// 종족 표시 이름 (예: "Kernel Giant")
|
||||
final String race;
|
||||
|
||||
/// 클래스 표시 이름 (예: "Bug Hunter")
|
||||
final String klass;
|
||||
|
||||
final int level;
|
||||
final String motto;
|
||||
final String guild;
|
||||
|
||||
/// 종족 ID (Phase 5, 예: "kernel_giant")
|
||||
final String raceId;
|
||||
|
||||
/// 클래스 ID (Phase 5, 예: "bug_hunter")
|
||||
final String classId;
|
||||
|
||||
factory Traits.empty() => const Traits(
|
||||
name: '',
|
||||
race: '',
|
||||
@@ -312,6 +325,8 @@ class Traits {
|
||||
level: 1,
|
||||
motto: '',
|
||||
guild: '',
|
||||
raceId: '',
|
||||
classId: '',
|
||||
);
|
||||
|
||||
Traits copyWith({
|
||||
@@ -321,6 +336,8 @@ class Traits {
|
||||
int? level,
|
||||
String? motto,
|
||||
String? guild,
|
||||
String? raceId,
|
||||
String? classId,
|
||||
}) {
|
||||
return Traits(
|
||||
name: name ?? this.name,
|
||||
@@ -329,6 +346,8 @@ class Traits {
|
||||
level: level ?? this.level,
|
||||
motto: motto ?? this.motto,
|
||||
guild: guild ?? this.guild,
|
||||
raceId: raceId ?? this.raceId,
|
||||
classId: classId ?? this.classId,
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -53,6 +53,8 @@ class GameSave {
|
||||
'level': traits.level,
|
||||
'motto': traits.motto,
|
||||
'guild': traits.guild,
|
||||
'raceId': traits.raceId,
|
||||
'classId': traits.classId,
|
||||
},
|
||||
'stats': {
|
||||
'str': stats.str,
|
||||
@@ -148,6 +150,8 @@ class GameSave {
|
||||
level: traitsJson['level'] as int? ?? 1,
|
||||
motto: traitsJson['motto'] as String? ?? '',
|
||||
guild: traitsJson['guild'] as String? ?? '',
|
||||
raceId: traitsJson['raceId'] as String? ?? '',
|
||||
classId: traitsJson['classId'] as String? ?? '',
|
||||
),
|
||||
stats: Stats(
|
||||
str: statsJson['str'] as int? ?? 0,
|
||||
|
||||
Reference in New Issue
Block a user