WiiFlow stub question

Discussion in 'Wii - Backup Loaders' started by fledge68, Apr 6, 2016.

  1. fledge68
    OP

    fledge68 GBAtemp Advanced Fan

    Member
    972
    529
    Jan 30, 2012
    United States
    Question for fellow Devs or anyone else who would know.
    so i was looking at the code for the wiiflow stub found here - https://github.com/FIX94/open-wiiflow-mod/tree/WiiFlowStub
    and was wondering in main.c if i change this line

    #define TITLE_UPPER 0x57494948 (WIIH)

    to some other channel ID then when apps or emus exit they will launch that channel?
    or do i have to change more than just that line?

    and what is this line for

    #define TITLE_LOWER 0x00010008
     
  2. GreyWolf

    GreyWolf GBAtemp Psycho!

    Member
    4,281
    823
    Mar 2, 2015
    United States
    The TITLE_UPPER value is the channel's title ID and the TITLE_LOWER is the channel type. The data for it would go in nand://title/00010008/057494948 and nand://ticket/00010008/057494948. 00010008 is hidden channels. They don't appear on the system menu.

    If you change the title ID and recompile it then WiiFlow will attempt to set the returnto address to WIIH but since it has a different value you'll either get a crash or return to the system menu when a title tries to go back to the loader.
     
  3. fledge68
    OP

    fledge68 GBAtemp Advanced Fan

    Member
    972
    529
    Jan 30, 2012
    United States
    Thanks for replying. After examining wiiflow code i found that wiiflow puts that stub in memory and then when it launches a app or emu plugin and when you decide to exit that app or emu plugin it thinks its using the HBC stub to return to the homebrew channel but instead it uses the wiiflow stub which launches the hidden channel WIIH which is basically a forwarder with the argument "EMULATOR_MAGIC" set which wiiflow detects but does nothing with it. i thought Wii and nand games use the cios to set the return to channel.

    i wanted to use wiiflow stub and mod it to launch my own forwarder that isn't hidden.
     
  4. GreyWolf

    GreyWolf GBAtemp Psycho!

    Member
    4,281
    823
    Mar 2, 2015
    United States