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

[ARCHIVE] Simple Questions (SEARCH BEFORE ASKING A QUESTION)

Status
Not open for further replies.

Telinc1

Weirdo Extraordinaire
168
Posts
10
Years
  • I knew the time would come when I ask another question. I have a level script that activates when you do a certain something. Everything works, however one of the two involved person events doesn't show up (removing the flag from it makes it show up permanently, but it is obviously not what I want) with the "showsprite" command. It's weird, because the other one does. Here is a screenshot of the map. Please don't mind the WIP map. Also note that the sprite uses flag 37 (the other one uses 36)
    FwiYOIn.png


    This is just a piece of the map because it is actually 48x40. This portion is in the middle of it.

    I made sure no level script interfered with anything, so I hope somebody can help.
     

    Orifiel

    Priestess
    413
    Posts
    10
    Years
  • I knew the time would come when I ask another question. I have a level script that activates when you do a certain something. Everything works, however one of the two involved person events doesn't show up (removing the flag from it makes it show up permanently, but it is obviously not what I want) with the "showsprite" command. It's weird, because the other one does. Here is a screenshot of the map. Please don't mind the WIP map. Also note that the sprite uses flag 37 (the other one uses 36)
    FwiYOIn.png


    This is just a piece of the map because it is actually 48x40. This portion is in the middle of it.

    I made sure no level script interfered with anything, so I hope somebody can help.

    Go to header
    and the map scripts. Choose there on entering map/not on menu close.
    Then make your script, normal with hidesprite, specifically, in your level script you need the flag.
    So it should be for the on entering map/not on menu close like this for example.

    #dynamic offset

    #org @start
    checkflag (flag)
    hidesprite 0x(NPC number)
    setflag (flag number for this script should be added on the NPC I.D)
    release
    end

    then on your level script.
    Just add show sprite. For showsprite to happen doesn't need flags to add in NPC by the way.
    It will automatically happen if added in script.
    Then you're good to go!

    Also, wrong section. Should be on script help thread. :(
     

    Telinc1

    Weirdo Extraordinaire
    168
    Posts
    10
    Years
  • Go to header
    and the map scripts. Choose there on entering map/not on menu close.
    Then make your script, normal with hidesprite, specifically, in your level script you need the flag.
    So it should be for the on entering map/not on menu close like this for example.

    #dynamic offset

    #org @start
    checkflag (flag)
    hidesprite 0x(NPC number)
    setflag (flag number for this script should be added on the NPC I.D)
    release
    end

    then on your level script.
    Just add show sprite. For showsprite to happen doesn't need flags to add in NPC by the way.
    It will automatically happen if added in script.
    Then you're good to go!

    Also, wrong section. Should be on script help thread. :(
    Hi. Thanks for the help, but unfortunately, the script (neither the type or the script itself) is not the problem. There's something weird going on with the flags, so I don't think the script help thread is suitable for this. I might be wrong, though.
    Though I will try to use on entering map as the type and see what happens.
    Huh, now that's weird. Swapping the person event numbers makes the first rival not appear and the second one appear. There's something strange going on and I will try to figure out what it is.

    Well, I was able to fix the problem. It seems that moving the showsprite command to a location where the camera has scrolled to the scene fixed the problem. Conclusion: showsprite without a clearflag doesn't work if the sprite you're trying to show is way off screen. You learn something new every day.

    (also, am I the only member of the PokéCommunity to realise that showsprite and hidesprite automatically do setflag/clearflag, so it's just a waste of space to use them)
     
    Last edited:

    Rezordaxx

    Asks many questions!
    290
    Posts
    10
    Years
  • I have given my lvl 5 fakemon surf trough yape
    but when I push z (a) at the water nothing happens,
    could it be because i dont have the pokemon menu activated?
    i need it deactivated for some reasons want to know why chek my hack thread in my signature
     

    Telinc1

    Weirdo Extraordinaire
    168
    Posts
    10
    Years
  • I have given my lvl 5 fakemon surf trough yape
    but when I push z (a) at the water nothing happens,
    could it be because i dont have the pokemon menu activated?
    i need it deactivated for some reasons want to know why chek my hack thread in my signature
    You need the Soul Badge (number 6, from Koga in the original game) in order to able to use Surf outside of battle. Currently, it has been only discovered how to prevent the badge check in the Pokémon menu but not on the overworld.
     

    Rezordaxx

    Asks many questions!
    290
    Posts
    10
    Years
  • You need the Soul Badge (number 6, from Koga in the original game) in order to able to use Surf outside of battle. Currently, it has been only discovered how to prevent the badge check in the Pokémon menu but notn t ohe overworld.

    what do you mean by

    "it has been only discovered how to prevent the badge check in the Pokémon menu but not the overworld."??
     

    karatekid552

    What happens if I push it?....
    1,771
    Posts
    11
    Years
  • You need the Soul Badge (number 6, from Koga in the original game) in order to able to use Surf outside of battle. Currently, it has been only discovered how to prevent the badge check in the Pokémon menu but not on the overworld.

    I actually found all of the offsets at one point. It is very simple to do if you know ASM. However, I don't remember where they are.
     

    karatekid552

    What happens if I push it?....
    1,771
    Posts
    11
    Years
  • Could you help me out in pm? Thanks and credits in the hack as advance

    You need to disable the call to the flagdecrypter that happens whenever you use surf. There are multiple calls to it by bl. It's offset is 0x0806E5C0 (I think this is the flagdecrypter that is used here.). Either way, set a breakpoint on that and then try to surf. Ideally, it should only run when a flag needs to be checked, so it should break only when the surf flag is being checked. From there, you can work backwards using the LR to find the routine which called it. If I remember correctly, this routine will have the flag number loaded into a register, then there is a bl to the decrypter, and then a cmp. The cmp and bl can then be overwritten so that the action which is called when the flag is set is always called, even if it not set.

    If you don't know ASM, never a better time to learn. Trust me, it makes hacking a lot more fun and interesting. ASM is the gateway into finally understanding what you are doing when you hack and opens up every single possibility.
     

    Jambo51

    Glory To Arstotzka
    736
    Posts
    14
    Years
    • Seen Jan 28, 2018
    You need to disable the call to the flagdecrypter that happens whenever you use surf. There are multiple calls to it by bl. It's offset is 0x0806E5C0 (I think this is the flagdecrypter that is used here.).

    It's actually at 0x6E6D0. All flags, with 2 exceptions (those being Pokémon seen and caught flags) are run through this routine when the value is required. IIRC, the flag setter is at 0x6E6A0 and the flag clearer at 0x6E6B8.
     

    Rezordaxx

    Asks many questions!
    290
    Posts
    10
    Years
  • You need to disable the call to the flagdecrypter that happens whenever you use surf. There are multiple calls to it by bl. It's offset is 0x0806E5C0 (I think this is the flagdecrypter that is used here.). Either way, set a breakpoint on that and then try to surf. Ideally, it should only run when a flag needs to be checked, so it should break only when the surf flag is being checked. From there, you can work backwards using the LR to find the routine which called it. If I remember correctly, this routine will have the flag number loaded into a register, then there is a bl to the decrypter, and then a cmp. The cmp and bl can then be overwritten so that the action which is called when the flag is set is always called, even if it not set.

    If you don't know ASM, never a better time to learn. Trust me, it makes hacking a lot more fun and interesting. ASM is the gateway into finally understanding what you are doing when you hack and opens up every single possibility.

    I dont know how to ASM and i dont know how to start learning it :/ and i only understand a litle from what u are saying could you explain it in a verry noobish way?

    Like:
    When you walk,
    You put one feet forward
    And then the other one
    And you repeat that
    (The best example i can think of, lol)
     

    karatekid552

    What happens if I push it?....
    1,771
    Posts
    11
    Years
  • It's actually at 0x6E6D0. All flags, with 2 exceptions (those being Pokémon seen and caught flags) are run through this routine when the value is required. IIRC, the flag setter is at 0x6E6A0 and the flag clearer at 0x6E6B8.

    The offset I gave was the one called by the checkflag, setflag, and clearflag commands. So, yeah, thanks man for clearing that up.

    I dont know how to ASM and i dont know how to start learning it :/ and i only understand a litle from what u are saying could you explain it in a verry noobish way?

    Like:
    When you walk,
    You put one feet forward
    And then the other one
    And you repeat that
    (The best example i can think of, lol)

    Your example is the reason I wrote this: http://www.pokemonhackersonline.com/showthread.php?t=14109

    Read it and just keep pushing. ASM is the gateway to a new world of hacking that is sooo much better.
     

    Renegade

    Time for real life...
    995
    Posts
    12
    Years
  • Hello~
    I'm having a problem with Overworld Editor (Rebirth). I erased frame 0 of the player's sprite and drew this one in place of it (Snivy):

    Rq8E4nO.png


    After checking what it looks like in-game, this showed up:

    azizks9.png


    Columns of the sprite are invisible. Does anyone know what the problem is?
     
    1
    Posts
    10
    Years
    • Seen Nov 3, 2013
    Okay, so I have been working on this Firered romhack for a while now and I would like to make a Wintery or frozen themed city. The problem is I suck at tilesets in general. I've seen the 'Frozen' tiles and have tried for a long time trying to import them but just not getting any luck. So basically I would HIGHLY appreciate it if someone could possible convert the tiles into a tileset that is compatible for advance map and send me the download link. Thanks!
     

    Rezordaxx

    Asks many questions!
    290
    Posts
    10
    Years
  • The offset I gave was the one called by the checkflag, setflag, and clearflag commands. So, yeah, thanks man for clearing that up.



    Your example is the reason I wrote this: http://www.pokemonhackersonline.com/showthread.php?t=14109

    Read it and just keep pushing. ASM is the gateway to a new world of hacking that is sooo much better.

    So i need to go to a setflag offset (0x806E6A0) in a hex editor and set a breakpoint. What is a breakpoint? 00 or something?
     
    199
    Posts
    12
    Years
    • Seen Jul 18, 2016
    So I am making some e4 rematches in emerald and it seems to be going quite well except for this.

    Spoiler:


    The problem? It is meant to show Sidney, not Wallace. This also happens to the other e4 members too.
    I had to replace a few trainers to fit them (the e4 rematches) in, so that may be causing it somehow?

    This is what it should look like.
    Spoiler:
     
    Last edited:
    Status
    Not open for further replies.
    Back
    Top