• 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.
  • Dawn, Gloria, Juliana, or Summer - which Pokémon protagonist is your favorite? Let us know by voting in our poll!
  • Our friends from the Johto Times are hosting a favorite Pokémon poll - and we'd love for you to participate! Click here for information on how to vote for your favorites!
  • 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.

[Scripting Question] Adding a hold item that gives a secondary Typing

  • 37
    Posts
    8
    Years
    • Seen Jan 21, 2021
    Only for a certain evolution line. I'm getting a syntax error when attempting to put in this script, just before the Shellos scripting for Multiple forms. All these Pokemon are monotyped, but I'm thinking the issue is that I'm not defining the individual Pokemon in the "then type2" line?

    if (isConst?(pokemon.species,PBSpecies,:ELEMBABY) || (isConst?(pokemon.species,PBSpecies,:FIRASTER) || (isConst?(pokemon.species,PBSpecies,:HIELOREX) &&
    if hasConst?(PBItems,:DRAGONBONE)
    then type2==getConst(PBTypes,:DRAGON)

    Any help is much appreciated.
     
    What you'd have to do is that when it holds the dragon bone; it changes form; (not sure if your using v17.2 so not sure if its different for 17.2)

    would be;

    Code:
    MultipleForms.register(:ELEMBABY,{
    "getForm"=>proc{|pokemon|
        if isConst?(pokemon.item,PBItems,:DRAGONBONE)
          next 1
        end
    },
    "type2"=>proc{|pokemon|
    next if pokemon.form==0
    next getID(PBTypes,:DRAGON)
    }
    })
    
    MultipleForms.copy(:ELEMBABY,:FIRESTER,:HEILOREX)
     
    If some of them is a evolution for a pokemon (Like Rockruff to Lycanroc, we have 3 differents forms), you need to change 'getForm' to 'getFormOnCreation'.
     
    Back
    Top