Resolved many Rubocop warnings

This commit is contained in:
Maruno17
2020-09-06 17:31:12 +01:00
parent 6c4670eaa3
commit 681a8331ab
137 changed files with 921 additions and 1200 deletions

View File

@@ -67,7 +67,7 @@ class PokeBattle_Battler
#=============================================================================
#
#=============================================================================
def pbBeginTurn(choice)
def pbBeginTurn(_choice)
# Cancel some lingering effects which only apply until the user next moves
@effects[PBEffects::BeakBlast] = false
@effects[PBEffects::DestinyBondPrevious] = @effects[PBEffects::DestinyBond]
@@ -105,7 +105,7 @@ class PokeBattle_Battler
@effects[PBEffects::FuryCutter] = 0
end
def pbEndTurn(choice)
def pbEndTurn(_choice)
@lastRoundMoved = @battle.turnCount # Done something this round
if @effects[PBEffects::ChoiceBand]<0 &&
hasActiveItem?([:CHOICEBAND,:CHOICESPECS,:CHOICESCARF])
@@ -438,7 +438,6 @@ class PokeBattle_Battler
# NOTE: If a multi-hit move becomes disabled partway through doing those
# hits (e.g. by Cursed Body), the rest of the hits continue as
# normal.
notFainted = false
break if !targets.any? { |t| !t.fainted? } # All targets are fainted
end
# Battle Arena only - attack is successful
@@ -479,7 +478,7 @@ class PokeBattle_Battler
newTargets = pbChangeTargets(move,b,newTargets)
success = pbProcessMoveHit(move,b,newTargets,0,false)
b.lastMoveFailed = true if !success
targets.each { |b| b.pbFaint if b && b.fainted? }
targets.each { |otherB| otherB.pbFaint if otherB && otherB.fainted? }
user.pbFaint if user.fainted?
end
# Magic Coat's bouncing back (move has no targets)