ctrulib get name and path of current 3dsx

Discussion in '3DS - Homebrew Development and Emulators' started by mashers, Oct 26, 2015.

  1. mashers
    OP

    mashers Stubborn ape

    Member
    3,837
    5,154
    Jun 10, 2015
    Kongo Jungle
    Is there any way for ctrulib to identify the name and full path of the currently running 3dsx? I want gridlauncher to be able to find its own executable on the SD card.
     
  2. daxtsu

    daxtsu GBAtemp Guru

    Member
    5,492
    3,878
    Jun 9, 2007
    Is it not argv[0]? Dunno if entrypoints bother setting up an initial argc/argv, though.
     
  3. TheCruel

    TheCruel Developer

    Banned
    1,351
    2,882
    Dec 6, 2013
    United States
  4. mashers
    OP

    mashers Stubborn ape

    Member
    3,837
    5,154
    Jun 10, 2015
    Kongo Jungle
    I don't know if the entry points set it up, but the hb launcher's main() doesn't specify any parameters so I assume none are passed.

    Thank you, I'll look at this :)
     
  5. daxtsu

    daxtsu GBAtemp Guru

    Member
    5,492
    3,878
    Jun 9, 2007
    I just tried it, and yeah, themehax at least doesn't seem to push any arguments to regular argv. I guess it makes sense, since a boot.3dsx wouldn't really need arguments in the first place. Maybe Cruel's idea will work.