Addition of blow skill damage and heal balance configurations.
This commit is contained in:
parent
3cd882c007
commit
cbf630302e
@ -1,8 +1,7 @@
|
|||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Class Balance
|
# Class Balance
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
# Multiply parameters based on player class.
|
||||||
# Multiply attack and defence based on player class.
|
|
||||||
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
||||||
|
|
||||||
PveMagicalSkillDamageMultipliers =
|
PveMagicalSkillDamageMultipliers =
|
||||||
@ -22,3 +21,11 @@ PvpPhysicalAttackDamageMultipliers =
|
|||||||
|
|
||||||
PvePhysicalAttackDefenceMultipliers =
|
PvePhysicalAttackDefenceMultipliers =
|
||||||
PvpPhysicalAttackDefenceMultipliers =
|
PvpPhysicalAttackDefenceMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDamageMultipliers =
|
||||||
|
PvpBlowSkillDamageMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDefenceMultipliers =
|
||||||
|
PvpBlowSkillDefenceMultipliers =
|
||||||
|
|
||||||
|
PlayerHealingSkillMultipliers =
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -109,6 +110,7 @@ public final class Heal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
||||||
{
|
{
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -105,6 +106,7 @@ public final class HpCpHeal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
||||||
{
|
{
|
||||||
|
@ -1119,6 +1119,11 @@ public final class Config
|
|||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PLAYER_HEALING_SKILL_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static boolean MULTILANG_ENABLE;
|
public static boolean MULTILANG_ENABLE;
|
||||||
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
||||||
public static String MULTILANG_DEFAULT;
|
public static String MULTILANG_DEFAULT;
|
||||||
@ -2679,6 +2684,76 @@ public final class Config
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
final String[] pveBlowSkillDamageMultipliers = ClassBalance.getString("PveBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDamageMultipliers = ClassBalance.getString("PvpBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pveBlowSkillDefenceMultipliers = ClassBalance.getString("PveBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDefenceMultipliers = ClassBalance.getString("PvpBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] playerHealingSkillMultipliers = ClassBalance.getString("PlayerHealingSkillMultipliers", "").trim().split(";");
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.clear();
|
||||||
|
if (playerHealingSkillMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : playerHealingSkillMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Load CommunityBoard config file (if exists)
|
// Load CommunityBoard config file (if exists)
|
||||||
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
||||||
|
@ -120,11 +120,21 @@ public final class Formulas
|
|||||||
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
double balanceMod = 1;
|
||||||
|
if (attacker.isPlayable())
|
||||||
|
{
|
||||||
|
balanceMod = target.isPlayable() ? Config.PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
if (target.isPlayable())
|
||||||
|
{
|
||||||
|
defence *= attacker.isPlayable() ? Config.PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
|
||||||
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
||||||
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
||||||
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
||||||
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
||||||
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod;
|
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod * balanceMod;
|
||||||
|
|
||||||
return damage;
|
return damage;
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Class Balance
|
# Class Balance
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
# Multiply parameters based on player class.
|
||||||
# Multiply attack and defence based on player class.
|
|
||||||
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
||||||
|
|
||||||
PveMagicalSkillDamageMultipliers =
|
PveMagicalSkillDamageMultipliers =
|
||||||
@ -22,3 +21,11 @@ PvpPhysicalAttackDamageMultipliers =
|
|||||||
|
|
||||||
PvePhysicalAttackDefenceMultipliers =
|
PvePhysicalAttackDefenceMultipliers =
|
||||||
PvpPhysicalAttackDefenceMultipliers =
|
PvpPhysicalAttackDefenceMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDamageMultipliers =
|
||||||
|
PvpBlowSkillDamageMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDefenceMultipliers =
|
||||||
|
PvpBlowSkillDefenceMultipliers =
|
||||||
|
|
||||||
|
PlayerHealingSkillMultipliers =
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -109,6 +110,7 @@ public final class Heal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
||||||
{
|
{
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -105,6 +106,7 @@ public final class HpCpHeal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
||||||
{
|
{
|
||||||
|
@ -1126,6 +1126,11 @@ public final class Config
|
|||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PLAYER_HEALING_SKILL_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static boolean MULTILANG_ENABLE;
|
public static boolean MULTILANG_ENABLE;
|
||||||
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
||||||
public static String MULTILANG_DEFAULT;
|
public static String MULTILANG_DEFAULT;
|
||||||
@ -2696,6 +2701,76 @@ public final class Config
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
final String[] pveBlowSkillDamageMultipliers = ClassBalance.getString("PveBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDamageMultipliers = ClassBalance.getString("PvpBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pveBlowSkillDefenceMultipliers = ClassBalance.getString("PveBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDefenceMultipliers = ClassBalance.getString("PvpBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] playerHealingSkillMultipliers = ClassBalance.getString("PlayerHealingSkillMultipliers", "").trim().split(";");
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.clear();
|
||||||
|
if (playerHealingSkillMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : playerHealingSkillMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Load CommunityBoard config file (if exists)
|
// Load CommunityBoard config file (if exists)
|
||||||
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
||||||
|
@ -120,11 +120,21 @@ public final class Formulas
|
|||||||
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
double balanceMod = 1;
|
||||||
|
if (attacker.isPlayable())
|
||||||
|
{
|
||||||
|
balanceMod = target.isPlayable() ? Config.PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
if (target.isPlayable())
|
||||||
|
{
|
||||||
|
defence *= attacker.isPlayable() ? Config.PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
|
||||||
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
||||||
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
||||||
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
||||||
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
||||||
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod;
|
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod * balanceMod;
|
||||||
|
|
||||||
return damage;
|
return damage;
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Class Balance
|
# Class Balance
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
# Multiply parameters based on player class.
|
||||||
# Multiply attack and defence based on player class.
|
|
||||||
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
||||||
|
|
||||||
PveMagicalSkillDamageMultipliers =
|
PveMagicalSkillDamageMultipliers =
|
||||||
@ -22,3 +21,11 @@ PvpPhysicalAttackDamageMultipliers =
|
|||||||
|
|
||||||
PvePhysicalAttackDefenceMultipliers =
|
PvePhysicalAttackDefenceMultipliers =
|
||||||
PvpPhysicalAttackDefenceMultipliers =
|
PvpPhysicalAttackDefenceMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDamageMultipliers =
|
||||||
|
PvpBlowSkillDamageMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDefenceMultipliers =
|
||||||
|
PvpBlowSkillDefenceMultipliers =
|
||||||
|
|
||||||
|
PlayerHealingSkillMultipliers =
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -109,6 +110,7 @@ public final class Heal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
||||||
{
|
{
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -105,6 +106,7 @@ public final class HpCpHeal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
||||||
{
|
{
|
||||||
|
@ -1134,6 +1134,11 @@ public final class Config
|
|||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PLAYER_HEALING_SKILL_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static boolean MULTILANG_ENABLE;
|
public static boolean MULTILANG_ENABLE;
|
||||||
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
||||||
public static String MULTILANG_DEFAULT;
|
public static String MULTILANG_DEFAULT;
|
||||||
@ -2711,6 +2716,76 @@ public final class Config
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
final String[] pveBlowSkillDamageMultipliers = ClassBalance.getString("PveBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDamageMultipliers = ClassBalance.getString("PvpBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pveBlowSkillDefenceMultipliers = ClassBalance.getString("PveBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDefenceMultipliers = ClassBalance.getString("PvpBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] playerHealingSkillMultipliers = ClassBalance.getString("PlayerHealingSkillMultipliers", "").trim().split(";");
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.clear();
|
||||||
|
if (playerHealingSkillMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : playerHealingSkillMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Load CommunityBoard config file (if exists)
|
// Load CommunityBoard config file (if exists)
|
||||||
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
||||||
|
@ -120,11 +120,21 @@ public final class Formulas
|
|||||||
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
double balanceMod = 1;
|
||||||
|
if (attacker.isPlayable())
|
||||||
|
{
|
||||||
|
balanceMod = target.isPlayable() ? Config.PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
if (target.isPlayable())
|
||||||
|
{
|
||||||
|
defence *= attacker.isPlayable() ? Config.PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
|
||||||
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
||||||
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
||||||
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
||||||
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
||||||
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod;
|
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod * balanceMod;
|
||||||
|
|
||||||
return damage;
|
return damage;
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Class Balance
|
# Class Balance
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
# Multiply parameters based on player class.
|
||||||
# Multiply attack and defence based on player class.
|
|
||||||
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
||||||
|
|
||||||
PveMagicalSkillDamageMultipliers =
|
PveMagicalSkillDamageMultipliers =
|
||||||
@ -22,3 +21,11 @@ PvpPhysicalAttackDamageMultipliers =
|
|||||||
|
|
||||||
PvePhysicalAttackDefenceMultipliers =
|
PvePhysicalAttackDefenceMultipliers =
|
||||||
PvpPhysicalAttackDefenceMultipliers =
|
PvpPhysicalAttackDefenceMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDamageMultipliers =
|
||||||
|
PvpBlowSkillDamageMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDefenceMultipliers =
|
||||||
|
PvpBlowSkillDefenceMultipliers =
|
||||||
|
|
||||||
|
PlayerHealingSkillMultipliers =
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -109,6 +110,7 @@ public final class Heal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
||||||
{
|
{
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -105,6 +106,7 @@ public final class HpCpHeal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
||||||
{
|
{
|
||||||
|
@ -1121,6 +1121,11 @@ public final class Config
|
|||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PLAYER_HEALING_SKILL_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static boolean MULTILANG_ENABLE;
|
public static boolean MULTILANG_ENABLE;
|
||||||
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
||||||
public static String MULTILANG_DEFAULT;
|
public static String MULTILANG_DEFAULT;
|
||||||
@ -2685,6 +2690,76 @@ public final class Config
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
final String[] pveBlowSkillDamageMultipliers = ClassBalance.getString("PveBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDamageMultipliers = ClassBalance.getString("PvpBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pveBlowSkillDefenceMultipliers = ClassBalance.getString("PveBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDefenceMultipliers = ClassBalance.getString("PvpBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] playerHealingSkillMultipliers = ClassBalance.getString("PlayerHealingSkillMultipliers", "").trim().split(";");
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.clear();
|
||||||
|
if (playerHealingSkillMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : playerHealingSkillMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Load CommunityBoard config file (if exists)
|
// Load CommunityBoard config file (if exists)
|
||||||
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
||||||
|
@ -120,11 +120,21 @@ public final class Formulas
|
|||||||
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
double balanceMod = 1;
|
||||||
|
if (attacker.isPlayable())
|
||||||
|
{
|
||||||
|
balanceMod = target.isPlayable() ? Config.PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
if (target.isPlayable())
|
||||||
|
{
|
||||||
|
defence *= attacker.isPlayable() ? Config.PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
|
||||||
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
||||||
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
||||||
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
||||||
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
||||||
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod;
|
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod * balanceMod;
|
||||||
|
|
||||||
return damage;
|
return damage;
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Class Balance
|
# Class Balance
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
# Multiply parameters based on player class.
|
||||||
# Multiply attack and defence based on player class.
|
|
||||||
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
||||||
|
|
||||||
PveMagicalSkillDamageMultipliers =
|
PveMagicalSkillDamageMultipliers =
|
||||||
@ -22,3 +21,11 @@ PvpPhysicalAttackDamageMultipliers =
|
|||||||
|
|
||||||
PvePhysicalAttackDefenceMultipliers =
|
PvePhysicalAttackDefenceMultipliers =
|
||||||
PvpPhysicalAttackDefenceMultipliers =
|
PvpPhysicalAttackDefenceMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDamageMultipliers =
|
||||||
|
PvpBlowSkillDamageMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDefenceMultipliers =
|
||||||
|
PvpBlowSkillDefenceMultipliers =
|
||||||
|
|
||||||
|
PlayerHealingSkillMultipliers =
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -109,6 +110,7 @@ public final class Heal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
||||||
{
|
{
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -105,6 +106,7 @@ public final class HpCpHeal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
||||||
{
|
{
|
||||||
|
@ -1117,6 +1117,11 @@ public final class Config
|
|||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PLAYER_HEALING_SKILL_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static boolean MULTILANG_ENABLE;
|
public static boolean MULTILANG_ENABLE;
|
||||||
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
||||||
public static String MULTILANG_DEFAULT;
|
public static String MULTILANG_DEFAULT;
|
||||||
@ -2761,6 +2766,76 @@ public final class Config
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
final String[] pveBlowSkillDamageMultipliers = ClassBalance.getString("PveBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDamageMultipliers = ClassBalance.getString("PvpBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pveBlowSkillDefenceMultipliers = ClassBalance.getString("PveBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDefenceMultipliers = ClassBalance.getString("PvpBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] playerHealingSkillMultipliers = ClassBalance.getString("PlayerHealingSkillMultipliers", "").trim().split(";");
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.clear();
|
||||||
|
if (playerHealingSkillMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : playerHealingSkillMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Load CommunityBoard config file (if exists)
|
// Load CommunityBoard config file (if exists)
|
||||||
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
||||||
|
@ -120,11 +120,21 @@ public final class Formulas
|
|||||||
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
double balanceMod = 1;
|
||||||
|
if (attacker.isPlayable())
|
||||||
|
{
|
||||||
|
balanceMod = target.isPlayable() ? Config.PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
if (target.isPlayable())
|
||||||
|
{
|
||||||
|
defence *= attacker.isPlayable() ? Config.PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
|
||||||
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
||||||
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
||||||
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
||||||
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
||||||
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod;
|
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod * balanceMod;
|
||||||
|
|
||||||
return damage;
|
return damage;
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Class Balance
|
# Class Balance
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
# Multiply parameters based on player class.
|
||||||
# Multiply attack and defence based on player class.
|
|
||||||
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
||||||
|
|
||||||
PveMagicalSkillDamageMultipliers =
|
PveMagicalSkillDamageMultipliers =
|
||||||
@ -22,3 +21,11 @@ PvpPhysicalAttackDamageMultipliers =
|
|||||||
|
|
||||||
PvePhysicalAttackDefenceMultipliers =
|
PvePhysicalAttackDefenceMultipliers =
|
||||||
PvpPhysicalAttackDefenceMultipliers =
|
PvpPhysicalAttackDefenceMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDamageMultipliers =
|
||||||
|
PvpBlowSkillDamageMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDefenceMultipliers =
|
||||||
|
PvpBlowSkillDefenceMultipliers =
|
||||||
|
|
||||||
|
PlayerHealingSkillMultipliers =
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -109,6 +110,7 @@ public final class Heal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
||||||
{
|
{
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -105,6 +106,7 @@ public final class HpCpHeal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
||||||
{
|
{
|
||||||
|
@ -1117,6 +1117,11 @@ public final class Config
|
|||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PLAYER_HEALING_SKILL_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static boolean MULTILANG_ENABLE;
|
public static boolean MULTILANG_ENABLE;
|
||||||
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
||||||
public static String MULTILANG_DEFAULT;
|
public static String MULTILANG_DEFAULT;
|
||||||
@ -2761,6 +2766,76 @@ public final class Config
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
final String[] pveBlowSkillDamageMultipliers = ClassBalance.getString("PveBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDamageMultipliers = ClassBalance.getString("PvpBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pveBlowSkillDefenceMultipliers = ClassBalance.getString("PveBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDefenceMultipliers = ClassBalance.getString("PvpBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] playerHealingSkillMultipliers = ClassBalance.getString("PlayerHealingSkillMultipliers", "").trim().split(";");
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.clear();
|
||||||
|
if (playerHealingSkillMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : playerHealingSkillMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Load CommunityBoard config file (if exists)
|
// Load CommunityBoard config file (if exists)
|
||||||
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
||||||
|
@ -120,11 +120,21 @@ public final class Formulas
|
|||||||
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
double balanceMod = 1;
|
||||||
|
if (attacker.isPlayable())
|
||||||
|
{
|
||||||
|
balanceMod = target.isPlayable() ? Config.PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
if (target.isPlayable())
|
||||||
|
{
|
||||||
|
defence *= attacker.isPlayable() ? Config.PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
|
||||||
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
||||||
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
||||||
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
||||||
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
||||||
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod;
|
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod * balanceMod;
|
||||||
|
|
||||||
return damage;
|
return damage;
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Class Balance
|
# Class Balance
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
# Multiply parameters based on player class.
|
||||||
# Multiply attack and defence based on player class.
|
|
||||||
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
||||||
|
|
||||||
PveMagicalSkillDamageMultipliers =
|
PveMagicalSkillDamageMultipliers =
|
||||||
@ -22,3 +21,11 @@ PvpPhysicalAttackDamageMultipliers =
|
|||||||
|
|
||||||
PvePhysicalAttackDefenceMultipliers =
|
PvePhysicalAttackDefenceMultipliers =
|
||||||
PvpPhysicalAttackDefenceMultipliers =
|
PvpPhysicalAttackDefenceMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDamageMultipliers =
|
||||||
|
PvpBlowSkillDamageMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDefenceMultipliers =
|
||||||
|
PvpBlowSkillDefenceMultipliers =
|
||||||
|
|
||||||
|
PlayerHealingSkillMultipliers =
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -109,6 +110,7 @@ public final class Heal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
||||||
{
|
{
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -105,6 +106,7 @@ public final class HpCpHeal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
||||||
{
|
{
|
||||||
|
@ -1134,6 +1134,11 @@ public final class Config
|
|||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PLAYER_HEALING_SKILL_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static boolean MULTILANG_ENABLE;
|
public static boolean MULTILANG_ENABLE;
|
||||||
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
||||||
public static String MULTILANG_DEFAULT;
|
public static String MULTILANG_DEFAULT;
|
||||||
@ -2796,6 +2801,76 @@ public final class Config
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
final String[] pveBlowSkillDamageMultipliers = ClassBalance.getString("PveBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDamageMultipliers = ClassBalance.getString("PvpBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pveBlowSkillDefenceMultipliers = ClassBalance.getString("PveBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDefenceMultipliers = ClassBalance.getString("PvpBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] playerHealingSkillMultipliers = ClassBalance.getString("PlayerHealingSkillMultipliers", "").trim().split(";");
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.clear();
|
||||||
|
if (playerHealingSkillMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : playerHealingSkillMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Load CommunityBoard config file (if exists)
|
// Load CommunityBoard config file (if exists)
|
||||||
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
||||||
|
@ -120,11 +120,21 @@ public final class Formulas
|
|||||||
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
double balanceMod = 1;
|
||||||
|
if (attacker.isPlayable())
|
||||||
|
{
|
||||||
|
balanceMod = target.isPlayable() ? Config.PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
if (target.isPlayable())
|
||||||
|
{
|
||||||
|
defence *= attacker.isPlayable() ? Config.PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
|
||||||
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
||||||
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
||||||
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
||||||
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
||||||
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod;
|
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod * balanceMod;
|
||||||
|
|
||||||
return damage;
|
return damage;
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Class Balance
|
# Class Balance
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
# Multiply parameters based on player class.
|
||||||
# Multiply attack and defence based on player class.
|
|
||||||
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
||||||
|
|
||||||
PveMagicalSkillDamageMultipliers =
|
PveMagicalSkillDamageMultipliers =
|
||||||
@ -22,3 +21,11 @@ PvpPhysicalAttackDamageMultipliers =
|
|||||||
|
|
||||||
PvePhysicalAttackDefenceMultipliers =
|
PvePhysicalAttackDefenceMultipliers =
|
||||||
PvpPhysicalAttackDefenceMultipliers =
|
PvpPhysicalAttackDefenceMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDamageMultipliers =
|
||||||
|
PvpBlowSkillDamageMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDefenceMultipliers =
|
||||||
|
PvpBlowSkillDefenceMultipliers =
|
||||||
|
|
||||||
|
PlayerHealingSkillMultipliers =
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -109,6 +110,7 @@ public final class Heal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
||||||
{
|
{
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -105,6 +106,7 @@ public final class HpCpHeal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
||||||
{
|
{
|
||||||
|
@ -1063,6 +1063,11 @@ public final class Config
|
|||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PLAYER_HEALING_SKILL_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static boolean MULTILANG_ENABLE;
|
public static boolean MULTILANG_ENABLE;
|
||||||
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
||||||
public static String MULTILANG_DEFAULT;
|
public static String MULTILANG_DEFAULT;
|
||||||
@ -2558,6 +2563,76 @@ public final class Config
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
final String[] pveBlowSkillDamageMultipliers = ClassBalance.getString("PveBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDamageMultipliers = ClassBalance.getString("PvpBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pveBlowSkillDefenceMultipliers = ClassBalance.getString("PveBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDefenceMultipliers = ClassBalance.getString("PvpBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] playerHealingSkillMultipliers = ClassBalance.getString("PlayerHealingSkillMultipliers", "").trim().split(";");
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.clear();
|
||||||
|
if (playerHealingSkillMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : playerHealingSkillMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Load CommunityBoard config file (if exists)
|
// Load CommunityBoard config file (if exists)
|
||||||
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
||||||
|
@ -120,11 +120,21 @@ public final class Formulas
|
|||||||
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
double balanceMod = 1;
|
||||||
|
if (attacker.isPlayable())
|
||||||
|
{
|
||||||
|
balanceMod = target.isPlayable() ? Config.PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
if (target.isPlayable())
|
||||||
|
{
|
||||||
|
defence *= attacker.isPlayable() ? Config.PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
|
||||||
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
||||||
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
||||||
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
||||||
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
||||||
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod;
|
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod * balanceMod;
|
||||||
|
|
||||||
return damage;
|
return damage;
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Class Balance
|
# Class Balance
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
# Multiply parameters based on player class.
|
||||||
# Multiply attack and defence based on player class.
|
|
||||||
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
||||||
|
|
||||||
PveMagicalSkillDamageMultipliers =
|
PveMagicalSkillDamageMultipliers =
|
||||||
@ -22,3 +21,11 @@ PvpPhysicalAttackDamageMultipliers =
|
|||||||
|
|
||||||
PvePhysicalAttackDefenceMultipliers =
|
PvePhysicalAttackDefenceMultipliers =
|
||||||
PvpPhysicalAttackDefenceMultipliers =
|
PvpPhysicalAttackDefenceMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDamageMultipliers =
|
||||||
|
PvpBlowSkillDamageMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDefenceMultipliers =
|
||||||
|
PvpBlowSkillDefenceMultipliers =
|
||||||
|
|
||||||
|
PlayerHealingSkillMultipliers =
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -109,6 +110,7 @@ public final class Heal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
||||||
{
|
{
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -105,6 +106,7 @@ public final class HpCpHeal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
||||||
{
|
{
|
||||||
|
@ -1067,6 +1067,11 @@ public final class Config
|
|||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PLAYER_HEALING_SKILL_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static boolean MULTILANG_ENABLE;
|
public static boolean MULTILANG_ENABLE;
|
||||||
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
||||||
public static String MULTILANG_DEFAULT;
|
public static String MULTILANG_DEFAULT;
|
||||||
@ -2565,6 +2570,76 @@ public final class Config
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
final String[] pveBlowSkillDamageMultipliers = ClassBalance.getString("PveBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDamageMultipliers = ClassBalance.getString("PvpBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pveBlowSkillDefenceMultipliers = ClassBalance.getString("PveBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDefenceMultipliers = ClassBalance.getString("PvpBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] playerHealingSkillMultipliers = ClassBalance.getString("PlayerHealingSkillMultipliers", "").trim().split(";");
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.clear();
|
||||||
|
if (playerHealingSkillMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : playerHealingSkillMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Load CommunityBoard config file (if exists)
|
// Load CommunityBoard config file (if exists)
|
||||||
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
||||||
|
@ -120,11 +120,21 @@ public final class Formulas
|
|||||||
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
double balanceMod = 1;
|
||||||
|
if (attacker.isPlayable())
|
||||||
|
{
|
||||||
|
balanceMod = target.isPlayable() ? Config.PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
if (target.isPlayable())
|
||||||
|
{
|
||||||
|
defence *= attacker.isPlayable() ? Config.PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
|
||||||
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
||||||
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
||||||
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
||||||
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
||||||
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod;
|
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod * balanceMod;
|
||||||
|
|
||||||
return damage;
|
return damage;
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Class Balance
|
# Class Balance
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
# Multiply parameters based on player class.
|
||||||
# Multiply attack and defence based on player class.
|
|
||||||
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
||||||
|
|
||||||
PveMagicalSkillDamageMultipliers =
|
PveMagicalSkillDamageMultipliers =
|
||||||
@ -22,3 +21,11 @@ PvpPhysicalAttackDamageMultipliers =
|
|||||||
|
|
||||||
PvePhysicalAttackDefenceMultipliers =
|
PvePhysicalAttackDefenceMultipliers =
|
||||||
PvpPhysicalAttackDefenceMultipliers =
|
PvpPhysicalAttackDefenceMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDamageMultipliers =
|
||||||
|
PvpBlowSkillDamageMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDefenceMultipliers =
|
||||||
|
PvpBlowSkillDefenceMultipliers =
|
||||||
|
|
||||||
|
PlayerHealingSkillMultipliers =
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -109,6 +110,7 @@ public final class Heal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
||||||
{
|
{
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -105,6 +106,7 @@ public final class HpCpHeal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
||||||
{
|
{
|
||||||
|
@ -1067,6 +1067,11 @@ public final class Config
|
|||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PLAYER_HEALING_SKILL_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static boolean MULTILANG_ENABLE;
|
public static boolean MULTILANG_ENABLE;
|
||||||
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
||||||
public static String MULTILANG_DEFAULT;
|
public static String MULTILANG_DEFAULT;
|
||||||
@ -2565,6 +2570,76 @@ public final class Config
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
final String[] pveBlowSkillDamageMultipliers = ClassBalance.getString("PveBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDamageMultipliers = ClassBalance.getString("PvpBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pveBlowSkillDefenceMultipliers = ClassBalance.getString("PveBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDefenceMultipliers = ClassBalance.getString("PvpBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] playerHealingSkillMultipliers = ClassBalance.getString("PlayerHealingSkillMultipliers", "").trim().split(";");
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.clear();
|
||||||
|
if (playerHealingSkillMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : playerHealingSkillMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Load CommunityBoard config file (if exists)
|
// Load CommunityBoard config file (if exists)
|
||||||
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
||||||
|
@ -120,11 +120,21 @@ public final class Formulas
|
|||||||
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
double balanceMod = 1;
|
||||||
|
if (attacker.isPlayable())
|
||||||
|
{
|
||||||
|
balanceMod = target.isPlayable() ? Config.PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
if (target.isPlayable())
|
||||||
|
{
|
||||||
|
defence *= attacker.isPlayable() ? Config.PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
|
||||||
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
||||||
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
||||||
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
||||||
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
||||||
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod;
|
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod * balanceMod;
|
||||||
|
|
||||||
return damage;
|
return damage;
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Class Balance
|
# Class Balance
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
# Multiply parameters based on player class.
|
||||||
# Multiply attack and defence based on player class.
|
|
||||||
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
||||||
|
|
||||||
PveMagicalSkillDamageMultipliers =
|
PveMagicalSkillDamageMultipliers =
|
||||||
@ -22,3 +21,11 @@ PvpPhysicalAttackDamageMultipliers =
|
|||||||
|
|
||||||
PvePhysicalAttackDefenceMultipliers =
|
PvePhysicalAttackDefenceMultipliers =
|
||||||
PvpPhysicalAttackDefenceMultipliers =
|
PvpPhysicalAttackDefenceMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDamageMultipliers =
|
||||||
|
PvpBlowSkillDamageMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDefenceMultipliers =
|
||||||
|
PvpBlowSkillDefenceMultipliers =
|
||||||
|
|
||||||
|
PlayerHealingSkillMultipliers =
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -109,6 +110,7 @@ public final class Heal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
||||||
{
|
{
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -105,6 +106,7 @@ public final class HpCpHeal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
||||||
{
|
{
|
||||||
|
@ -1067,6 +1067,11 @@ public final class Config
|
|||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PLAYER_HEALING_SKILL_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static boolean MULTILANG_ENABLE;
|
public static boolean MULTILANG_ENABLE;
|
||||||
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
||||||
public static String MULTILANG_DEFAULT;
|
public static String MULTILANG_DEFAULT;
|
||||||
@ -2565,6 +2570,76 @@ public final class Config
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
final String[] pveBlowSkillDamageMultipliers = ClassBalance.getString("PveBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDamageMultipliers = ClassBalance.getString("PvpBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pveBlowSkillDefenceMultipliers = ClassBalance.getString("PveBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDefenceMultipliers = ClassBalance.getString("PvpBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] playerHealingSkillMultipliers = ClassBalance.getString("PlayerHealingSkillMultipliers", "").trim().split(";");
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.clear();
|
||||||
|
if (playerHealingSkillMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : playerHealingSkillMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Load CommunityBoard config file (if exists)
|
// Load CommunityBoard config file (if exists)
|
||||||
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
||||||
|
@ -120,11 +120,21 @@ public final class Formulas
|
|||||||
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
double balanceMod = 1;
|
||||||
|
if (attacker.isPlayable())
|
||||||
|
{
|
||||||
|
balanceMod = target.isPlayable() ? Config.PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
if (target.isPlayable())
|
||||||
|
{
|
||||||
|
defence *= attacker.isPlayable() ? Config.PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
|
||||||
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
||||||
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
||||||
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
||||||
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
||||||
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod;
|
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod * balanceMod;
|
||||||
|
|
||||||
return damage;
|
return damage;
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Class Balance
|
# Class Balance
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
# Multiply parameters based on player class.
|
||||||
# Multiply attack and defence based on player class.
|
|
||||||
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
# Example: ClassId1,Multiplier1;ClassId2,Multiplier2;...
|
||||||
|
|
||||||
PveMagicalSkillDamageMultipliers =
|
PveMagicalSkillDamageMultipliers =
|
||||||
@ -22,3 +21,11 @@ PvpPhysicalAttackDamageMultipliers =
|
|||||||
|
|
||||||
PvePhysicalAttackDefenceMultipliers =
|
PvePhysicalAttackDefenceMultipliers =
|
||||||
PvpPhysicalAttackDefenceMultipliers =
|
PvpPhysicalAttackDefenceMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDamageMultipliers =
|
||||||
|
PvpBlowSkillDamageMultipliers =
|
||||||
|
|
||||||
|
PveBlowSkillDefenceMultipliers =
|
||||||
|
PvpBlowSkillDefenceMultipliers =
|
||||||
|
|
||||||
|
PlayerHealingSkillMultipliers =
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -109,6 +110,7 @@ public final class Heal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
if (skill.isMagic() && Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill))
|
||||||
{
|
{
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.effecthandlers;
|
package handlers.effecthandlers;
|
||||||
|
|
||||||
|
import org.l2jmobius.Config;
|
||||||
import org.l2jmobius.gameserver.enums.ShotType;
|
import org.l2jmobius.gameserver.enums.ShotType;
|
||||||
import org.l2jmobius.gameserver.model.StatsSet;
|
import org.l2jmobius.gameserver.model.StatsSet;
|
||||||
import org.l2jmobius.gameserver.model.actor.Creature;
|
import org.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@ -105,6 +106,7 @@ public final class HpCpHeal extends AbstractEffect
|
|||||||
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
amount += staticShotBonus + Math.sqrt(mAtkMul * effector.getMAtk());
|
||||||
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
amount *= effected.getStat().getValue(Stats.HEAL_EFFECT, 1);
|
||||||
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
amount += effected.getStat().getValue(Stats.HEAL_EFFECT_ADD, 0);
|
||||||
|
amount *= (item == null) && effector.isPlayable() ? Config.PLAYER_HEALING_SKILL_MULTIPLIERS.getOrDefault(effector.getActingPlayer().getClassId(), 1f) : 1;
|
||||||
// Heal critic, since CT2.3 Gracia Final
|
// Heal critic, since CT2.3 Gracia Final
|
||||||
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
if (skill.isMagic() && (Formulas.calcCrit(skill.getMagicCriticalRate(), effector, effected, skill) || effector.isAffected(EffectFlag.HPCPHEAL_CRITICAL)))
|
||||||
{
|
{
|
||||||
|
@ -1067,6 +1067,11 @@ public final class Config
|
|||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVE_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
public static Map<ClassId, Float> PVP_PHYSICAL_ATTACK_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
|
public static Map<ClassId, Float> PLAYER_HEALING_SKILL_MULTIPLIERS = new ConcurrentHashMap<>();
|
||||||
public static boolean MULTILANG_ENABLE;
|
public static boolean MULTILANG_ENABLE;
|
||||||
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
public static List<String> MULTILANG_ALLOWED = new ArrayList<>();
|
||||||
public static String MULTILANG_DEFAULT;
|
public static String MULTILANG_DEFAULT;
|
||||||
@ -2565,6 +2570,76 @@ public final class Config
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
final String[] pveBlowSkillDamageMultipliers = ClassBalance.getString("PveBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDamageMultipliers = ClassBalance.getString("PvpBlowSkillDamageMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDamageMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDamageMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pveBlowSkillDefenceMultipliers = ClassBalance.getString("PveBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pveBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pveBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] pvpBlowSkillDefenceMultipliers = ClassBalance.getString("PvpBlowSkillDefenceMultipliers", "").trim().split(";");
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.clear();
|
||||||
|
if (pvpBlowSkillDefenceMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : pvpBlowSkillDefenceMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
final String[] playerHealingSkillMultipliers = ClassBalance.getString("PlayerHealingSkillMultipliers", "").trim().split(";");
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.clear();
|
||||||
|
if (playerHealingSkillMultipliers.length > 0)
|
||||||
|
{
|
||||||
|
for (String info : playerHealingSkillMultipliers)
|
||||||
|
{
|
||||||
|
final String[] classInfo = info.trim().split(",");
|
||||||
|
if (classInfo.length == 2)
|
||||||
|
{
|
||||||
|
final String id = classInfo[0].trim();
|
||||||
|
PLAYER_HEALING_SKILL_MULTIPLIERS.put(Util.isDigit(id) ? ClassId.getClassId(Integer.parseInt(id)) : Enum.valueOf(ClassId.class, id), Float.parseFloat(classInfo[1].trim()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Load CommunityBoard config file (if exists)
|
// Load CommunityBoard config file (if exists)
|
||||||
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
final PropertiesParser CommunityBoard = new PropertiesParser(CUSTOM_COMMUNITY_BOARD_CONFIG_FILE);
|
||||||
|
@ -120,11 +120,21 @@ public final class Formulas
|
|||||||
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
// power *= 1 - (Math.min(target.getLevel() - attacker.getLevel(), 9) / 10);
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
double balanceMod = 1;
|
||||||
|
if (attacker.isPlayable())
|
||||||
|
{
|
||||||
|
balanceMod = target.isPlayable() ? Config.PVP_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DAMAGE_MULTIPLIERS.getOrDefault(attacker.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
if (target.isPlayable())
|
||||||
|
{
|
||||||
|
defence *= attacker.isPlayable() ? Config.PVP_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f) : Config.PVE_BLOW_SKILL_DEFENCE_MULTIPLIERS.getOrDefault(target.getActingPlayer().getClassId(), 1f);
|
||||||
|
}
|
||||||
|
|
||||||
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
// ........................_____________________________Initial Damage____________________________...___________Position Additional Damage___________..._CriticalAdd_
|
||||||
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
// ATTACK CALCULATION 77 * [(skillpower+patk) * 0.666 * cdbonus * cdPosBonusHalf * cdVulnHalf * ss + isBack0.2Side0.05 * (skillpower+patk*ss) * random + 6 * cd_patk] / pdef
|
||||||
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
// ````````````````````````^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^```^^^^^^^^^^^^
|
||||||
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
final double baseMod = (77 * (((power + attacker.getPAtk()) * 0.666) + (isPosition * (power + attacker.getPAtk()) * randomMod) + (6 * cdPatk))) / defence;
|
||||||
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod;
|
final double damage = baseMod * ssmod * cdMult * weaponTraitMod * generalTraitMod * weaknessMod * attributeMod * randomMod * pvpPveMod * balanceMod;
|
||||||
|
|
||||||
return damage;
|
return damage;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user