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

Temporarily disable HM use?

115
Posts
9
Years
    • Seen Nov 17, 2023
    I have a small area inside of a map that the player can explore post-game (meaning they have all badges), but I don't want them to be able to use Surf while inside of this area. I figured that I could do this by temporarily taking away the badge that allows the player to Surf, but I realized that the HM system doesn't keep track of badges that way, it counts them instead. So taking away badge #4 when the player still has 7 means they can still surf, because 7 > 4.

    Is there any other way I can temporarily disable the use of surf?

    Bonus: I realize that by disabling surf the player can still teleport out of the area without passing through the event that re-enables surf, so I would need a way to disable teleport as well. The area is small, so it's unlikely that they will, but they still could.
     
    Last edited:

    Ego13

    hollow_ego
    311
    Posts
    6
    Years
  • Ypu can add a condition to these field moves that checks for a certain switch. If the switch is off the move can be used and if its on it can't be used
     
    115
    Posts
    9
    Years
    • Seen Nov 17, 2023
    Thanks Ego13, I figured it out. I just put these lines just before the conditional statement that prompts the user to surf:

    Code:
    if $game_switches[159]
         Kernel.pbMessage(_INTL("NO SURF."))
        return false
        end

    The no surf message was for testing purposes and isn't necessary.

    EDIT: Slight correction, the "return false" line needs to be inside the if statement, otherwise the player will never be prompted to surf ever again. I fixed the code shown above.
     
    Last edited:
    Back
    Top