config.alltsettings.properties
config.java
PcStat.java
(с)
- Код:
# Limit of Attributes
AltMaxAtkElem = 200
AltMaxDefElem = 200
config.java
- Код:
//////ALT_SETTINGS_FILE//////
public static int ALT_MAX_ATK_ELEM;
public static int ALT_MAX_DEF_ELEM;
ALT_MAX_ATK_ELEM = Integer.parseInt(altSettings.getProperty("MaxAtkElem", "500"));
ALT_MAX_DEF_ELEM = Integer.parseInt(altSettings.getProperty("MaxDefElem", "500"));
else if (pName.equalsIgnoreCase("MaxAtkElem"))
ALT_GRADE_PENALTY = Boolean.parseBoolean(pValue);
else if (pName.equalsIgnoreCase("MaxDefElem"))
ALT_GRADE_PENALTY = Boolean.parseBoolean(pValue);
PcStat.java
- Код:
@Override
public int getAttackElementValue(byte attribute)
{
int value = super.getAttackElementValue(attribute);
if (value > Config.ALT_MAX_ATK_ELEM && Config.ALT_MAX_ATK_ELEM > 0 && !getActiveChar().isGM())
return Config.ALT_MAX_ATK_ELEM;
// 20% if summon exist
if (summonShouldHaveAttackElemental(getActiveChar().getPet()))
return value / 5;
return value;
}
@Override
public int getDefenseElementValue(byte attribute)
{
int value = super.getDefenseElementValue(attribute);
if (value > Config.ALT_MAX_DEF_ELEM && Config.ALT_MAX_DEF_ELEM > 0 && !getActiveChar().isGM())
return Config.ALT_MAX_DEF_ELEM;
return value;
}
(с)