mirror of
https://github.com/OMGeeky/andors-trail.git
synced 2026-01-17 09:07:49 +01:00
Change "weapon proficiency"-skills to adding %ac,%bc,%cs instead of fixed values
* Also, lower "weapon and shield" and "2hand style" slightly.
This commit is contained in:
@@ -602,11 +602,11 @@
|
||||
<string name="skill_shortdescription_specialization_2hand">Expert at two-handed weapons</string>
|
||||
<string name="skill_shortdescription_specialization_weapon_shield">Expert at fighting with weapon and shield</string>
|
||||
|
||||
<string name="skill_longdescription_weapon_prof_dagger">Increases attack chance of daggers and shortswords by %1$d for each level.</string>
|
||||
<string name="skill_longdescription_weapon_prof_1hsword">Increases attack chance of longswords and broadswords by %1$d for each level.</string>
|
||||
<string name="skill_longdescription_weapon_prof_2hsword">Increases attack chance of two-handed swords by %1$d for each level.</string>
|
||||
<string name="skill_longdescription_weapon_prof_axe">Increases attack chance of axes and greataxes by %1$d for each level.</string>
|
||||
<string name="skill_longdescription_weapon_prof_blunt">Increases attack chance of bludgeoning weapons by %1$d for each level. This includes clubs, quarterstaves, maces, scepters, warhammers and giant hammers.</string>
|
||||
<string name="skill_longdescription_weapon_prof_dagger">For each skill level, increases attack chance when using daggers and shortswords by %1$d %% of the item\'s base attack chance, increases block chance by %2$d %% of the item\'s base block chance, and increases critical skill by %3$d %% of the item\'s base critical skill.</string>
|
||||
<string name="skill_longdescription_weapon_prof_1hsword">For each skill level, increases attack chance of longswords and broadswords by %1$d %% of the item\'s base attack chance, increases block chance by %2$d %% of the item\'s base block chance, and increases critical skill by %3$d %% of the item\'s base critical skill.</string>
|
||||
<string name="skill_longdescription_weapon_prof_2hsword">For each skill level, increases attack chance of two-handed swords by %1$d %% of the item\'s base attack chance, increases block chance by %2$d %% of the item\'s base block chance, and increases critical skill by %3$d %% of the item\'s base critical skill.</string>
|
||||
<string name="skill_longdescription_weapon_prof_axe">For each skill level, increases attack chance of axes and greataxes by %1$d %% of the item\'s base attack chance, increases block chance by %2$d %% of the item\'s base block chance, and increases critical skill by %3$d %% of the item\'s base critical skill.</string>
|
||||
<string name="skill_longdescription_weapon_prof_blunt">For each skill level, increases attack chance of bludgeoning weapons by %1$d %% of the item\'s base attack chance, increases block chance by %2$d %% of the item\'s base block chance, and increases critical skill by %3$d %% of the item\'s base critical skill. This includes clubs, quarterstaves, maces, scepters, warhammers and giant hammers.</string>
|
||||
<string name="skill_longdescription_weapon_prof_unarmed">When fighting without a weapon and shield, gain %1$d attack chance, %2$d damage potential and %3$d block chance per skill level.</string>
|
||||
<string name="skill_longdescription_armor_prof_shield">Increase damage resistance by %1$d per skill level while having a shield equipped.</string>
|
||||
<string name="skill_longdescription_armor_prof_unarmored">While fighting without having any armor equipped, gain %1$d block chance per skill level. Items made of cloth are not considered as being armor.</string>
|
||||
|
||||
@@ -183,11 +183,11 @@ public final class SkillInfoActivity extends Activity {
|
||||
case SkillCollection.SKILL_REJUVENATION: return res.getString(R.string.skill_longdescription_rejuvenation, SkillCollection.PER_SKILLPOINT_INCREASE_REJUVENATION_CHANCE);
|
||||
case SkillCollection.SKILL_TAUNT: return res.getString(R.string.skill_longdescription_taunt, SkillCollection.PER_SKILLPOINT_INCREASE_TAUNT_CHANCE, SkillCollection.TAUNT_AP_LOSS);
|
||||
case SkillCollection.SKILL_CONCUSSION: return res.getString(R.string.skill_longdescription_concussion, SkillCollection.CONCUSSION_THRESHOLD, SkillCollection.PER_SKILLPOINT_INCREASE_CONCUSSION_CHANCE);
|
||||
case SkillCollection.SKILL_WEAPON_PROFICIENCY_DAGGER: return res.getString(R.string.skill_longdescription_weapon_prof_dagger, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC);
|
||||
case SkillCollection.SKILL_WEAPON_PROFICIENCY_1HSWORD: return res.getString(R.string.skill_longdescription_weapon_prof_1hsword, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC);
|
||||
case SkillCollection.SKILL_WEAPON_PROFICIENCY_2HSWORD: return res.getString(R.string.skill_longdescription_weapon_prof_2hsword, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC);
|
||||
case SkillCollection.SKILL_WEAPON_PROFICIENCY_AXE: return res.getString(R.string.skill_longdescription_weapon_prof_axe, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC);
|
||||
case SkillCollection.SKILL_WEAPON_PROFICIENCY_BLUNT: return res.getString(R.string.skill_longdescription_weapon_prof_blunt, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC);
|
||||
case SkillCollection.SKILL_WEAPON_PROFICIENCY_DAGGER: return res.getString(R.string.skill_longdescription_weapon_prof_dagger, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_BC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_CS_PERCENT);
|
||||
case SkillCollection.SKILL_WEAPON_PROFICIENCY_1HSWORD: return res.getString(R.string.skill_longdescription_weapon_prof_1hsword, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_BC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_CS_PERCENT);
|
||||
case SkillCollection.SKILL_WEAPON_PROFICIENCY_2HSWORD: return res.getString(R.string.skill_longdescription_weapon_prof_2hsword, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_BC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_CS_PERCENT);
|
||||
case SkillCollection.SKILL_WEAPON_PROFICIENCY_AXE: return res.getString(R.string.skill_longdescription_weapon_prof_axe, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_BC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_CS_PERCENT);
|
||||
case SkillCollection.SKILL_WEAPON_PROFICIENCY_BLUNT: return res.getString(R.string.skill_longdescription_weapon_prof_blunt, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_BC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_CS_PERCENT);
|
||||
case SkillCollection.SKILL_WEAPON_PROFICIENCY_UNARMED: return res.getString(R.string.skill_longdescription_weapon_prof_unarmed, SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_AC, SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_DMG, SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_BC);
|
||||
case SkillCollection.SKILL_ARMOR_PROFICIENCY_SHIELD: return res.getString(R.string.skill_longdescription_armor_prof_shield, SkillCollection.PER_SKILLPOINT_INCREASE_SHIELD_PROF_DR);
|
||||
case SkillCollection.SKILL_ARMOR_PROFICIENCY_UNARMORED: return res.getString(R.string.skill_longdescription_armor_prof_unarmored, SkillCollection.PER_SKILLPOINT_INCREASE_UNARMORED_BC);
|
||||
|
||||
@@ -9,7 +9,6 @@ import com.gpl.rpg.AndorsTrail.model.ability.ActorConditionEffect;
|
||||
import com.gpl.rpg.AndorsTrail.model.ability.ActorConditionType;
|
||||
import com.gpl.rpg.AndorsTrail.model.ability.SkillCollection;
|
||||
import com.gpl.rpg.AndorsTrail.model.ability.SkillInfo;
|
||||
import com.gpl.rpg.AndorsTrail.model.ability.traits.AbilityModifierTraits;
|
||||
import com.gpl.rpg.AndorsTrail.model.actor.Actor;
|
||||
import com.gpl.rpg.AndorsTrail.model.actor.Monster;
|
||||
import com.gpl.rpg.AndorsTrail.model.actor.Player;
|
||||
@@ -196,7 +195,10 @@ public final class SkillController {
|
||||
|
||||
ItemType mainWeapon = ItemController.getMainWeapon(player);
|
||||
if (mainWeapon != null) {
|
||||
playerTraits.attackChance += SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC * getSkillLevelForItemType(player, mainWeapon);
|
||||
final int skillLevel = getSkillLevelForItemType(player, mainWeapon);
|
||||
addPercentAttackChance(player, mainWeapon, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC_PERCENT * skillLevel, 0);
|
||||
addPercentBlockChance(player, mainWeapon, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_BC_PERCENT * skillLevel, 0);
|
||||
addPercentCriticalSkill(player, mainWeapon, SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_CS_PERCENT * skillLevel, 0);
|
||||
}
|
||||
|
||||
final int unarmedLevel = player.getSkillLevel(SkillCollection.SKILL_WEAPON_PROFICIENCY_UNARMED);
|
||||
@@ -233,11 +235,11 @@ public final class SkillController {
|
||||
int skill = getProficiencySkillForItemCategory(itemType.category);
|
||||
if (skill == SkillCollection.SKILL_ARMOR_PROFICIENCY_LIGHT) {
|
||||
if (skillLevelLightArmor > 0) {
|
||||
playerTraits.blockChance += getPercentage(itemType.effects_equip.stats.increaseBlockChance, SkillCollection.PER_SKILLPOINT_INCREASE_LIGHT_ARMOR_BC_PERCENT * skillLevelLightArmor, 0);
|
||||
addPercentBlockChance(player, itemType, SkillCollection.PER_SKILLPOINT_INCREASE_LIGHT_ARMOR_BC_PERCENT * skillLevelLightArmor, 0);
|
||||
}
|
||||
} else if (skill == SkillCollection.SKILL_ARMOR_PROFICIENCY_HEAVY) {
|
||||
if (skillLevelHeavyArmor > 0) {
|
||||
playerTraits.blockChance += getPercentage(itemType.effects_equip.stats.increaseBlockChance, SkillCollection.PER_SKILLPOINT_INCREASE_HEAVY_ARMOR_BC_PERCENT * skillLevelHeavyArmor, 0);
|
||||
addPercentBlockChance(player, itemType, SkillCollection.PER_SKILLPOINT_INCREASE_HEAVY_ARMOR_BC_PERCENT * skillLevelHeavyArmor, 0);
|
||||
playerTraits.moveCost -= getPercentage(itemType.effects_equip.stats.increaseMoveCost, SkillCollection.PER_SKILLPOINT_INCREASE_HEAVY_ARMOR_MOVECOST_PERCENT * skillLevelHeavyArmor, 0);
|
||||
playerTraits.attackCost -= getPercentage(itemType.effects_equip.stats.increaseAttackCost, SkillCollection.PER_SKILLPOINT_INCREASE_HEAVY_ARMOR_ATKCOST_PERCENT * skillLevelHeavyArmor, 0);
|
||||
}
|
||||
@@ -320,7 +322,6 @@ public final class SkillController {
|
||||
if (isDualWielding(mainHandItem, offHandItem)) {
|
||||
int skillLevelFightStyle = player.getSkillLevel(SkillCollection.SKILL_FIGHTSTYLE_DUAL_WIELD);
|
||||
if (offHandItem.effects_equip != null) {
|
||||
AbilityModifierTraits offHandCombatTraits = offHandItem.effects_equip.stats;
|
||||
int attackCostMainHand = mainHandItem.effects_equip.stats.increaseAttackCost;
|
||||
int attackCostOffHand = offHandItem.effects_equip.stats.increaseAttackCost;
|
||||
int percent;
|
||||
@@ -335,13 +336,15 @@ public final class SkillController {
|
||||
playerTraits.attackCost = attackCostMainHand + attackCostOffHand;
|
||||
}
|
||||
|
||||
final int increaseACFromWeaponProficiency = SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC * getSkillLevelForItemType(player, offHandItem);
|
||||
playerTraits.attackChance += getPercentage(increaseACFromWeaponProficiency, percent, 0);
|
||||
final int skillLevel = getSkillLevelForItemType(player, offHandItem);
|
||||
addPercentAttackChance(player, offHandItem, getPercentage(SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC_PERCENT * skillLevel, percent, 0), 0);
|
||||
addPercentBlockChance(player, offHandItem, getPercentage(SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_BC_PERCENT * skillLevel, percent, 0), 0);
|
||||
addPercentCriticalSkill(player, offHandItem, getPercentage(SkillCollection.PER_SKILLPOINT_INCREASE_WEAPON_PROF_CS_PERCENT * skillLevel, percent, 0), 0);
|
||||
|
||||
addPercentAttackChance(player, offHandItem, percent, 100);
|
||||
addPercentBlockChance(player, offHandItem, percent, 100);
|
||||
addPercentDamage(player, offHandItem, percent, 100);
|
||||
playerTraits.criticalSkill += getPercentage(offHandCombatTraits.increaseCriticalSkill, percent, 100);
|
||||
addPercentCriticalSkill(player, offHandItem, percent, 100);
|
||||
}
|
||||
|
||||
int skillLevelSpecialization = player.getSkillLevel(SkillCollection.SKILL_SPECIALIZATION_DUAL_WIELD);
|
||||
@@ -368,6 +371,11 @@ public final class SkillController {
|
||||
player.damagePotential.add(getPercentage(itemType.effects_equip.stats.increaseMinDamage, percentForPositiveValues, percentForNegativeValues), false);
|
||||
}
|
||||
|
||||
private static void addPercentCriticalSkill(Player player, ItemType itemType, int percentForPositiveValues, int percentForNegativeValues) {
|
||||
if (itemType.effects_equip == null) return;
|
||||
player.criticalSkill += getPercentage(itemType.effects_equip.stats.increaseCriticalSkill, percentForPositiveValues, percentForNegativeValues);
|
||||
}
|
||||
|
||||
private static int getPercentage(int originalValue, int percentForPositiveValues, int percentForNegativeValues) {
|
||||
if (originalValue == 0) {
|
||||
return 0;
|
||||
|
||||
@@ -84,7 +84,9 @@ public final class SkillCollection {
|
||||
public static final int TAUNT_AP_LOSS = 2;
|
||||
public static final int CONCUSSION_THRESHOLD = 50;
|
||||
public static final int PER_SKILLPOINT_INCREASE_CONCUSSION_CHANCE = 15;
|
||||
public static final int PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC = 10;
|
||||
public static final int PER_SKILLPOINT_INCREASE_WEAPON_PROF_AC_PERCENT = 30;
|
||||
public static final int PER_SKILLPOINT_INCREASE_WEAPON_PROF_CS_PERCENT = 10;
|
||||
public static final int PER_SKILLPOINT_INCREASE_WEAPON_PROF_BC_PERCENT = 30;
|
||||
public static final int PER_SKILLPOINT_INCREASE_UNARMED_AC = 20;
|
||||
public static final int PER_SKILLPOINT_INCREASE_UNARMED_DMG = 2;
|
||||
public static final int PER_SKILLPOINT_INCREASE_UNARMED_BC = 5;
|
||||
@@ -94,11 +96,11 @@ public final class SkillCollection {
|
||||
public static final int PER_SKILLPOINT_INCREASE_HEAVY_ARMOR_BC_PERCENT = 10;
|
||||
public static final int PER_SKILLPOINT_INCREASE_HEAVY_ARMOR_MOVECOST_PERCENT = 25;
|
||||
public static final int PER_SKILLPOINT_INCREASE_HEAVY_ARMOR_ATKCOST_PERCENT = 25;
|
||||
public static final int PER_SKILLPOINT_INCREASE_FIGHTSTYLE_2HAND_DMG_PERCENT = 50;
|
||||
public static final int PER_SKILLPOINT_INCREASE_FIGHTSTYLE_2HAND_DMG_PERCENT = 30;
|
||||
public static final int PER_SKILLPOINT_INCREASE_SPECIALIZATION_2HAND_DMG_PERCENT = 50;
|
||||
public static final int PER_SKILLPOINT_INCREASE_SPECIALIZATION_2HAND_AC_PERCENT = 20;
|
||||
public static final int PER_SKILLPOINT_INCREASE_FIGHTSTYLE_WEAPON_AC_PERCENT = 50;
|
||||
public static final int PER_SKILLPOINT_INCREASE_FIGHTSTYLE_SHIELD_BC_PERCENT = 50;
|
||||
public static final int PER_SKILLPOINT_INCREASE_FIGHTSTYLE_WEAPON_AC_PERCENT = 25;
|
||||
public static final int PER_SKILLPOINT_INCREASE_FIGHTSTYLE_SHIELD_BC_PERCENT = 25;
|
||||
public static final int PER_SKILLPOINT_INCREASE_SPECIALIZATION_WEAPON_AC_PERCENT = 50;
|
||||
public static final int PER_SKILLPOINT_INCREASE_SPECIALIZATION_WEAPON_DMG_PERCENT = 20;
|
||||
public static final int DUALWIELD_EFFICIENCY_LEVEL2 = 100;
|
||||
|
||||
Reference in New Issue
Block a user