Try to give name card

This commit is contained in:
Yazawazi
2022-04-23 21:03:29 +08:00
committed by GitHub
parent 042bdc2ff2
commit 3bc249f042
4 changed files with 69 additions and 2 deletions

View File

@@ -433,6 +433,7 @@ public class GenshinAvatar {
// Fetters
this.setFetterList(data.getFetters());
this.setNameCardRewardId(data.getNameCardRewardId());
// Get hp percent, set to 100% if none
float hpPercent = this.getFightProperty(FightProperty.FIGHT_PROP_MAX_HP) <= 0 ? 1f : this.getFightProperty(FightProperty.FIGHT_PROP_CUR_HP) / this.getFightProperty(FightProperty.FIGHT_PROP_MAX_HP);