v2.4.0: redesigned brawler's stance ability
This commit is contained in:
@@ -955,10 +955,11 @@ items.rings.ringofforce.stats=When unarmed, at your current strength, this ring
|
||||
items.rings.ringofforce.typical_stats=When unarmed, at your current strength, typically this ring will deal _%1$d-%2$d damage._ With a weapon equipped, typically this ring will increase damage by _%3$d._
|
||||
items.rings.ringofforce.combined_stats=Your equipped rings are combining their power, dealing a total of _%1$d-%2$d damage_ without a weapon, or increasing damage by _%3$d_ with one.
|
||||
items.rings.ringofforce.ability_name=brawler's stance
|
||||
items.rings.ringofforce.ability_desc=The Duelist can adopt a _brawler's stance_ with this ring. While in this stance the Duelist's regular attacks will use this ring even with a weapon equipped. The ring will also inherit the weapon's enchantment and augmentation. Each regular attack in this stance consumes 1/6 of a weapon charge.
|
||||
items.rings.ringofforce.typical_ability_desc=The Duelist can adopt a _brawler's stance_ with this ring, causing her regular attacks to always use this ring even with a weapon equipped. These attacks will typically deal _%1$d-%2$d damage_ and will also inherit the weapon's enchantment and augmentation. This stance slows weapon recharging speed by 50%%.
|
||||
items.rings.ringofforce.ability_desc=The Duelist can adopt a _brawler's stance_ with this ring, causing her regular attacks to always use this ring even with a weapon equipped. These attacks will deal _%1$d-%2$d damage_ and will also inherit the weapon's enchantment and augmentation. This stance slows weapon recharging speed by 50%%.
|
||||
items.rings.ringofforce.desc=This ring enhances the force of the wearer's melee blows. This extra power is fairly weak when wielding weapons, but an unarmed attack will be made much stronger. A cursed ring will instead weaken the wearer's blows.
|
||||
items.rings.ringofforce$brawlersstance.name=brawler's stance
|
||||
items.rings.ringofforce$brawlersstance.desc=While in this stance the Duelist's regular attacks will use an equipped ring of force even when she has a weapon equipped. The attack will still use the weapon's augmentation and enchantment however.\n\nEach regular attack in this stance consumes 1/6 of a weapon charge. You currently have enough charge for %d attacks.\n\nThis stance can be toggled on or off by using a ring of force.
|
||||
items.rings.ringofforce$brawlersstance.desc=While in this stance the Duelist's regular attacks will use an equipped ring of force even when she has a weapon equipped. These attacks gain bonus damage and will still use the weapon's augmentation and enchantment.\n\nMaintaining this stance takes focus however, reducing weapon ability recharge speed by 50%.\n\nThis stance can be toggled on or off by using a ring of force.
|
||||
|
||||
items.rings.ringoffuror.name=ring of furor
|
||||
items.rings.ringoffuror.stats=When worn, this ring will increase the speed of your attacks by _%s%%._
|
||||
|
||||
@@ -127,7 +127,6 @@ import com.shatteredpixel.shatteredpixeldungeon.items.weapon.SpiritBow;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.Weapon;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.melee.Flail;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.melee.MagesStaff;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.melee.MeleeWeapon;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.melee.Quarterstaff;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.melee.RoundShield;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.melee.Sai;
|
||||
@@ -2119,18 +2118,6 @@ public class Hero extends Char {
|
||||
Buff.affect( this, Sai.ComboStrikeTracker.class).addHit();
|
||||
}
|
||||
|
||||
RingOfForce.BrawlersStance brawlStance = buff(RingOfForce.BrawlersStance.class);
|
||||
if (brawlStance != null && brawlStance.hitsLeft() > 0){
|
||||
MeleeWeapon.Charger charger = Buff.affect(this, MeleeWeapon.Charger.class);
|
||||
charger.partialCharge -= RingOfForce.BrawlersStance.HIT_CHARGE_USE;
|
||||
while (charger.partialCharge < 0) {
|
||||
charger.charges--;
|
||||
charger.partialCharge++;
|
||||
}
|
||||
BuffIndicator.refreshHero();
|
||||
Item.updateQuickslot();
|
||||
}
|
||||
|
||||
curAction = null;
|
||||
|
||||
super.onAttackComplete();
|
||||
|
||||
@@ -33,7 +33,6 @@ import com.shatteredpixel.shatteredpixeldungeon.sprites.ItemSpriteSheet;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.ui.AttackIndicator;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.ui.BuffIndicator;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.utils.GLog;
|
||||
import com.watabou.noosa.Image;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
@@ -81,7 +80,13 @@ public class RingOfForce extends Ring {
|
||||
&& hero.buff(MonkEnergy.MonkAbility.UnarmedAbilityTracker.class) == null) {
|
||||
int level = getBuffedBonus(hero, Force.class);
|
||||
float tier = tier(hero.STR());
|
||||
return Char.combatRoll(min(level, tier), max(level, tier));
|
||||
int dmg = Char.combatRoll(min(level, tier), max(level, tier));
|
||||
if (hero.buff(BrawlersStance.class) != null){
|
||||
// 1+tier base dmg, roughly +35% dmg
|
||||
// lvl*((3+tier)/8) scaling, roughly +30% dmg
|
||||
dmg += Math.round(1+tier+(level*((3+tier)/8f)));
|
||||
}
|
||||
return dmg;
|
||||
} else {
|
||||
//attack without any ring of force influence
|
||||
return Char.combatRoll(1, Math.max(hero.STR()-8, 1));
|
||||
@@ -175,10 +180,6 @@ public class RingOfForce extends Ring {
|
||||
} else if (!isEquipped(hero)) {
|
||||
GLog.w(Messages.get(MeleeWeapon.class, "ability_need_equip"));
|
||||
|
||||
} else if ((Buff.affect(hero, MeleeWeapon.Charger.class).charges + Buff.affect(hero, MeleeWeapon.Charger.class).partialCharge)
|
||||
< BrawlersStance.HIT_CHARGE_USE){
|
||||
GLog.w(Messages.get(MeleeWeapon.class, "ability_no_charge"));
|
||||
|
||||
} else {
|
||||
Buff.affect(hero, BrawlersStance.class);
|
||||
AttackIndicator.updateState();
|
||||
@@ -194,7 +195,15 @@ public class RingOfForce extends Ring {
|
||||
|
||||
if (Dungeon.hero.heroClass == HeroClass.DUELIST
|
||||
&& (anonymous || isIdentified() || isEquipped(Dungeon.hero))){
|
||||
info += "\n\n" + Messages.get(this, "ability_desc");
|
||||
//0 if unidentified, solo level if unequipped, combined level if equipped
|
||||
int level = isIdentified() ? (isEquipped(Dungeon.hero) ? getBuffedBonus(Dungeon.hero, Force.class) : soloBuffedBonus()) : 0;
|
||||
float tier = tier(Dungeon.hero.STR());
|
||||
int dmgBoost = Math.round(1+tier+(level*((3+tier)/8f)));
|
||||
if (isIdentified()) {
|
||||
info += "\n\n" + Messages.get(this, "ability_desc", min(level, tier)+dmgBoost, max(level, tier)+dmgBoost);
|
||||
} else {
|
||||
info += "\n\n" + Messages.get(this, "typical_ability_desc", min(level, tier)+dmgBoost, max(level, tier)+dmgBoost);
|
||||
}
|
||||
}
|
||||
|
||||
return info;
|
||||
@@ -209,7 +218,7 @@ public class RingOfForce extends Ring {
|
||||
return false;
|
||||
}
|
||||
BrawlersStance stance = hero.buff(BrawlersStance.class);
|
||||
if (stance != null && stance.hitsLeft() > 0){
|
||||
if (stance != null){
|
||||
//clear the buff if no ring of force is equipped
|
||||
if (hero.buff(RingOfForce.Force.class) == null){
|
||||
stance.detach();
|
||||
@@ -230,7 +239,7 @@ public class RingOfForce extends Ring {
|
||||
return hero.buff(MonkEnergy.MonkAbility.FlurryEmpowerTracker.class) != null;
|
||||
}
|
||||
BrawlersStance stance = hero.buff(BrawlersStance.class);
|
||||
if (stance != null && stance.hitsLeft() > 0){
|
||||
if (stance != null){
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
@@ -242,7 +251,7 @@ public class RingOfForce extends Ring {
|
||||
return false;
|
||||
}
|
||||
BrawlersStance stance = hero.buff(BrawlersStance.class);
|
||||
if (stance != null && stance.hitsLeft() > 0){
|
||||
if (stance != null){
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
@@ -250,51 +259,15 @@ public class RingOfForce extends Ring {
|
||||
|
||||
public static class BrawlersStance extends Buff {
|
||||
|
||||
public static float HIT_CHARGE_USE = 1/6f;
|
||||
|
||||
{
|
||||
announced = true;
|
||||
type = buffType.POSITIVE;
|
||||
}
|
||||
|
||||
public int hitsLeft(){
|
||||
MeleeWeapon.Charger charger = Buff.affect(target, MeleeWeapon.Charger.class);
|
||||
float charges = charger.charges;
|
||||
charges += charger.partialCharge;
|
||||
|
||||
return (int)(charges/HIT_CHARGE_USE);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int icon() {
|
||||
return BuffIndicator.DUEL_BRAWL;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void tintIcon(Image icon) {
|
||||
if (hitsLeft() == 0){
|
||||
icon.brightness(0.25f);
|
||||
} else {
|
||||
icon.resetColor();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public float iconFadePercent() {
|
||||
float usableCharges = hitsLeft()*HIT_CHARGE_USE;
|
||||
|
||||
return 1f - (usableCharges / Buff.affect(target, MeleeWeapon.Charger.class).chargeCap());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String iconTextDisplay() {
|
||||
return Integer.toString(hitsLeft());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String desc() {
|
||||
return Messages.get(this, "desc", hitsLeft());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -38,6 +38,7 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Talent;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.effects.FloatingText;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.Item;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.KindOfWeapon;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.rings.RingOfForce;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.Weapon;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.messages.Messages;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.scenes.CellSelector;
|
||||
@@ -455,6 +456,11 @@ public class MeleeWeapon extends Weapon {
|
||||
chargeToGain *= 1.5f;
|
||||
}
|
||||
|
||||
//50% slower charge gain with brawler's stance enabled
|
||||
if (Dungeon.hero.buff(RingOfForce.BrawlersStance.class) != null){
|
||||
chargeToGain *= 0.50f;
|
||||
}
|
||||
|
||||
partialCharge += chargeToGain;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user