• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
  • Our weekly protagonist poll is now up! Vote for your favorite Conquest protagonist in the poll by clicking here.
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

[Essentials v17.2] Gen 8 stuffs (Abilities, Items & Move)

Unfortunately, this will be hard because we won't know if the abilities were before activated while no Pokémon with Neutralizing Gas existed in the battle. I tried to do that but it gave errors and that require heavy edition to make that working

Oh, well, that's right. I won't say anything else, because I don't know so much about scripting and I couldn't figure out a good way in order to help to achieve that, but thank you for your time.
Anyway, could you show me where you put this in your scripts, please?
Next, find where Delta Stream ability code exists. Now we add this after the strong winds weather initialization with DeltaStream:
Code:
      # Neutralizing Gas
      if self.hasWorkingAbility(:NEUTRALIZINGGAS) && [email protected][PBEffects::NeutralizingGas]  # Not hasWorkingAbility (We need to be workable even if other abilities supressed)
        @battle.field.effects[PBEffects::NeutralizingGas]=true
        PBDebug.log("[Ability triggered] #{pbThis}'s Neutralizing Gas started")
      end

I know you wrote "after the strong winds weather initialization with DeltaStream", but I'm pretty sure that I didn't paste the script in the right place (I just put it below Delta Stream's script). I'd like knowing what text is before and after that part of the script.
Thanks.
 
Hello!
I just came here to mention that the Gulp Missile ability code shown in this thread is actually wrong, I don't know how to fix it, but Ill mention the things that it doesnt have.

Gulp Missile triggers from the first turn of Dive even if the second turn doesn't happen (if Surf is fully blocked it doesn't trigger)
Gulp Missile's Arrokuda projectile deals 1/4 max HP damage and lowers the target's Defense 1 stage
Gulp Missile's Pikachu projectile deals 1/4 max HP damage and paralyzes the target (even Ground types)
Gulp Missile fires the projectile even if Cramorant gets knocked out
Gulp Missile's have types, Arrokuda is water type, Pikachu is Electric type, but it seems to only consider Super Effective damage, not Resisted
So Pikachu does 2/4 to water and flying, but still hit 1/4 to every other type
So Arrokuda does 2/4 towards rock and ground (unsure how it works against a rock/ground mon tho sorry), but does 1/4 against everything else.
 
EDIT 02/22:
My Ice Scales was added in the same place than Heat Proof:
In 'PokeBattle_Move', find Heat Proof's code and paste inside 'if !attacker.hasMoldBreaker', like:
Spoiler:
 
Last edited:
Steely Spirit:
In 'PokeBattle_Move' script, paste above ' if attacker.hasWorkingItem(:THICKCLUB) &&':
Code:
    if attacker.pbPartner.hasWorkingAbility(:STEELYSPIRIT) && isConst?(type,PBTypes,:STEEL)
      atkmult=(atkmult*1.5).round
    end
    if attacker.hasWorkingItem(:THICKCLUB) &&
       (isConst?(attacker.species,PBSpecies,:CUBONE) ||
       isConst?(attacker.species,PBSpecies,:MAROWAK)) && pbIsPhysical?(type)
      atkmult=(atkmult*2.0).round
    end
    if attacker.hasWorkingItem(:DEEPSEATOOTH) &&
 
Last edited:
Gorilla Tactics:
In ability txt, the info for:
XXX,GORILLATACTICS,Gorilla Tactics,"Boosts the Pokémon's Attack stat but only allows the use of the first selected move."

In 'PBEffects' add a new effect for, inside ' ############# These effects apply to a battler' (XXX will be your last number):
Code:
    GorillaTactics     = XXX
    
    ############################################################################
    # These effects apply to a side
    CraftyShield       = 0

In 'PokeBattle_Battler' script, add a new effect for, inside 'def pbInitEffects(batonpass)' into the last line, above the 'end', like:
Code:
    @effects[PBEffects::GorillaTactics]   = -1
  end

  def pbUpdate(fullchange=false)

Then, 'def pbEndTurn(choice)' add for the ability:
Code:
    if @effects[PBEffects::GorillaTactics]<0 && @lastMoveUsed>=0 && !fainted? && 
       self.hasWorkingAbility(:GORILLATACTICS)
      @effects[PBEffects::GorillaTactics]=@lastMoveUsed
    end
    @battle.pbPrimordialWeather

Now, to power up thanks to ability, go to 'PokeBattle_Move' script and above THICKCLUB's code, paste:
Code:
    if attacker.hasWorkingAbility(:GORILLATACTICS) && pbIsPhysical?(type)
      atkmult=(atkmult*1.5).round
    end
    if attacker.hasWorkingItem(:THICKCLUB) &&

Finally, in 'PokeBattle_Battle' script, inside 'def pbCanChooseMove?(idxPokemon,idxMove,showMessages,sleeptalk=false)' paste below 'if thispkmn.effects[PBEffects::Encore]>0 && idxMove!=thispkmn.effects[PBEffects::EncoreIndex]', like:
Code:
    if thispkmn.effects[PBEffects::Encore]>0 && idxMove!=thispkmn.effects[PBEffects::EncoreIndex]
      return false
    end
    if thispkmn.effects[PBEffects::GorillaTactics]>=0 && thispkmn.hasWorkingAbility(:GORILLATACTICS)
      hasmove=false
      for i in 0...4
        if thispkmn.moves[i].id==thispkmn.effects[PBEffects::GorillaTactics]
          hasmove=true; break
        end
      end
      if hasmove && thismove.id!=thispkmn.effects[PBEffects::GorillaTactics]
        if showMessages
          pbDisplayPaused(_INTL("{1} can only use {2}!",
             thispkmn.pbThis,
             PBMoves.getName(thispkmn.effects[PBEffects::GorillaTactics])))
        end
        return false
      end
    end
 
Last edited:
Perish Body:

In ability.txt add:
XXX,PERISHBODY,Perish Body,"When hit by a move that makes direct contact, the Pokémon and the attacker will faint after three turns unless they switch out of battle."

Now, 'PBEffects' script, add for:
Code:
    Yawn               = 108
    PerishBody     = 109

Then 'PokeBattle_Battler' script:
Code:
    @effects[PBEffects::Yawn]             = 0
    @effects[PBEffects::PerishBody]       = 0

Look for 'def pbEffectsOnDealingDamage(move,user,target,damage)' and add below POISONTOUCH's code:
Code:
        if user.hasWorkingAbility(:POISONTOUCH,true) &&
           target.pbCanPoison?(nil,false) && @battle.pbRandom(10)<3
          PBDebug.log("[Ability triggered] #{user.pbThis}'s Poison Touch")
          target.pbPoison(user,_INTL("{1}'s {2} poisoned {3}!",user.pbThis,
             PBAbilities.getName(user.ability),target.pbThis(true)))
        end
        if target.hasWorkingAbility(:PERISHBODY,true) && !user.hasMoldBreaker && 
           user.effects[PBEffects::PerishBody]==0 && target.effects[PBEffects::PerishBody]==0
          @battle.pbDisplay(_INTL("Both Pokémon will faint in three turns!"))
          user.effects[PBEffects::PerishBody]=3; target.effects[PBEffects::PerishBody]=3
        end
      end
    end
    if damage>0

Now in 'PokeBattle_Battle' script, use CTRL+F and find 'PBDebug.log("[Withdrew Pokémon] Player withdrew #{i.pbThis(true)}")' and paste below 'i.effects[PBEffects::PerishBody]=0 # Reset Perish Body if has one' (like):
Code:
    # Switch out Pokémon
    @switching=true
    switched=[]
    for i in priority
      if @choices[i.index][0]==2 && !i.effects[PBEffects::SkipTurn]
        index=@choices[i.index][1] # party position of Pokémon to switch to
        newpokename=index
        if isConst?(pbParty(i.index)[index].ability,PBAbilities,:ILLUSION)
          newpokename=pbGetLastPokeInTeam(i.index)
        end
        self.lastMoveUser=i.index
        if !pbOwnedByPlayer?(i.index)
          owner=pbGetOwner(i.index)
          pbDisplayBrief(_INTL("{1} withdrew {2}!",owner.fullname,i.name))
          PBDebug.log("[Withdrew Pokémon] Opponent withdrew #{i.pbThis(true)}")
        else
          pbDisplayBrief(_INTL("{1}, that's enough!\r\nCome back!",i.name))
          PBDebug.log("[Withdrew Pokémon] Player withdrew #{i.pbThis(true)}")
        end
        i.effects[PBEffects::PerishBody]=0 # Reset Perish Body if has one
        for j in priority
          next if !i.pbIsOpposing?(j.index)

Finally to show the countdown, paste above # Uproar, like:
Code:
    # Perish Body
    for i in priority
      next if i.fainted?
      if i.effects[PBEffects::PerishBody]>0
        i.effects[PBEffects::PerishBody]-=1
        pbDisplay(_INTL("{1}'s perish count fell to {2}!",i.pbThis,i.effects[PBEffects::PerishBody]))
        PBDebug.log("[Lingering effect triggered] #{i.pbThis}'s Perish Body count dropped to #{i.effects[PBEffects::PerishBody]}")
        if i.effects[PBEffects::PerishBody]==0
          i.pbReduceHP(i.hp,true)
        end
      end
      if i.fainted?
        return if !i.pbFaint
      end
    end
    if @decision>0
      pbGainEXP
      return
    end
    # Uproar
    for i in priority
      next if i.fainted?
      if i.effects[PBEffects::Uproar]>0
 
Last edited:
Sand Spit:

For ability.txt:
XXX,SANDSPIT,Sand Spit."The Pokémon creates a sandstorm when it's hit by an attack."

Now in 'PokeBattle_Battler' script paste above Air Ballon's code (I just copied like SANDSTORM move works):
Code:
        if target.hasWorkingAbility(:SANDSPIT)
          if @battle.weather!=PBWeather::HEAVYRAIN || @battle.weather!=PBWeather::HARSHSUN || 
             @battle.weather!=PBWeather::STRONGWINDS || 
            @battle.weather!=PBWeather::SANDSTORM
            @battle.pbAnimation(getConst(PBMoves,:SANDSTORM),self,nil)
            @battle.weather=PBWeather::SANDSTORM
            @battle.weatherduration=5
            @battle.weatherduration=8 if target.hasWorkingItem(:SMOOTHROCK)
            @battle.pbCommonAnimation("Sandstorm",nil,nil)
            @battle.pbDisplay(_INTL("A sandstorm brewed!"))
          end
        end
        if target.hasWorkingItem(:AIRBALLOON,true)
          PBDebug.log("[Item triggered] #{target.pbThis}'s Air Balloon popped")
          @battle.pbDisplay(_INTL("{1}'s Air Balloon popped!",target.pbThis))
          target.pbConsumeItem(true,false)
 
Last edited:
Ice Face:

For ability.txt:
XXX,ICEFACE,Ice Face,"The Pokémon's ice head can take a physical attack as a substitute, but the attack also changes the Pokémon's appearance. The ice will be restored when it hails."

Now, in 'PokeBattle_Battler' script look for SNOWWARNING's code to add ICEFACE case:
Code:
        if self.hasWorkingAbility(:SNOWWARNING) && (@battle.weather!=PBWeather::HAIL || @battle.weatherduration!=-1)
          @battle.weather=PBWeather::HAIL
          if USENEWBATTLEMECHANICS
            @battle.weatherduration=5
            @battle.weatherduration=8 if hasWorkingItem(:ICYROCK)
          else
            @battle.weatherduration=-1
          end
          @battle.pbCommonAnimation("Hail",nil,nil)
          @battle.pbDisplay(_INTL("{1}'s {2} made it hail!",pbThis,PBAbilities.getName(self.ability)))
          PBDebug.log("[Ability triggered] #{pbThis}'s Snow Warning made it hail")
          for i in 0...4
            [email protected][i]
            if poke.hasWorkingAbility(:ICEFACE) && isConst?(poke.species,PBSpecies,:EISCUE) && poke.form!=0
              poke.form=0
              poke.pbUpdate(true)
              @battle.scene.pbChangePokemon(poke,poke.pokemon)
              @battle.pbDisplay(_INTL("{1} transformed!",poke.pbThis))
              PBDebug.log("[Form changed] #{poke.pbThis} changed to form #{poke.form}")
            end
          end
        end
      end
      if self.hasWorkingAbility(:AIRLOCK) ||

Now, I added like DISGUISE works, if hit itself thanks to Confusion, will trigger the ability:
Inside 'if !turneffects[PBEffects::SkipAccuracyCheck]' add:
Code:
    if !turneffects[PBEffects::SkipAccuracyCheck]
      if @effects[PBEffects::Confusion]>0
        @effects[PBEffects::Confusion]-=1
        if @effects[PBEffects::Confusion]<=0
          pbCureConfusion
        else
          pbContinueConfusion
          PBDebug.log("[Status] #{pbThis} remained confused (count: #{@effects[PBEffects::Confusion]})")
          if @battle.pbRandom(3)==0
            if isConst?(self.species,PBSpecies,:EISCUE) && self.hasWorkingAbility(:ICEFACE) && self.form!=1
              @battle.pbAnimation(getConst(PBMoves,:TACKLE),self,self)
              self.form=1; pbUpdate(true)
              @battle.scene.pbChangePokemon(self,@pokemon)
              @battle.pbDisplay(_INTL("{1} transformed!",self.pbThis))
              PBDebug.log("[Form changed] #{self.pbThis} changed to form #{self.form}")
              return false
            else  
              pbConfusionDamage
              @battle.pbDisplay(_INTL("It hurt itself in its confusion!")) 
              PBDebug.log("[Status] #{pbThis} hurt itself in its confusion and couldn't move")
              return false
            end
          end
        end
      end
    end
    if @effects[PBEffects::Flinch]

Then, in 'PokeBattle_Move' script inside ' def pbReduceHPDamage(damage,attacker,opponent)' add elsif for ICEFACE case:
Code:
    if opponent.effects[PBEffects::Substitute]>0 && !ignoresSubstitute?(attacker) &&
       (!attacker || attacker.index!=opponent.index)
      PBDebug.log("[Lingering effect triggered] #{opponent.pbThis}'s Substitute took the damage")
      damage=opponent.effects[PBEffects::Substitute] if damage>opponent.effects[PBEffects::Substitute]
      opponent.effects[PBEffects::Substitute]-=damage
      opponent.damagestate.substitute=true
      @battle.scene.pbDamageAnimation(opponent,0)
      @battle.pbDisplayPaused(_INTL("The substitute took damage for {1}!",opponent.name))
      if opponent.effects[PBEffects::Substitute]<=0
        opponent.effects[PBEffects::Substitute]=0
        @battle.pbDisplayPaused(_INTL("{1}'s substitute faded!",opponent.name))
        PBDebug.log("[End of effect] #{opponent.pbThis}'s Substitute faded")
      end
      opponent.damagestate.hplost=damage
      damage=0
    elsif isConst?(opponent.species,PBSpecies,:EISCUE) && opponent.hasWorkingAbility(:ICEFACE) && 
          opponent.form!=1 && pbIsPhysical?(type) && !attacker.hasMoldBreaker
      opponent.form=1; opponent.pbUpdate(true)
      @battle.scene.pbChangePokemon(opponent,opponent.pokemon)
      @battle.pbDisplay(_INTL("{1} transformed!",opponent.name))
      PBDebug.log("[Form changed] #{opponent.pbThis} changed to form #{opponent.form}")
      opponent.damagestate.hplost=damage
      damage=0
    else 
      opponent.damagestate.substitute=false

Finally, in 'PokeBattle_MoveEffects' add inside HAIL move script, ICEFACE case, like:
Code:
################################################################################
# Starts hail weather. (Hail)
################################################################################
class PokeBattle_Move_102 < PokeBattle_Move
  def pbEffect(attacker,opponent,hitnum=0,alltargets=nil,showanimation=true)
    case @battle.weather
    when PBWeather::HEAVYRAIN
      @battle.pbDisplay(_INTL("There is no relief from this heavy rain!"))
      return -1
    when PBWeather::HARSHSUN
      @battle.pbDisplay(_INTL("The extremely harsh sunlight was not lessened at all!"))
      return -1
    when PBWeather::STRONGWINDS
      @battle.pbDisplay(_INTL("The mysterious air current blows on regardless!"))
      return -1
    when PBWeather::HAIL
      @battle.pbDisplay(_INTL("But it failed!"))
      return -1
    end
    pbShowAnimation(@id,attacker,nil,hitnum,alltargets,showanimation)
    @battle.weather=PBWeather::HAIL
    @battle.weatherduration=5
    @battle.weatherduration=8 if attacker.hasWorkingItem(:ICYROCK)
    @battle.pbCommonAnimation("Hail",nil,nil)
    @battle.pbDisplay(_INTL("It started to hail!"))
    for i in 0...4
      [email protected][i]
      if poke.hasWorkingAbility(:ICEFACE) && isConst?(poke.species,PBSpecies,:EISCUE) && poke.form!=0
        poke.form=0
        poke.pbUpdate(true)
        @battle.scene.pbChangePokemon(poke,poke.pokemon)
        @battle.pbDisplay(_INTL("{1} transformed!",poke.pbThis))
        PBDebug.log("[Form changed] #{poke.pbThis} changed to form #{poke.form}")
      end
    end
    return 0
  end
end
 
Last edited:
Hello!
I'm here to deliver information on things, I'm not a coder, I'm just the information delivery guy.

General Mechanic changes:

Speed is calculated immediatly:
Getting paralized in a turn, will make your speed change at that exact moment,
instead of waiting for the start of the next turn like in gen 7

Gen 8 Moves

Spoiler:


Gen 8 Items

Spoiler:



Gen 8 Abilities

Spoiler:
 
Power Spot:

Search this code in 'PokeBattle_Move':
Code:
    if (@battle.pbWeather==PBWeather::SUNNYDAY ||
       @battle.pbWeather==PBWeather::HARSHSUN) && pbIsPhysical?(type)
      if attacker.hasWorkingAbility(:FLOWERGIFT) ||
         attacker.pbPartner.hasWorkingAbility(:FLOWERGIFT)
        atkmult=(atkmult*1.5).round
      end
    end

and paste below:
Code:
    if attacker.pbPartner.hasWorkingAbility(:POWERSPOT)
      atkmult=(atkmult*1.3).round
    end

About Neutralizing Gas we need more details about what abilities won't be affected, to make a blacklist (like Ice Face).
 
Last edited:
I'll be piecing my Gen 8 scripts as I go

################################################################################
# Increases the user's Attack, Defense, Speed, Special Attack and Special Defense
# by 1 stage each at the cost of HP. (Clangorous Soul)
################################################################################
class PokeBattle_Move_XXX < PokeBattle_Move
def pbEffect(attacker,opponent,hitnum=0,alltargets=nil,showanimation=true)
if attacker.hp<=(attacker.totalhp/6).floor ||
!attacker.pbCanIncreaseStatStage?(PBStats::ATTACK,attacker,false,self)
@battle.pbDisplay(_INTL("{1} is too weak to do it again!",attacker.pbThis))
return -1
end
pbShowAnimation(@id,attacker,opponent,hitnum,alltargets,showanimation)
attacker.pbReduceHP((attacker.totalhp/6).floor)
if attacker.hasWorkingAbility(:CONTRARY)
attacker.stages[PBStats::ATTACK]=-1
attacker.stages[PBStats::DEFENSE]=-1
attacker.stages[PBStats::SPATK]=-1
attacker.stages[PBStats::SPDEF]=-1
attacker.stages[PBStats::SPEED]=-1
@battle.pbCommonAnimation("StatDown",attacker,nil)
@battle.pbDisplay(_INTL("{1} cut its own HP and minimized its stats!",attacker.pbThis))
else
attacker.stages[PBStats::ATTACK]=1
attacker.stages[PBStats::DEFENSE]=1
attacker.stages[PBStats::SPATK]=1
attacker.stages[PBStats::SPDEF]=1
attacker.stages[PBStats::SPEED]=1
@battle.pbCommonAnimation("StatUp",attacker,nil)
@battle.pbDisplay(_INTL("{1} cut its own HP and raised its stats!",attacker.pbThis))
end
return 0
end
end

################################################################################
# Switches effects on all sides. (Court Change)
################################################################################
class PokeBattle_Move_XXX < PokeBattle_Move
def pbEffect(attacker,opponent,hitnum=0,alltargets=nil,showanimation=true)
return super(attacker,opponent,hitnum,alltargets,showanimation) if pbIsDamaging?
pbShowAnimation(@id,attacker,opponent,hitnum,alltargets,showanimation)
attacker.pbOwnSide.effects[PBEffects::Reflect] = opponent.pbOwnSide.effects[PBEffects::Reflect]
attacker.pbOwnSide.effects[PBEffects::LightScreen] = opponent.pbOwnSide.effects[PBEffects::LightScreen]
attacker.pbOwnSide.effects[PBEffects::Mist] = opponent.pbOwnSide.effects[PBEffects::Mist]
attacker.pbOwnSide.effects[PBEffects::Safeguard] = opponent.pbOwnSide.effects[PBEffects::Safeguard]
attacker.pbOwnSide.effects[PBEffects::Spikes] = opponent.pbOwnSide.effects[PBEffects::Spikes]
attacker.pbOwnSide.effects[PBEffects::StealthRock] = opponent.pbOwnSide.effects[PBEffects::StealthRock]
attacker.pbOwnSide.effects[PBEffects::StickyWeb] = opponent.pbOwnSide.effects[PBEffects::StickyWeb]
attacker.pbOwnSide.effects[PBEffects::ToxicSpikes] = opponent.pbOwnSide.effects[PBEffects::ToxicSpikes]
opponent.pbOwnSide.effects[PBEffects::Reflect] = attacker.pbOwnSide.effects[PBEffects::Reflect]
opponent.pbOwnSide.effects[PBEffects::LightScreen] = attacker.pbOwnSide.effects[PBEffects::LightScreen]
opponent.pbOwnSide.effects[PBEffects::Mist] = attacker.pbOwnSide.effects[PBEffects::Mist]
opponent.pbOwnSide.effects[PBEffects::Safeguard] = attacker.pbOwnSide.effects[PBEffects::Safeguard]
opponent.pbOwnSide.effects[PBEffects::Spikes] = attacker.pbOwnSide.effects[PBEffects::Spikes]
opponent.pbOwnSide.effects[PBEffects::StealthRock] = attacker.pbOwnSide.effects[PBEffects::StealthRock]
opponent.pbOwnSide.effects[PBEffects::StickyWeb] = attacker.pbOwnSide.effects[PBEffects::StickyWeb]
opponent.pbOwnSide.effects[PBEffects::ToxicSpikes] = attacker.pbOwnSide.effects[PBEffects::ToxicSpikes]
if USENEWBATTLEMECHANICS
attacker.pbOwnSide.effects[PBEffects::Reflect] = opponent.pbOwnSide.effects[PBEffects::Reflect]
attacker.pbOwnSide.effects[PBEffects::LightScreen] = opponent.pbOwnSide.effects[PBEffects::LightScreen]
attacker.pbOwnSide.effects[PBEffects::Mist] = opponent.pbOwnSide.effects[PBEffects::Mist]
attacker.pbOwnSide.effects[PBEffects::Safeguard] = opponent.pbOwnSide.effects[PBEffects::Safeguard]
attacker.pbOwnSide.effects[PBEffects::Spikes] = opponent.pbOwnSide.effects[PBEffects::Spikes]
attacker.pbOwnSide.effects[PBEffects::StealthRock] = opponent.pbOwnSide.effects[PBEffects::StealthRock]
attacker.pbOwnSide.effects[PBEffects::StickyWeb] = opponent.pbOwnSide.effects[PBEffects::StickyWeb]
attacker.pbOwnSide.effects[PBEffects::ToxicSpikes] = opponent.pbOwnSide.effects[PBEffects::ToxicSpikes]
opponent.pbOwnSide.effects[PBEffects::Reflect] = attacker.pbOwnSide.effects[PBEffects::Reflect]
opponent.pbOwnSide.effects[PBEffects::LightScreen] = attacker.pbOwnSide.effects[PBEffects::LightScreen]
opponent.pbOwnSide.effects[PBEffects::Mist] = attacker.pbOwnSide.effects[PBEffects::Mist]
opponent.pbOwnSide.effects[PBEffects::Safeguard] = attacker.pbOwnSide.effects[PBEffects::Safeguard]
opponent.pbOwnSide.effects[PBEffects::Spikes] = attacker.pbOwnSide.effects[PBEffects::Spikes]
opponent.pbOwnSide.effects[PBEffects::StealthRock] = attacker.pbOwnSide.effects[PBEffects::StealthRock]
opponent.pbOwnSide.effects[PBEffects::StickyWeb] = attacker.pbOwnSide.effects[PBEffects::StickyWeb]
opponent.pbOwnSide.effects[PBEffects::ToxicSpikes] = attacker.pbOwnSide.effects[PBEffects::ToxicSpikes]
end
@battle.pbDisplay(_INTL("{1} changed the playing field!",attacker.pbThis))
return 0
end

def pbAdditionalEffect(attacker,opponent)
attacker.pbOwnSide.effects[PBEffects::Reflect] = opponent.pbOwnSide.effects[PBEffects::Reflect]
attacker.pbOwnSide.effects[PBEffects::LightScreen] = opponent.pbOwnSide.effects[PBEffects::LightScreen]
attacker.pbOwnSide.effects[PBEffects::Mist] = opponent.pbOwnSide.effects[PBEffects::Mist]
attacker.pbOwnSide.effects[PBEffects::Safeguard] = opponent.pbOwnSide.effects[PBEffects::Safeguard]
attacker.pbOwnSide.effects[PBEffects::Spikes] = opponent.pbOwnSide.effects[PBEffects::Spikes]
attacker.pbOwnSide.effects[PBEffects::StealthRock] = opponent.pbOwnSide.effects[PBEffects::StealthRock]
attacker.pbOwnSide.effects[PBEffects::StickyWeb] = opponent.pbOwnSide.effects[PBEffects::StickyWeb]
attacker.pbOwnSide.effects[PBEffects::ToxicSpikes] = opponent.pbOwnSide.effects[PBEffects::ToxicSpikes]
opponent.pbOwnSide.effects[PBEffects::Reflect] = attacker.pbOwnSide.effects[PBEffects::Reflect]
opponent.pbOwnSide.effects[PBEffects::LightScreen] = attacker.pbOwnSide.effects[PBEffects::LightScreen]
opponent.pbOwnSide.effects[PBEffects::Mist] = attacker.pbOwnSide.effects[PBEffects::Mist]
opponent.pbOwnSide.effects[PBEffects::Safeguard] = attacker.pbOwnSide.effects[PBEffects::Safeguard]
opponent.pbOwnSide.effects[PBEffects::Spikes] = attacker.pbOwnSide.effects[PBEffects::Spikes]
opponent.pbOwnSide.effects[PBEffects::StealthRock] = attacker.pbOwnSide.effects[PBEffects::StealthRock]
opponent.pbOwnSide.effects[PBEffects::StickyWeb] = attacker.pbOwnSide.effects[PBEffects::StickyWeb]
opponent.pbOwnSide.effects[PBEffects::ToxicSpikes] = attacker.pbOwnSide.effects[PBEffects::ToxicSpikes]
if USENEWBATTLEMECHANICS
attacker.pbOwnSide.effects[PBEffects::Reflect] = opponent.pbOwnSide.effects[PBEffects::Reflect]
attacker.pbOwnSide.effects[PBEffects::LightScreen] = opponent.pbOwnSide.effects[PBEffects::LightScreen]
attacker.pbOwnSide.effects[PBEffects::Mist] = opponent.pbOwnSide.effects[PBEffects::Mist]
attacker.pbOwnSide.effects[PBEffects::Safeguard] = opponent.pbOwnSide.effects[PBEffects::Safeguard]
attacker.pbOwnSide.effects[PBEffects::Spikes] = opponent.pbOwnSide.effects[PBEffects::Spikes]
attacker.pbOwnSide.effects[PBEffects::StealthRock] = opponent.pbOwnSide.effects[PBEffects::StealthRock]
attacker.pbOwnSide.effects[PBEffects::StickyWeb] = opponent.pbOwnSide.effects[PBEffects::StickyWeb]
attacker.pbOwnSide.effects[PBEffects::ToxicSpikes] = opponent.pbOwnSide.effects[PBEffects::ToxicSpikes]
opponent.pbOwnSide.effects[PBEffects::Reflect] = attacker.pbOwnSide.effects[PBEffects::Reflect]
opponent.pbOwnSide.effects[PBEffects::LightScreen] = attacker.pbOwnSide.effects[PBEffects::LightScreen]
opponent.pbOwnSide.effects[PBEffects::Mist] = attacker.pbOwnSide.effects[PBEffects::Mist]
opponent.pbOwnSide.effects[PBEffects::Safeguard] = attacker.pbOwnSide.effects[PBEffects::Safeguard]
opponent.pbOwnSide.effects[PBEffects::Spikes] = attacker.pbOwnSide.effects[PBEffects::Spikes]
opponent.pbOwnSide.effects[PBEffects::StealthRock] = attacker.pbOwnSide.effects[PBEffects::StealthRock]
opponent.pbOwnSide.effects[PBEffects::StickyWeb] = attacker.pbOwnSide.effects[PBEffects::StickyWeb]
opponent.pbOwnSide.effects[PBEffects::ToxicSpikes] = attacker.pbOwnSide.effects[PBEffects::ToxicSpikes]
end
end
end

################################################################################
# Higher Defense = Greater Damage (Body Press)
################################################################################
class PokeBattle_Move_XXX < PokeBattle_Move
def pbBaseDamage(basedmg,attacker,opponent)
if opponent.stages[PBStats::DEFENSE]>0
return basedmg*opponent.stages[PBStats::DEFENSE]
end
return basedmg
end
end

################################################################################
# Power is doubled if the attacker has already moved this round. (Bolt Beak, Fishious Rend)
################################################################################
class PokeBattle_Move_XXX < PokeBattle_Move
def pbBaseDamage(basedmg,attacker,opponent)
if @battle.choices[opponent.index][0]!=1 || # Didn't choose a move
attacker.hasMovedThisRound? # Used a move already
return basedmg*2
end
return basedmg
end
end

'XXX' Can be changed to suit your game, I use that for effect definition, internal number or move class needed if not already defined by another line of script.
I tested them and they work.
 
A few Galar Forms:

GALARIAN_MAPS = [1] (Can be changed to suit your game)

MultipleForms.register(:STUNFISK,{
"getFormOnCreation"=>proc{|pokemon|
if $game_map && GALARIAN_MAPS.include?($game_map.map_id)
next 1 # Galarian Stunfisk
else
next 0 # Stunfisk
end
},
"type1"=>proc{|pokemon|
next if pokemon.form==0 # Stunfisk
case pokemon.form
when 1; next getID(PBTypes,:GROUND) # Galarian Stunfisk
end
},
"type2"=>proc{|pokemon|
next if pokemon.form==0 # Stunfisk
case pokemon.form
when 1; next getID(PBTypes,:STEEL) # Galarian Stunfisk
end
},
"getBaseStats"=>proc{|pokemon|
case pokemon.form
when 1; next [109,81,99,66,84,32] # Galarian Stunfisk
else; next # Stunfisk
end
},
"getAbilityList"=>proc{|pokemon|
case pokemon.form
when 1; next [[getID(PBAbilities,:MIMICRY),0]] # Galarian Stunfisk
else; next # Stunfisk
end
},
"weight"=>proc{|pokemon|
next if pokemon.form==0 #
next 20.5 # Galarian Stunfisk
},
"getMoveList"=>proc{|pokemon|
next if pokemon.form==0 # Stunfisk
movelist=[]
case pokemon.form
when 1; movelist=[[1,:MUDSLAP],[1,:TACKLE],[1,:WATERGUN],[1,:METALCLAW],
[5,:ENDURE],[10,:MUDSHOT],[15,:REVENGE],[20,:METALSOUND],
[25,:SUCKERPUNCH],[30,:IRONDEFENSE],[35,:BOUNCE],[40,:MUDDYWATER],
[45,:SNAPTRAP],[50,:FLAIL],[55,:FISSURE]] # Galarian Stunfisk
end
for i in movelist
i[1]=getConst(PBMoves,i[1])
end
next movelist
},
"getMoveCompatibility"=>proc{|pokemon|
next if pokemon.form==0 # Stunfisk
movelist=[]
case pokemon.form
when 1; movelist=[# TMs
:YAWN,:ASTONISH,:CURSE,:SPITE,:PAINSPLIT,
:REFLECTTYPE,:BIND,:COUNTER
# Move Tutors
:STEELBEAM] # Galarian Stunfisk
end
for i in 0...movelist.length
movelist=getConst(PBMoves,movelist)
end
next movelist
},
"dexEntry"=>proc{|pokemon|
next if pokemon.form==0 # Stunfisk
next _INTL("Living in mud with a high iron content has given it a strong steel body.") # Galarian Stunfisk
},
"kind"=>proc{|pokemon|
next if pokemon.form==0 # Stunfisk
next _INTL("Trap") # Galarian Stunfisk
},
"onSetForm"=>proc{|pokemon,form|
pbSeenForm(pokemon)
}
})

MultipleForms.register(:WEEZING,{
"getFormOnCreation"=>proc{|pokemon|
if $game_map && GALARIAN_MAPS.include?($game_map.map_id)
next 1 # Galarian Weezing
else
next 0 # Weezing
end
},
"type1"=>proc{|pokemon|
next if pokemon.form==0 # Weezing
case pokemon.form
when 1; next getID(PBTypes,:POISON) # Galarian Weezing
end
},
"type2"=>proc{|pokemon|
next if pokemon.form==0 # Weezing
case pokemon.form
when 1; next getID(PBTypes,:FAIRY) # Galarian Weezing
end
},
"getAbilityList"=>proc{|pokemon|
case pokemon.form
when 1; next [[getID(PBAbilities,:LEVITATE),0],
[getID(PBAbilities,:NEUTRALIZINGGAS),1],
[getID(PBAbilities,:MISTYSURGE),2]] # Galarian Weezing
else; next # Weezing
end
},
"height"=>proc{|pokemon|
next if pokemon.form==0 # Weezing
next 3 # Galarian Weezing
},
"weight"=>proc{|pokemon|
next if pokemon.form==0 # Weezing
next 16 # Galarian Weezing
},
"wildHoldItems"=>proc{|pokemon|
next if pokemon.form==0 # Weezing
next [0,getID(PBItems,:MISTYSEED),2] # Galarian Weezing
},
"getMoveList"=>proc{|pokemon|
next if pokemon.form==0 # Weezing
movelist=[]
case pokemon.form
when 1; movelist=[[1,:DOUBLEHIT],[1,:STRANGESTEAM],[1,:DEFOG],[1,:HEATWAVE],
[1,:SMOG],[1,:SMOKESCREEN],[1,:HAZE],[1,:POISONGAS],
[1,:TACKLE],[1,:FAIRYWIND],[1,:AROMATICMIST],[12,:CLEARSMOG],
[16,:ASSURANCE],[20,:SLUDGE],[24,:AROMATHERAPY],[28,:SELFDESTRUCT],
[32,:SLUDGEBOMB],[38,:TOXIC],[44,:BELCH],[50,:EXPLOSION],
[56,:MEMENTO],[62,:DESTINYBOND],[68,:MISTYTERRAIN]] # Galarian Weezing
end
for i in movelist
i[1]=getConst(PBMoves,i[1])
end
next movelist
},
"getMoveCompatibility"=>proc{|pokemon|
next if pokemon.form==0 # Weezing
movelist=[]
case pokemon.form
when 1; movelist=[# TMs
:HYPERBEAM,:GIGAIMPACT,:SCREECH,:SELFDESTRUCT,:REST,
:THIEF,:SNORE,:PROTECT,:ATTRACT,:RAINDANCE,
:SUNNYDAY,:WILLOWISP,:FACADE,:PAYBACK,:ASSURANCE,
:WONDERROOM,:VENOSHOCK,:ROUND,:MISTYTERRAIN,:BRUTALSWING
# Move Tutors] # Galarian Weezing
end
for i in 0...movelist.length
movelist=getConst(PBMoves,movelist)
end
next movelist
},
"dexEntry"=>proc{|pokemon|
next if pokemon.form==0 # Weezing
next _INTL("This Pokémon consumes particles that contaminate the air. Instead of leaving droppings, it expels clean air.") # Galarian Weezing
},
"onSetForm"=>proc{|pokemon,form|
pbSeenForm(pokemon)
}
})

MultipleForms.register(:MEOWTH,{
"getFormOnCreation"=>proc{|pokemon|
if $game_map && GALARIAN_MAPS.include?($game_map.map_id)
next 2 # Galarian Meowth
else
next 0 # Meowth
end
},
"type1"=>proc{|pokemon|
next if pokemon.form==0 # Meowth
case pokemon.form
when 2; next getID(PBTypes,:STEEL) # Galarian Meowth
end
},
"getBaseStats"=>proc{|pokemon|
case pokemon.form
when 2; next [50,65,55,40,40,40] # Galarian Meowth
else; next # Meowth
end
},
"getAbilityList"=>proc{|pokemon|
case pokemon.form
when 2; next [[getID(PBAbilities,:PICKUP),0],
[getID(PBAbilities,:TOUGHCLAWS),1],
[getID(PBAbilities,:UNNERVE),2]] # Galarian Meowth
else; next # Meowth
end
},
"evYield"=>proc{|pokemon|
case pokemon.form
when 2; next [0,1,0,0,0,0] # Galarian Meowth
else; next # Meowth
end
},
"height"=>proc{|pokemon|
next if pokemon.form==0 # Meowth
next 0.4 # Galarian Meowth
},
"weight"=>proc{|pokemon|
next if pokemon.form==0 # Meowth
next 4.2 # Galarian Meowth
},
"getMoveList"=>proc{|pokemon|
next if pokemon.form==0 # Meowth
movelist=[]
case pokemon.form
when 2; movelist=[[1,:FAKEOUT],[1,:GROWL],[4,:HONECLAWS],[8,:SCRATCH],
[12,:PAYDAY],[16,:METALCLAW],[20,:TAUNT],[24,:SWAGGER],
[29,:FURYSWIPES],[32,:SCREECH],[36,:SLASH],[40,:METALSOUND],
[44,:THRASH]] # Galarian Meowth
end
for i in movelist
i[1]=getConst(PBMoves,i[1])
end
next movelist
},
"getMoveCompatibility"=>proc{|pokemon|
next if pokemon.form==0 # Meowth
movelist=[]
case pokemon.form
when 1; movelist=[# TMs
:PAYDAY,:DIG,:SCREECH,:REST,:THIEF,
:SNORE,:PROTECT,:ATTRACT,:RAINDANCE,:SUNNYDAY,
:FACADE,:UTURN,:PAYBACK,:ASSUANCE,:SHADOWCLAW,
:ROUND,:RETALIATE
# Move Tutors
:STEELBEAM] # Galarian Meowth
end
for i in 0...movelist.length
movelist=getConst(PBMoves,movelist)
end
next movelist
},
"dexEntry"=>proc{|pokemon|
next if pokemon.form==0 # Meowth
next _INTL("Living with a savage, seafaring people has toughened this Pokémon's body so much that parts of it have turned to iron.") # Galarian Meowth
},
"onSetForm"=>proc{|pokemon,form|
pbSeenForm(pokemon)
}
})

Evolutions=PERRSERKER,LevelForm2,28 # Add to Meowth's Evolutions= in Pokemon.txt
 
Last edited:
Small word of advice for anyone trying to define Dynamax and Gigantimax:

Step 1: Find the script for Mega Evolution for pokemon with multiple forms.. Seriously, this is most important cause some pokemon that can Dynamax already have a mega evolution.

Step 2: Use Pokemon_MegaEvolution and the Z-move add-on as a base for this. (That's what I'm doing cause that's pretty much what Dynamax and Gigantamax are with a small catch of only lasting 3 turns.)

Step 3: Define Dynamax and Gigantamax as their individual OwnSide effects in PBEffects. (Then I think you know the rest from there form wise)

Step 4: Max Moves, Put the Max Move names first in the Zmove.txt with 10PP instead of 1 like other Z-moves cause when Z-moves run out of PP, they revert to normal moves.

Step 5: Add in settings NO_DYNAMAX and NO_GIGANTAMAX to ensure this 3-turn gimmick can't be used more than once per battle.

Hope this helps ^^
 
Last edited:
We need more details for these abilities:
Mimicry: official phrases/cutscene when some terrain is used/ changed for other one;

Ripen: official phrases/cutscene when eat some berry. Also, if Double Battle, will affect its partner nor opponents?;

SandSpit: official phrases/cutscene when triggered (script here);

Propeller Tail/ Stalwart: more info about the ability/ official phrases/cutscene when triggered;

Screen Cleaner: official phrases/cutscene when triggered (script here);

Power Spot: more info about the ability and official phrases/cutscene when triggered.

Mimicry
I tested Mimicry with my Stunfisk, and the message is: Stunfisk has changed to X type!

X depends of terrain:
Electric Terrain: Electric type
Grassy Terrain: Grass type
Misty Terrain: Fairy type
Psychic Terrain: Psychic type

And the ability is triggered just after the terrain has changed, even before any move. Doesn't matter if it's a double battle, whatever. If the terrain changes, the ability will be triggered instantly after that.
Stunfisk changes into a PURE type. From Ground-Steel to Fairy, Psychic, Grass or Electric. There's no type's combination or something. When a terrain wores off and there's no another one, the message is: Stunfisk has recovered its original types!

Sand Spit
Sand Spit message: it doesn't have a specific one, it uses the same message of when a sandstorm appears in battle, nothing new. The Pokémon recieves an attack and the message of "sandstorm appears" appears (xd).

Screen Cleaner
Screen Cleaner's message: again, nothing new. The message is the same when the effects of Light Screen, Reflect or Aurora Veil end.
Mr. Rime enters to the battle and the ability is triggered instantly if there're some "screens", even if the screens are in your side.

Ripen
It doesn't have any message. The ability appears like "Appeltun's Rippen" and then it eats the berry normally but with the effects doubled. I tested it with an Oran Berry, and it ate the berry, and it healed 20 HP to the Pokémon instead of 10 HP, without saying anything, just the normal message of when a Pokémon eats a berry.
Besides, the ability doesn't affect to the opponent (I tested it with a Galarian-Yamask, and when Yamask had Ripen, my Pokémon ate its Oran Berry and the effect wasn't doubled). The ability doesn't affect to an ally (tested in Coffee Bar's Double Battles).

Hunger Switch
Morpeko will always return to its Full Belly Mode (form 0 in Essentials) after battle. Doesn't matter if you win, flee or lose. Always.

I can't test for now Propeller Tail and Stalwart, because my Duraludon and my Barraskewda don't have their hidden abilities, and I can't test Power Spot, because Stonjouner it's an exclusive Pokémon of Pokémon Sword, and I have Pokémon Shield.

Any question about 8th Gen mechanics, like about moves or abilities, quote this post or PM me and I'll be updating this if I can test the request in my game.
 
Last edited:
Throat Spray:

In items.txt:
Code:
xxx,THROATSPRAY,Throat Spray,Throat Sprays,1,4000,"Raises Sp. Atk when a Pokémon uses a sound-based move.",0,0,0,

P.S: for Fling move, the power is 30.

Inside 'PokeBattle_Battler' script, look for WEAKNESSPOLICY's code and below it, add:
Code:
        elsif target.hasWorkingItem(:WEAKNESSPOLICY) && target.damagestate.typemod>8
          showanim=true
          if target.pbIncreaseStatWithCause(PBStats::ATTACK,2,target,PBItems.getName(target.item),showanim)
            PBDebug.log("[Item triggered] #{target.pbThis}'s Weakness Policy (Attack)")
            showanim=false
          end
          if target.pbIncreaseStatWithCause(PBStats::SPATK,2,target,PBItems.getName(target.item),showanim)
            PBDebug.log("[Item triggered] #{target.pbThis}'s Weakness Policy (Special Attack)")
            showanim=false
          end
          target.pbConsumeItem if !showanim
        elsif user.hasWorkingItem(:THROATSPRAY) && move.isSoundBased?
          if user.pbIncreaseStatWithCause(PBStats::SPATK,1,user,PBItems.getName(user.item))
            PBDebug.log("[Item triggered] #{user.pbThis}'s #{PBItems.getName(user.item)}")
            user.pbConsumeItem
          end
        elsif target.hasWorkingItem(:ENIGMABERRY) && target.damagestate.typemod>8
 

Attachments

  • [PokeCommunity.com] [Essentials v17.2] Gen 8 stuffs (Abilities, Items & Move)
    itemxxx.png
    923 bytes · Views: 708
Back
Top