mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-08 13:44:59 +00:00
Merge branch 'master' into dev
This commit is contained in:
@@ -119,6 +119,7 @@ class PokeBattle_Battler
|
||||
def statusCount=(value)
|
||||
@statusCount = value
|
||||
@pokemon.statusCount = value if @pokemon
|
||||
@battle.scene.pbRefreshOne(@index)
|
||||
end
|
||||
|
||||
#=============================================================================
|
||||
|
||||
@@ -48,7 +48,7 @@ class PokeBattle_Move_003 < PokeBattle_SleepMove
|
||||
return if @id != :RELICSONG
|
||||
return if !user.isSpecies?(:MELOETTA)
|
||||
return if user.hasActiveAbility?(:SHEERFORCE) && @addlEffect>0
|
||||
newForm = (oldForm+1)%2
|
||||
newForm = (user.Form+1)%2
|
||||
user.pbChangeForm(newForm,_INTL("{1} transformed!",user.pbThis))
|
||||
end
|
||||
end
|
||||
|
||||
@@ -3019,7 +3019,7 @@ class PokeBattle_Move_0EB < PokeBattle_Move
|
||||
next if b.fainted? || b.damageState.unaffected || switchedBattlers.include?(b.index)
|
||||
newPkmn = @battle.pbGetReplacementPokemonIndex(b.index,true) # Random
|
||||
next if newPkmn<0
|
||||
@battle.pbRecallAndReplace(b.index,newPkmn)
|
||||
@battle.pbRecallAndReplace(b.index, newPkmn, true)
|
||||
@battle.pbDisplay(_INTL("{1} was dragged out!",b.pbThis))
|
||||
@battle.pbClearChoice(b.index) # Replacement Pokémon does nothing this round
|
||||
switchedBattlers.push(b.index)
|
||||
@@ -3061,7 +3061,7 @@ class PokeBattle_Move_0EC < PokeBattle_Move
|
||||
next if b.hasActiveAbility?(:SUCTIONCUPS) && !@battle.moldBreaker
|
||||
newPkmn = @battle.pbGetReplacementPokemonIndex(b.index,true) # Random
|
||||
next if newPkmn<0
|
||||
@battle.pbRecallAndReplace(b.index,newPkmn)
|
||||
@battle.pbRecallAndReplace(b.index, newPkmn, true)
|
||||
@battle.pbDisplay(_INTL("{1} was dragged out!",b.pbThis))
|
||||
@battle.pbClearChoice(b.index) # Replacement Pokémon does nothing this round
|
||||
switchedBattlers.push(b.index)
|
||||
@@ -3098,7 +3098,7 @@ class PokeBattle_Move_0ED < PokeBattle_Move
|
||||
return if user.fainted?
|
||||
newPkmn = @battle.pbGetReplacementPokemonIndex(user.index) # Owner chooses
|
||||
return if newPkmn<0
|
||||
@battle.pbRecallAndReplace(user.index,newPkmn,true)
|
||||
@battle.pbRecallAndReplace(user.index, newPkmn, false, true)
|
||||
@battle.pbClearChoice(user.index) # Replacement Pokémon does nothing this round
|
||||
@battle.moldBreaker = false
|
||||
switchedBattlers.push(user.index)
|
||||
|
||||
@@ -223,11 +223,11 @@ class PokeBattle_Battle
|
||||
end
|
||||
|
||||
# Actually performs the recalling and sending out in all situations.
|
||||
def pbRecallAndReplace(idxBattler,idxParty,batonPass=false)
|
||||
def pbRecallAndReplace(idxBattler,idxParty,randomReplacement=false,batonPass=false)
|
||||
@scene.pbRecall(idxBattler) if !@battlers[idxBattler].fainted?
|
||||
@battlers[idxBattler].pbAbilitiesOnSwitchOut # Inc. primordial weather check
|
||||
@scene.pbShowPartyLineup(idxBattler&1) if pbSideSize(idxBattler)==1
|
||||
pbMessagesOnReplace(idxBattler,idxParty)
|
||||
pbMessagesOnReplace(idxBattler,idxParty) if !randomReplacement
|
||||
pbReplace(idxBattler,idxParty,batonPass)
|
||||
end
|
||||
|
||||
|
||||
@@ -1238,7 +1238,7 @@ BattleHandlers::TargetItemAfterMoveUse.add(:REDCARD,
|
||||
battle.pbDisplay(_INTL("{1} held up its {2} against {3}!",
|
||||
battler.pbThis,battler.itemName,user.pbThis(true)))
|
||||
battler.pbConsumeItem
|
||||
battle.pbRecallAndReplace(user.index,newPkmn)
|
||||
battle.pbRecallAndReplace(user.index, newPkmn, true)
|
||||
battle.pbDisplay(_INTL("{1} was dragged out!",user.pbThis))
|
||||
battle.pbClearChoice(user.index) # Replacement Pokémon does nothing this round
|
||||
switched.push(user.index)
|
||||
|
||||
Reference in New Issue
Block a user