• 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] Legendary Encounter Script issues

476
Posts
6
Years
    • Seen Feb 26, 2020
    (original post info, outdated but keeping it makes the early replies make sense):
    Spoiler:


    Updates:

    I'm trying to set up a battle in Pok?mon FireRed that lets the player get Mew, and I've got a script made from an example I saw in a video, with tweaks so it works in new versions of XSE. I'm wanting to use music from RSE (which is still in the FR ROM, but not even AdvanceMap knows how to view it) to make it more customized and unique, but The music is the only thing that doesn't work. I've got the script functioning - I got it imported and I get the Mew encounter, and even hacked the offset that makes Mew act like a teenager with his random naps, ignoring, and slapping himself for no reason not obey the player (I don't remember the thread or the offset, sorry :( ) and on top of that, edited the shiny spawn rate to make a shinyhunted mew reasonable for casual players, but I still can't make the music work. When I use the playsong command with a valid ID (I've tried both of the music pieces for Deoxys, I've tried Pallet Town's theme, I've tried all four generic encounter themes, etc.) it still uses the wild encounter music. I have not gotten it to play any other music. My current script uses Deoxys' theme and I even used a "special" command that people in this thread said should work. It didn't and it still uses the wild theme no matter what order I put things in relative to the playsong command, or what ID I put on it.

    Here's my current script, that I have in my ROM right now:

    Spoiler:


    Any ideas as to what dumb noob mistake I'm making? :P I'm honestly completely stuck here.
     
    Last edited:
    82
    Posts
    6
    Years
  • Could be wrong here but why not open the script that is run when you encounter mewtwo? You could theoretically copy the code, change a few things and be done?
     
    476
    Posts
    6
    Years
    • Seen Feb 26, 2020
    Could be wrong here but why not open the script that is run when you encounter mewtwo? You could theoretically copy the code, change a few things and be done?

    Yeah, I saw that as a suggestion with Mew's script in Emerald while looking for methods of customizing the music and making flags/pointers work...after I already got most of it working, and was able to make the actual battle work correctly. At the current moment all I have to do to get the script just as I want it is the music, but

    a) I just refuses to be different from the regular wild Pok?mon theme, even if I use something 100% random like the GB heal theme, it still uses the regular wild encounter music.
    b) I can't find the values for RSE music anywhere (as they are ID'd in FRLG) - no one has made a list showing all of FRLG's music yet. (There are a lot of claims, but they are only the FRLG stuff, they don't show the unused RSE music)
     
    476
    Posts
    6
    Years
    • Seen Feb 26, 2020
    So...apparently..."setwildbattle" DOES work...and is the command you need to make the custom music work...
     
    43
    Posts
    6
    Years
    • Seen Sep 23, 2023
    So...apparently..."setwildbattle" DOES work...and is the command you need to make the custom music work...



    Did you ever figure it out? I'm having the same problem but whatever I do, nothing works, the sprite never goes away.
     
    Last edited:
    476
    Posts
    6
    Years
    • Seen Feb 26, 2020
    Did you ever figure it out? I'm having the same problem but whatever I do, nothing works, the sprite never goes away.

    LMFAO! This isn't a script that is meant to make the NPC leave, as you can tell by the segment where you can talk to it after the battle lol
     
    Last edited:
    476
    Posts
    6
    Years
    • Seen Feb 26, 2020
    Thanks for the info! Here's the newest version of what I've come up with - purpose is the same (encountering Mew) but the order of the sections has been changed to try to resolve the double encounter glitch while taking the advice above into account:

    Code:
    '---------------
    #dynamic 0x800000
    #org @start
    lock
    faceplayer
    checkflag 0x1213
    if 0x1 goto @encountered
    cry 151 0x0
    msgbox @fight_me_bitch MSG_NORMAL '"Myuuu!!"
    special 138
    playsong 154 0x0
    setwildbattle 151 13 0xC8
    setflag 0x1213
    release
    end
    
    '---------
    ' Strings
    '---------
    #org @encountered
    = You've already earned my trust,\n[player]. No need for more fighting!
    
    #org @fight_me_bitch
    = Myuuu!!

    Edit: XSE keeps replacing the first MSG box with a "braille2" command, which crashes. Maybe don't replace my commands with different ones that crash? (yes I'm on the latest version)
     
    Last edited:
    476
    Posts
    6
    Years
    • Seen Feb 26, 2020
    I'm saying:

    special 138
    playsong 154 0x0
    setwildbattle 151 13 0xC8

    Isn't that going to make two battles happen because setwildbattle calls a wild battle? I don't know right off hand.

    Well, using the order of the commands that you suggested, using special 138, did fix the double encounter glitch, but trying to talk to the NPC after the battle still doesn't work...
     
    Back
    Top