• 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!
  • Dawn, Gloria, Juliana, or Summer - which Pokémon protagonist is your favorite? Let us know by voting in our poll!
  • 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] Freeze-Dry-alike with additional effect

  • 1
    Posts
    0
    Days
    • Seen yesterday
    Hi, let me preface this with saying that English isn't my first language, that I have no background in programming, and that I have less than a week of time with both Pokemon Essentials and RPGMaker XP overall.

    Through watching some tutorials, reading older threads on the forum and reading the code of both Freeze-Dry and Fire Lash, I was trying to make a move that is both supereffective against Ice and drops down Defense by 1.
    I got the super-effective part working, but when adding the lines of code from Fire Lash both stop working, which I guess is due to me not knowing how to read/write code and thus doing something wrong. I would ask for some guidance on how to solve this.

    What I have so far is this:

    class Battle::Move::IceBreakerDefDown < Battle::Move::FreezeTarget
    attr_reader :statDown

    def canMagicCoat?; return true; end

    def pbFailsAgainstTarget?(user, target, show_message)
    return false if damagingMove?
    return !target.pbCanLowerStatStage?(@statDown[0], user, self, show_message)
    end

    def pbEffectAgainstTarget(user, target)
    return if damagingMove?
    target.pbLowerStatStage(@statDown[0], @statDown[1], user)
    end

    def pbAdditionalEffect(user, target)
    return if target.damageState.substitute
    return if !target.pbCanLowerStatStage?(@statDown[0], user, self)
    target.pbLowerStatStage(@statDown[0], @statDown[1], user)
    end
    def pbAdditionalEffect(user, target)
    def pbCalcTypeModSingle(moveType, defType, user, target)
    return Effectiveness::SUPER_EFFECTIVE_MULTIPLIER if defType == :ICE
    return super
    end
    end

    When I first got the Ice part working, I had it in the front; I don't know if that could do something with it.
    Thanks in advance.
     
    Back
    Top