The PokéCommunity Forums

The PokéCommunity Forums (https://www.pokecommunity.com/index.php)
-   Binary ROM Hacking (https://www.pokecommunity.com/forumdisplay.php?f=284)
-   -   Script XSE: Error 9 on line 55 Subscript out of range (https://www.pokecommunity.com/showthread.php?t=398428)

PotatoJedi August 16th, 2017 5:14 AM

XSE: Error 9 on line 55 Subscript out of range
 
When I compiled my script for a squirtle starter it said Error 9 on line 55 Subscript out of range, even though I had only 34 lines. I am using wine, because I have a mac, and it has been working perfectly up until now. I have looked into it, and I did check the settings.ini and it said =0, here is the script:
Spoiler:

#dynamic 0x800000
#org @start

lock
checkflag 0x200
if 0x1 goto @done
msgbox @t1 0x5
compare 0x800D 0x1
if 0x1 goto @yes
compare 0x800D 0x1
if 0x0 goto @no
release
end


#org @yes
givepokemon 0x7 0x5 0x0 0x0 0x0 0x0
setflag 0x200
release
end

#org @no
= [blue_fr]Okay, Just click the\nnext pokeball to check out\lthat pokemon.
release
end


#org @done
msgbox @t2 0x6

#org @t2
= [black_fr]You canít take another!
release
end

#org @t1
= [black_fr]Choose [blue_fr]Squirtle[black_fr]?
release
end




If you know anything please tell me, thank you :)

Skeli August 16th, 2017 12:43 PM

I made some comments that might help you fix your problem.
Spoiler:
#dynamic 0x800000
#org @start

lock
checkflag 0x200
if 0x1 goto @done
msgbox @t1 0x5
compare 0x800D 0x1
if 0x1 goto @yes
compare 0x800D 0x0
if 0x1 goto @no //This should point to another snippet of code, not message data
release
end

#org @yes
givepokemon 0x7 0x5 0x0 0x0 0x0 0x0
setflag 0x200
release
end

#org @no
msgbox @nomessage 0x5
release
end

#org @done
msgbox @t2 0x6
release //add an end command
end


#org @t2
= [black_fr]You can't take another!
//release NOT NEEDED
//end NOT NEEDED


#org @t1
= [black_fr]Choose [blue_fr]Squirtle[black_fr]?
//release NOT NEEDED
//end NOT NEEDED


#org @nomessage
= [blue_fr]Okay, just click on the next Pok\e\nBall to check out that Pok\emon.


PotatoJedi August 17th, 2017 3:08 AM

Thank You so much!

PotatoJedi August 17th, 2017 3:09 AM

I accidentally disliked, sorry.


All times are GMT -8. The time now is 9:14 AM.


Like our Facebook Page Follow us on Twitter © 2002 - 2018 The PokéCommunity™, pokecommunity.com.
Pokémon characters and images belong to The Pokémon Company International and Nintendo. This website is in no way affiliated with or endorsed by Nintendo, Creatures, GAMEFREAK, The Pokémon Company or The Pokémon Company International. We just love Pokémon.
All forum styles, their images (unless noted otherwise) and site designs are © 2002 - 2016 The PokéCommunity / PokéCommunity.com.
PokéCommunity™ is a trademark of The PokéCommunity. All rights reserved. Sponsor advertisements do not imply our endorsement of that product or service. User generated content remains the property of its creator.

Acknowledgements
Use of PokéCommunity Assets
vB Optimise by DragonByte Technologies Ltd © 2023.