• 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.

[Scripting Question] Curing Burn Before Move

  • 1
    Posts
    1
    Years
    • Seen Feb 16, 2024
    Hello! I'm sorry if this question seems obvious, I've been trawling forms and can't seem to figure it out. I want to create a move which functions like scald, but rather than curing the user's frozen status before acting, cures the user's burn before moving. I cannot for the life of me figure out what the best way to get this to happen before damage is calculated might be. If anyone might know a possible solution, I'd appreciate it immensely. Cheers!
     
    Hello! I'm sorry if this question seems obvious, I've been trawling forms and can't seem to figure it out. I want to create a move which functions like scald, but rather than curing the user's frozen status before acting, cures the user's burn before moving. I cannot for the life of me figure out what the best way to get this to happen before damage is calculated might be. If anyone might know a possible solution, I'd appreciate it immensely. Cheers!
    I don't know anything about coding or anything, however I could do a suggested order!

    1. Cures burn: The reason this goes first is because for moves like Scald, it cures the freeze first
    2. Deals damage: Then you, of course, deal damage. If this is a Physical move, it'll deal normal damage because the burn was removed beforehand
    3. Might burn: After dealing damage, there's the chance to burn, as like Scald

    I hope this helps!
     
    Hello!

    It's been a while since I've looked at moves so this is how I would investigate the way to do it.
    We know that the functionality exists in Scald already to perform something before the damage. So, it probably has a Flag set something like ThawsUser. From there we can look at how this flag is implemented.
    In Battle_Move we can define the flags that exist something like:
    Spoiler:


    Then I would check the instances you find a move.thawsUser and try to mimic the functionality but instead check for burns.
    So you'll probably want to check in Battler_UseMove, Battler_UseMoveSuccessChecks, Battler_UseMoveTriggerEffects. Then you probably want to investigate the AI code too though I've not looked in there forever so I won't provide any useful information on that!

    Hope that helps!
     
    Back
    Top