Skip to content

Commit

Permalink
Added artifact substats
Browse files Browse the repository at this point in the history
  • Loading branch information
Wolfteam committed Feb 23, 2021
1 parent 49ac2c3 commit e63d2b9
Show file tree
Hide file tree
Showing 14 changed files with 115 additions and 51 deletions.
1 change: 1 addition & 0 deletions lib/application/character/character_bloc.dart
Expand Up @@ -105,6 +105,7 @@ class CharacterBloc extends Bloc<CharacterEvent, CharacterState> {
builds: char.builds.map((build) {
return CharacterBuildCardModel(
isForSupport: build.isSupport,
subStatsToFocus: build.subStatsToFocus,
weapons: build.weaponImages.map((e) => _genshinService.getWeaponForCardByImg(e)).toList(),
artifacts: build.artifacts.map(
(e) {
Expand Down
1 change: 1 addition & 0 deletions lib/domain/enums/stat_type.dart
Expand Up @@ -21,4 +21,5 @@ enum StatType {
geoDmgBonusPercentage,
anemoDmgBonusPercentage,
healingBonusPercentage,
def,
}
3 changes: 3 additions & 0 deletions lib/domain/models/characters/character_build_card_model.dart
Expand Up @@ -7,10 +7,13 @@ class CharacterBuildCardModel {
final bool isForSupport;
final List<WeaponCardModel> weapons;
final List<CharacterBuildArtifactModel> artifacts;
final List<StatType> subStatsToFocus;

CharacterBuildCardModel({
@required this.isForSupport,
@required this.weapons,
@required this.artifacts,
@required this.subStatsToFocus,
});
}

Expand Down
1 change: 1 addition & 0 deletions lib/domain/models/db/characters/character_file_model.dart
Expand Up @@ -91,6 +91,7 @@ abstract class CharacterFileBuild implements _$CharacterFileBuild {
@required bool isSupport,
@required List<String> weaponImages,
@required List<CharacterFileArtifactBuild> artifacts,
@required List<StatType> subStatsToFocus,
}) = _CharacterFileBuild;

const CharacterFileBuild._();
Expand Down
52 changes: 28 additions & 24 deletions lib/generated/intl/messages_en.dart
Expand Up @@ -37,29 +37,31 @@ class MessageLookup extends MessageLookupByLibrary {

static m8(value) => "${value} CRIT Rate %";

static m9(value) => "${value} DEF %";
static m9(value) => "${value} DEF";

static m10(value) => "${value} Elementary Mastery";
static m10(value) => "${value} DEF %";

static m11(value) => "${value} Energy Recharge %";
static m11(value) => "${value} Elementary Mastery";

static m12(value) => "${value} Healing Bonus %";
static m12(value) => "${value} Energy Recharge %";

static m13(value) => "${value} HP";
static m13(value) => "${value} Healing Bonus %";

static m14(value) => "${value} HP %";
static m14(value) => "${value} HP";

static m15(value) => "${value} PHYS DMG Bonus";
static m15(value) => "${value} HP %";

static m16(value) => "${value} PHYS DMG %";
static m16(value) => "${value} PHYS DMG Bonus";

static m17(value) => "Talent Ascension ${value}";
static m17(value) => "${value} PHYS DMG %";

static m18(value) => "Unlocked at ascension level ${value}";
static m18(value) => "Talent Ascension ${value}";

static m19(value, x) => "${value} ${x} DMG Bonus %";
static m19(value) => "Unlocked at ascension level ${value}";

static m20(value) => "${value} Piece(s)";
static m20(value, x) => "${value} ${x} DMG Bonus %";

static m21(value) => "${value} Piece(s)";

final messages = _notInlinedMessages(_notInlinedMessages);
static _notInlinedMessages(_) => <String, Function> {
Expand Down Expand Up @@ -124,7 +126,8 @@ class MessageLookup extends MessageLookupByLibrary {
"currentLevel" : MessageLookupByLibrary.simpleMessage("Current level"),
"dark" : MessageLookupByLibrary.simpleMessage("Dark"),
"day" : MessageLookupByLibrary.simpleMessage("Day"),
"defPercentage" : m9,
"def" : m9,
"defPercentage" : m10,
"deleteRow" : MessageLookupByLibrary.simpleMessage("Delete row"),
"desc" : MessageLookupByLibrary.simpleMessage("Descending"),
"description" : MessageLookupByLibrary.simpleMessage("Description"),
Expand All @@ -143,9 +146,9 @@ class MessageLookup extends MessageLookupByLibrary {
"elementalResonances" : MessageLookupByLibrary.simpleMessage("Elemental Resonances"),
"elementalResonancesExplained" : MessageLookupByLibrary.simpleMessage("Having these types of character in your party will give you the corresponding effect"),
"elementalSkill" : MessageLookupByLibrary.simpleMessage("Elemental Skill"),
"elementaryMastery" : m10,
"elementaryMastery" : m11,
"elements" : MessageLookupByLibrary.simpleMessage("Elements"),
"energyRechargePercentage" : m11,
"energyRechargePercentage" : m12,
"english" : MessageLookupByLibrary.simpleMessage("English"),
"europe" : MessageLookupByLibrary.simpleMessage("Europe"),
"female" : MessageLookupByLibrary.simpleMessage("Female"),
Expand All @@ -161,11 +164,11 @@ class MessageLookup extends MessageLookupByLibrary {
"goblet" : MessageLookupByLibrary.simpleMessage("Goblet"),
"happyBirthday" : MessageLookupByLibrary.simpleMessage("Happy Birthday!"),
"healingBonus" : MessageLookupByLibrary.simpleMessage("Healing Bonus"),
"healingBonusPercentage" : m12,
"healingBonusPercentage" : m13,
"hold" : MessageLookupByLibrary.simpleMessage("Hold"),
"home" : MessageLookupByLibrary.simpleMessage("Home"),
"hp" : m13,
"hpPercentage" : m14,
"hp" : m14,
"hpPercentage" : m15,
"imgSavedSuccessfully" : MessageLookupByLibrary.simpleMessage("Image was successfully saved to the gallery"),
"issues" : MessageLookupByLibrary.simpleMessage("Issues"),
"language" : MessageLookupByLibrary.simpleMessage("Language"),
Expand Down Expand Up @@ -195,8 +198,8 @@ class MessageLookup extends MessageLookupByLibrary {
"others" : MessageLookupByLibrary.simpleMessage("Others"),
"partial" : MessageLookupByLibrary.simpleMessage("Partial"),
"passives" : MessageLookupByLibrary.simpleMessage("Passives"),
"physDmgBonus" : m15,
"physDmgPercentage" : m16,
"physDmgBonus" : m16,
"physDmgPercentage" : m17,
"pickColor" : MessageLookupByLibrary.simpleMessage("Pick a color"),
"pieces" : MessageLookupByLibrary.simpleMessage("Pieces"),
"plume" : MessageLookupByLibrary.simpleMessage("Plume"),
Expand Down Expand Up @@ -240,13 +243,14 @@ class MessageLookup extends MessageLookupByLibrary {
"startByAddingMsg" : MessageLookupByLibrary.simpleMessage("Start by adding some characters / weapons"),
"stats" : MessageLookupByLibrary.simpleMessage("Stats"),
"subStat" : MessageLookupByLibrary.simpleMessage("Sub. Stat"),
"subStats" : MessageLookupByLibrary.simpleMessage("Substats"),
"summary" : MessageLookupByLibrary.simpleMessage("Summary"),
"sunday" : MessageLookupByLibrary.simpleMessage("Sunday"),
"support" : MessageLookupByLibrary.simpleMessage("Support"),
"supportDps" : MessageLookupByLibrary.simpleMessage("Support DPS"),
"supportMsg" : MessageLookupByLibrary.simpleMessage("I made this app in my free time and it is also open source. If you would like to help me, report an issue, have an idea, want a feature to be implemented, etc, please open an issue in my Github:"),
"sword" : MessageLookupByLibrary.simpleMessage("Sword"),
"talentAscensionX" : m17,
"talentAscensionX" : m18,
"talentsAscension" : MessageLookupByLibrary.simpleMessage("Talents Ascension"),
"theme" : MessageLookupByLibrary.simpleMessage("Theme"),
"thursday" : MessageLookupByLibrary.simpleMessage("Thursday"),
Expand All @@ -257,7 +261,7 @@ class MessageLookup extends MessageLookupByLibrary {
"tuesday" : MessageLookupByLibrary.simpleMessage("Tuesday"),
"type" : MessageLookupByLibrary.simpleMessage("Type"),
"unknownError" : MessageLookupByLibrary.simpleMessage("Unknown error occurred"),
"unlockedAtAscensionLevelX" : m18,
"unlockedAtAscensionLevelX" : m19,
"unlockedAutomatically" : MessageLookupByLibrary.simpleMessage("Unlocked Automatically"),
"unreleased" : MessageLookupByLibrary.simpleMessage("Unreleased"),
"utility" : MessageLookupByLibrary.simpleMessage("Utility"),
Expand All @@ -266,8 +270,8 @@ class MessageLookup extends MessageLookupByLibrary {
"weapons" : MessageLookupByLibrary.simpleMessage("Weapons"),
"wednesday" : MessageLookupByLibrary.simpleMessage("Wednesday"),
"wishSimulator" : MessageLookupByLibrary.simpleMessage("Wish simulator"),
"xDmgBonusPercentage" : m19,
"xPieces" : m20,
"xDmgBonusPercentage" : m20,
"xPieces" : m21,
"youCanAlsoSendMeAnEmail" : MessageLookupByLibrary.simpleMessage("You can also send me an email")
};
}
52 changes: 28 additions & 24 deletions lib/generated/intl/messages_es_ES.dart
Expand Up @@ -37,29 +37,31 @@ class MessageLookup extends MessageLookupByLibrary {

static m8(value) => "${value} Prob. CRIT %";

static m9(value) => "${value} DEF %";
static m9(value) => "${value} DEF";

static m10(value) => "${value} Maestría Elemental";
static m10(value) => "${value} DEF %";

static m11(value) => "${value} Recarga de Energía %";
static m11(value) => "${value} Maestría Elemental";

static m12(value) => "${value} Bonus de Curación %";
static m12(value) => "${value} Recarga de Energía %";

static m13(value) => "${value} Vida";
static m13(value) => "${value} Bonus de Curación %";

static m14(value) => "${value} Vida %";
static m14(value) => "${value} Vida";

static m15(value) => "${value} Bono Daño FIS.";
static m15(value) => "${value} Vida %";

static m16(value) => "${value} Daño FIS. %";
static m16(value) => "${value} Bono Daño FIS.";

static m17(value) => "Talento de Ascención ${value}";
static m17(value) => "${value} Daño FIS. %";

static m18(value) => "Desbloqueada en nivel de ascención ${value}";
static m18(value) => "Talento de Ascención ${value}";

static m19(value, x) => "${value} Bono de Daño ${x} %";
static m19(value) => "Desbloqueada en nivel de ascención ${value}";

static m20(value) => "${value} Pieza(s)";
static m20(value, x) => "${value} Bono de Daño ${x} %";

static m21(value) => "${value} Pieza(s)";

final messages = _notInlinedMessages(_notInlinedMessages);
static _notInlinedMessages(_) => <String, Function> {
Expand Down Expand Up @@ -123,7 +125,8 @@ class MessageLookup extends MessageLookupByLibrary {
"currentLevel" : MessageLookupByLibrary.simpleMessage("Nivel actual"),
"dark" : MessageLookupByLibrary.simpleMessage("Oscuro"),
"day" : MessageLookupByLibrary.simpleMessage("Día"),
"defPercentage" : m9,
"def" : m9,
"defPercentage" : m10,
"deleteRow" : MessageLookupByLibrary.simpleMessage("Borrar fila"),
"desc" : MessageLookupByLibrary.simpleMessage("Descendente"),
"description" : MessageLookupByLibrary.simpleMessage("Descripción"),
Expand All @@ -142,9 +145,9 @@ class MessageLookup extends MessageLookupByLibrary {
"elementalResonances" : MessageLookupByLibrary.simpleMessage("Resonancias Elementales"),
"elementalResonancesExplained" : MessageLookupByLibrary.simpleMessage("Teniendo estos tipos de personajes en tu equipo te daran el effecto correspondiente"),
"elementalSkill" : MessageLookupByLibrary.simpleMessage("Habilidad Elemental"),
"elementaryMastery" : m10,
"elementaryMastery" : m11,
"elements" : MessageLookupByLibrary.simpleMessage("Elementos"),
"energyRechargePercentage" : m11,
"energyRechargePercentage" : m12,
"english" : MessageLookupByLibrary.simpleMessage("Inglés"),
"europe" : MessageLookupByLibrary.simpleMessage("Europa"),
"female" : MessageLookupByLibrary.simpleMessage("Mujer"),
Expand All @@ -160,11 +163,11 @@ class MessageLookup extends MessageLookupByLibrary {
"goblet" : MessageLookupByLibrary.simpleMessage("Copa"),
"happyBirthday" : MessageLookupByLibrary.simpleMessage("¡Feliz Cumpleaños!"),
"healingBonus" : MessageLookupByLibrary.simpleMessage("Bono de curación"),
"healingBonusPercentage" : m12,
"healingBonusPercentage" : m13,
"hold" : MessageLookupByLibrary.simpleMessage("Mantener"),
"home" : MessageLookupByLibrary.simpleMessage("Inicio"),
"hp" : m13,
"hpPercentage" : m14,
"hp" : m14,
"hpPercentage" : m15,
"imgSavedSuccessfully" : MessageLookupByLibrary.simpleMessage("La imagen fue guardada exitósamente en la galería"),
"issues" : MessageLookupByLibrary.simpleMessage("Inconvenientes"),
"language" : MessageLookupByLibrary.simpleMessage("Lenguaje"),
Expand Down Expand Up @@ -194,8 +197,8 @@ class MessageLookup extends MessageLookupByLibrary {
"others" : MessageLookupByLibrary.simpleMessage("Otros"),
"partial" : MessageLookupByLibrary.simpleMessage("Parcial"),
"passives" : MessageLookupByLibrary.simpleMessage("Pasivas"),
"physDmgBonus" : m15,
"physDmgPercentage" : m16,
"physDmgBonus" : m16,
"physDmgPercentage" : m17,
"pickColor" : MessageLookupByLibrary.simpleMessage("Selecciona un color"),
"pieces" : MessageLookupByLibrary.simpleMessage("Piezas"),
"plume" : MessageLookupByLibrary.simpleMessage("Pluma"),
Expand Down Expand Up @@ -239,13 +242,14 @@ class MessageLookup extends MessageLookupByLibrary {
"startByAddingMsg" : MessageLookupByLibrary.simpleMessage("Empieza por agregar algunos personajes / armas"),
"stats" : MessageLookupByLibrary.simpleMessage("Estadísticas"),
"subStat" : MessageLookupByLibrary.simpleMessage("Sub. Stat"),
"subStats" : MessageLookupByLibrary.simpleMessage("Subestadisticas"),
"summary" : MessageLookupByLibrary.simpleMessage("Resúmen"),
"sunday" : MessageLookupByLibrary.simpleMessage("Domingo"),
"support" : MessageLookupByLibrary.simpleMessage("Soporte"),
"supportDps" : MessageLookupByLibrary.simpleMessage("DPS de Soporte"),
"supportMsg" : MessageLookupByLibrary.simpleMessage("Hice esta aplicación en mi tiempo libre y también es de código abierto. Si deseas ayudarme, informar de un problema, tienes una idea, deseas que se implemente una funcionalidad, etc., crea un issue en mi Github:"),
"sword" : MessageLookupByLibrary.simpleMessage("Espada"),
"talentAscensionX" : m17,
"talentAscensionX" : m18,
"talentsAscension" : MessageLookupByLibrary.simpleMessage("Talentos de Ascención"),
"theme" : MessageLookupByLibrary.simpleMessage("Tema"),
"thursday" : MessageLookupByLibrary.simpleMessage("Jueves"),
Expand All @@ -256,7 +260,7 @@ class MessageLookup extends MessageLookupByLibrary {
"tuesday" : MessageLookupByLibrary.simpleMessage("Martes"),
"type" : MessageLookupByLibrary.simpleMessage("Tipo"),
"unknownError" : MessageLookupByLibrary.simpleMessage("Un error desconocido ha ocurrido"),
"unlockedAtAscensionLevelX" : m18,
"unlockedAtAscensionLevelX" : m19,
"unlockedAutomatically" : MessageLookupByLibrary.simpleMessage("Desbloqueada Automáticamente"),
"unreleased" : MessageLookupByLibrary.simpleMessage("No Publicado"),
"utility" : MessageLookupByLibrary.simpleMessage("Utilidad"),
Expand All @@ -265,8 +269,8 @@ class MessageLookup extends MessageLookupByLibrary {
"weapons" : MessageLookupByLibrary.simpleMessage("Armas"),
"wednesday" : MessageLookupByLibrary.simpleMessage("Miércoles"),
"wishSimulator" : MessageLookupByLibrary.simpleMessage("Simulador de Deseos"),
"xDmgBonusPercentage" : m19,
"xPieces" : m20,
"xDmgBonusPercentage" : m20,
"xPieces" : m21,
"youCanAlsoSendMeAnEmail" : MessageLookupByLibrary.simpleMessage("También puedes enviarme un correo")
};
}
20 changes: 20 additions & 0 deletions lib/generated/l10n.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 3 additions & 1 deletion lib/l10n/intl_en.arb
Expand Up @@ -14,6 +14,7 @@
"atk": "{value} ATK",
"atkPercentage": "{value} ATK %",
"defPercentage": "{value} DEF %",
"def": "{value} DEF",
"critAtk": "{value} CRIT ATK",
"critRate": "{value} CRIT Rate",
"critRatePercentage": "{value} CRIT Rate %",
Expand Down Expand Up @@ -204,5 +205,6 @@
"europe": "Europe",
"asia": "Asia",
"chooseServer": "Choose a server",
"serverWhereYouPlay":"The server where you play"
"serverWhereYouPlay":"The server where you play",
"subStats": "Substats"
}
4 changes: 3 additions & 1 deletion lib/l10n/intl_es_ES.arb
Expand Up @@ -14,6 +14,7 @@
"atk": "{value} ATQ",
"atkPercentage": "{value} ATQ %",
"defPercentage": "{value} DEF %",
"def": "{value} DEF",
"critAtk": "{value} ATQ CRIT",
"critRate": "{value} Prob. CRIT",
"critRatePercentage": "{value} Prob. CRIT %",
Expand Down Expand Up @@ -203,5 +204,6 @@
"europe": "Europa",
"asia": "Asia",
"chooseServer": "Escoge un servidor",
"serverWhereYouPlay":"El servidor donde juegas"
"serverWhereYouPlay":"El servidor donde juegas",
"subStats": "Subestadisticas"
}
4 changes: 3 additions & 1 deletion lib/l10n/intl_fr.arb
Expand Up @@ -14,6 +14,7 @@
"atk": "{value} ATK",
"atkPercentage": "{value} ATK %",
"defPercentage": "{value} DEF %",
"def": "{value} DEF",
"critAtk": "{value} CRIT ATK",
"critRate": "{value} CRIT Rate",
"critRatePercentage": "{value} CRIT Rate %",
Expand Down Expand Up @@ -204,5 +205,6 @@
"europe": "Europe",
"asia": "Asia",
"chooseServer": "Choose a server",
"serverWhereYouPlay":"The server where you play"
"serverWhereYouPlay":"The server where you play",
"subStats": "Substats"
}
Expand Up @@ -46,6 +46,7 @@ class CharacterDetailBottom extends StatelessWidget {
elementType: state.elementType,
weapons: build.weapons,
artifacts: build.artifacts,
subStatsToFocus: build.subStatsToFocus,
))
.toList(),
),
Expand Down

0 comments on commit e63d2b9

Please sign in to comment.