• 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.
  • Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
  • 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

Status
Not open for further replies.
  • 34
    Posts
    17
    Years
    • Seen Oct 16, 2008
    I am attempting to write a script where the player walks up to a pokeball and get a message to choose the pokemon (if he/she wants), and if not, can go to one of the other pokeballs. Basically, I am attempting to write the script from the orignal game (like in fire red, where u can choose).

    I currently have:
    Code:
    #org $givedragon
    checkflag 0x830
    if B_true goto $donealready
    message $wantdragon
    $wantdragon 1 = Do you want the DRAGON pokemon ORMR?
    boxset 5
    compare LASTRESULT B_TRUE
    if B_False goto $dontwant
    jingle
    message $gotdragon
    $gotdragon 1 = You got the DRAGON pokemon ORMR!
    givepokemon 1 5 0x8
    setflag 0x830
    release
    end
    
    #org $dontwant
    release
    end
    
    #org $donealready
    release
    end

    The problems are:
    1) It does not play any sound (jingle)
    2) It gives you the pokemon regardless if you said yes or no
    3) It does not enable the pokemon menu (as flag 830 should do [or at least I think so])

    Any help is greatly appreciated.
     
    I am attempting to write a script where the player walks up to a pokeball and get a message to choose the pokemon (if he/she wants), and if not, can go to one of the other pokeballs. Basically, I am attempting to write the script from the orignal game (like in fire red, where u can choose).

    I currently have:
    Code:
    #org $givedragon
    checkflag 0x830
    if B_true goto $donealready
    message $wantdragon
    $wantdragon 1 = Do you want the DRAGON pokemon ORMR?
    boxset 5
    [B] compare LASTRESULT 1[/B]
    if B_False goto $dontwant
    jingle
    message $gotdragon
    $gotdragon 1 = You got the DRAGON pokemon ORMR!
    givepokemon 1 5 0x8
    setflag 0x830
    release
    end
    
    #org $dontwant
    release
    end
    
    #org $donealready
    release
    end
    The problems are:
    1) It does not play any sound (jingle)
    2) It gives you the pokemon regardless if you said yes or no
    3) It does not enable the pokemon menu (as flag 830 should do [or at least I think so])

    Any help is greatly appreciated.

    try that ...but im not too sure...i THINK that should fix it
     
    actually jingle isn't jingle. Kawa just messed up when naming some commands.
    Hackmew (I think it was him, not sure) did a rubikon.dat edit and named it "dontfaceplayer", which doesn't make much sense either.
    command 0x69 (which scripted calls jingle) closes previously opened messageboxes. Sometimes, if you don't use it and run the script while the location window (the map name when you enter a city, for example) is disappearing, the message is misplaced.
    about the rest... It's sunday, hangovers, etc, not in the mood to analyze the script
     
    actually jingle isn't jingle. Kawa just messed up when naming some commands.
    Hackmew (I think it was him, not sure) did a rubikon.dat edit and named it "dontfaceplayer", which doesn't make much sense either.
    command 0x69 (which scripted calls jingle) closes previously opened messageboxes. Sometimes, if you don't use it and run the script while the location window (the map name when you enter a city, for example) is disappearing, the message is misplaced.
    about the rest... It's sunday, hangovers, etc, not in the mood to analyze the script

    I heard that jingle isn't jingle either. I heard that it is a sprite lock. Instead of locking the hero, I was told that it locks the Ow, you'd talked to.

    And about the script, you use the wrong flag. 0x828, not 0x830.
    and when I script a boxset 5 in pokescript, I try to use
    compare LASTRESULT b_true
    if b_true goto $yes
    By using them as both b_true's it seems to work better with pokescript.
     
    hey, thanks for all your help. It worked. Now just to figure out how to get it to jingle...
     
    hey, thanks for all your help. It worked. Now just to figure out how to get it to jingle...
    the "jingle" is a fanfare. Just find the da-da-da-dam sound index. In fire red it's 0x101, dunno ruby, dunno which one are you using. (check in elitemap)
    Can also be inserted as a text command in the message, inserting the bytes FC 0B YY XX where XXYY is the song index. For example, in fire red, you can insert the sound 102 in a message inserting the bytes FC 0B 02 01.
     
    so what actual code would you put in? just like message FC 0B 02 01?
     
    I can help you with the pokemon menu and the regardless of if you say yes or no

    instead of compare LASTRESULT B_true put in compare LASTRESULT 1

    on the next line put if B_true goto $soandso

    its better somehow i don't know why

    as for the pokemon menu

    it's not 0x830 it's 0x828

    i hope this helps

    i'm not sure about the jingle though i'm just a basic scripter.
     
    Status
    Not open for further replies.
    Back
    Top