Procházet zdrojové kódy

DP Side for [L4915].

Nik před 13 roky
rodič
revize
d130c0286b

+ 3 - 3
L2J_DataPack_BETA/data/scripts/handlers/skillhandlers/Blow.java

@@ -102,8 +102,8 @@ public class Blow implements ISkillHandler
 				boolean soul = (weapon != null && weapon.getChargedSoulshot() == L2ItemInstance.CHARGED_SOULSHOT && (weapon.getItemType() == L2WeaponType.DAGGER || weapon.getItemType() == L2WeaponType.DUALDAGGER || weapon.getItemType() == L2WeaponType.RAPIER));
 				byte shld = Formulas.calcShldUse(activeChar, target, skill);
 				
-				double damage = (int) Formulas.calcBlowDamage(activeChar, target, skill, shld, soul);
-				if (skill.getMaxSoulConsumeCount() > 0 && activeChar instanceof L2PcInstance)
+				double damage = skill.isStaticDamage() ? skill.getPower() : (int) Formulas.calcBlowDamage(activeChar, target, skill, shld, soul);
+				if (!skill.isStaticDamage() && skill.getMaxSoulConsumeCount() > 0 && activeChar instanceof L2PcInstance)
 				{
 					switch (((L2PcInstance) activeChar).getSouls())
 					{
@@ -128,7 +128,7 @@ public class Blow implements ISkillHandler
 				}
 				
 				// Crit rate base crit rate for skill, modified with STR bonus
-				if (Formulas.calcCrit(skill.getBaseCritRate() * 10 * BaseStats.STR.calcBonus(activeChar), true, target))
+				if (!skill.isStaticDamage() && Formulas.calcCrit(skill.getBaseCritRate() * 10 * BaseStats.STR.calcBonus(activeChar), true, target))
 					damage *= 2;
 				
 				if (soul)

+ 2 - 2
L2J_DataPack_BETA/data/scripts/handlers/skillhandlers/Manadam.java

@@ -111,9 +111,9 @@ public class Manadam implements ISkillHandler
 					}
 				}
 				
-				double damage = Formulas.calcManaDam(activeChar, target, skill, ss, bss);
+				double damage = skill.isStaticDamage() ? skill.getPower() : Formulas.calcManaDam(activeChar, target, skill, ss, bss);
 				
-				if (Formulas.calcMCrit(activeChar.getMCriticalHit(target, skill)))
+				if (!skill.isStaticDamage() && Formulas.calcMCrit(activeChar.getMCriticalHit(target, skill)))
 				{
 					damage *= 3.;
 					activeChar.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.CRITICAL_HIT_MAGIC));

+ 3 - 3
L2J_DataPack_BETA/data/scripts/handlers/skillhandlers/Mdam.java

@@ -110,12 +110,12 @@ public class Mdam implements ISkillHandler
 			final byte shld = Formulas.calcShldUse(activeChar, target, skill);
 			final byte reflect = Formulas.calcSkillReflect(target, skill);
 			
-			int damage = (int) Formulas.calcMagicDam(activeChar, target, skill, shld, ss, bss, mcrit);
+			int damage = skill.isStaticDamage() ? (int)skill.getPower() : (int) Formulas.calcMagicDam(activeChar, target, skill, shld, ss, bss, mcrit);
 			
-			if (skill.getDependOnTargetBuff() != 0)
+			if (!skill.isStaticDamage() && skill.getDependOnTargetBuff() != 0)
 				damage += (int) (damage * target.getBuffCount() * skill.getDependOnTargetBuff());
 			
-			if (skill.getMaxSoulConsumeCount() > 0 && activeChar instanceof L2PcInstance)
+			if (!skill.isStaticDamage() && skill.getMaxSoulConsumeCount() > 0 && activeChar instanceof L2PcInstance)
 			{
 				switch (((L2PcInstance) activeChar).getSouls())
 				{

+ 3 - 3
L2J_DataPack_BETA/data/scripts/handlers/skillhandlers/Pdam.java

@@ -98,15 +98,15 @@ public class Pdam implements ISkillHandler
 			final byte shld = Formulas.calcShldUse(activeChar, target, skill);
 			// PDAM critical chance not affected by buffs, only by STR. Only some skills are meant to crit.
 			boolean crit = false;
-			if (skill.getBaseCritRate() > 0)
+			if (!skill.isStaticDamage() && skill.getBaseCritRate() > 0)
 				crit = Formulas.calcCrit(skill.getBaseCritRate() * 10 * BaseStats.STR.calcBonus(activeChar), true, target);
 			
 			
 			if (!crit && (skill.getCondition() & L2Skill.COND_CRIT) != 0)
 				damage = 0;
 			else
-				damage = (int) Formulas.calcPhysDam(activeChar, target, skill, shld, false, dual, soul);
-			if (skill.getMaxSoulConsumeCount() > 0 && activeChar instanceof L2PcInstance)
+				damage = skill.isStaticDamage() ? (int)skill.getPower() : (int) Formulas.calcPhysDam(activeChar, target, skill, shld, false, dual, soul);
+			if (!skill.isStaticDamage() && skill.getMaxSoulConsumeCount() > 0 && activeChar instanceof L2PcInstance)
 			{
 				switch (((L2PcInstance) activeChar).getSouls())
 				{

+ 1 - 1
L2J_DataPack_BETA/data/scripts/handlers/skillhandlers/StrSiegeAssault.java

@@ -97,7 +97,7 @@ public class StrSiegeAssault implements ISkillHandler
 				if (!crit && (skill.getCondition() & L2Skill.COND_CRIT) != 0)
 					damage = 0;
 				else
-					damage = (int) Formulas.calcPhysDam(activeChar, target, skill, shld, crit, dual, soul);
+					damage = skill.isStaticDamage() ? (int)skill.getPower() : (int) Formulas.calcPhysDam(activeChar, target, skill, shld, crit, dual, soul);
 				
 				if (damage > 0)
 				{