oops, typeless for real this time + proper usage of the debuffData
This commit is contained in:
1 parent
d25a48e875
commit
df61806edd
2 files changed
+5
-4
No files matched your search
@@ -8,14 +8,15 @@ namespace CalamityMod.Buffs.DamageOverTime
|
||||
{
|
||||
public static DebuffData debuffData = new DebuffData()
|
||||
{
|
||||
EnemyLostRegen = 50, //This is the base DoT before the scaling formula. Not used in the method, here for referece.
|
||||
EnemyLostRegen = 50,
|
||||
NPCLifeRegenMethod = SagePoisonPower
|
||||
};
|
||||
public static void SagePoisonPower(NPC npc, int buffType, ref int buffIndex, ref int damage)
|
||||
{
|
||||
// npc.Calamity().sagePoisonDamage = 50 * (float)(Math.Pow(totalSageSpirits, 0.73D) + Math.Pow(totalSageSpirits, 1.1D)) * 0.5f
|
||||
// The dot ia multipliplied by this before being applied:
|
||||
// (float)(Math.Pow(totalSageSpirits, 0.9D) + Math.Pow(totalSageSpirits, 1.13D)) * 0.5f;
|
||||
// See SageNeedle.cs for details
|
||||
int baseSagePoisonDoTValue = npc.Calamity().sagePoisonDamage;
|
||||
int baseSagePoisonDoTValue = (int)npc.Calamity().ActiveTypelessDebuffMultiplier.ApplyTo(npc.Calamity().sagePoisonDamage);
|
||||
npc.Calamity().ApplyDPSDebuff(baseSagePoisonDoTValue, baseSagePoisonDoTValue / 5, ref npc.lifeRegen, ref damage);
|
||||
}
|
||||
public override void SetStaticDefaults()
|
||||
|
||||
@@ -48,7 +48,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
// 3 slots provide 76 DoT.
|
||||
// [...]
|
||||
// 9 slots provide 240 DoT.
|
||||
int sagePoisonDamage = (int)(50 * averageDamageMultiplier);
|
||||
int sagePoisonDamage = (int)(SagePoison.debuffData.EnemyLostRegen * averageDamageMultiplier);
|
||||
target.AddBuff(ModContent.BuffType<SagePoison>(), 300);
|
||||
target.Calamity().sagePoisonDamage = sagePoisonDamage;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user