1
This commit is contained in:
parent
68ddbb136c
commit
024b9ddece
@ -892,3 +892,13 @@ float BattleDataContext::GetBrainLifePct()
|
||||
{
|
||||
return hero_ability_->GetBrainLifePct();
|
||||
}
|
||||
|
||||
float BattleDataContext::GetSkillCdPct()
|
||||
{
|
||||
return 0.0f;
|
||||
}
|
||||
|
||||
float BattleDataContext::GetRescueTimePct()
|
||||
{
|
||||
return 0.0f;
|
||||
}
|
||||
|
@ -62,6 +62,8 @@ struct BattleDataContext
|
||||
float GetHeroTotalAtk();
|
||||
float GetExtRecoverHp();
|
||||
float GetBrainLifePct();
|
||||
float GetSkillCdPct();
|
||||
float GetRescueTimePct();
|
||||
|
||||
void SetReviveCoin(int num);
|
||||
int GetReviveCoin();
|
||||
|
@ -711,7 +711,7 @@ void Player::HumanInteraction(Human* hum)
|
||||
return;
|
||||
}
|
||||
int downed_relive_time = mt::Param::GetIntParam("downed_relive_time") * 1000;
|
||||
downed_relive_time -= GetAbility()->GetAttrAbs(kHAT_RescueTime);
|
||||
downed_relive_time *= 1 + GetBattleContext()->GetRescueTimePct();
|
||||
downed_relive_time = std::max(0, downed_relive_time);
|
||||
StartAction(
|
||||
AT_Rescue,
|
||||
|
@ -54,7 +54,12 @@ void Skill::Initialzie()
|
||||
|
||||
int Skill::GetCd()
|
||||
{
|
||||
return meta->skill_cd() * 1000;
|
||||
if (meta->IsTurnOverSkill() ||
|
||||
meta->skill_type() == kPassiveSkill) {
|
||||
return meta->skill_cd() * 1000;
|
||||
} else {
|
||||
return meta->skill_cd() * 1000 * (1 + owner->GetBattleConetxt()->GetSkillCdPct());
|
||||
}
|
||||
}
|
||||
|
||||
int Skill::GetPassedTime()
|
||||
|
Loading…
x
Reference in New Issue
Block a user