mirror of
https://github.com/Grasscutters/Grasscutter.git
synced 2025-05-08 21:15:54 +08:00
Clean up adding extra embryo logic in Avatar::recalcStats
This commit is contained in:
parent
45c08c5826
commit
bab6e6845e
@ -556,8 +556,8 @@ public class Avatar {
|
|||||||
this.addFightProperty(prop.getProp(), prop.getValue());
|
this.addFightProperty(prop.getProp(), prop.getValue());
|
||||||
}
|
}
|
||||||
|
|
||||||
// Add any skill strings from this proud skill
|
// Add any embryos from this proud skill
|
||||||
this.addToExtraAbilityEmbryos(proudSkillData.getOpenConfig(), true);
|
this.addToExtraAbilityEmbryos(proudSkillData.getOpenConfig());
|
||||||
}
|
}
|
||||||
|
|
||||||
// Constellations
|
// Constellations
|
||||||
@ -566,7 +566,7 @@ public class Avatar {
|
|||||||
.filter(Objects::nonNull)
|
.filter(Objects::nonNull)
|
||||||
.map(AvatarTalentData::getOpenConfig)
|
.map(AvatarTalentData::getOpenConfig)
|
||||||
.filter(Objects::nonNull)
|
.filter(Objects::nonNull)
|
||||||
.forEach(openConfig -> this.addToExtraAbilityEmbryos(openConfig, false));
|
.forEach(this::addToExtraAbilityEmbryos);
|
||||||
// Add any skill strings from this constellation
|
// Add any skill strings from this constellation
|
||||||
|
|
||||||
// Set % stats
|
// Set % stats
|
||||||
@ -601,6 +601,10 @@ public class Avatar {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void addToExtraAbilityEmbryos(String openConfig) {
|
||||||
|
this.addToExtraAbilityEmbryos(openConfig, false);
|
||||||
|
}
|
||||||
|
|
||||||
public void addToExtraAbilityEmbryos(String openConfig, boolean forceAdd) {
|
public void addToExtraAbilityEmbryos(String openConfig, boolean forceAdd) {
|
||||||
if (openConfig == null || openConfig.length() == 0) {
|
if (openConfig == null || openConfig.length() == 0) {
|
||||||
return;
|
return;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user