mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-08 21:54:58 +00:00
Made various changes to effects, added some Gen 8 mechanics
This commit is contained in:
@@ -140,19 +140,31 @@ module Settings
|
||||
# If a move taught by a TM/HM/TR replaces another move, this setting is
|
||||
# whether the machine's move retains the replaced move's PP (true), or whether
|
||||
# the machine's move has full PP (false).
|
||||
TAUGHT_MACHINES_KEEP_OLD_PP = (MECHANICS_GENERATION == 5)
|
||||
TAUGHT_MACHINES_KEEP_OLD_PP = (MECHANICS_GENERATION == 5)
|
||||
# Whether the Black/White Flutes will raise/lower the levels of wild Pokémon
|
||||
# respectively (true), or will lower/raise the wild encounter rate
|
||||
# respectively (false).
|
||||
FLUTES_CHANGE_WILD_ENCOUNTER_LEVELS = (MECHANICS_GENERATION >= 6)
|
||||
FLUTES_CHANGE_WILD_ENCOUNTER_LEVELS = (MECHANICS_GENERATION >= 6)
|
||||
# Whether Repel uses the level of the first Pokémon in the party regardless of
|
||||
# its HP (true), or it uses the level of the first unfainted Pokémon (false).
|
||||
REPEL_COUNTS_FAINTED_POKEMON = (MECHANICS_GENERATION >= 6)
|
||||
REPEL_COUNTS_FAINTED_POKEMON = (MECHANICS_GENERATION >= 6)
|
||||
# Whether various HP-healing items heal the amounts they do in Gen 7+ (true)
|
||||
# or in earlier Generations (false).
|
||||
REBALANCED_HEALING_ITEM_AMOUNTS = (MECHANICS_GENERATION >= 7)
|
||||
# Whether Rage Candy Bar acts as a Full Heal (true) or a Potion (false).
|
||||
RAGE_CANDY_BAR_CURES_STATUS_PROBLEMS = (MECHANICS_GENERATION >= 7)
|
||||
RAGE_CANDY_BAR_CURES_STATUS_PROBLEMS = (MECHANICS_GENERATION >= 7)
|
||||
# Whether vitamins can add EVs no matter how many that stat already has in it
|
||||
# (true), or whether they can't make that stat's EVs greater than 100 (false).
|
||||
NO_VITAMIN_EV_CAP = (MECHANICS_GENERATION >= 8)
|
||||
# Whether Rare Candy can be used on a Pokémon that is already at its maximum
|
||||
# level if it is able to evolve by level-up (if so, triggers that evolution).
|
||||
RARE_CANDY_USABLE_AT_MAX_LEVEL = (MECHANICS_GENERATION >= 8)
|
||||
RARE_CANDY_USABLE_AT_MAX_LEVEL = (MECHANICS_GENERATION >= 8)
|
||||
# Whether you get 1 Premier Ball for every 10 of any kind of Poké Ball bought
|
||||
# at once (true), or 1 Premier Ball for buying 10+ Poké Balls (false).
|
||||
MORE_BONUS_PREMIER_BALLS = (MECHANICS_GENERATION >= 8)
|
||||
# Whether more abilities affect whether wild Pokémon appear, which Pokémon
|
||||
# they are, etc.
|
||||
MORE_ABILITIES_AFFECT_WILD_ENCOUNTERS = (MECHANICS_GENERATION >= 8)
|
||||
|
||||
#=============================================================================
|
||||
|
||||
|
||||
@@ -24,6 +24,9 @@ module Settings
|
||||
# Whether X items (X Attack, etc.) raise their stat by 2 stages (true) or 1
|
||||
# (false).
|
||||
X_STAT_ITEMS_RAISE_BY_TWO_STAGES = (MECHANICS_GENERATION >= 7)
|
||||
# Whether a Pokémon holding a Power item gains 8 (true) or 4 (false) EVs in
|
||||
# the relevant stat.
|
||||
MORE_EVS_FROM_POWER_ITEMS = (MECHANICS_GENERATION >= 7)
|
||||
# Whether some Poké Balls have catch rate multipliers from Gen 7 (true) or
|
||||
# from earlier generations (false).
|
||||
NEW_POKE_BALL_CATCH_RATES = (MECHANICS_GENERATION >= 7)
|
||||
|
||||
@@ -84,7 +84,7 @@ class PokeBattle_Battler
|
||||
end
|
||||
# Assault Vest (prevents choosing status moves but doesn't prevent
|
||||
# executing them)
|
||||
if hasActiveItem?(:ASSAULTVEST) && move.statusMove? && commandPhase
|
||||
if hasActiveItem?(:ASSAULTVEST) && move.statusMove? && move.id != :MEFIRST && commandPhase
|
||||
if showMessages
|
||||
msg = _INTL("The effects of the {1} prevent status moves from being used!",
|
||||
itemName)
|
||||
@@ -345,7 +345,7 @@ class PokeBattle_Battler
|
||||
@battle.successStates[user.index].protected = true
|
||||
if move.pbContactMove?(user) && user.affectedByContactEffect?
|
||||
if user.pbCanLowerStatStage?(:ATTACK)
|
||||
user.pbLowerStatStage(:ATTACK,2,nil)
|
||||
user.pbLowerStatStage(:ATTACK, (Settings::MECHANICS_GENERATION >= 8) ? 1 : 2, nil)
|
||||
end
|
||||
end
|
||||
return false
|
||||
|
||||
@@ -48,6 +48,7 @@ begin
|
||||
Ingrain = 42
|
||||
Instruct = 43
|
||||
Instructed = 44
|
||||
JawLock = 994
|
||||
KingsShield = 45
|
||||
LaserFocus = 46
|
||||
LeechSeed = 47
|
||||
|
||||
@@ -644,6 +644,7 @@ BattleHandlers::MoveImmunityTargetAbility.add(:SAPSIPPER,
|
||||
BattleHandlers::MoveImmunityTargetAbility.add(:SOUNDPROOF,
|
||||
proc { |ability,user,target,move,type,battle|
|
||||
next false if !move.soundMove?
|
||||
next false if Settings::MECHANICS_GENERATION >= 8 && user.index == target.index
|
||||
battle.pbShowAbilitySplash(target)
|
||||
if PokeBattle_SceneConstants::USE_ABILITY_SPLASH
|
||||
battle.pbDisplay(_INTL("It doesn't affect {1}...",target.pbThis(true)))
|
||||
@@ -1158,7 +1159,7 @@ BattleHandlers::DamageCalcTargetAbility.add(:FLOWERGIFT,
|
||||
BattleHandlers::DamageCalcTargetAbility.add(:FLUFFY,
|
||||
proc { |ability,user,target,move,mults,baseDmg,type|
|
||||
mults[:final_damage_multiplier] *= 2 if move.calcType == :FIRE
|
||||
mults[:final_damage_multiplier] /= 2 if move.contactMove?
|
||||
mults[:final_damage_multiplier] /= 2 if move.pbContactMove?
|
||||
}
|
||||
)
|
||||
|
||||
@@ -1940,9 +1941,16 @@ BattleHandlers::EOREffectAbility.add(:MOODY,
|
||||
proc { |ability,battler,battle|
|
||||
randomUp = []
|
||||
randomDown = []
|
||||
GameData::Stat.each_battle do |s|
|
||||
randomUp.push(s.id) if battler.pbCanRaiseStatStage?(s.id, battler)
|
||||
randomDown.push(s.id) if battler.pbCanLowerStatStage?(s.id, battler)
|
||||
if Settings::MECHANICS_GENERATION >= 8
|
||||
GameData::Stat.each_main_battle do |s|
|
||||
randomUp.push(s.id) if battler.pbCanRaiseStatStage?(s.id, battler)
|
||||
randomDown.push(s.id) if battler.pbCanLowerStatStage?(s.id, battler)
|
||||
end
|
||||
else
|
||||
GameData::Stat.each_battle do |s|
|
||||
randomUp.push(s.id) if battler.pbCanRaiseStatStage?(s.id, battler)
|
||||
randomDown.push(s.id) if battler.pbCanLowerStatStage?(s.id, battler)
|
||||
end
|
||||
end
|
||||
next if randomUp.length==0 && randomDown.length==0
|
||||
battle.pbShowAbilitySplash(battler)
|
||||
@@ -1964,7 +1972,8 @@ BattleHandlers::EOREffectAbility.add(:SPEEDBOOST,
|
||||
proc { |ability,battler,battle|
|
||||
# A Pokémon's turnCount is 0 if it became active after the beginning of a
|
||||
# round
|
||||
if battler.turnCount>0 && battler.pbCanRaiseStatStage?(:SPEED,battler)
|
||||
if battler.turnCount > 0 && battle.choices[battler.index][0] != :Run &&
|
||||
battler.pbCanRaiseStatStage?(:SPEED, battler)
|
||||
battler.pbRaiseStatStageByAbility(:SPEED,1,battler)
|
||||
end
|
||||
}
|
||||
@@ -2270,8 +2279,14 @@ BattleHandlers::AbilityOnSwitchIn.add(:INTIMIDATE,
|
||||
battle.pbShowAbilitySplash(battler)
|
||||
battle.eachOtherSideBattler(battler.index) do |b|
|
||||
next if !b.near?(battler)
|
||||
check_item = true
|
||||
if b.hasActiveAbility?(:CONTRARY)
|
||||
check_item = false if b.statStageAtMax?(:ATTACK)
|
||||
else
|
||||
check_item = false if b.statStageAtMin?(:ATTACK)
|
||||
end
|
||||
b.pbLowerAttackStatStageIntimidate(battler)
|
||||
b.pbItemOnIntimidatedCheck
|
||||
b.pbItemOnIntimidatedCheck if check_item
|
||||
end
|
||||
battle.pbHideAbilitySplash(battler)
|
||||
}
|
||||
@@ -2371,6 +2386,40 @@ BattleHandlers::AbilityOnSwitchIn.add(:UNNERVE,
|
||||
# AbilityOnSwitchOut handlers
|
||||
#===============================================================================
|
||||
|
||||
BattleHandlers::AbilityOnSwitchOut.add(:IMMUNITY,
|
||||
proc { |ability, battler, endOfBattle|
|
||||
next if battler.status != :POISON
|
||||
PBDebug.log("[Ability triggered] #{battler.pbThis}'s #{battler.abilityName}")
|
||||
battler.status = :NONE
|
||||
}
|
||||
)
|
||||
|
||||
BattleHandlers::AbilityOnSwitchOut.add(:INSOMNIA,
|
||||
proc { |ability, battler, endOfBattle|
|
||||
next if battler.status != :SLEEP
|
||||
PBDebug.log("[Ability triggered] #{battler.pbThis}'s #{battler.abilityName}")
|
||||
battler.status = :NONE
|
||||
}
|
||||
)
|
||||
|
||||
BattleHandlers::AbilityOnSwitchOut.copy(:INSOMNIA, :VITALSPIRIT)
|
||||
|
||||
BattleHandlers::AbilityOnSwitchOut.add(:LIMBER,
|
||||
proc { |ability, battler, endOfBattle|
|
||||
next if battler.status != :PARALYSIS
|
||||
PBDebug.log("[Ability triggered] #{battler.pbThis}'s #{battler.abilityName}")
|
||||
battler.status = :NONE
|
||||
}
|
||||
)
|
||||
|
||||
BattleHandlers::AbilityOnSwitchOut.add(:MAGMAARMOR,
|
||||
proc { |ability, battler, endOfBattle|
|
||||
next if battler.status != :FROZEN
|
||||
PBDebug.log("[Ability triggered] #{battler.pbThis}'s #{battler.abilityName}")
|
||||
battler.status = :NONE
|
||||
}
|
||||
)
|
||||
|
||||
BattleHandlers::AbilityOnSwitchOut.add(:NATURALCURE,
|
||||
proc { |ability,battler,endOfBattle|
|
||||
PBDebug.log("[Ability triggered] #{battler.pbThis}'s #{battler.abilityName}")
|
||||
@@ -2386,6 +2435,16 @@ BattleHandlers::AbilityOnSwitchOut.add(:REGENERATOR,
|
||||
}
|
||||
)
|
||||
|
||||
BattleHandlers::AbilityOnSwitchOut.add(:WATERVEIL,
|
||||
proc { |ability, battler, endOfBattle|
|
||||
next if battler.status != :BURN
|
||||
PBDebug.log("[Ability triggered] #{battler.pbThis}'s #{battler.abilityName}")
|
||||
battler.status = :NONE
|
||||
}
|
||||
)
|
||||
|
||||
BattleHandlers::AbilityOnSwitchOut.copy(:WATERVEIL, :WATERBUBBLE)
|
||||
|
||||
#===============================================================================
|
||||
# AbilityChangeOnBattlerFainting handlers
|
||||
#===============================================================================
|
||||
|
||||
@@ -30,19 +30,19 @@ class PokeBattle_AI
|
||||
# Item categories
|
||||
hpItems = {
|
||||
:POTION => 20,
|
||||
:SUPERPOTION => 50,
|
||||
:HYPERPOTION => 200,
|
||||
:SUPERPOTION => (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 60 : 50,
|
||||
:HYPERPOTION => (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 120 : 200,
|
||||
:MAXPOTION => 999,
|
||||
:BERRYJUICE => 20,
|
||||
:SWEETHEART => 20,
|
||||
:FRESHWATER => 50,
|
||||
:SODAPOP => 60,
|
||||
:LEMONADE => 80,
|
||||
:FRESHWATER => (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 30 : 50,
|
||||
:SODAPOP => (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 50 : 60,
|
||||
:LEMONADE => (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 70 : 80,
|
||||
:MOOMOOMILK => 100,
|
||||
:ORANBERRY => 10,
|
||||
:SITRUSBERRY => battler.totalhp/4,
|
||||
:ENERGYPOWDER => 50,
|
||||
:ENERGYROOT => 200
|
||||
:ENERGYPOWDER => (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 60 : 50,
|
||||
:ENERGYROOT => (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 120 : 200
|
||||
}
|
||||
hpItems[:RAGECANDYBAR] = 20 if !Settings::RAGE_CANDY_BAR_CURES_STATUS_PROBLEMS
|
||||
fullRestoreItems = [
|
||||
|
||||
@@ -1356,37 +1356,37 @@ BattleHandlers::EVGainModifierItem.add(:MACHOBRACE,
|
||||
|
||||
BattleHandlers::EVGainModifierItem.add(:POWERANKLET,
|
||||
proc { |item,battler,evYield|
|
||||
evYield[:SPEED] += 4
|
||||
evYield[:SPEED] += (Settings::MORE_EVS_FROM_POWER_ITEMS) ? 8 : 4
|
||||
}
|
||||
)
|
||||
|
||||
BattleHandlers::EVGainModifierItem.add(:POWERBAND,
|
||||
proc { |item,battler,evYield|
|
||||
evYield[:SPECIAL_DEFENSE] += 4
|
||||
evYield[:SPECIAL_DEFENSE] += (Settings::MORE_EVS_FROM_POWER_ITEMS) ? 8 : 4
|
||||
}
|
||||
)
|
||||
|
||||
BattleHandlers::EVGainModifierItem.add(:POWERBELT,
|
||||
proc { |item,battler,evYield|
|
||||
evYield[:DEFENSE] += 4
|
||||
evYield[:DEFENSE] += (Settings::MORE_EVS_FROM_POWER_ITEMS) ? 8 : 4
|
||||
}
|
||||
)
|
||||
|
||||
BattleHandlers::EVGainModifierItem.add(:POWERBRACER,
|
||||
proc { |item,battler,evYield|
|
||||
evYield[:ATTACK] += 4
|
||||
evYield[:ATTACK] += (Settings::MORE_EVS_FROM_POWER_ITEMS) ? 8 : 4
|
||||
}
|
||||
)
|
||||
|
||||
BattleHandlers::EVGainModifierItem.add(:POWERLENS,
|
||||
proc { |item,battler,evYield|
|
||||
evYield[:SPECIAL_ATTACK] += 4
|
||||
evYield[:SPECIAL_ATTACK] += (Settings::MORE_EVS_FROM_POWER_ITEMS) ? 8 : 4
|
||||
}
|
||||
)
|
||||
|
||||
BattleHandlers::EVGainModifierItem.add(:POWERWEIGHT,
|
||||
proc { |item,battler,evYield|
|
||||
evYield[:HP] += 4
|
||||
evYield[:HP] += (Settings::MORE_EVS_FROM_POWER_ITEMS) ? 8 : 4
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
@@ -121,7 +121,7 @@ BallHandlers::ModifyCatchRate.add(:LUREBALL,proc { |ball,catchRate,battle,battle
|
||||
|
||||
BallHandlers::ModifyCatchRate.add(:HEAVYBALL,proc { |ball,catchRate,battle,battler,ultraBeast|
|
||||
next 0 if catchRate==0
|
||||
weight = battler.pbWeight
|
||||
weight = battler.pokemon.species_data.base_stats[:SPEED]
|
||||
if Settings::NEW_POKE_BALL_CATCH_RATES
|
||||
if weight>=3000; catchRate += 30
|
||||
elsif weight>=2000; catchRate += 20
|
||||
@@ -164,7 +164,7 @@ BallHandlers::ModifyCatchRate.add(:SPORTBALL,proc { |ball,catchRate,battle,battl
|
||||
})
|
||||
|
||||
BallHandlers::ModifyCatchRate.add(:DREAMBALL,proc { |ball,catchRate,battle,battler,ultraBeast|
|
||||
catchRate *= 4 if battler.status == :SLEEP
|
||||
catchRate *= 4 if battler.asleep?
|
||||
next catchRate
|
||||
})
|
||||
|
||||
|
||||
@@ -137,6 +137,11 @@ class PokemonEncounters
|
||||
when :STENCH, :WHITESMOKE, :QUICKFEET
|
||||
encounter_chance /= 2
|
||||
min_steps_needed *= 2
|
||||
when :INFILTRATOR
|
||||
if Settings::MORE_ABILITIES_AFFECT_WILD_ENCOUNTERS
|
||||
encounter_chance /= 2
|
||||
min_steps_needed *= 2
|
||||
end
|
||||
when :SNOWCLOAK
|
||||
if GameData::Weather.get($game_screen.weather_type).category == :Hail
|
||||
encounter_chance /= 2
|
||||
@@ -271,10 +276,26 @@ class PokemonEncounters
|
||||
if first_pkmn
|
||||
favored_type = nil
|
||||
case first_pkmn.ability_id
|
||||
when :STATIC
|
||||
favored_type = :ELECTRIC if GameData::Type.exists?(:ELECTRIC) && rand(100) < 50
|
||||
when :FLASHFIRE
|
||||
if Settings::MORE_ABILITIES_AFFECT_WILD_ENCOUNTERS
|
||||
favored_type = :FIRE if GameData::Type.exists?(:FIRE) && rand(100) < 50
|
||||
end
|
||||
when :HARVEST
|
||||
if Settings::MORE_ABILITIES_AFFECT_WILD_ENCOUNTERS
|
||||
favored_type = :GRASS if GameData::Type.exists?(:GRASS) && rand(100) < 50
|
||||
end
|
||||
when :LIGHTNINGROD
|
||||
if Settings::MORE_ABILITIES_AFFECT_WILD_ENCOUNTERS
|
||||
favored_type = :ELECTRIC if GameData::Type.exists?(:ELECTRIC) && rand(100) < 50
|
||||
end
|
||||
when :MAGNETPULL
|
||||
favored_type = :STEEL if GameData::Type.exists?(:STEEL) && rand(100) < 50
|
||||
when :STATIC
|
||||
favored_type = :ELECTRIC if GameData::Type.exists?(:ELECTRIC) && rand(100) < 50
|
||||
when :STORMDRAIN
|
||||
if Settings::MORE_ABILITIES_AFFECT_WILD_ENCOUNTERS
|
||||
favored_type = :WATER if GameData::Type.exists?(:WATER) && rand(100) < 50
|
||||
end
|
||||
end
|
||||
if favored_type
|
||||
new_enc_list = []
|
||||
@@ -374,7 +395,14 @@ def pbGenerateWildPokemon(species,level,isRoamer=false)
|
||||
items = genwildpoke.wildHoldItems
|
||||
first_pkmn = $Trainer.first_pokemon
|
||||
chances = [50,5,1]
|
||||
chances = [60,20,5] if first_pkmn && first_pkmn.hasAbility?(:COMPOUNDEYES)
|
||||
if first_pkmn
|
||||
case first_pkmn.ability_id
|
||||
when :COMPOUNDEYES
|
||||
chances = [60, 20, 5]
|
||||
when :SUPERLUCK
|
||||
chances = [60, 20, 5] if Settings::MORE_ABILITIES_AFFECT_WILD_ENCOUNTERS
|
||||
end
|
||||
end
|
||||
itemrnd = rand(100)
|
||||
if (items[0]==items[1] && items[1]==items[2]) || itemrnd<chances[0]
|
||||
genwildpoke.item = items[0]
|
||||
@@ -402,7 +430,9 @@ def pbGenerateWildPokemon(species,level,isRoamer=false)
|
||||
(rand(3)<2) ? genwildpoke.makeMale : genwildpoke.makeFemale
|
||||
end
|
||||
elsif first_pkmn.hasAbility?(:SYNCHRONIZE)
|
||||
genwildpoke.nature = first_pkmn.nature if !isRoamer && rand(100)<50
|
||||
if !isRoamer && (Settings::MORE_ABILITIES_AFFECT_WILD_ENCOUNTERS || (rand(100) < 50))
|
||||
genwildpoke.nature = first_pkmn.nature
|
||||
end
|
||||
end
|
||||
end
|
||||
# Trigger events that may alter the generated Pokémon further
|
||||
|
||||
@@ -373,13 +373,13 @@ def pbJustRaiseEffortValues(pkmn, stat, evGain)
|
||||
return evGain
|
||||
end
|
||||
|
||||
def pbRaiseEffortValues(pkmn, stat, evGain = 10, ev_limit = true)
|
||||
def pbRaiseEffortValues(pkmn, stat, evGain = 10, no_ev_cap = false)
|
||||
stat = GameData::Stat.get(stat).id
|
||||
return 0 if ev_limit && pkmn.ev[stat] >= 100
|
||||
return 0 if !no_ev_cap && pkmn.ev[stat] >= 100
|
||||
evTotal = 0
|
||||
GameData::Stat.each_main { |s| evTotal += pkmn.ev[s.id] }
|
||||
evGain = evGain.clamp(0, Pokemon::EV_STAT_LIMIT - pkmn.ev[stat])
|
||||
evGain = evGain.clamp(0, 100 - pkmn.ev[stat]) if ev_limit
|
||||
evGain = evGain.clamp(0, 100 - pkmn.ev[stat]) if !no_ev_cap
|
||||
evGain = evGain.clamp(0, Pokemon::EV_LIMIT - evTotal)
|
||||
if evGain > 0
|
||||
pkmn.ev[stat] += evGain
|
||||
|
||||
@@ -28,7 +28,7 @@ ItemHandlers::UseFromBag.add(:ESCAPEROPE,proc { |item|
|
||||
next 0
|
||||
end
|
||||
if ($PokemonGlobal.escapePoint rescue false) && $PokemonGlobal.escapePoint.length>0
|
||||
next 4 # End screen and consume item
|
||||
next (GameData::Item.get(item).is_key_item?) ? 2 : 4 # End screen and use item
|
||||
end
|
||||
pbMessage(_INTL("Can't use that here."))
|
||||
next 0
|
||||
@@ -177,7 +177,7 @@ ItemHandlers::UseInField.add(:ESCAPEROPE,proc { |item|
|
||||
$game_map.refresh
|
||||
}
|
||||
pbEraseEscapePoint
|
||||
next 3
|
||||
next (GameData::Item.get(item).is_key_item?) ? 1 : 3
|
||||
})
|
||||
|
||||
ItemHandlers::UseInField.add(:SACREDASH,proc { |item|
|
||||
@@ -366,11 +366,11 @@ ItemHandlers::UseOnPokemon.copy(:POTION,:BERRYJUICE,:SWEETHEART)
|
||||
ItemHandlers::UseOnPokemon.copy(:POTION,:RAGECANDYBAR) if !Settings::RAGE_CANDY_BAR_CURES_STATUS_PROBLEMS
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:SUPERPOTION,proc { |item,pkmn,scene|
|
||||
next pbHPItem(pkmn,50,scene)
|
||||
next pbHPItem(pkmn, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 60 : 50, scene)
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:HYPERPOTION,proc { |item,pkmn,scene|
|
||||
next pbHPItem(pkmn,200,scene)
|
||||
next pbHPItem(pkmn, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 120 : 200, scene)
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:MAXPOTION,proc { |item,pkmn,scene|
|
||||
@@ -378,15 +378,15 @@ ItemHandlers::UseOnPokemon.add(:MAXPOTION,proc { |item,pkmn,scene|
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:FRESHWATER,proc { |item,pkmn,scene|
|
||||
next pbHPItem(pkmn,50,scene)
|
||||
next pbHPItem(pkmn, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 30 : 50, scene)
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:SODAPOP,proc { |item,pkmn,scene|
|
||||
next pbHPItem(pkmn,60,scene)
|
||||
next pbHPItem(pkmn, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 50 : 60, scene)
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:LEMONADE,proc { |item,pkmn,scene|
|
||||
next pbHPItem(pkmn,80,scene)
|
||||
next pbHPItem(pkmn, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 70 : 80, scene)
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:MOOMOOMILK,proc { |item,pkmn,scene|
|
||||
@@ -524,7 +524,7 @@ ItemHandlers::UseOnPokemon.add(:MAXREVIVE,proc { |item,pkmn,scene|
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:ENERGYPOWDER,proc { |item,pkmn,scene|
|
||||
if pbHPItem(pkmn,50,scene)
|
||||
if pbHPItem(pkmn, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 60 : 50, scene)
|
||||
pkmn.changeHappiness("powder")
|
||||
next true
|
||||
end
|
||||
@@ -532,7 +532,7 @@ ItemHandlers::UseOnPokemon.add(:ENERGYPOWDER,proc { |item,pkmn,scene|
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:ENERGYROOT,proc { |item,pkmn,scene|
|
||||
if pbHPItem(pkmn,200,scene)
|
||||
if pbHPItem(pkmn, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 120 : 200, scene)
|
||||
pkmn.changeHappiness("energyroot")
|
||||
next true
|
||||
end
|
||||
@@ -645,7 +645,7 @@ ItemHandlers::UseOnPokemon.add(:PPMAX,proc { |item,pkmn,scene|
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:HPUP,proc { |item,pkmn,scene|
|
||||
if pbRaiseEffortValues(pkmn,:HP)==0
|
||||
if pbRaiseEffortValues(pkmn, :HP, 10, Settings::NO_VITAMIN_EV_CAP) == 0
|
||||
scene.pbDisplay(_INTL("It won't have any effect."))
|
||||
next false
|
||||
end
|
||||
@@ -656,7 +656,7 @@ ItemHandlers::UseOnPokemon.add(:HPUP,proc { |item,pkmn,scene|
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:PROTEIN,proc { |item,pkmn,scene|
|
||||
if pbRaiseEffortValues(pkmn,:ATTACK)==0
|
||||
if pbRaiseEffortValues(pkmn, :ATTACK, 10, Settings::NO_VITAMIN_EV_CAP) == 0
|
||||
scene.pbDisplay(_INTL("It won't have any effect."))
|
||||
next false
|
||||
end
|
||||
@@ -666,7 +666,7 @@ ItemHandlers::UseOnPokemon.add(:PROTEIN,proc { |item,pkmn,scene|
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:IRON,proc { |item,pkmn,scene|
|
||||
if pbRaiseEffortValues(pkmn,:DEFENSE)==0
|
||||
if pbRaiseEffortValues(pkmn, :DEFENSE, 10, Settings::NO_VITAMIN_EV_CAP) == 0
|
||||
scene.pbDisplay(_INTL("It won't have any effect."))
|
||||
next false
|
||||
end
|
||||
@@ -676,7 +676,7 @@ ItemHandlers::UseOnPokemon.add(:IRON,proc { |item,pkmn,scene|
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:CALCIUM,proc { |item,pkmn,scene|
|
||||
if pbRaiseEffortValues(pkmn,:SPECIAL_ATTACK)==0
|
||||
if pbRaiseEffortValues(pkmn, :SPECIAL_ATTACK, 10, Settings::NO_VITAMIN_EV_CAP) == 0
|
||||
scene.pbDisplay(_INTL("It won't have any effect."))
|
||||
next false
|
||||
end
|
||||
@@ -686,7 +686,7 @@ ItemHandlers::UseOnPokemon.add(:CALCIUM,proc { |item,pkmn,scene|
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:ZINC,proc { |item,pkmn,scene|
|
||||
if pbRaiseEffortValues(pkmn,:SPECIAL_DEFENSE)==0
|
||||
if pbRaiseEffortValues(pkmn, :SPECIAL_DEFENSE, 10, Settings::NO_VITAMIN_EV_CAP) == 0
|
||||
scene.pbDisplay(_INTL("It won't have any effect."))
|
||||
next false
|
||||
end
|
||||
@@ -696,7 +696,7 @@ ItemHandlers::UseOnPokemon.add(:ZINC,proc { |item,pkmn,scene|
|
||||
})
|
||||
|
||||
ItemHandlers::UseOnPokemon.add(:CARBOS,proc { |item,pkmn,scene|
|
||||
if pbRaiseEffortValues(pkmn,:SPEED)==0
|
||||
if pbRaiseEffortValues(pkmn, :SPEED, 10, Settings::NO_VITAMIN_EV_CAP) == 0
|
||||
scene.pbDisplay(_INTL("It won't have any effect."))
|
||||
next false
|
||||
end
|
||||
|
||||
@@ -323,11 +323,11 @@ ItemHandlers::BattleUseOnPokemon.copy(:POTION,:BERRYJUICE,:SWEETHEART)
|
||||
ItemHandlers::BattleUseOnPokemon.copy(:POTION,:RAGECANDYBAR) if !Settings::RAGE_CANDY_BAR_CURES_STATUS_PROBLEMS
|
||||
|
||||
ItemHandlers::BattleUseOnPokemon.add(:SUPERPOTION,proc { |item,pokemon,battler,choices,scene|
|
||||
pbBattleHPItem(pokemon,battler,50,scene)
|
||||
pbBattleHPItem(pokemon, battler, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 60 : 50, scene)
|
||||
})
|
||||
|
||||
ItemHandlers::BattleUseOnPokemon.add(:HYPERPOTION,proc { |item,pokemon,battler,choices,scene|
|
||||
pbBattleHPItem(pokemon,battler,200,scene)
|
||||
pbBattleHPItem(pokemon, battler, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 120 : 200, scene)
|
||||
})
|
||||
|
||||
ItemHandlers::BattleUseOnPokemon.add(:MAXPOTION,proc { |item,pokemon,battler,choices,scene|
|
||||
@@ -335,15 +335,15 @@ ItemHandlers::BattleUseOnPokemon.add(:MAXPOTION,proc { |item,pokemon,battler,cho
|
||||
})
|
||||
|
||||
ItemHandlers::BattleUseOnPokemon.add(:FRESHWATER,proc { |item,pokemon,battler,choices,scene|
|
||||
pbBattleHPItem(pokemon,battler,50,scene)
|
||||
pbBattleHPItem(pokemon, battler, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 30 : 50, scene)
|
||||
})
|
||||
|
||||
ItemHandlers::BattleUseOnPokemon.add(:SODAPOP,proc { |item,pokemon,battler,choices,scene|
|
||||
pbBattleHPItem(pokemon,battler,60,scene)
|
||||
pbBattleHPItem(pokemon, battler, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 50 : 60, scene)
|
||||
})
|
||||
|
||||
ItemHandlers::BattleUseOnPokemon.add(:LEMONADE,proc { |item,pokemon,battler,choices,scene|
|
||||
pbBattleHPItem(pokemon,battler,80,scene)
|
||||
pbBattleHPItem(pokemon, battler, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 70 : 80, scene)
|
||||
})
|
||||
|
||||
ItemHandlers::BattleUseOnPokemon.add(:MOOMOOMILK,proc { |item,pokemon,battler,choices,scene|
|
||||
@@ -451,13 +451,13 @@ ItemHandlers::BattleUseOnPokemon.add(:MAXREVIVE,proc { |item,pokemon,battler,cho
|
||||
})
|
||||
|
||||
ItemHandlers::BattleUseOnPokemon.add(:ENERGYPOWDER,proc { |item,pokemon,battler,choices,scene|
|
||||
if pbBattleHPItem(pokemon,battler,50,scene)
|
||||
if pbBattleHPItem(pokemon, battler, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 60 : 50, scene)
|
||||
pokemon.changeHappiness("powder")
|
||||
end
|
||||
})
|
||||
|
||||
ItemHandlers::BattleUseOnPokemon.add(:ENERGYROOT,proc { |item,pokemon,battler,choices,scene|
|
||||
if pbBattleHPItem(pokemon,battler,200,scene)
|
||||
if pbBattleHPItem(pokemon, battler, (Settings::REBALANCED_HEALING_ITEM_AMOUNTS) ? 120 : 200, scene)
|
||||
pokemon.changeHappiness("energyroot")
|
||||
end
|
||||
})
|
||||
|
||||
@@ -594,8 +594,19 @@ class PokemonMartScreen
|
||||
end
|
||||
@stock.compact!
|
||||
pbDisplayPaused(_INTL("Here you are! Thank you!")) { pbSEPlay("Mart buy item") }
|
||||
if $PokemonBag
|
||||
if quantity>=10 && GameData::Item.get(item).is_poke_ball? && GameData::Item.exists?(:PREMIERBALL)
|
||||
if quantity >= 10 && $PokemonBag && GameData::Item.exists?(:PREMIERBALL)
|
||||
if Settings::MORE_BONUS_PREMIER_BALLS && GameData::Item.get(item).is_poke_ball?
|
||||
premier_balls_added = 0
|
||||
(quantity / 10).times do
|
||||
break if !@adapter.addItem(:PREMIERBALL)
|
||||
premier_balls_added += 1
|
||||
end
|
||||
if premier_balls_added > 1
|
||||
pbDisplayPaused(_INTL("I'll throw in some {1}, too.", GameData::Item.get(:PREMIERBALL).name_plural))
|
||||
elsif premier_balls_added > 0
|
||||
pbDisplayPaused(_INTL("I'll throw in a {1}, too.", GameData::Item.get(:PREMIERBALL).name))
|
||||
end
|
||||
elsif !Settings::MORE_BONUS_PREMIER_BALLS && GameData::Item.get(item) == :POKEBALL
|
||||
if @adapter.addItem(GameData::Item.get(:PREMIERBALL))
|
||||
pbDisplayPaused(_INTL("I'll throw in a Premier Ball, too."))
|
||||
end
|
||||
|
||||
@@ -8,11 +8,78 @@ The game records, for each species, how many have been caught or defeated
|
||||
(counts both wild and trainer battles), and the shiny chance increases for that
|
||||
species because of this. This value is also shown in the Pokédex entry screen.
|
||||
|
||||
Some moves have changed properties/effects.
|
||||
Some moves have changed properties/effects:
|
||||
- Multi-Attack's power changed to 120.
|
||||
- Rapid Spin's power changed to 50, and it now raises the user's Speed by 1
|
||||
stage (100% additional effect chance).
|
||||
- Howl's target changed to UserAndAllies, and is now a sound move. It is now
|
||||
blocked by Soundproof (I don't know if it should be checking the allies for
|
||||
pbImmunityByAbility, but leaning towards yes; will Volt Absorb block an
|
||||
Electrified Howl?).
|
||||
- Vice Grip renamed to Vise Grip.
|
||||
- Teleport switches the user out. If the user is a wild Pokémon, ends the battle
|
||||
instead.
|
||||
- Curse's Ghost effect now targets a random foe (don't know if it can be non-
|
||||
adjacent); the target cannot be chosen by the player (it appears to target the
|
||||
user).
|
||||
- Look at the moves Nature Power turns into.
|
||||
- Healing Wish's effect and Lunar Dance's effect are no longer used up if a
|
||||
Pokémon that switches to the targeted position can't make use of it. Each
|
||||
position can only have one of each effect applied at once.
|
||||
- Multiple Quashed Pokémon now move in order from fastest to slowest, rather
|
||||
than the order in which they were Quashed.
|
||||
- Parting Shot is able to make the user switch out if its effect is redirected
|
||||
by Mirror Armor. Throat Spray is triggered and applies before the switch.
|
||||
- Terrains have altered/additional effects.
|
||||
- Double Iron Bash no longer has a different effect if the target is Minimized.
|
||||
|
||||
Some abilities have changed effects:
|
||||
- Oblivious, Own Tempo, Inner Focus and Scrappy now block Intimidate.
|
||||
- Intimidate now triggers Rattled.
|
||||
- If Unburden is negated by Neutralizing Gas, Unburden's effect stops applying.
|
||||
If Neutralizing Gas then leaves the field, Unburden's boost returns.
|
||||
- If another Pokémon faints before a Pokémon with Analytic makes its move,
|
||||
Analytic calculates whether it would have moved before or after the fainted
|
||||
Pokémon. In Gen 8, speed- and priority-modifying effects aren't considered,
|
||||
but in earlier Gens they are.
|
||||
- Disguise now reduces the damage taken to 1/8, rather than to 0.
|
||||
|
||||
Some items have changed properties/effects:
|
||||
- Zygarde Cube now changes a Zygarde's ability.
|
||||
- Ability Capsule/Ability Patch fail if used on Zygarde.
|
||||
- If Leppa Berry is forced to be consumed, it will first try to work on a move
|
||||
with 0 PP left (preferring the earliest such move in the list of moves), and
|
||||
failing that, the earliest move in the list of moves which has any PP missing
|
||||
(no matter how much).
|
||||
- Ensure that Choice items cause different moves to fail (without subtracting
|
||||
PP) if they were forced to be used by Instruct/Dancer.
|
||||
- Iron Ball shouldn't modify the effectiveness of Ground moves against a Flying
|
||||
holder if the holder is grounded by another effect that isn't Iron Ball.
|
||||
|
||||
Other notes:
|
||||
- In Gen 7+, Shaymin/Hoopa revert their form when withdrawn from storage rather
|
||||
than when deposited. It still also reverts under other conditions. Shaymin
|
||||
reverts its form when deposited in the Day Care (all Gens).
|
||||
- Look at Sweet Scent's out of battle effect, namely whether it should try to
|
||||
cause a horde battle (and what does that mean in Essentials?).
|
||||
- Maybe have multiple sets of Pickup items for multiple Gens.
|
||||
- Dive Ball should have an increased catch rate if surfing or fishing(?).
|
||||
- Add a newer type of berry tree mechanics? Have a separate setting that
|
||||
prevents deterioration?
|
||||
- King's Rock/Razor Fang should probably stop using a flag to determine if a
|
||||
move is boosted by it, and instead check def flinchingMove?.
|
||||
- Skipped looking at TMs and HMs.
|
||||
- If a battle ends because of Rocky Helmet damage, the side that the Rocky
|
||||
Helmet holder is on should lose (Gen 7+) or win (Gen 6-).
|
||||
- Maybe the N-Solarizer/N-Lunarizer/that other fusion item that changes
|
||||
descriptions should actually be two items each (one that combines, one that
|
||||
splits) and they alternate upon use. No reasonable game would have multiple
|
||||
sets of Pokémon to fuse at once, so allowing just one of each fusion at a time
|
||||
is probably fine.
|
||||
|
||||
Can use Fly from within the Town Map if possible. (Good QoL, add if possible.)
|
||||
|
||||
Example event that combines the Gen 8 fossils.
|
||||
Make example event that combines the Gen 8 fossils.
|
||||
|
||||
New evolution methods:
|
||||
- Galarian Farfetch'd: performing 3 critical hits in a single battle
|
||||
@@ -25,7 +92,7 @@ PBS file data:
|
||||
- Aegislash's stats changed.
|
||||
- 2 existing Pokémon gained new abilities.
|
||||
- Vice Grip becomes Vise Grip.
|
||||
- Some items change names (Stick -> Leek, etc.).
|
||||
- Some items change names (Stick -> Leek, Bicycle -> Bike in Gen 6+, etc.).
|
||||
|
||||
Add AI for new moves/items/abilities.
|
||||
|
||||
@@ -74,4 +141,8 @@ New evolution methods:
|
||||
- Kubfu (triggered by an event; Kubfu's form can be set beforehand by the event,
|
||||
so don't worry about the multiple forms it can evolve into)
|
||||
|
||||
Escape Rope's code now supports both consumable and non-consumable versions,
|
||||
depending on whether it is a key item. All it needs is a proper definition in
|
||||
items.txt.
|
||||
|
||||
=end
|
||||
|
||||
Reference in New Issue
Block a user