i18n翻译
This commit is contained in:
@@ -19,19 +19,38 @@ type ThirdPartyArtifactDTO struct {
|
||||
// Note: This is a placeholder structure. Adjust it according to the actual API response.
|
||||
// ThirdPartyHeroDTO 第三方英雄数据传输对象
|
||||
type ThirdPartyHeroDTO struct {
|
||||
Code string `json:"code"`
|
||||
ID string `json:"_id"`
|
||||
Name string `json:"-"`
|
||||
Rarity int `json:"rarity"`
|
||||
Attribute string `json:"attribute"`
|
||||
Role string `json:"role"`
|
||||
Zodiac string `json:"zodiac"`
|
||||
SelfDevotion SelfDevotion `json:"self_devotion"`
|
||||
Assets Assets `json:"assets"`
|
||||
ExEquip []ExEquip `json:"ex_equip"`
|
||||
Skills map[string]Skill `json:"skills"`
|
||||
CalculatedStatus map[string]Status `json:"calculatedStatus"`
|
||||
Code string `json:"code"`
|
||||
ID string `json:"_id"`
|
||||
Name string `json:"-"`
|
||||
Rarity int `json:"rarity"`
|
||||
Attribute string `json:"attribute"`
|
||||
Role string `json:"role"`
|
||||
Zodiac string `json:"zodiac"`
|
||||
SelfDevotion SelfDevotion `json:"self_devotion"`
|
||||
Assets Assets `json:"assets"`
|
||||
ExEquip []ExEquip `json:"ex_equip"`
|
||||
Skills Skills `json:"skills"`
|
||||
CalculatedStatus CalculatedStatus `json:"calculatedStatus"`
|
||||
}
|
||||
|
||||
// Skills结构体,支持点语法访问S1、S2、S3
|
||||
type Skills struct {
|
||||
S1 Skill `json:"S1"`
|
||||
S2 Skill `json:"S2"`
|
||||
S3 Skill `json:"S3"`
|
||||
}
|
||||
|
||||
// 新增结构体,支持点语法访问
|
||||
// CalculatedStatus 兼容第三方API的calculatedStatus字段
|
||||
// 只声明常用的两个等级
|
||||
// 其他等级如有需要可自行添加
|
||||
// 字段名需与json tag严格对应
|
||||
|
||||
type CalculatedStatus struct {
|
||||
Lv50FiveStarFullyAwakened Stats `json:"lv50FiveStarFullyAwakened"`
|
||||
Lv60SixStarFullyAwakened Stats `json:"lv60SixStarFullyAwakened"`
|
||||
}
|
||||
|
||||
type SelfDevotion struct {
|
||||
Type string `json:"type"`
|
||||
Grades map[string]float64 `json:"grades"`
|
||||
@@ -60,11 +79,6 @@ type Skill struct {
|
||||
Options []any `json:"options"`
|
||||
}
|
||||
|
||||
type Status struct {
|
||||
Lv50FiveStarFullyAwakened Stats `json:"lv50FiveStarFullyAwakened"`
|
||||
Lv60SixStarFullyAwakened Stats `json:"lv60SixStarFullyAwakened"`
|
||||
}
|
||||
|
||||
type Stats struct {
|
||||
CP int `json:"cp"`
|
||||
ATK int `json:"atk"`
|
||||
|
||||
Reference in New Issue
Block a user