• 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.
  • Our friends from the Johto Times are hosting a favorite Pokémon poll - and we'd love for you to participate! Click here for information on how to vote for your favorites!
  • Serena, Kris, Dawn, Red - which Pokémon protagonist is your favorite? Let us know by voting in our grand final favorite protagonist 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.

Multichoice List that contains a variable number of selections? (pokeemerald)

  • 17
    Posts
    3
    Years
    • Seen Dec 14, 2022
    So I'm in the process of making the scientist in Devon Corp that revives the fossil you pick up in Mirage Tower be able to revive any fossil from Gens 1-6 (since the gen 8 fossils are acquired differently). I noticed there was a map script in the base game that accounted for the situation where you bring both fossils to him, and it calls a multichoicelist that lets you choose which one you want to revive. However, since multichoicelists are a predefined structure, if I were to go about this the traditional way I would have to make 2048 different multichoice lists to account for every combination of fossils you could bring to him (which obviously isn't feasible). Is there a way to create a single multichoice list that checks which fossils you have, and then presents you with those options as a multichoicelist? Or do I have to solve this problem another way (like just picking the first one in the bag or something). I'm still kinda a novice at scripting, so any help is appreciated
     
    So I'm in the process of making the scientist in Devon Corp that revives the fossil you pick up in Mirage Tower be able to revive any fossil from Gens 1-6 (since the gen 8 fossils are acquired differently). I noticed there was a map script in the base game that accounted for the situation where you bring both fossils to him, and it calls a multichoicelist that lets you choose which one you want to revive. However, since multichoicelists are a predefined structure, if I were to go about this the traditional way I would have to make 2048 different multichoice lists to account for every combination of fossils you could bring to him (which obviously isn't feasible). Is there a way to create a single multichoice list that checks which fossils you have, and then presents you with those options as a multichoicelist? Or do I have to solve this problem another way (like just picking the first one in the bag or something). I'm still kinda a novice at scripting, so any help is appreciated
    If you want to do something like this in a smooth manner, you'll probably have to dive into C code.
    I wanted to do something like this with a multichoice that listed options dynamically, but that didn't go well for me.
    If you're interested enough, Emerald has one instance of a multichoice that is filled dynamically; the ship at Lilycove City. You could probably use that as a reference.
    Check out the ScriptMenu_CreateLilycoveSSTidalMultichoice and GetLilycoveSSTidalSelection functions in src/script_menu.c for more info.
     
    Back
    Top