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

[Script] Subscript out of range XSE

  • 6
    Posts
    6
    Years
    • Seen Sep 17, 2020
    Hello, I'm pretty new to scripting and I'm trying to make a movement script.
    This is the script I made:

    #dynamic 0x801A00

    #org @start
    lock
    faceplayer
    applymovement 0x1 @towards
    waitmovement 0x0
    msgbox @rival 0x6
    applymovement 0x1 @away
    waitmovement 0x0
    hidesprite 0x1
    release
    end

    #org @towards
    #raw 0x11
    #raw 0x11
    #raw 0x11
    #raw 0x11
    #raw 0x11
    #raw 0x11
    #raw 0x3
    #raw 0xfe

    #org @rival
    = [player]!\pIt's finally time!\nTime to set of on our adventure!\pThanks to your dad we can go travel\nall around the Orre region!\pHe even arranged three special Pokemon we can\nchoose from to start of with on our adventure!\pCome on, let's hurry up to his lab!\nI can barely wait!

    #org @away
    #raw 0x1D
    #raw 0x1D
    #raw 0x20
    #raw 0x20
    #raw 0x20
    #raw 0x20
    #raw 0x20
    #raw 0x20
    #raw 0x20
    #raw 0xfe

    What it's supposed to do is have a NPC walk towards the player, say something, walk away, and disappear off screen, but when I try to compile it it says 'Subscript out of range on line 26'. I checked multiple times but I just can't seem to figure out what I did wrong. I'm not sure if I'm just doing it completely wrong or if I'm making a small mistake, but I can't seem to figure it out.
    Thanks in advance!
     
    Back
    Top