• 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 Trading Card Game 2 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.

[Scripting Question] How do you make Pokemon who attack with raised Atk/SpAtk stats reset their Atk/SpAtk modifiers to +0 at the end of their turn?

  • 428
    Posts
    5
    Years
    I was thinking, setup sweepers can be REALLY busted. Especially in my game, where some changes made this even better. So I came up with a system to nerf it.

    When a Pokemon attacks physically while having a boosted Attack stat (due to Swords Dance for example) or attacks Specially while having a boosted Special Attack stat (due to Tail Glow for example) how do I reset this to 0 at the end of the turn?

    How do I write the following in Pokemon Essentials code, and where do I put it?

    When TurnEnd=True
    If Pokemon.PhysicallyAttackedThisTurn=True && Pokemon.AttackRaised = True
    Pokemon.AttackModifier = -1
    end
    If Pokemon.SpeciallyAttackedThisTurn=True && Pokemon.SpecialAttackRaised = True
    Pokemon.SpecialAttackModifier = -1
    end
     
    Last edited:
    Back
    Top