mirror of
https://github.com/OMGeeky/andors-trail.git
synced 2026-01-07 04:01:45 +01:00
First draft of the unarmed and unarmored skill
This commit is contained in:
@@ -612,6 +612,7 @@
|
||||
<string name="skill_title_fightstyle_dualwield">Fighting style: Dual wield</string>
|
||||
<string name="skill_title_fightstyle_2hand">Fighting style: Two-handed weapon</string>
|
||||
<string name="skill_title_fightstyle_weapon_shield">Fighting style: Weapon and shield</string>
|
||||
<string name="skill_title_fightstyle_unarmed_unarmored">Fighting style: Way of the monk</string>
|
||||
<string name="skill_title_specialization_dualwield">Specialization: Dual wield</string>
|
||||
<string name="skill_title_specialization_2hand">Specialization: Two-handed weapon</string>
|
||||
<string name="skill_title_specialization_weapon_shield">Specialization: Weapon and shield</string>
|
||||
@@ -630,6 +631,7 @@
|
||||
<string name="skill_shortdescription_fightstyle_dualwield">Wield two weapons at the same time</string>
|
||||
<string name="skill_shortdescription_fightstyle_2hand">Make better use of weapons that require both hands</string>
|
||||
<string name="skill_shortdescription_fightstyle_weapon_shield">Better at fighting with weapon and shield</string>
|
||||
<string name="skill_shortdescription_fightstyle_unarmed_unarmored">Better at fighting unarmed/unarmored</string>
|
||||
<string name="skill_shortdescription_specialization_dualwield">Expert at dual wielding</string>
|
||||
<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>
|
||||
@@ -658,6 +660,9 @@ Every skill level increases damage potential of two-handed weapons with %1$d %%
|
||||
<string name="skill_longdescription_fightstyle_weapon_shield">"Gives benefits when fighting with a weapon in the main hand and having a shield equipped in the off-hand.
|
||||
|
||||
Every skill level increases the attack chance of weapons with %1$d %% of their original attack chances, and the block chance of shields by %2$d %% of their original block chances."</string>
|
||||
<string name="skill_longdescription_fightstyle_unarmed_unarmored">"While fighting without having any piece of armor equipped, gain %1$d block chance and %2$d damage resistance per skill level. Items made of cloth are not considered as being armor.
|
||||
|
||||
Every skill level increases for each free hand the attack chance by %3$d, the maximum damage by %4$d and gives a critical multiplier of %5$d %% when both hands are free."</string>
|
||||
<string name="skill_longdescription_specialization_dualwield">Increases the attack chance of both wielded weapons by an additional %1$d %% of their original attack chances, in addition to the benefits given by the weapon style skill. The block chances of both wielded weapons are also increased by %2$d %% of their original block chances.</string>
|
||||
<string name="skill_longdescription_specialization_2hand">Increases damage potential of two-handed weapons by an additional %1$d %% of the original damage potential, in addition to the benefits given by the weapon style skill. The attack chances of two-handed weapons are also increased by %2$d %% of their original attack chances.</string>
|
||||
<string name="skill_longdescription_specialization_weapon_shield">Increases both attack chances and damage potential of weapons. The attack chance is increased by %1$d %% of the original attack chance, and the damage potential is increased by %2$d %% of the original damage potential.</string>
|
||||
|
||||
@@ -148,6 +148,7 @@ public final class SkillInfoActivity extends AndorsTrailBaseActivity {
|
||||
case fightstyleDualWield: return R.string.skill_title_fightstyle_dualwield;
|
||||
case fightstyle2hand: return R.string.skill_title_fightstyle_2hand;
|
||||
case fightstyleWeaponShield: return R.string.skill_title_fightstyle_weapon_shield;
|
||||
case fightstyleUnarmedUnarmored: return R.string.skill_title_fightstyle_unarmed_unarmored;
|
||||
case specializationDualWield: return R.string.skill_title_specialization_dualwield;
|
||||
case specialization2hand: return R.string.skill_title_specialization_2hand;
|
||||
case specializationWeaponShield: return R.string.skill_title_specialization_weapon_shield;
|
||||
@@ -198,6 +199,12 @@ public final class SkillInfoActivity extends AndorsTrailBaseActivity {
|
||||
case fightstyleDualWield: return res.getString(R.string.skill_longdescription_fightstyle_dualwield, SkillCollection.DUALWIELD_EFFICIENCY_LEVEL0, SkillCollection.DUALWIELD_EFFICIENCY_LEVEL1, SkillCollection.DUALWIELD_LEVEL1_OFFHAND_AP_COST_PERCENT, SkillCollection.DUALWIELD_EFFICIENCY_LEVEL2);
|
||||
case fightstyle2hand: return res.getString(R.string.skill_longdescription_fightstyle_2hand, SkillCollection.PER_SKILLPOINT_INCREASE_FIGHTSTYLE_2HAND_DMG_PERCENT);
|
||||
case fightstyleWeaponShield: return res.getString(R.string.skill_longdescription_fightstyle_weapon_shield, SkillCollection.PER_SKILLPOINT_INCREASE_FIGHTSTYLE_WEAPON_AC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_FIGHTSTYLE_SHIELD_BC_PERCENT);
|
||||
case fightstyleUnarmedUnarmored: return res.getString(R.string.skill_longdescription_fightstyle_unarmed_unarmored,
|
||||
SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_BC,
|
||||
SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_DR,
|
||||
SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_AC,
|
||||
SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_DMG_MAX,
|
||||
SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_CM_PERCENT);
|
||||
case specializationDualWield: return res.getString(R.string.skill_longdescription_specialization_dualwield, SkillCollection.PER_SKILLPOINT_INCREASE_SPECIALIZATION_DUALWIELD_AC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_SPECIALIZATION_DUALWIELD_BC_PERCENT);
|
||||
case specialization2hand: return res.getString(R.string.skill_longdescription_specialization_2hand, SkillCollection.PER_SKILLPOINT_INCREASE_SPECIALIZATION_2HAND_DMG_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_SPECIALIZATION_2HAND_AC_PERCENT);
|
||||
case specializationWeaponShield: return res.getString(R.string.skill_longdescription_specialization_weapon_shield, SkillCollection.PER_SKILLPOINT_INCREASE_SPECIALIZATION_WEAPON_AC_PERCENT, SkillCollection.PER_SKILLPOINT_INCREASE_SPECIALIZATION_WEAPON_DMG_PERCENT);
|
||||
|
||||
@@ -307,6 +307,30 @@ public final class SkillController {
|
||||
ItemType mainHandItem = player.inventory.getItemTypeInWearSlot(Inventory.WearSlot.weapon);
|
||||
ItemType offHandItem = player.inventory.getItemTypeInWearSlot(Inventory.WearSlot.shield);
|
||||
|
||||
final int skillLevelFightStyleUnarmedUnarmored = player.getSkillLevel(SkillID.fightstyleUnarmedUnarmored);
|
||||
if (skillLevelFightStyleUnarmedUnarmored > 0) {
|
||||
if (isUnarmored(player)) {
|
||||
player.blockChance += SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_BC * skillLevelFightStyleUnarmedUnarmored;
|
||||
player.damageResistance += SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_DR * skillLevelFightStyleUnarmedUnarmored;
|
||||
}
|
||||
|
||||
int multiplier = 0;
|
||||
if (mainHandItem == null) {
|
||||
multiplier++;
|
||||
}
|
||||
if (offHandItem == null) {
|
||||
multiplier++;
|
||||
}
|
||||
if (multiplier > 0) {
|
||||
player.attackChance += SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_AC * skillLevelFightStyleUnarmedUnarmored * multiplier;
|
||||
player.damagePotential.addToMax(SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_DMG_MAX * skillLevelFightStyleUnarmedUnarmored * multiplier);
|
||||
|
||||
if (multiplier == 2) {
|
||||
player.criticalMultiplier = 1 + ((float)SkillCollection.PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_CM_PERCENT / 100) * skillLevelFightStyleUnarmedUnarmored;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (isWielding2HandItem(mainHandItem, offHandItem)) {
|
||||
int skillLevelFightStyle = player.getSkillLevel(SkillID.fightstyle2hand);
|
||||
int skillLevelSpecialization = player.getSkillLevel(SkillID.specialization2hand);
|
||||
|
||||
@@ -55,6 +55,7 @@ public final class SkillCollection {
|
||||
,specialization2hand
|
||||
,specializationWeaponShield
|
||||
,weaponProficiencyPole
|
||||
,fightstyleUnarmedUnarmored
|
||||
}
|
||||
|
||||
// should be in the same number &U order as in arrays.xml
|
||||
@@ -117,6 +118,11 @@ public final class SkillCollection {
|
||||
public static final int PER_SKILLPOINT_INCREASE_SPECIALIZATION_2HAND_AC_PERCENT = 20;
|
||||
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_UNARMED_UNARMORED_BC = 5;
|
||||
public static final int PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_DR = 1;
|
||||
public static final int PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_AC = 6;
|
||||
public static final int PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_DMG_MAX = 2;
|
||||
public static final int PER_SKILLPOINT_INCREASE_UNARMED_UNARMORED_CM_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;
|
||||
@@ -223,6 +229,9 @@ public final class SkillCollection {
|
||||
initializeSkill(new SkillInfo(SkillID.fightstyleWeaponShield, 2, SkillInfo.LevelUpType.alwaysShown, SkillCategory.specialty, new SkillLevelRequirement[] {
|
||||
SkillLevelRequirement.requireExperienceLevels(15, 0)
|
||||
}, position++));
|
||||
initializeSkill(new SkillInfo(SkillID.fightstyleUnarmedUnarmored, 3, SkillInfo.LevelUpType.alwaysShown, SkillCategory.specialty, new SkillLevelRequirement[] {
|
||||
SkillLevelRequirement.requireExperienceLevels(15, 0)
|
||||
}, position++));
|
||||
initializeSkill(new SkillInfo(SkillID.specializationDualWield, 1, SkillInfo.LevelUpType.alwaysShown, SkillCategory.specialty, new SkillLevelRequirement[] {
|
||||
SkillLevelRequirement.requireExperienceLevels(45, 0)
|
||||
,SkillLevelRequirement.requireOtherSkill(SkillID.fightstyleDualWield, 2)
|
||||
|
||||
@@ -155,6 +155,7 @@ public final class SkillListAdapter extends ArrayAdapter<SkillInfo> {
|
||||
case fightstyleDualWield: return R.string.skill_shortdescription_fightstyle_dualwield;
|
||||
case fightstyle2hand: return R.string.skill_shortdescription_fightstyle_2hand;
|
||||
case fightstyleWeaponShield: return R.string.skill_shortdescription_fightstyle_weapon_shield;
|
||||
case fightstyleUnarmedUnarmored: return R.string.skill_shortdescription_fightstyle_unarmed_unarmored;
|
||||
case specializationDualWield: return R.string.skill_shortdescription_specialization_dualwield;
|
||||
case specialization2hand: return R.string.skill_shortdescription_specialization_2hand;
|
||||
case specializationWeaponShield: return R.string.skill_shortdescription_specialization_weapon_shield;
|
||||
|
||||
Reference in New Issue
Block a user