• 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.
  • 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!
  • Cyndy, May, Hero (Conquest), or Wes - 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.

[Script] PLAYERFACING? [Emerald]

Karl

Creator of Pokémon Darkfire
  • 169
    Posts
    14
    Years
    • Seen May 7, 2025
    Facing a problem with my XSE script. I wonder if anyone could help me. I'm hacking Pok?mon Emerald.

    My plan is to get the player to jump in a direction depending on where they are facing when they interact with the script.

    I'm using an orange signpost script in AdvanceMap (not a person event or green tile), and I'm getting the @failed message when I compile the following script:

    Spoiler:

    I'm 99% sure the comparefarbytetobyte value of 0x2036E58 is wrong (I copied this from a working FR script but have no idea how to find the right value).

    I have tried copying var 0x8000 and comparing, and I've also tried the standard PLAYERFACING command, but both don't work on an orange script box (on a person event it works fine).

    If anyone knows a way to get this to work I'd appreciate it!
     
    I have ran into a similar problem before. I don't know if this will work in your case, but you could try having the script check the player's X-Y coordinates ("getplayerpos" command) instead of which way they are facing.

    Try something like this:
    Code:
    getplayerpos 0x[Variable to store X] 0x[Variable to store Y]
    compare 0x[Variable X] 0x[X-coordinate in Advance Map]
    if 0x1 goto @next
     
    Last edited:
    I have ran into a similar problem before. I don't know if this will work in your case, but you could try having the script check the player's X-Y coordinates ("getplayerpos" command) instead of which way they are facing.

    Thanks for sharing this method (and your Stabilizing Emerald tutorial), it's working great for me!
     
    Back
    Top