• 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!
  • Dawn, Gloria, Juliana, or Summer - which Pokémon protagonist is your favorite? Let us know by voting in our poll!
  • 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.

[Other] Scripting Help

timaeus222

Music Composer, Mixing/Mastering Engineer
  • 56
    Posts
    14
    Years
    Scripting Help [has been solved]

    Never mind all this, delete this topic if desired. I finally figured it out! Who knew there was a "trainerflag" command?! :D

    I just used settrainerflag 0xXXX and checktrainerflag 0xXXX to do this script. :D

    Ended up looking like this:

    '---------------
    #org 0x76AA60
    lock
    faceplayer
    setvar LASTRESULT 0x1
    checktrainerflag 0x2EF
    compare LASTRESULT 0x1
    if 0x1 goto 0x876AC20
    msgbox 0x8762050 MSG_NORMAL '"Keep up the good work, trainer!"
    end

    '---------------
    #org 0x76AC20
    trainerbattle 0x0 0x2EF 0x0 0x876AB37 0x876AB9F
    msgbox 0x8762050 MSG_NORMAL '"Keep up the good work, trainer!"
    settrainerflag 0x2EF
    end


    '---------
    ' Strings
    '---------
    #org 0x762050
    = Keep up the good work, trainer!

    #org 0x76AB37
    = I see you want to battle\nme again!\pWell, your wish is granted!\nPrepare for a battle unlike\lmany others!

    #org 0x76AB9F
    = Wonderful job, [player]!\nYou're a very good trainer.\lKeep it up!
     
    Last edited:
    Back
    Top