• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • 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.

Report bugs and errors in unmodified Essentials version 21

1,224
Posts
10
Years
  • I'm possibly wrong, but I don't believe I've edited anything in my base v14, and when you define an individual trainer with specific moves, it does not give them that first move.
     
    119
    Posts
    10
    Years
  • I'm possibly wrong, but I don't believe I've edited anything in my base v14, and when you define an individual trainer with specific moves, it does not give them that first move.

    it works fine for me whenever i give trainers a defined move set
     

    Florio

    Pokemon Crimson Skies Owner
    391
    Posts
    15
    Years
  • Problems with Bulk Up, Coil, Work Up and Growth. Source: http://www.pokecommunity.com/showthread.php?t=338880

    This may or may not be related, but I'm seeming to have problems with Charge Beam. It was a Meowstic vs. Meowstic battle and mine knew Charge Beam, the other knew Reflect, Light Screen, Psyshock and Fake Out. I was faster and used Charge Beam and for some reason the opponent kept skipping the turn (as in I would use charge beam, and then it would just go right back to picking my next move before my opponent even went). This happened on most the turns, but the other Meowstic did manage to actually get a turn a few times before I KOed it.

    I'm thinking it could have to do with stat boosts. I am not sure if it was skipping on the same turn I was getting the boost from Charge Beam or not (since I wasn't paying attention), but I am pretty sure it was because of the boosts, since all the moves that FL posted also boost an attacking stat, or maybe this could have to do with the fact that multiple messages are displayed? Not sure.
     
    1,224
    Posts
    10
    Years
  • This may or may not be related, but I'm seeming to have problems with Charge Beam. It was a Meowstic vs. Meowstic battle and mine knew Charge Beam, the other knew Reflect, Light Screen, Psyshock and Fake Out. I was faster and used Charge Beam and for some reason the opponent kept skipping the turn (as in I would use charge beam, and then it would just go right back to picking my next move before my opponent even went). This happened on most the turns, but the other Meowstic did manage to actually get a turn a few times before I KOed it.

    I'm thinking it could have to do with stat boosts. I am not sure if it was skipping on the same turn I was getting the boost from Charge Beam or not (since I wasn't paying attention), but I am pretty sure it was because of the boosts, since all the moves that FL posted also boost an attacking stat, or maybe this could have to do with the fact that multiple messages are displayed? Not sure.

    Turn your internal flag on (you can do this from the bottom of the debug menu), and recreate the battle. It will create a log of it's AI decisions in your data folder, and you can determine from that if it's the AI causing the error, or something else.
     

    Nickalooose

    --------------------
    1,309
    Posts
    16
    Years
    • Seen Dec 28, 2023
    Rest is definitely broken and it's the "ignorestatus" part of pbCanSleep?... So any move that will use this is going to be broken... I don't quite understand the point to ignoring a status, I suppose there are moves out there which don't override other statuses quite like Rest does... But it will have to be changed, I've noticed in some cases, that if a def has a condition that has more than 1 or 2 true's, false's, 0's or nil's, for example:
    Code:
    def myNewDef(index,self=false,opponent=true)
    end
    Only in some cases though and this is one of them... I've recently created a def where this has happened and I worked around it nonetheless, but it will need to be worked around here or removed...
     

    SoulfulLex

    Empiricist-at-Large
    10
    Posts
    10
    Years
    • Seen Aug 19, 2019
    Have a couple of bugs to report. Both of which can be replicated in Vanilla Essentials v14.

    The first occurs when you select an item to use on a Pokemon, and then cancel the use of the item once you're on the Pokemon Selection screen (i.e. Bag > Select Healing Item to Use (like Full Restore) > Cancel [at Pokemon Screen]).

    In Vanilla Essentials, it doesn't go back to the bag when I cancel the item's use, but acts as if I used it anyway.

    In the game I'm working on, however, this Error shows up with the Internal Flag set (I was trying to see what was the cause and fix it myself at the time):

    Spoiler:

    In both cases, normally it doesn't present problems (other than both sides skipping a turn), but when a Pokemon on either side is Poisoned, Burned, or some other condition that activates between turns, it causes them to activate.


    The second error has to do with Mirror Move. The message that shows up when there is no move to mirror shows up fine, but a NoMethodError occurs when a Pokemon tries to use it:

    Spoiler:
     
    1,224
    Posts
    10
    Years
  • In this method

    Spoiler:


    the lines
    Code:
    $scene.transfer_player
    should be
    Code:
    $scene.transfer_player if $scene.is_a?(Scene_Map)

    To prevent crashes when losing battles from the Debug Menu
     
    1,224
    Posts
    10
    Years
  • Slight AI bug for Roar, Whirlwind, Dragon Tail, etc.

    In the AI on lines 1935 and 1942
    Code:
    score+=50 if opponent.pbOwnSide.effects[PBEffects::StealthRock]>0
    should be
    Code:
    score+=50 if opponent.pbOwnSide.effects[PBEffects::StealthRock]==true
    since Stealth Rock is a boolean. This will cause the opponent to not make a move.


    Fix for Mirror Move usage

    In class PokeBattle_Move_0AE

    replace
    Code:
    if opponent.lastMoveUsed<=0 || 
             !PBMoveData.new(opponent.lastMoveUsed).canMirrorMove?
    with
    Code:
    if opponent.lastMoveUsed<=0 || 
             !PokeBattle_Move.pbFromPBMove(@battle,PBMove.new(opponent.lastMoveUsed)).canMirrorMove?


    This same thing must be done in the AI around the 1700s (when 0xAE)

    It seems to be failing because opponent.lastMovedUsed is just a move's id, and PBMoveData does not have the method canMirrorMove? , so we must make it an actual instance of PokeBattle_Move , where this method resides.
     
    Last edited:
    1,224
    Posts
    10
    Years
  • Just another small mistake I found.
    The check for Mummy winds up being done after the pokemon with Mummy has fainted, so if you one-shot it with a physical move you won't be mummified. We simply need to change the new target.hasWorkingAbility? check back to the v13 way of checking, since this check always returns false if the user is fainted.

    Change
    Code:
    if target.hasWorkingAbility(:MUMMY) && !user.isFainted?
              if !isConst?(user.ability,PBAbilities,:MULTITYPE) &&
                 !isConst?(user.ability,PBAbilities,:WONDERGUARD) &&
                 !isConst?(user.ability,PBAbilities,:MUMMY)
                user.ability=getConst(PBAbilities,:MUMMY) || 0
                @battle.pbDisplay(_INTL("{1} was mummified by {2}!",
                   user.pbThis,target.pbThis(true)))
              end
            end
    to
    Code:
    if isConst?(target.ability,PBAbilities,:MUMMY) && !target.effects[PBEffects::GastroAcid] && !user.isFainted?
              if !isConst?(user.ability,PBAbilities,:MULTITYPE) &&
                 !isConst?(user.ability,PBAbilities,:WONDERGUARD) &&
                 !isConst?(user.ability,PBAbilities,:MUMMY)
                user.ability=getConst(PBAbilities,:MUMMY) || 0
                @battle.pbDisplay(_INTL("{1} was mummified by {2}!",
                   user.pbThis,target.pbThis(true)))
              end
            end

    Edit: This is a problem for many similar abilities also (Effect Spore, Iron Barbs, etc)
    Also, I accidentally put this here instead of Bug Reporting, can you please move it?
     
    Last edited:

    SoulfulLex

    Empiricist-at-Large
    10
    Posts
    10
    Years
    • Seen Aug 19, 2019
    Not a bug, per se, but the message for Pressure at the beginning of a battle is missing from Vanilla Essentials. Very easy fix for it, though:

    Code:
        # Pressure
        if self.hasWorkingAbility(:PRESSURE) && onactive
          @battle.pbDisplay(_INTL("{1} is exerting its Pressure!",pbThis))
        end
    This goes in PokeBattle_Battler. Put it before # Trace on line 828 (but after the "end" of the Cloud Nine prompt).
     

    venom12

    Pokemon Crystal Rain Relased
    476
    Posts
    17
    Years
    • Age 33
    • Seen Dec 28, 2023
    Also Dragon Dance have problems. replace

    Code:
          when 0x26
            score+=40 if attacker.turncount==0 # Dragon Dance tends to be popular
            if attacker.pbTooHigh?(PBStats::ATTACK) &&
               attacker.pbTooHigh?(PBStats::SPEED)
              score-=90
            else
              score-=attacker.stages[PBStats::ATTACK]*10
              score-=attacker.stages[PBStats::SPEED]*10
              if skill>=PBTrainerAI.mediumSkill
                hasphysicalattack=false
                for thismove in attacker.moves
                  if thismove.id!=0 && thismove.basedamage>0 &&
                     thismove.pbIsPhysical?(thismove.type)
                    hasphysicalattack=true
                  end
                end
                if hasphysicalattack
                  score+=20
                elsif skill>=PBTrainerAI.highSkill
                  score-=90
                end
              end
              if skill>=PBTrainerAI.highSkill
                aspeed=pbRoughStat(attacker,PBStats::SPEED,skill)
                ospeed=pbRoughStat(opponent,PBStats::SPEED,skill)
                if aspeed<ospeed && aspeed*2>ospeed
                  score+=20
                end
              end
            end
     

    FL

    Pokémon Island Creator
    2,450
    Posts
    13
    Years
    • Seen today
    I can't edit/save HiddenAbility on editor.
     

    AmethystRain

    pixie-powered judgment!
    253
    Posts
    12
    Years
    • Seen Nov 28, 2022
    A couple other AI issues:

    Beat-Up AI also causes opponent inaction. Change
    Code:
          when 0xC1 # Beat Up
            party=pbParty(attacker.index)
            mult=0
            for i in 0...party.length
              [COLOR="Red"]multi[/COLOR]+=1 if party[i] && !party[i].egg? &&
                          party[i].hp>0 && party[i].status==0
            end
            basedamage*=mult
    to
    Code:
        when 0xC1 # Beat Up
            party=pbParty(attacker.index)
            mult=0
            for i in 0...party.length
              [COLOR="red"]mult[/COLOR]+=1 if party[i] && !party[i].egg? &&
                          party[i].hp>0 && party[i].status==0
            end
            basedamage*=mult

    More importantly, let's talk about this section of the AI
    Code:
     def pbRoughAccuracy(move,attacker,opponent,skill)
        # Get base accuracy
        [COLOR="RoyalBlue"]accuracy[/COLOR]=move.accuracy
        if skill>=PBTrainerAI.mediumSkill
          if pbWeather==PBWeather::SUNNYDAY &&
             (move.function==0x08 || move.function==0x15) # Thunder, Hurricane
            [COLOR="RoyalBlue"]accuracy[/COLOR]=50
          end
        end
        # Accuracy stages
        accstage=attacker.stages[PBStats::ACCURACY]
        accstage=0 if opponent.hasWorkingAbility(:UNAWARE)
        [COLOR="Purple"]accuracy[/COLOR]=(accstage>=0) ? (accstage+3)*100.0/3 : 300.0/(3-accstage)
        evastage=opponent.stages[PBStats::EVASION]
        evastage-=2 if @field.effects[PBEffects::Gravity]>0
        evastage=-6 if evastage<-6
        evastage=0 if opponent.effects[PBEffects::Foresight] ||
                      opponent.effects[PBEffects::MiracleEye] ||
                      move.function==0xA9 || # Chip Away
                      attacker.hasWorkingAbility(:UNAWARE)
        evasion=(evastage>=0) ? (evastage+3)*100.0/3 : 300.0/(3-evastage)
        [COLOR="Red"]accuracy/=evasion[/COLOR]
        # Accuracy modifiers
    Please correct me if I'm misunderstanding this part, but from playing around with it a little bit, my understanding is as follows:
    Firstly, the blue sections start by getting the accuracy and changing it for weather, but then just below that the accuracy variable seems to be set according to the stages. To me, this appears to overwrite the previous changes in blue.
    Then, with the line in red below, if I'm not completely mistaken, this returns a result of 1 with no stage alterations. This is later going to feed back out to the main AI function here:
    Code:
            accuracy=pbRoughAccuracy(move,attacker,opponent,skill)
            basedamage*=accuracy/100
    ...which means we get the basedamage calculation chopped to /100. Since some of the other accuracy modifiers also set that variable to 100 or thereabouts, it makes sense to me to multiply accuracy by 100 after the red-lighted part in the previous code block, otherwise the AI thinks the base damage is a -lot- lower than it should.
     

    KillerMapper

    Helix Follower
    200
    Posts
    9
    Years
  • I noticed that when you use any ball trying to catch a pokémon in double battles, when both wild pokémon are still up, you got the message that you can't aim when there are 2 pokémons (which is ok) but the ball is still consumed (is it the case in official games? I'm not sure but I don't think it is).

    Was already in v14, I found it yesterday before the release of v15.
     
    57
    Posts
    10
    Years
    • Seen Sep 10, 2022
    I was battling in a double battle against Diglett and Remoraid

    I'm sure the problem is Remoraid because when it attacks I get the following error

    Exception: NoMethodError
    Message: undefined method `pbType' for #<PokeBattle_Battle:0xaa9dcd8>
    PokeBattle_AI:3498:in `pbRoughAccuracy'
    PokeBattle_AI:2569:in `pbGetMoveScore'
    PokeBattle_AI:3577:in `pbChooseMoves'
    PokeBattle_AI:3575:in `each'
    PokeBattle_AI:3575:in `pbChooseMoves'
    PokeBattle_AI:4058:in `pbDefaultChooseEnemyCommand'
    PokeBattle_ActualScene:2729:in `pbChooseEnemyCommand'
    PokeBattle_Battle:2344:in `pbCommandPhase'
    PokeBattle_Battle:2339:in `each'
    PokeBattle_Battle:2339:in `pbCommandPhase'
     
    30
    Posts
    10
    Years
    • Seen Mar 25, 2017
    I noticed that upon updating my game to Essentials 15, the opponent Pokemon failed to make a move and instead reset my Pokemon to the command screen directly after attacking. Upon investigation of the base Essentials, I noted the same problem.

    Here's the battle log in my game:
    Code:
    ***Round 1***
    [The wild Diggersby: Odor Sleuth=100, Flail=100, Dig=100, Bounce=100]
    [Using two-turn attack]
    ***Round 2***
    [reusing commands for the wild Diggersby]
    [Continuing move]
    [Lauren lost 17 HP, now has 116 HP]
    ***Round 3***
    [The wild Diggersby: Odor Sleuth=100, Flail=100, Dig=100, Bounce=100] (Diggersby does not move)
    ***Round 4***
    [The wild Diggersby: Odor Sleuth=100, Flail=100, Dig=100, Bounce=100] (Diggersby does not move)
    ***Round 5***
    [The wild Diggersby: Odor Sleuth=100, Flail=100, Dig=100, Bounce=100]
    [Lauren lost 5 HP, now has 111 HP]
    ***Round 6***
    [The wild Diggersby: Odor Sleuth=100, Flail=100, Dig=100, Bounce=100]
    [The wild Diggersby lost 141 HP, now has 0 HP]
    [The wild Diggersby fainted]

    And for base Essentials:

    Code:
    ***Round 1***
    [The wild Rattata: Tail Whip=100, Quick Attack=100, Focus Energy=100, Bite=100]
    [Pikachu lost 9 HP, now has 37 HP]
    ***Round 2***
    [The wild Rattata: Tail Whip=100, Quick Attack=100, Focus Energy=100, Bite=100]
    ***Round 3***
    [The wild Rattata: Tail Whip=100, Quick Attack=100, Focus Energy=100, Bite=100] (Rattata does not move)
    ***Round 4***
    [The wild Rattata: Tail Whip=100, Quick Attack=100, Focus Energy=100, Bite=100]
    [The wild Rattata lost 30 HP, now has 0 HP]
    [The wild Rattata fainted]

    The second battle was done with the unmodified scripts, and I'm not sure what's causing this.
     

    Maruno

    Lead Dev of Pokémon Essentials
    5,286
    Posts
    16
    Years
    • Seen yesterday
    I'm sure you should have gotten an error message. I don't know why you wouldn't have.
     
    30
    Posts
    10
    Years
    • Seen Mar 25, 2017
    I'm sure you should have gotten an error message. I don't know why you wouldn't have.

    An error message doesn't show up and I can't imagine why it doesn't; I feel like something in the code might be syntactically correct but functionally incorrect.
     

    Savordez

    It's time to end fangames.
    115
    Posts
    10
    Years
  • I'm sure you should have gotten an error message. I don't know why you wouldn't have.

    NMTfC2B.gif

    As you can see, the Pidgey does not do anything after my first Quick Attack. And this is from the unmodified version. No error messages.
     
    Back
    Top