Skip to content

Commit

Permalink
Fixed SolarBeam.
Browse files Browse the repository at this point in the history
  • Loading branch information
cathyjf committed Oct 5, 2010
1 parent 29e45b9 commit 24f549f
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions resources/moves.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8825,8 +8825,16 @@ makeRecoveryMove(this);
<init>
<![CDATA[
makeChargeMove(this, Text.battle_messages_charge.wrap(0));
var parent = this.use;
var parentPrepareSelf = this.prepareSelf;
var parentUse = this.use;
var power_ = this.power;
this.prepareSelf = function(field, user, target) {
var flags = getGlobalController(field).getFlags();
if (flags[GlobalEffect.SUN]) {
return;
}
parentPrepareSelf.call(this, field, user, target);
};
this.use = function(field, user, target, targets) {
this.power = power_;
var flags = getGlobalController(field).getFlags();
Expand All @@ -8839,7 +8847,7 @@ this.use = function(field, user, target, targets) {
target.hp -= field.calculate(this, user, target, targets);
return;
}
parent.call(this, field, user, target, targets);
parentUse.call(this, field, user, target, targets);
};
]]>
</init>
Expand Down

0 comments on commit 24f549f

Please sign in to comment.