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

[Script] PLAYERFACING? [Emerald]

Karl

Creator of [b]Pokémon Darkfire[/b]
168
Posts
13
Years
    • Seen Apr 29, 2024
    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!
     
    237
    Posts
    7
    Years
  • 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:

    Karl

    Creator of [b]Pokémon Darkfire[/b]
    168
    Posts
    13
    Years
    • Seen Apr 29, 2024
    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