mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-07-10 14:27:45 +00:00
and blood lily
This commit is contained in:
parent
d3c656e8b8
commit
f8e3e0333b
3 changed files with 34 additions and 1 deletions
|
@ -587,6 +587,7 @@ namespace Sapphire::Common
|
|||
// AetherflowStack = 30,
|
||||
// Status = 32,
|
||||
PLDGauge = 41,
|
||||
WHMBloodLily = 56,
|
||||
WHMLily = 57,
|
||||
// RDMGaugeBoth = 74,
|
||||
//// RDMGaugeBlack = 75, // not right?
|
||||
|
@ -1077,6 +1078,7 @@ namespace Sapphire::Common
|
|||
GainMPPercentage = 4,
|
||||
GainJobResource = 8,
|
||||
SelfHeal = 16,
|
||||
DamageFallOff = 32,
|
||||
};
|
||||
|
||||
enum ActionBonusEffectRequirement : uint8_t
|
||||
|
|
|
@ -464,15 +464,27 @@ void Action::Action::buildEffects()
|
|||
}
|
||||
|
||||
bool isFirstValidVictim = true;
|
||||
int victimCounter = 0;
|
||||
|
||||
for( auto& actor : m_hitActors )
|
||||
{
|
||||
victimCounter++;
|
||||
if( m_lutEntry.damagePotency > 0 )
|
||||
{
|
||||
Common::AttackType attackType = static_cast< Common::AttackType >( m_actionData->attackType );
|
||||
actor->onActionHostile( m_pSource );
|
||||
|
||||
auto dmg = calcDamage( isCorrectCombo() ? m_lutEntry.damageComboPotency : m_lutEntry.damagePotency );
|
||||
if( victimCounter > 1 )
|
||||
{
|
||||
if( m_lutEntry.bonusEffect & Common::ActionBonusEffect::DamageFallOff )
|
||||
{
|
||||
if( checkActionBonusRequirement() )
|
||||
{
|
||||
dmg.first = static_cast< uint32_t >( 1.0 * dmg.first * ( m_lutEntry.bonusDataByte1 / 100.0 ) );
|
||||
}
|
||||
}
|
||||
}
|
||||
dmg.first = Math::CalcStats::applyDamageReceiveMultiplier( *actor, dmg.first, attackType );
|
||||
|
||||
float originalDamage = dmg.first;
|
||||
|
@ -808,6 +820,23 @@ bool Action::Action::primaryCostCheck( bool subtractCosts )
|
|||
return false;
|
||||
}
|
||||
|
||||
case Common::ActionPrimaryCostType::WHMBloodLily:
|
||||
{
|
||||
auto pPlayer = m_pSource->getAsPlayer();
|
||||
if( pPlayer )
|
||||
{
|
||||
auto bloodLily = pPlayer->gaugeWhmGetBloodLily();
|
||||
if( bloodLily >= m_primaryCost )
|
||||
{
|
||||
if( subtractCosts )
|
||||
pPlayer->gaugeWhmSetLilies( pPlayer->gaugeWhmGetLily(), bloodLily - m_primaryCost );
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
case Common::ActionPrimaryCostType::WHMLily:
|
||||
{
|
||||
auto pPlayer = m_pSource->getAsPlayer();
|
||||
|
|
|
@ -1849,7 +1849,9 @@ ActionLut::Lut ActionLut::m_actionLut =
|
|||
{ 16533, { 300, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } },
|
||||
|
||||
//Afflatus Misery, ハート・オブ・ミゼリ
|
||||
{ 16535, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } },
|
||||
//has damage: potency 900, combo potency 0, directional potency 0
|
||||
//has bonus effect: DamageFallOff, 75
|
||||
{ 16535, { 900, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 75 } },
|
||||
|
||||
//Afflatus Rapture, ハート・オブ・ラプチャー
|
||||
//has heal: potency 300
|
||||
|
|
Loading…
Add table
Reference in a new issue