• 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 Help Thread (DO NOT REQUEST SCRIPTS)

Status
Not open for further replies.

metapod23

Hardened Trainer
673
Posts
15
Years
    • Seen Aug 18, 2016
    Ok yea i saw that and fixed it since my last post, but im glad to say i now got the script to work where the trainer comes to me when i step on the script tile, he battles me but after he is supposed to say a line and walk away. He does not say anything and is just facing me, can't talk to him, only can walk away and back onto the script tile then he says see ya later and walks away..

    Is there anyway to fix this new problem....im almost there!


    My new script!
    Spoiler:


    Changes in bold. Use trainerbattle 0x3 to continue the script.

    Also, obviously if flag 0x1008 isn't set, the script will end abruptly after the trainer battle as well. I don't see the point for the flag at all, in fact, so I just removed it from the script all together.

    Are you using an older version of XSE? You shouldn't need to use any boxset commands with the latest version.
     

    ruup20

    Gonna splash everybody!
    118
    Posts
    13
    Years
  • #dynamic 0x800240
    #org @start
    lock
    msgbox @text1 0x5
    if 0x1 goto @fine
    if 0x0 goto @notfine
    release
    end

    #org @text1
    = Beep-beep!\nBeep-beep!\lIt's Ash.\lAsh: Hello [player]. How are\lyou doing?

    #org @fine
    = That's nice. I tought you\nwould be nervous. You get your\lfirst pokemon today. Isn't it?\lPlease chose wisely! My friend\lDawn is coming to help you to\lbecome a Pokemon trainer.\lJust like me. Bye-bye!

    #org @notfine
    = Oh. I think you are nervous.\nToday you get your first Pokemon.\lPlease choose wisely.My friend\lDawn is coming to help you to\lbecome a Pokemon trainer.\lJust like me. Bye-bye!


    What's wrong with this script? It freezes when I step on it.
     
    5,256
    Posts
    16
    Years
  • The script tile needs an unknown of 03 and a variable of 4050.
    Also, the script will read as:
    Beep-beep!
    Beep-beep!
    It's Ash.
    Ash: Hello [player]. How are you doing?

    YES/NO

    That doesn't make sense. Try to rephrase it to something like "Ash: Hello, [player]! How are you? Are you nervous for the big day?". Anyway yeah, unknown and var.
     

    ruup20

    Gonna splash everybody!
    118
    Posts
    13
    Years
  • Yes, but I have a tool to change the multichoises to Fine/Bad. Anyway thanks.

    Edit: It still doesn't work I set everything good.
     
    Last edited:

    [T]ouko

    Dedicated Scripter!
    46
    Posts
    12
    Years
    • Seen Jul 9, 2013
    #dynamic 0x800240
    #org @start
    lock
    msgbox @text1 0x5
    if 0x1 goto @fine
    if 0x0 goto @notfine
    release
    end

    #org @text1
    = Beep-beep!\nBeep-beep!\lIt's Ash.\lAsh: Hello [player]. How are\lyou doing?

    #org @fine
    = That's nice. I tought you\nwould be nervous. You get your\lfirst pokemon today. Isn't it?\lPlease chose wisely! My friend\lDawn is coming to help you to\lbecome a Pokemon trainer.\lJust like me. Bye-bye!

    #org @notfine
    = Oh. I think you are nervous.\nToday you get your first Pokemon.\lPlease choose wisely.My friend\lDawn is coming to help you to\lbecome a Pokemon trainer.\lJust like me. Bye-bye!


    What's wrong with this script? It freezes when I step on it.

    You forgot something.

    Msgbox @text 0x5
    Compare lastresult 0x1
    If 0x1 goto @fine
    And here you put what happens whn no is pressed. You don't need an extra line for if 0x0....

    You forgot the compare line, which compares the lastresult (yes if you pressed yes, no if not) witn 0x1. If it is 0x1, meaning you pressed yes, it will go to fine. If not it will continue.
     

    RedFan

    Master Trainer
    48
    Posts
    13
    Years
  • Jeez, ive got a problem with a trigger script in XSE
    When i trigger the script i want to use showsprite for person number 11 (B in hex).
    But, for some reason when i compile the script and open it up again my command Changes.
    I compiled it as

    showsprite 0x0B

    and it changes to

    showsprite 0xB

    Anyone help? :/
     

    Christopher D.

    → Espoinage!
    9
    Posts
    13
    Years
    • Seen Jan 30, 2012
    Jeez, ive got a problem with a trigger script in XSE
    When i trigger the script i want to use showsprite for person number 11 (B in hex).
    But, for some reason when i compile the script and open it up again my command Changes.
    I compiled it as

    showsprite 0x0B

    and it changes to

    showsprite 0xB

    Anyone help? :/

    I'm positive 0x0B is the same as 0xB, just as 0x01 the same as 0x1.
     
    16
    Posts
    13
    Years
    • Seen Aug 7, 2016
    Pokemon Center

    Hello.
    Simply put, I need help with a Pokemon Center script.
    I'm using FireRed for the rom and XSE for my scripts.
    I have two questions, the first one being more important than the second.

    Here's the situation:
    I am trying to make the hero go to a Pokemon healing location every single time they white out from a trainer battle or wild-battle.
    My game is centered around a single map, so technically, I only wish to use 1 or 2 healing places.

    My problems arise from reasons I cannot find solutions for on the Internet:

    Problem 1. The level scripts have me confused when setting the healing place.
    Bear in mind that I have a rough understanding on how level scripts work.
    I wouldn't be surprised if this was my source of error.
    For one map, I placed these 2 level scripts:
    Spoiler:

    The player walks through that map first.
    He/She then takes the stairs (warp) down a level into another map with these 2 level scripts:
    Spoiler:

    I should mention that I am certain that I have the correct script type in A-Map.
    The script at 0x1BC05C is categorized as "On entering map/on menu close"
    The script at the other place is categorized as "on entering map/not on menu close"

    It is in this map (the second one) where I have my "Pokemon Center."
    However, it is not the same layout as the original one; the map is expanded and Nurse Joy is moved to another location.

    The main problem arises when I go to another map and "white-out."
    Instead of returning to the Pokemon Center (as described above), I end up at a glitched location.
    At the glitched location, the automatic healing begins and ends, with a messed up healing screen (the TV) and no pokeballs showing up in the invisible machine.
    I have yet to find the particular map that I end up in after whiting out (just my luck: there isn't a warp to take).

    I have no clue how to fix this
    :|

    Problem 2. The location of "Nurse Joy" and her healing script is not in the exact position as the original "Pokemon Center." Rather, I have created a new map and placed "Nurse Joy" in another location.
    I notice that when I manually go to heal my Pokemon (so, when I go heal without whiting out), the television icon in the back does not fully light up (only the bottom half does) and the Pokeball icon does not show.
    Perhaps this problem is caused by me moving Nurse Joy to another location?

    I honestly have searched through the simple help thread and this thread, but the things I've found have not helped me fully.
    Yes, I've used the search function, but that didn't help much.
    I am still a "noobie" at this stuff, so likewise, I am not surprised that such error showed up.

    Any help is greatly appreciated.
    I am willing, wholeheartedly, to listen to any advice from the more experienced people on this forum.
    Thank you for taking the time to read all this, and hopefully, responding with helpful advice.
     

    marcc5m

    what
    1,116
    Posts
    13
    Years
  • Spoiler:


    Basically, if flag 0x4013 hasn't been set, it freezes.
    It's a level script for Ruby btw.
    Oh and the running shoes also won't work.
     
    8
    Posts
    12
    Years
  • Somebody gave me a script they used to get the National dex.

    Spoiler:


    Problem is that once I got this script I wasn't sure what to do with it even when I read many tutorials repeatedly.

    I opened up AdvanceMap and have XSE as the default script program for it. I proceeded to try and paste this into Prof Oak's preexisting scripts to get the National dex right after he gives you the Pokedex. That didn't work.

    Then I tried to create a new script event for the lab so I could get the pokedex, and I got stuck because I have no idea what to do.

    I feel like I missed something. Do I need previous experience in coding/programming to do scripting? I feel hugely overwhelmed even only using a premade script given to me.
     
    5
    Posts
    14
    Years
    • Seen Dec 14, 2012
    Hi, I have this script:

    #dynamic 0xf00000
    #org @start
    lock
    faceplayer
    msgbox @1 0x6
    cry 0x6 0x0
    wildbattle 0xf5 0x19 0x8B
    fadescreen 0x1
    fadescreen 0x0
    hidesprite 0x800F
    setflag 0x200
    release
    end

    #org @1
    = Suiiii!

    There's no problem with this script, but I just wanna know how we can do to put the lugia music battle when the battle is beginning...?
    Thanks :)
     

    Kevin

    kevin del rey
    2,686
    Posts
    13
    Years
  • Somebody gave me a script they used to get the National dex.

    Spoiler:


    Problem is that once I got this script I wasn't sure what to do with it even when I read many tutorials repeatedly.

    I opened up AdvanceMap and have XSE as the default script program for it. I proceeded to try and paste this into Prof Oak's preexisting scripts to get the National dex right after he gives you the Pokedex. That didn't work.

    Then I tried to create a new script event for the lab so I could get the pokedex, and I got stuck because I have no idea what to do.

    I feel like I missed something. Do I need previous experience in coding/programming to do scripting? I feel hugely overwhelmed even only using a premade script given to me.
    If you inserted the script after the script when Prof. Oak gives you the Pokedex it probably didn't work since this script required you to talk to the person (which is why it has lock and faceplayer).

    I suggest you make a totally new script for this, since copying + pasting this script in won't work as smoothly than creating a new script. Check out some scripting tutorials (preferably diegoisawesome's tutorial).

    Hi, I have this script:

    #dynamic 0xf00000
    #org @start
    lock
    faceplayer
    msgbox @1 0x6
    cry 0x6 0x0
    wildbattle 0xf5 0x19 0x8B
    fadescreen 0x1
    fadescreen 0x0
    hidesprite 0x800F
    setflag 0x200
    release
    end

    #org @1
    = Suiiii!

    There's no problem with this script, but I just wanna know how we can do to put the lugia music battle when the battle is beginning...?
    Thanks :)
    You'd need to know ASM if I'm correct.
     
    63
    Posts
    14
    Years
  • #dynamic 0x800200
    #org @start
    checkflag 0x828
    if 0x1 goto @done
    applymovement 0x02 @move1
    waitmovement 0x2
    applymovement 0x03 @move2
    waitmovement 0x3
    msgbox @1 0x6
    applymovement 0x04 @move3
    waitmovement 0x04
    msgbox @2 0x6
    applymovement 0x06 @move4
    waitmovement 0x06
    msgbox @3 0x6
    fadescreen 0x1
    warp 0x3 0x1 0x0 0x6 0x9
    release
    end

    #org @done
    release
    end

    #org @move
    #raw 0x60

    #org @move2
    #raw 0x60
    #raw 0x61
    #raw 0x60
    #raw 0x61
    #raw 0x60
    #raw 0x61
    #raw 0x60
    #raw 0x61
    #raw 0x60
    #raw 0x61
    #raw 0x60
    #raw 0x61
    #raw 0xFE

    #org @1
    (HERE)=???:Pardon me. You wouldn't\nhappen to know where I could find\lLANCE the DRAGON master, would\lyou?\p\v\h01: …Dad? Can you come\noutside\lplease?\p???: Erm, that won't be\nnecessary. All I need is too…

    #org @move3
    #raw 0x65

    #org @2
    = LANCE: DOCTOR…!\p\v\h01: DOCTOR? Doctor who?\pLANCE: I'll explain later.\pDR.: Actually, I think I ought to\nexplain myself. Now, what is your\lname?\p\v\h01: \v\h01, Mr.-- Erm, DR.\nDR.: Excellent. And your father\lis LANCE?\p\v\h01: Well, yeah.\nDR.: Is that so? Well, you see,\lyour father and I met quite a\lwhile ago, back before he even\ljoined the Elite Four, and,\llogically, before you were born.\lI found him while he was training\lto take on the PKMN League, and\ltook him under my wing as we\ljoined to defeat Team Glacier,\lwho aimed to freeze the planet of\lBarcelona. All of that practice\lagainst Ice, his sole weakness,\lhelped him to dominate the\lLeague, which is why he's who he\lis now. That was a pretty crazy\ladventure, was it not?\pLANCE: It certainly was, but\nthat's not why you're here, is it?

    #org @3
    = DR.: …No, it's not. There is a\nsinister team that I am tracking\ldown that goes by the name of\lRagnarok. They've been working on\la highly secretive plan for\lyears, and I've been tracking\lthem.\pLANCE: How secretive?\pDR.: Did you know they existed\nuntil now?\pLANCE: No Idea.\pDR.: Then you probably don't know\nthat they caused the premature\leruption of Cinnibar Island's\lvolcano, and used high-pitch\lfrequency airwaves to drive the\lGyarados, who protect the region,\lto flood the Power Plant, cutting\loff the power to the entire\lregion, allowing them to bring it\lunder its control.\pLANCE: …WHAT!?\p\v\h01: We can't let that happen!\pDR.: No, we cannot. But while it\nseems that they are just aiming\lfor world domination, there\lexists an ulterior motive. Are\lyou aware of MEWTWO?\l\v\h01: I've heard legends of it,\lbut I'm not too familiar\lotherwise…\pDR.: It's not a legend. It\nexists. And everything they've\ldone is leading up to it. But for\lnow, that's more or less\lirrelevant. What's important now\lis that we stop them from\lcompleting the preliminary stage\lof their plot.\pLANCE: Right. What's your plan,\nDOCTOR?\pDR.: As it happens, I was hoping\nyou'd have a child. This time, I\lneed \v\h01's help.\pLANCE: Hold on a minute, \v\h01-\nhasn't got a PKMN. I'm not certain\lI want to let you pull \v\h01 into\lthis if it's truly as bad as it\lsound, which it likely does.\pDR.: Nonsense! Really, the\nconditions could not be more\lperfect for \v\h01. You know, you\lweren't that much older than him\lwhen I met you.\pLANCE: I was 19. \v\h01's just not\n16. It was a foolish idea for me\lto go along with you that\lhappened to turn out perfectly,\lbut I can't trust things to be so\lperfect twice in a row, and I\ldon't think you can guarantee\lthat nothing will happen to\l\v\h01.\pDR.: Now, really, LANCE. You're\nhurting my feelings! Do you\lreally think I would ever let\lanything happen to \v\h01? Things\lturned out well for you because I\lwas with you every step of the\lway. How can you expect me to do\lany less for \v\h01?\pLANCE: …I don't know, DOCTOR.\n\v\h01: I do.\pLANCE: \v\h01?\p\v\h01: If this guy's the reason\nyou became a Master and a\lChampion, then I want to go with\lhim, too. Besides, it can't be\lthat hard, can it?\pLANCE: (sigh)… Neither of you are\ngoing to let up about this, are\lyou?\p\v\h01: Nope.\nDR.: Not as long as the world is\lin danger.\pLANCE: …Alright. But, \v\h01, I\nneed you go talk to your mother\labout this. DOCTOR, would you\lmind coming in as well?\pDR.: Not at all, old friend. Not\nat all.

    When ever i compile the script it says "Error 9 subscript out of rage on line 44" at the (HERE) part can anyone tell me whats wrong!
     

    masterquestmq

    Enthusiastic Rom Hacker
    194
    Posts
    13
    Years
    • Seen Nov 19, 2023
    Well it seems right, some changes made in italic

    if it still dosent work i made an alternative script below


    #dynamic 0x800200
    #org @start
    checkflag 0x828
    if 0x1 goto @done
    applymovement 0x02 @move1
    waitmovement 0x2
    applymovement 0x03 @move2
    waitmovement 0x3
    msgbox @1 0x6
    applymovement 0x04 @move3
    waitmovement 0x04
    msgbox @2 0x6
    applymovement 0x06 @move4
    waitmovement 0x06
    msgbox @3 0x6
    fadescreen 0x1
    warp 0x3 0x1 0x0 0x6 0x9
    release
    end

    #org @done
    release
    end

    #org @move
    #raw 0x60
    #raw 0xFE
    #org @move2
    #raw 0x60
    #raw 0x61
    #raw 0x60
    #raw 0x61
    #raw 0x60
    #raw 0x61
    #raw 0x60
    #raw 0x61
    #raw 0x60
    #raw 0x61
    #raw 0x60
    #raw 0x61
    #raw 0xFE

    #org @1
    (HERE)=???:Pardon me. You wouldn't\nhappen to know where I could find\lLANCE the DRAGON master, would\lyou?\p\v\h01: …Dad? Can you come\noutside\lplease?\p???: Erm, that won't be\nnecessary. All I need is too…

    #org @move3
    #raw 0x65
    #raw 0xFE

    #org @2
    = (TOO LONG TEXT)(break it up into more talking scripts i.e @4 @5 @6 etc)

    When ever i compile the script it says "Error 9 subscript out of rage on line 44" at the (HERE) part can anyone tell me whats wrong!


    alternative script

    #org @start
    checkflag 0x828
    if 0x0 got @play
    if 0x1 goto @done

    org @play
    applymovement 0x02 @move1
    waitmovement 0x2
    applymovement 0x03 @move2
    waitmovement 0x3
    msgbox @1 0x6
    applymovement 0x04 @move3
    waitmovement 0x04
    msgbox @2 0x6
    applymovement 0x06 @move4
    waitmovement 0x06
    msgbox @3 0x6
    fadescreen 0x1
    warp 0x3 0x1 0x0 0x6 0x9
    release
    end

    #org @done
    release
    end


    and continue the rest of the script
    p.s. check your applymovement scripts some of them are missing raw 0xFE u dont put this in the script will go wrong.


    good luck
     

    cheshirecat

    A Tad Insane
    4
    Posts
    12
    Years
  • Would love some help with this script!

    Hi everyone, I've been playing with this script for a little while and it's almost there but it needs to work out a few bugs.

    The script should progress like this:
    (Talk to man)
    Man: ...... ..... ..........
    Man: Get out of Here!
    Screen Fades to Black
    Man: Your journey ends.
    Game restarts and dumps save data.

    What the script is currently doing is:
    Man: .... .... ...... (working fine)
    Fades to Black (Out of order)
    Man: Get out of here! (Should be before the fade)
    NOT saying "Your journey ends"
    restarting the game (no save dump - I know this is not the correct cmd to dump the save data, is there one?)

    Here's the actual script I have:
    Code:
    #org 0x8804000
    '-----------------------------------
    lock
    faceplayer
    msgbox 0x8804023 ' ......\n.........\l....
    callstd MSG_LOCK ' Built-in lock command
    msgbox 0x8804043 ' get out of here!
    fadescreen FADEOUT_BLACK
    callstd MSG_LOCK ' Built-in lock command
    msgbox 0x8804058 ' Your journey ends.
    special 0x10F
    end
    
    
    #org 0x8804023
    = ......\n.........\l.....
    
    #org 0x8804043
    = Get out of here!\nWhile you still can!
    
    #org 0x8804058
    = Your journey ends.

    Thanks for any and all help on this!
     
    Status
    Not open for further replies.
    Back
    Top