Adjustments for skills that use charges.
Contributed by Trance.
This commit is contained in:
@@ -49,8 +49,7 @@ public class FocusMaxMomentum extends AbstractEffect
|
||||
if (effected.isPlayer())
|
||||
{
|
||||
final PlayerInstance player = effected.getActingPlayer();
|
||||
|
||||
final int count = (int) effected.getStat().getValue(Stat.MAX_MOMENTUM, 1);
|
||||
final int count = (int) effected.getStat().getValue(Stat.MAX_MOMENTUM, 0);
|
||||
|
||||
player.setCharges(count);
|
||||
|
||||
|
@@ -58,7 +58,7 @@ public class FocusMomentum extends AbstractEffect
|
||||
|
||||
final PlayerInstance player = effected.getActingPlayer();
|
||||
final int currentCharges = player.getCharges();
|
||||
final int maxCharges = Math.min(_maxCharges, (int) effected.getStat().getValue(Stat.MAX_MOMENTUM, 1));
|
||||
final int maxCharges = Math.min(_maxCharges, (int) effected.getStat().getValue(Stat.MAX_MOMENTUM, 8));
|
||||
|
||||
if (currentCharges >= maxCharges)
|
||||
{
|
||||
@@ -70,7 +70,6 @@ public class FocusMomentum extends AbstractEffect
|
||||
}
|
||||
|
||||
final int newCharge = Math.min(currentCharges + _amount, maxCharges);
|
||||
|
||||
player.setCharges(newCharge);
|
||||
|
||||
if (newCharge == maxCharges)
|
||||
|
@@ -51,7 +51,7 @@ public class GetMomentum extends AbstractEffect
|
||||
if (effected.isPlayer())
|
||||
{
|
||||
final PlayerInstance player = effected.getActingPlayer();
|
||||
final int maxCharge = (int) player.getStat().getValue(Stat.MAX_MOMENTUM, 1);
|
||||
final int maxCharge = (int) player.getStat().getValue(Stat.MAX_MOMENTUM, 0);
|
||||
final int newCharge = Math.min(player.getCharges() + 1, maxCharge);
|
||||
|
||||
player.setCharges(newCharge);
|
||||
|
Reference in New Issue
Block a user