Add Heal function for monsters. Make player stat functions const return. Add Missing Health bonus stat from buffs. Refactor names of stat functions to be more explicit. Add more stat buff and pct buff checks. Fix up discrepancies with how stat up buffs work for the player. 53/53 passing tests.
This commit is contained in:
@@ -65,7 +65,7 @@ namespace CharacterMenuWindow{
|
||||
const static std::array<AttributeData,7>displayAttrs{
|
||||
AttributeData{"Health",[]()->int{return game->GetPlayer()->GetMaxHealth();}},
|
||||
AttributeData{"Attack",[]()->int{return game->GetPlayer()->GetAttack();}},
|
||||
AttributeData{"Defense",[]()->int{return game->GetPlayer()->GetStat("Defense");}},
|
||||
AttributeData{"Defense",[]()->int{return game->GetPlayer()->GetDefense();}},
|
||||
AttributeData{"Move Spd %",[]()->int{return ceil(game->GetPlayer()->GetMoveSpdMult()*100);}},
|
||||
AttributeData{"CDR",[]()->int{return ceil(game->GetPlayer()->GetCooldownReductionPct()*100);}},
|
||||
AttributeData{"Crit Rate",[]()->int{return ceil(game->GetPlayer()->GetCritRatePct()*100);}},
|
||||
@@ -178,7 +178,7 @@ void Menu::InitializeCharacterMenuWindow(){
|
||||
|
||||
const static auto GetLabelText=[](ItemAttribute attribute){
|
||||
std::string attrStr=std::string(attribute.Name())+"\n ";
|
||||
attrStr+=std::to_string(game->GetPlayer()->GetStat(attribute));
|
||||
attrStr+=std::to_string(game->GetPlayer()->GetEquipStat(attribute));
|
||||
if(attribute.DisplayAsPercent()){
|
||||
attrStr+="%";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user